X-Git-Url: http://www.project-moonshot.org/gitweb/?a=blobdiff_plain;f=scripts%2Fcryptpasswd.in;h=dbc0f4f5c52fc88d0c5dd8379571892be3c765ed;hb=HEAD;hp=e9388ad858ff9cca9861c703dd5ffa10a48a5a34;hpb=8a30e2a06e505ca6fbad1b53e2b686ebfc85abe2;p=freeradius.git diff --git a/scripts/cryptpasswd.in b/scripts/cryptpasswd.in index e9388ad..dbc0f4f 100755 --- a/scripts/cryptpasswd.in +++ b/scripts/cryptpasswd.in @@ -14,7 +14,7 @@ # # You should have received a copy of the GNU General Public License # along with this program; if not, write to the Free Software -# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA +# Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA # # Copyright (C) 2001 The FreeRADIUS Project http://www.freeradius.org # @@ -34,7 +34,10 @@ sub check_md5 { } sub usage { - die "Usage: cryptpasswd [--des|--md5|--check] plaintext_password [crypted_password]\n"; + $name = $0; + $name =~ s,.*/,,; + + die "Usage: $name [--des|--md5|--check] plaintext_password [crypted_password]\n"; } @saltc = ( '.', '/', '0'..'9', 'A'..'Z', 'a'..'z' ); @@ -59,7 +62,7 @@ sub main { } } - usage() unless ($opt_des || $opt_md5); + $opt_des = 1 unless ($opt_des || $opt_md5); usage() unless ($#ARGV == 0); die "DES password hashing not available\n"