Page 1 of 2 12 LastLast
Results 1 to 10 of 13

Thread: SOAP for generating Preauth key??

  1. #1
    bonadio is offline Loyal Member
    Join Date
    Oct 2007
    Location
    Brazil
    Posts
    88
    Rep Power
    7

    Default SOAP for generating Preauth key??

    Hello

    I would like to know if there is a SOAP call that can generate the Preauthkey for a domain, I know we can run zmprov> gdpak <domain>, but we would like to automate this process. I already tried to call a soap method GenerateDomainPreAuthKey but it returns
    "Erro:unknown document: ns1:GenerateDomainPreAuthKey"

    Thanks for any help

    []s

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

  3. #3
    acajaja is offline Junior Member
    Join Date
    Jun 2010
    Posts
    5
    Rep Power
    5

    Default

    I don't think you answered bonadio's question. To me, it doesn't seem that he/she is asking HOW to pre auth, rather they're asking how to generate a PREAUTH KEY for a given domain via a SOAP request so that they CAN pre auth.

    I too would like to know the answer. Please be direct and concise.

    The doc at Preauth - Zimbra :: Wiki DOES NOT answer the question. It simply says to run the zmprov command which I don't know how to do. I am using the ZCS NOT the desktop version and would like to ultimately set up an API for my company so we can integrate calendaring functionality into our site for our users.

  4. #4
    gunthor is offline Junior Member
    Join Date
    May 2010
    Posts
    7
    Rep Power
    5

    Default

    I don't think it's possible yet.. it would be insecure either...

    Index of /pub/zimbra/zimbra/trunk/branches/EDISON/ZimbraServer/docs
    I've checked preAuth.txt and the soap files, there's no hint for it. It is also not possible to generate it with the webinterface, so i also cannot fetch soap information this way...

    But may'be a PHP-shell interface can help you?
    gunthor's zimbraControl at gunthor - GitHub

    it's not a complete package, but the shell-part works fine!

    have fun
    Gunthor

  5. #5
    gunthor is offline Junior Member
    Join Date
    May 2010
    Posts
    7
    Rep Power
    5

    Default

    okay, i give up! sry for distrubing you, i didn't want to spam here, i thought it could help
    Last edited by gunthor; 07-07-2010 at 05:40 PM.

  6. #6
    phoenix is offline Zimbra Consultant & Moderator
    Join Date
    Sep 2005
    Location
    Vannes, France
    Posts
    23,499
    Rep Power
    56

    Default

    Quote Originally Posted by gunthor View Post
    okay, i give up! sry for distrubing you, i didn't want to spam here, i thought it could help
    All you had to do was wait for your post to be approved.
    Regards


    Bill


    Acompli: A new adventure for Co-Founder KevinH.

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

    Default

    That artictle tells you exactly what to do
    Code:
    su - zimbra
    zmprov gdpak <domain_name>

  8. #8
    jpkboca is offline Member
    Join Date
    Jul 2010
    Posts
    10
    Rep Power
    5

    Default

    This is using zmprov.

    Is there a way to do it via SOAP?

    I have added the --debug flag to this call and see the following, but unsure what the key should be in the zimbraPreAuthKeyNode, or is it just generating it for me, and not possible to do via SOAP?

    Here is the example (only snipping out pertinant parts)

    zmprov --debug gdpak jeffzz798.com

    <ModifyDomainRequest xmlns="urn:zimbraAdmin">
    <id>4a693890-7643-40d9-abe2-3d310ff02409</id>
    <a n="zimbraPreAuthKey">513e2eff591e343dd6e8397c7237c d6618f51b702f5a4c46fe08d1730114271e</a>
    </ModifyDomainRequest>


    preAuthKey: 513e2eff591e343dd6e8397c7237cd6618f51b702f5a4c46fe 08d1730114271e

    Anyone done this successfully?


    Quote Originally Posted by uxbod View Post
    That artictle tells you exactly what to do
    Code:
    su - zimbra
    zmprov gdpak <domain_name>

  9. #9
    nickzm is offline Intermediate Member
    Join Date
    Apr 2011
    Posts
    15
    Rep Power
    4

    Question

    I am also eager to know this answer. Especially how to solve unknown-document issue, which constantly happens when using the soap api!

  10. #10
    yutaka is offline Project Contributor
    Join Date
    Oct 2009
    Location
    Tokyo
    Posts
    113
    Rep Power
    5

    Default

    I have never done this before.
    But maybe you can generate zimbraPreAuthKey for a domain like this:

    try {
    java.security.SecureRandom random = java.security.SecureRandom.getInstance("SHA1PRNG") ;
    byte[] key = new byte[32];
    random.nextBytes(key);
    return new String(org.apache.commons.codec.binary.Hex.encodeH ex(key));
    } catch (NoSuchAlgorithmException e) {
    throw ServiceException.FAILURE("unable to initialize SecureRandom", e);
    }
    And you send

    <ModifyDomainRequest xmlns="urn:zimbraAdmin">
    <id>4a693890-7643-40d9-abe2-3d310ff02409</id>
    <a n="zimbraPreAuthKey">513e2eff591e343dd6e8397c723 7c d6618f51b702f5a4c46fe08d1730114271e</a>
    </ModifyDomainRequest>
    That seems all "zmprov gdpak" do for you inside.

    I hope this might help you.

Page 1 of 2 12 LastLast

Thread Information

Users Browsing this Thread

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

Similar Threads

  1. Having problem form todat accessing zimbra desktop
    By rajeshkodali in forum Installation Help
    Replies: 2
    Last Post: 06-18-2009, 11:30 PM
  2. zmzimletctl deploy zimbra_posixaccount.zip - ERROR -
    By todd_dsm in forum Administrators
    Replies: 0
    Last Post: 04-02-2009, 01:41 PM
  3. Replies: 2
    Last Post: 10-23-2008, 09:50 AM
  4. Bug with preauth mechanism and SOAP headers?
    By Coilcore in forum Developers
    Replies: 3
    Last Post: 07-20-2006, 10:41 AM
  5. Replies: 13
    Last Post: 10-31-2005, 04:22 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
  •