I am not sure if it's just me, but I'd be frightened if I knew my username and password were recorded in nothing more than a user=pass text file. It doesn't even sound like the user is encrypting this information. Instead of reading from and writing to a file, wouldn't it be easier if the user used a flat file database like SDBM or DB_File? It would make it a lot easier to sort by username or password or even search for them by one or the other; not to mention make it a million times easier to change a user=pass by updating the $user{'newpass'];.

I could be wrong, but this was my first thoughts when reading what the original poster asked and wondering why none of the rest of you have mentioned this.

"Age is nothing more than an inaccurate number bestowed upon us at birth as just another means for others to judge and classify us"

sulfericacid


In reply to Re: changing password by sulfericacid
in thread changing password by bory

Title:
Use:  <p> text here (a paragraph) </p>
and:  <code> code here </code>
to format your post, it's "PerlMonks-approved HTML":



  • Posts are HTML formatted. Put <p> </p> tags around your paragraphs. Put <code> </code> tags around your code and data!
  • Titles consisting of a single word are discouraged, and in most cases are disallowed outright.
  • Read Where should I post X? if you're not absolutely sure you're posting in the right place.
  • Please read these before you post! —
  • Posts may use any of the Perl Monks Approved HTML tags:
    a, abbr, b, big, blockquote, br, caption, center, col, colgroup, dd, del, details, div, dl, dt, em, font, h1, h2, h3, h4, h5, h6, hr, i, ins, li, ol, p, pre, readmore, small, span, spoiler, strike, strong, sub, summary, sup, table, tbody, td, tfoot, th, thead, tr, tt, u, ul, wbr
  • You may need to use entities for some characters, as follows. (Exception: Within code tags, you can put the characters literally.)
            For:     Use:
    & &amp;
    < &lt;
    > &gt;
    [ &#91;
    ] &#93;
  • Link using PerlMonks shortcuts! What shortcuts can I use for linking?
  • See Writeup Formatting Tips and other pages linked from there for more info.