2013-04-05 2 views
0

일반적으로 chpasswd는 사용자 비밀번호 설정에 훌륭한 역할을합니다.bash : 루트 권한없이 내 비밀번호 변경

비 특권 사용자가 자신의 암호를 변경할 수있는 방법이 있습니까?

나는 이것을 위해 gtk 프런트 엔드를 작성하는 데 관심이 있으며, 사용자의 이전 암호도 필요하면 최상일 것입니다. 이 물론

$command 
$enter:oldpass 
$enter:newpass 
password updated 

답변

6

을 찾고


Change $user password? 

     Old password [   ] 

     new password [   ] 
new password again [   ] 

[cancel]    [apply] 

, 여기 linux

에서 암호의 튜토리얼과 솔루션은

Task: Set or Change User Password 

Type passwd command as follows to change your own password: 
$ passwd 
Output: 

Changing password for vivek 
(current) UNIX password: 
Enter new UNIX password: 
Retype new UNIX password: 
passwd: password updated successfully 

The user is first prompted for his/her old password, if one is present. This password is then encrypted and compared against the stored password. The user has only one chance to enter the correct password. The super user is permitted to bypass this step so that forgotten passwords may be changed. 

A new password is tested for complexity. As a general guideline, passwords should consist of 6 to 8 characters including one or more from each of following sets: 

    Lower case alphabetics 
    Upper case alphabetics 
    Digits 0 thru 9 
    Punctuation marks 
입니다3210
+0

감사합니다. chpasswd가 루트로만 사용될 수 있다는 것을 깨달을 때 알아 내려고했습니다. – user2225483

관련 문제