Results 1 to 7 of 7

Thread: Import Users

  1. #1
    MartinSmith is offline Starter Member
    Join Date
    Jul 2009
    Posts
    1
    Rep Power
    5

    Default Import Users

    Hi all,

    I am exploring Zimbra as a replacement for my companies iMail server.
    We currently have 20 domains with about 100 total users using iMail
    We would like to use something like Zimbra for many reasons.
    As part of my evaulation I am trying to plan a migration from iMail.

    I have two ideas how this might work. But I need some help with both of them.

    One way would be to export the users then use zmprov to create the accounts.
    Most are POP so this would work ok.

    I have successfully exported the user names and provisioned Zimbra accounts using zmprov.
    The exported file from iMail is formated like this.

    msmith:x:0:384:Martin Smith:\IMAIL\domain_com\Users\msmith

    The format needed by zmprov is this.

    ca msmith@domain.com password displayName "Martin Smith" cn Martin sn Smith gn Martin

    So if I use this method I will need some code to convert the iMail file to the zimbra file. Not sure if anyone out their has done this already, if so that would be great. If not I will have to write this and I will post it here in case someone else finds it useful.

    The second would be to somehow do an ldap export and import. This might be ideal considering both mail systems utilize LDAP.

    I have no idea if this is possible or how I would proceed.

    I also don't know if it would be possible to bring over the passwords.

    Thanks
    Martin,
    Gulftex Operating, Inc.

  2. #2
    uxbod's Avatar
    uxbod is offline Moderator
    Join Date
    Nov 2006
    Location
    UK
    Posts
    8,017
    Rep Power
    24

    Default

    Welcome to the forums

    If you can export the passwords, even if MD5 encrypted, you can then use them on the zmprov command when you create the account. Why do you need to create a program to import the email This can be done using IMAPSync.

  3. #3
    eganja is offline Starter Member
    Join Date
    Sep 2009
    Posts
    1
    Rep Power
    5

    Default

    I need your experience with MD5

    I have already successed to import passwords from /etc/shadow in zimbra

    with the command
    zmprov ma $user@$domain userPassword '{crypt}$pass'
    but if I'm not wrong, md5 passwords in shadow are salted

    but now I have problems to import md5 passwords created by the winmail server program which seems to use another mode

    in this program the encrypted version of the string 'md5' is '1bc29b36f623ba82aaf6724fd3b16718'
    I can easily check with milworm or other pass cracking that it's a valid md5 string

    but none of these command lines allow me to enter 'md5' as password in the wemail panel

    zmprov ma eric@test.be userPassword '{crypt}1bc29b36f623ba82aaf6724fd3b16718'

    zmprov ma eric@test.be userPassword '{md5}1bc29b36f623ba82aaf6724fd3b16718'

    zmprov ma eric@test.be userPassword '{SSHA}1bc29b36f623ba82aaf6724fd3b16718'

    zmprov ma eric@test.be userPassword '{crypt}{md5}1bc29b36f623ba82aaf6724fd3b16718'

    i probably forget something stupid
    help
    thank you in advance
    eric from belgium

  4. #4
    joho's Avatar
    joho is offline Loyal Member
    Join Date
    Jan 2009
    Location
    Stockholm, Sweden
    Posts
    96
    Rep Power
    6

    Default

    Did you ever manage to solve this?

    I too have the need to import a pre-encrypted password into Zimbra, the shadow entry has a password like this (on another Linux machine):

    $1$TMpWrOd7$2eL/F8sHshybbWGOcZ5Yx.

  5. #5
    Direw79 is offline Trained Alumni
    Join Date
    Feb 2009
    Location
    MD
    Posts
    1
    Rep Power
    6

    Default

    A quick solution is to create the account with no password

    zmprov ma john@test.com "" ...

    Then run an ldapmodify on the account after creation with the salted/encrypted password stored there.

    dn: uid=john,ou=people,dc=domain,dc=com
    userPassword:: e2NYeXB8fTu5OFRBdjX4empHV0E=

    This worked during my migration on 5.x with 5500 or so accounts and I will be testing shortly on 6 to see if I can get it working there as well...

    Ill be back to let everyone know If I can get zmprov working or if the ldapmodify method still seems to work best

  6. #6
    raj's Avatar
    raj
    raj is offline Moderator
    Join Date
    Oct 2005
    Location
    USA, Canada and India
    Posts
    777
    Rep Power
    10

    Default

    using zmprov the userPassword '{ANYTHING}' dont work..i tried it with all options with mmorse once..
    ldapmodify is the only way to go..
    by the way..anyone have full command how to use ldapmodify to update the crypt password

    Raj
    i2k2 Networks
    Dedicated & Shared Zimbra Hosting Provider

  7. #7
    odeleon is offline Advanced Member
    Join Date
    Sep 2009
    Location
    Spain
    Posts
    233
    Rep Power
    5

    Talking

    When using zmprov createAccount or zmprov setPassword Zimbra will encrypt whatever you give it.

    To get a pre-encrypted password into a Zimbra account you should use zmprov modifyAccount account@example.com userPassword password and it will take that and put it into the ldap directory as-is. I did it once when moving from a "generic" OpenLDAP to Zimbra's, I haven't done extensive testing but I think it will allow any encryption method that's compatible with OpenLDAP...so even your {crypt} passwords from /etc/shadow should work. I don't know what happens if they are salted, probably won't work.

Thread Information

Users Browsing this Thread

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

Similar Threads

  1. Active Directory Script to import users to Zimbra
    By egrueda in forum Administrators
    Replies: 35
    Last Post: 08-29-2012, 10:54 AM
  2. how to bulk import users with zmprov?
    By leocertuche in forum Administrators
    Replies: 3
    Last Post: 06-29-2009, 02:19 PM
  3. ical4j.data.ParserException
    By amit_saini54 in forum Migration
    Replies: 0
    Last Post: 12-06-2007, 07:45 AM
  4. Replies: 1
    Last Post: 06-18-2007, 10:32 PM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •