imap - How to access a shared mailbox using NTLM authentication -


i'm trying access shared mailbox in exchange using imap don't want store password in app give try ntlm authentication.

i able autentication using sspi framework api i'm struggling select shared inbox.

using "basic" authentication know do:

  login domain/username/mailboxalias username_password //a ok login completed.   b select inbox //...\r\nb ok [read-write] select completed." 

and work fine, don't wan't to store password in app, i'm using ntlm auth (connecting exchangeserver1.domain.com mailboxalias stored):

  authenticate ntlm  // +   <type_1_msg>  // + <type_2_msg>   <type_3_msg> // ok [referral imap://;auth=*@exchangeserver2.domain.com/] authenticate completed.   b select inbox // b no [referral imap://;auth=*@exchangeserver2.domain.com/inbox] there no replica mailbox on server."   c select mailboxalias //c no there no replica mailbox on server.   d select mailboxalias/inbox //d no there no replica mailbox on server.   e select inbox/mailboxalias //e no there no replica mailbox on server. 

the current context user mailbox stored in exchangeserver2 shared mailbox in exchangeserver1, that's why in ntlm see referral piece, in both scenarios above i'm connecting exchangeserver1.

i tried several variations of select command 'mailbox alias' , 'inbox' none worked. have access mailbox, i'm owners , can access outlook (but believe uses mapi) , 'basic authentication'.

after authentication, how can select shared mailbox inbox?

i'm using following acquirecredentialshandle call generate ntlm type 1 message: acquirecredentialshandle (null, "ntlm", 2, 0, 0, 0, 0, ref phcredential, ref ptsexpiry)

i tried changing first parameter (which username) null (the current context user) "domain/username/mailbox" didn't work.

thanks :)


Comments

Popular posts from this blog

c++ - CryptStringToBinary API behavior -

c++ - Correct method for redrawing a layered window -

java.util.scanner - How to read and add only numbers to array from a text file -