Results 1 to 3 of 3

Thread: Error with "Add/edit user"

  1. #1
    dianelane is offline Member
    Join Date
    Jan 2007
    Posts
    8

    Default Error with "Add/edit user"

    Windows XP-SP2, Apache 2.2.4, PHP 5.2.2, MySQL 5.1.19
    OpenSugar 4.5.1d

    Add/edit an user seems not to work. Here following the content of USER table:

    "1";"admin";"0100da88e55a2e06da50346a1b09d704";NUL L;"1";NULL;"Administrator";NULL;"1";"1";NULL;"20 07-06-12 15:32:34";"2007-06-12 15:32:34";"1";NULL;"Administrator";NULL;NULL;NULL; NULL;NULL;NULL;NULL;NULL;"Active";NULL;NULL;NULL;N ULL;NULL;NULL;"0";"0";NULL;NULL;NULL;"0"

    "2";"pmoro";"0100da88e55a2e06da50346a1b09d704";NUL L;"1";"Pietro";"Moro";NULL;"1";"1";NULL;"2007-06-12 15:35:07";"2007-06-12 15:35:07";"1";"1";NULL;NULL;NULL;NULL;NULL;NULL;NU LL;NULL;NULL;"Active";NULL;NULL;NULL;NULL;NULL;NUL L;"0";"0";"Active";NULL;NULL;"0"

    "3";"kcleris";"0100da88e55a2e06da50346a1b09d704";N ULL;"1";"Katia";"Cleris";NULL;"1";"1";NULL;"2007-06-12 16:10:51";"2007-06-12 16:10:51";"1";"1";NULL;NULL;NULL;NULL;NULL;NULL;NU LL;NULL;NULL;"Active";NULL;NULL;NULL;NULL;NULL;NUL L;"0";"0";"Active";NULL;NULL;"0"

    "91746381-45b9-630f-79d5-46711843fb84";"newUser";NULL;NULL;"1";"user";"User";NULL;"1";"1";NULL;"2007-06-14 10:30:08";"2007-06-14 10:30:08";"2";"2";NULL;"Dept";NULL;NULL;NULL;NULL; NULL;"user@example.com";NULL;"Active";NULL;NULL;NU LL;NULL;NULL;NULL;"0";"0";"Active";NULL;NULL;"0"


    a) for a "newUser" (item 4) Sugar records a strange ID, and not the password
    b) I have modified by hand the ID and password for pmoro and kCleris
    c) I have tried to edit the password for kCleris (item 3) via Sugar, but no change has been made

    Thank you for help
    Last edited by dianelane; 2007-06-15 at 09:31 PM.

  2. #2
    Angel's Avatar
    Angel is offline Sugar Community Member
    Join Date
    Jul 2005
    Location
    Los Angeles
    Posts
    4,813

    Default Re: Error with "Add/edit user"

    I am not sure I understand what the problem is as you haven't illustrated it, but hopefully some of my answers will help you.

    Quote Originally Posted by dianelane
    a) for a "newUser" (item 4) Sugar records a strange ID, and not the password
    Sugar doesn't store passwords. It stores an MD5 hash, or encrypted, representation of the password.

    Quote Originally Posted by dianelane
    b) I have modified by hand the ID and password for pmoro and kCleris
    Why? That would break it unless you know the exact MD5 hash of a given word.

    Quote Originally Posted by dianelane
    c) I have tried to edit the password for kCleris (item 3) via Sugar, but no change has been made
    Thank you for help
    Do other changes to that user save properly? Assuming you haven't assigned anything to that user, you could also try deleting that user and then recreating them.
    Regards,

    Angel Magaņa
    Co-Author: Implementing SugarCRM 5.x (Packt Publishing -- Sept. 2010)
    Blog: http://cheleguanaco.blogspot.com.
    Twitter: @cheleguanaco.

    ________
    | Projects: |_____________________________________
    |
    | CandyWrapper (.NET Wrapper for SugarCRM SOAP API). Source now available on GitHub!
    | GoldMine to SugarCRM Express Conversion. Latest: 1.0.1.7 (Nov. 3, 2009)
    | CRM SkyDialer (Skype Integration). Latest: 1.0.2 (Feb. 17, 2010)
    | Round Robin Leads Assignment
    | Phone Number Formatter
    | CaseTwit (Twitter Integration)
    ______________________________________________

  3. #3
    dianelane is offline Member
    Join Date
    Jan 2007
    Posts
    8

    Default Re: Error with "Add/edit user"

    Quote Originally Posted by Angel
    Sugar doesn't store passwords. It stores an MD5 hash, or encrypted, representation of the password.
    Why? That would break it unless you know the exact MD5 hash of a given word.
    Do other changes to that user save properly? Assuming you haven't assigned anything to that user, you could also try deleting that user and then recreating them.
    I explain in more details.

    1) Installation of Sugar creates the user "admin" with the password I have chosen, and that is hashed in the table (I know that it is not stored in clear). The user is identified by ID=1 (first field in the record.

    2) After logging as "admin", I create a couple of users: "pmoro" and "kcleris", each with a password (in this case it is the same value as the usernames)

    3) As I cannot login with these usernames (wrong password error message), I check the USER table, and find that:
    - ID has a wrong value (see item 4, as an example)
    - the hashed password field is empty (again as in item 4)

    4) I change ID and password field to correct values for "pmoro" and "kcleris", via phpMyAdmin: ID set to 2 and 3, password copied from "admin"

    5) I can login with these usernames, and work

    6) Now I modify the password for "kcleris". But, as you can see in item 3, it remains unchanged.

    7) Item 4 is an example of record for a user added from administration|edit user. In particular: the ID and (hashed) password as recorded by Sugar

    To summarize:
    Sugar records wrong ID and password fields in USER table,
    and
    function "edit user" does not updates the concerned record in the table.

    Thank you.
    pm
    Last edited by dianelane; 2007-06-15 at 09:33 PM.

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Similar Threads

  1. Adding another "assigned user"
    By oleko in forum Developer Help
    Replies: 0
    Last Post: 2006-04-07, 07:17 AM

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
  •