Forums / General / importing users from an external datasource

importing users from an external datasource

Author Message

Robin de Silva Jayasinghe

Friday 09 July 2004 5:43:21 am

hello!

i am planning to implement an large scale community site for an organisation with about 2000 members. every member shall have its own pre-installed user. i have all the userdata like email, name, surname, etc. in a separete excel-file.
my question is if there is an possibility to import this file as csv and generate ezPublish users with limited rights automatically?

thanks and best regards from germany!
robin

visit http://www.jayasinghe.de

Paul Borgermans

Friday 09 July 2004 6:03:15 am

Yes,

I did something similar when migrating users in pre 3.4 sites. I modified the text login handler a little bit: instead of creating a user upon firts attempt to login, I let the script "slurp" the entire file. After this I changed the login handler back to the default. Passwords were migrated too (ie the hashed values)

hth

-paul

eZ Publish, eZ Find, Solr expert consulting and training
http://twitter.com/paulborgermans

Jonathan Dillon-Hayes

Sunday 19 September 2004 6:57:27 pm

Bump.

This actually is something we're interested in doing as well. We could import, but unfortunately everything else in our architecture is integrated with the parent DB and not eZ. So I suppose we'll have to get eZ to auth against our other MysqlDB and not export it.

I'm working on a 3.4 codebase, and I think I have it down. Quite a challenge though -- I wish there were a way to do this with a web service (SOAP) client.

Anyone have an idea of a good way to do it? I have a couple of thousand users in an external MysqlDB with SHA1 encryption. I can use php's native functions to auth against the raw output (I have php accessing a perl script to get raw output with a 4.3 php version so it's actually just a string comparison).

Anyone have any experience with this? I could use some pointers myself before I break my head for the next two days. ;-)

Jonathan

---------
FireBright provides advanced eZ deployment with root access
http://www.FireBright.com/

Marco Zinn

Tuesday 21 September 2004 1:20:17 pm

Hi,

well, we actually did both with extensions, that we bought from ezSystems for our ez 3.3 system.
First, we had a CSV import module, which imported users to pre-installed user groups, including the sending of generated first-time passwords by email to the individual user.

Now, we are having a User directory, which can be accessed via SOAP. ezSystems wrote an extension, which provided a new user handler, which connects to that User directory via SOAP and checks for the Password. If the login is okay, the SOAP server replies with the full user data, as well as some role identifiers. The user plugin maps those roles to ezPublish roles and creates or updates a "local user" (the one in the ezPublish DB).

The SOAP solution is quite special for our needs, but the CSV import should work fine for any ezPublish solution.

Marco
http://www.hyperroad-design.com

riccardo refolo

Thursday 24 February 2005 1:26:01 am

I have to import user by a csv file, have somebody got a module to do it?
Thank's.
Ps. He could send me the file by mail. I could tell him my mail.