Zimbra offers Open Source email server software and shared calendar for Linux and the Mac
Go Back   Zimbra :: Forums > Zimbra Collaboration Suite > Developers

Welcome to the Zimbra :: Forums!
Welcome, if you would like to post a comment please register. We also encourage you to explore all things Zimbra with our team and members of the community.

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1 (permalink)  
Old 07-08-2010, 05:52 AM
pns pns is offline
Member
 
Posts: 13
Thumbs up SOAP AuthRequest Failure (account.INVALID_PASSWORD)

Hi...

I am playing with my local Zimbra installation (ZD 1.0.4 over Linux) by sending it some test SOAP messages from a custom Java application and I can convince the service to authenticate.

More specifically, I post the following SOAP message through a Java OutputStremWriter (variable w):
w.write("<?xml version='1.0'?>\r\n");
w.write("<soap:Envelope xmlns:soap=\"http://www.w3.org/2003/05/soap-envelope\">\r\n");
w.write("<soap:Body>\r\n");
w.write(" <AuthRequest xmlns=\"urn:zimbraAccount\">\r\n");
w.write(" <account by=\"name">MyAccName@gmail.com</account>\r\n");
w.write(" <password>MyPassword</password>\r\n");
w.write(" </AuthRequest>\r\n");
w.write("</soap:Body>\r\n");
w.write("</soap:Envelope>\r\n");
where MyAccName@gmail.com is an existing GMail address, the inbox of which I access via ZD (or via any browser), using MyPassword. ZD synchronizes with MyAccName flawlessly.

However, whenever I post the above SOAP message, I get the following response:

<soap:Body>
<soap:Fault>
<soap:Code><soap:Value>soap:Sender</soap:Value>
</soap:Code>
<soap:Reason>
<soap:Text>invalid password: MyPassword</soap:Text>
</soap:Reason>
<soap: Detail>
<Error xmlns="urn:zimbra">
<Code>account.INVALID_PASSWORD</Code>
</Error>
.......

As I said above, MyPassword works fine with both GMail and ZD. The documentation (soap.txt) says that account.INVALID_PASSWORD means "new password doesn't meet the system's rules", but how can this be possible, since it works already and I am not trying to create a new password anyway?

Any ideas?

Thanks!
Reply With Quote
  #2 (permalink)  
Old 07-08-2010, 09:31 AM
Outstanding Member
 
Posts: 717
Default

The SOAP service wants the password for your Zimbra account.

I haven't ever used SOAP with ZDesktop, so I'm not sure how it works, or even why you'd want to do it for that matter. I've only used it against a real Zimbra Server. So if you are giving it your @gmail.com account, that is why it is not authenticating you - it is not a local account to Zimbra. The @gmail.com is a data source within your actual Zimbra account.
Reply With Quote
  #3 (permalink)  
Old 07-08-2010, 12:57 PM
pns pns is offline
Member
 
Posts: 13
Default

Quite right, and the Zimbra Account is (of course) not the OS Zimbra Account ("zimbra" user, which I had also tried), but a Zimbra Server (ZCS Account). I just tested my code with a demo account from Zimbra Collaboration Suite Log In and it works just fine. Thanks!

I am still puzzled as to why there couldn't be a local Zimbra Account (even a dummy one) to play with SOAP, since the local URL (http://localhost/service/soap) works and since ZD is indeed used for development (e.g., for zimlet development, as per the corresponding Zimbra Desktop Wiki Section). That would be very convenient for people who want a portable offline (e.g., laptop) setup to play with, as I want to do.

If anyone has a suggestion (or a hack) to achive this, please contribute.
Reply With Quote
Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes


Similar Threads

Why Join?

Registering let's you ask questions, makes it easier to search, displays any files attached to posts, and notifies you about replies.

blog.zimbra.com




 

SEO by vBSEO ©2011, Crawlability, Inc.