- added a usage-screen and a system-type check
This commit is contained in:
parent
0b1163c4c3
commit
d403ceb52e
|
@ -321,9 +321,20 @@ Please choose a password with at least 2 character classes.")
|
||||||
(else
|
(else
|
||||||
(lp pw))))))))
|
(lp pw))))))))
|
||||||
|
|
||||||
|
(define (display-usage)
|
||||||
|
(display "Usage: passwd-wrapper.scm\n")
|
||||||
|
(display "Change NIS, Kerberos IV and Kerberos V passwords at once.\n")
|
||||||
|
(display "Written by David Frese.\n"))
|
||||||
|
|
||||||
(define (main args)
|
(define (main args)
|
||||||
(let ((old-pw (ask/check-old-password))
|
(if (null? (cdr args))
|
||||||
(new-pw (ask-new-password)))
|
(case system-type
|
||||||
(if (change-all-passwords old-pw new-pw)
|
((freebsd solaris)
|
||||||
(display "Password changed.\n")
|
(let ((old-pw (ask/check-old-password))
|
||||||
(display "Password could not be changed.\n"))))
|
(new-pw (ask-new-password)))
|
||||||
|
(if (change-all-passwords old-pw new-pw)
|
||||||
|
(display "Password changed.\n")
|
||||||
|
(display "Password could not be changed.\n"))))
|
||||||
|
(else
|
||||||
|
(raise-unsupported-machine)))
|
||||||
|
(display-usage)))
|
||||||
|
|
Loading…
Reference in New Issue