1. No Profile Picture
    Junior Member
    Devshed Newbie (0 - 499 posts)

    Join Date
    Jul 2000
    Falun, Sweden
    Rep Power
    I am trying to solve this problem I had for a while, but can't find any useful info anywhere.

    I am running/helping with several websites using the .htpasswd for user-access.

    I recently got a huge ASCII-file with usernames/passwords, looking like this:

    --- CUT ---
    --- CUT ---

    And this goes on for about 12Kb, so You can imagine, it's not a fun thing to type in to htpasswd. :-)

    What I need is some sort of encryption-program for either Mac (OS7.1 or lower) or Win98 that I can just run this little text-file through, and get an complete encrypted (of the passwords only of course) version of it on "the other side".

    I do *not* want a perl-script or any script I have to run on the UNIX-machine, since the only UNIX-machine I have telnet-access to doesn't have Perl installed (please don't ask me about this - it's a Swedish provider, and I've been trying to solve this... )

    I am very happy for any help in this matter!

    Thank You!

    / Pingo - www.penguinfilms.com
  2. #2
  3. No Profile Picture
    Devshed Newbie (0 - 499 posts)
    >>I do *not* want a perl-script or any script I have to run on the UNIX-machine

    You have no choice!

    >>I've been trying to solve this

    Open an account at http://www.hypermart.net (free) just to run this script once.


    $ascii_file = "/path/to/password.txt";
    $htpasswd_file = "/path/to/.htpasswd"; #chmod666

    @lines = <ASCII>;
    foreach $line (@lines) {
    chomp $line;
    ($username,$password) = split(/,/,$line);
    $salt = substr($username,0,2);
    $encrypted_password = crypt($password,$salt);
    print HTPASSWD "$username:$encrypted_passwordn";
    print "Content-type: text/htmlnn";
    print "Done!n";
  4. #3
  5. No Profile Picture
    Devshed Newbie (0 - 499 posts)
    or just download activeperl and run the script on your own system

    ... or send the file to me and i'll do it for you and send the new file with encrypted passwords back to you

IMN logo majestic logo threadwatch logo seochat tools logo