Results 1 to 4 of 4
  1. #1
    Join Date
    Aug 2008
    Location
    The Midwest
    Posts
    11
    Plugin Contributions
    0

    Default Why is the admin password length limited to 40 characters?

    I'm attempting to update a site to Zen-Cart 1.5.5f. I was having trouble logging in to the admin section on the upgraded site, and I discovered that the password field has a `maxlength=40` attribute.

    I typically use 64 character passwords. I removed the `maxlength=40` attribute and my long password works fine. Is there a practical reason for the limit?

  2. #2
    Join Date
    Jul 2012
    Posts
    16,732
    Plugin Contributions
    17

    Default Re: Why is the admin password length limited to 40 characters?

    Certainly have me intrigued about the reason, though for some reason I have a suspicion that at one point that was possibly the longest password that could be processed to give a result that fit within the database field length. Meaning, anything longer than that might have allowed variation on the actually input password to provide a successful entry. Ie. Pwd1 or Pwd2 could be entered to gain entry. Could be complete hogwash, but mentally that's a possibility...
    ZC Installation/Maintenance Support <- Site
    Contribution for contributions welcome...

  3. #3
    Join Date
    Jan 2004
    Posts
    66,373
    Blog Entries
    7
    Plugin Contributions
    274

    Default Re: Why is the admin password length limited to 40 characters?

    I'm pretty sure it's a leftover legacy thing that needs cleaning up.
    Unlike other fields where the number of allowed characters is matched roughly with the limit that the database can store (so the user can't unwittingly submit data that gets chopped off), password hashes are handled differently so there's no correlation there.
    .

    Zen Cart - putting the dream of business ownership within reach of anyone!
    Donate to: DrByte directly or to the Zen Cart team as a whole

    Remember: Any code suggestions you see here are merely suggestions. You assume full responsibility for your use of any such suggestions, including any impact ANY alterations you make to your site may have on your PCI compliance.
    Furthermore, any advice you see here about PCI matters is merely an opinion, and should not be relied upon as "official". Official PCI information should be obtained from the PCI Security Council directly or from one of their authorized Assessors.

  4. #4
    Join Date
    Jul 2012
    Posts
    16,732
    Plugin Contributions
    17

    Default Re: Why is the admin password length limited to 40 characters?

    Quote Originally Posted by DrByte View Post
    I'm pretty sure it's a leftover legacy thing that needs cleaning up.
    Unlike other fields where the number of allowed characters is matched roughly with the limit that the database can store (so the user can't unwittingly submit data that gets chopped off), password hashes are handled differently so there's no correlation there.
    Thanks for that explanation of the likely source of the 40 characters. Certainly at one point even considering a password of 40 characters in length was unusual. :)
    ZC Installation/Maintenance Support <- Site
    Contribution for contributions welcome...

 

 

Similar Threads

  1. v139a the length of the product name gets limited to 10 symbols when in Russian language...
    By Yaro in forum Templates, Stylesheets, Page Layout
    Replies: 2
    Last Post: 19 May 2012, 06:33 PM
  2. Replies: 2
    Last Post: 28 Jul 2011, 09:23 PM
  3. text Field attributes with limited characters
    By ReneeN in forum Setting Up Categories, Products, Attributes
    Replies: 1
    Last Post: 3 Mar 2010, 10:40 PM
  4. why the contents is not limited inside the border
    By eaglewu in forum Templates, Stylesheets, Page Layout
    Replies: 2
    Last Post: 8 Jan 2007, 04:08 PM

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
disjunctive-egg
Zen-Cart, Internet Selling Services, Klamath Falls, OR