Importing Users/Passwords

For general questions and discussions specific to the AbleCommerce 7.0 Asp.Net product.
Post Reply
dsimione
Ensign (ENS)
Ensign (ENS)
Posts: 2
Joined: Mon Oct 26, 2009 12:38 pm

Importing Users/Passwords

Post by dsimione » Thu Aug 05, 2010 8:22 am

I am in the process of implementing an AC7 site for a client. Everything is going great, and I'm finding it very easy to do just about anything they need. One small hiccup, though.

The client manages all user accounts in their AS/400. There is no registration on the AC site - the users must contact the client and create an account with the company before being allowed onto the site. Each day, the client exports a list of the active users, their information, and their password. They will be sending this file over SFTP to the hosting server, and I need to import it into AC. I can get the user account created, along with all supporting information, but I am not seeing any way to generate the encrypted password through SQL. I've seen posts for using DataPort, but because it isn't scriptable, I don't think it will fit their needs.

As I see it, I have the following options:
1. Import the plain text passwords to a separate table, and then have a utility in the Admin that will loop through the users and assign their password. This adds an extra step for the client, but is probably ok. However, will the storing of passwords in plain text, even for a brief amount of time, invalidate any PCI compliance?

2. Try either a .NET Stored Procedure or an SSIS package, importing the CommerceBuilder assemblies. Has anyone tried this before? Is this allowed under the standard (non-source) license?

3. Other options?

Thanks!
Dave

User avatar
mikek
Commander (CMDR)
Commander (CMDR)
Posts: 112
Joined: Wed Oct 15, 2008 9:30 pm
Location: Boston, MA
Contact:

Re: Importing Users/Passwords

Post by mikek » Thu Aug 05, 2010 10:45 am

Hi Dave,

You can use the AbleCommerce CommerceBuilder API to register and manage user accounts : CommerceBuilder.Users

I do not know if there is a documentation available for CommerceBuilder.Users , but you can use reflector to check all classes available.

There is a method:

public MembershipCreateStatus Register(string username, string email, string password, string securityQuestion, string securityAnswer, bool isApproved)

I would not recommend working with the Database Directly since it may cause side effects and is not a good developer practice in general.
Mike Kolev

Pawan
Ensign (ENS)
Ensign (ENS)
Posts: 10
Joined: Mon May 04, 2009 5:56 am

Re: Importing Users/Passwords

Post by Pawan » Thu Dec 22, 2011 7:29 am

Can anybody share the SQL script to create users from backend.
Thanks.

Post Reply