Page 1 of 2 12 LastLast
Results 1 to 10 of 11
  1. #1
    Join Date
    Feb 2007
    Posts
    19
    Plugin Contributions
    0

    Default Importing customer data from old site and password encryption

    Hello,

    I am currently working on a zen-cart site which is to replace an older bespoke system by another developer.

    I have a dump of the old data base from the site and have managed to manually import the customers details successfully.

    The only exceotion is with passwords which were stored encrypted by the previous site. Obviously I
    want to make the transition from old site to new site as seamless to the customers as possible so keeping the login details the same is very desirable.

    At present the old email/password combo's don't work. If I could make sure that zen-cart is using the same encryption method as the old site would this solve my issue? If so how would I go about this? I understand that zen-cart uses MD5+salt, is there anyway to change this simply?

    Worst case scenario I will just reset everyones password and email that out to them, of course this isn't ideal. Any other ideas?

    Many thanks,

    Richard

  2. #2
    Join Date
    Apr 2006
    Location
    London, UK
    Posts
    10,569
    Plugin Contributions
    25

    Default Re: Importing customer data from old site and password encryption

    I suspect that trying to change the method used in Zen Cart would give you problems in the future, whereas whenever I have transferred carts into Zen Cart I have always managed to break the passwords (for those that didn't simply hold them in plain text!) from the data alone, and then use the Zen Cart password function to re-encrypt them as Zen Cart expects. If you actually know the encryption method used on the existing site. this may be even easier.

    Though some encryption regimes are more difficult to crack than others and one of the reasons that I like Zen Cart is that the password is not susceptible to being cracked like this, which is why I recommend using the Zen Cart approach.
    Kuroi Web Design and Development | Twitter

    (Questions answered in the forum only - so that any forum member can benefit - not by personal message)

  3. #3
    Join Date
    Feb 2007
    Posts
    19
    Plugin Contributions
    0

    Default Re: Importing customer data from old site and password encryption

    Thanks. Part of the problem is the previous developer not being too helpful, the less I deal with them the better.

    I notice that the encrypted passwords in the old site are in the format of a 33 alphanumeric character string while the zen cart ones are the same with the addition of a colon and then two characters (i.e :ab)

    Looking through the password_funcs.php file it seems that the colon is just a split point and the two additional characters are the 'salt'. Would removing this part help at all?

  4. #4
    Join Date
    Feb 2007
    Posts
    19
    Plugin Contributions
    0

    Default Re: Importing customer data from old site and password encryption

    I've had it confirmed that the passwords are hashed with MD5. Any further ideas?

  5. #5
    Join Date
    Nov 2007
    Posts
    5
    Plugin Contributions
    0

    Default Re: Importing customer data from old site and password encryption

    I have a matter a step removed.
    I'm importing from a database where there was NO encryption of the password, so I need to encrypt them for Zen Cart. Considering there are over 2000 customers, I'd like to have some sort of automated method.
    How do you proceed with that?

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

    Default Re: Importing customer data from old site and password encryption

    .

    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.

  7. #7
    Join Date
    Feb 2007
    Location
    Ontario, Canada
    Posts
    234
    Plugin Contributions
    0

    Default Re: Importing customer data from old site and password encryption

    I just have a few questions about importing customers that I am trying to get through:

    I am trying to add one customer as a test, before doing the full 2000 <insert pat on back here for being smart>

    I have inserted the customer into:
    customers
    customers_info
    address_book

    When I go into admin and do a search I find the customer, however the date is screwy and when I hit "Edit" none of the information is there. Also this error is above it:

    Warning: array_merge() [function.array-merge]: Argument #1 is not an array in /home/actforms/public_html/cart/admin/customers.php on line 1035

    Warning: array_merge() [function.array-merge]: Argument #2 is not an array in /home/actforms/public_html/cart/admin/customers.php on line 1037

    Warning: reset() [function.reset]: Passed variable is not an array or object in /home/actforms/public_html/cart/admin/includes/classes/object_info.php on line 29

    Warning: Variable passed to each() is not an array or object in /home/actforms/public_html/cart/admin/includes/classes/object_info.php on line 30


    Did I miss a table?

    Also, do I need to encrypt the password, I would just like to put a generic one and let the customer choose their own.

    Thanks for any help or input!!
    Thanks, Colleen
    www.af-company.com
    To err is human, but to really foul things up requires a computer. Farmers' Almanac, 1978

  8. #8
    Join Date
    Feb 2007
    Location
    Ontario, Canada
    Posts
    234
    Plugin Contributions
    0

    Default Re: Importing customer data from old site and password encryption

    Quote Originally Posted by margecc View Post
    I just have a few questions about importing customers that I am trying to get through:

    I am trying to add one customer as a test, before doing the full 2000 <insert pat on back here for being smart>

    I have inserted the customer into:
    customers
    customers_info
    address_book

    When I go into admin and do a search I find the customer, however the date is screwy and when I hit "Edit" none of the information is there. Also this error is above it:

    Warning: array_merge() [function.array-merge]: Argument #1 is not an array in /home/actforms/public_html/cart/admin/customers.php on line 1035

    Warning: array_merge() [function.array-merge]: Argument #2 is not an array in /home/actforms/public_html/cart/admin/customers.php on line 1037

    Warning: reset() [function.reset]: Passed variable is not an array or object in /home/actforms/public_html/cart/admin/includes/classes/object_info.php on line 29

    Warning: Variable passed to each() is not an array or object in /home/actforms/public_html/cart/admin/includes/classes/object_info.php on line 30


    Did I miss a table?

    Also, do I need to encrypt the password, I would just like to put a generic one and let the customer choose their own.

    Thanks for any help or input!!
    Ok I figured it out. Completely stupid error on my part. Sorry for the bother.

    Thanks, Colleen
    www.af-company.com
    To err is human, but to really foul things up requires a computer. Farmers' Almanac, 1978

  9. #9
    Join Date
    Jun 2009
    Location
    NC
    Posts
    174
    Plugin Contributions
    1

    Default Re: Importing customer data from old site and password encryption

    So, um, I'm kinda embarassed to be asking this, especially considering you're referring to whatever I've got going on as a "completely stupid error," but...exactly how did you sort it? I'm getting the same error messages that you got after importing a customers.csv into phpMyAdmin.

  10. #10
    Join Date
    Feb 2007
    Location
    Ontario, Canada
    Posts
    234
    Plugin Contributions
    0

    Default Re: Importing customer data from old site and password encryption

    LOL, it was an easy fix so I felt kinda silly after wards.

    It's from your customer.csv file not matching your address_book.csv file not matching your customers_info.csv file. What created this was when I imported the file, the header row on the customers.csv file and the address_book.csv is automatically given a ID numbers by the tables, which was putting all my ID numbers off by one.

    How I fixed it (its much easier than the description sounds). I opened all three files in excel. I went into zen, created a fake customer. I went into the tables and checked on the customer table and address table and noted the respective ID numbers. Go into excel, and start your id number at +1. So if your created customer has an ID number of 100, then the first customer in my csv file was assigned the number of 102 cause the header row would automatically be assigned the number of 101 by the table. Same applies in the address_book table. If the address_book_id for the fake customer was 150, then my .csv file would start at 152. Also make sure that the customers_default_address_id numbers in the customer.csv file matches the assigned address_book_id in the address_book table. The customer_info table is very straight forward. Once you've uploaded all files, you need to go to the table and delete the header rows, or when you go to do it again, it will give you duplicate errors.

    Hope that makes sense. I hate partial explanations of things, but perhaps I over complicate things by full explanations. If you keep having problems fire me off a PM and I'll give you a hand.
    Thanks, Colleen
    www.af-company.com
    To err is human, but to really foul things up requires a computer. Farmers' Almanac, 1978

 

 
Page 1 of 2 12 LastLast

Similar Threads

  1. Importing Products From Old Site
    By Lisascraftiques in forum Setting Up Categories, Products, Attributes
    Replies: 1
    Last Post: 12 Nov 2012, 11:32 PM
  2. Importing Data from Old Zen Database
    By rka81 in forum General Questions
    Replies: 3
    Last Post: 19 Oct 2011, 07:57 AM
  3. Replies: 5
    Last Post: 19 Dec 2010, 02:40 PM
  4. Importing Customer Data from Filemaker
    By Out2lunch in forum Managing Customers and Orders
    Replies: 3
    Last Post: 31 Oct 2009, 12:28 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
  •  
disjunctive-egg
Zen-Cart, Internet Selling Services, Klamath Falls, OR