Pekka Pessi napsal(a): > 2008/1/18, Martin Drasar <[EMAIL PROTECTED]>: > >> I have a problem with proxy authentication. >> >> My user agent registers itself with proxy without a problem. However >> when I want it to redirect a call, the following happens: >> >> 1) REFER is sent to proxy >> 2) Proxy answers with 407 >> 3) In nua_r_refer event I use this code to answer the challenge: >> >> const char* realm = >> msg_params_find(sip->sip_proxy_authenticate->au_params, "realm="); >> sprintf(authString, "Digest:%s:%s:%s", realm, proxy->username, >> proxy->password); >> nua_authenticate(proxy->proxyHandle, NUTAG_AUTH(authString), TAG_END()); >> >> 4) Then I get 904 "No matching challenge" >> > > Weird. > > It seems to me that REFER manages to trash its dialog if it is used on > a new handle, but it should not affect your case. Have you tried to > send other in-dialog requests, like re-INVITE? What happens when they > are challenged? > > Could you also try to narrow down the problem and try with a proxy > that has something in realm? > > --Pekka Hi Pekka, thanks for the response.
1) I have modified the proxy to send some realm and it didn't help. 2) reINVITE I'm not sure how the reinvite works so I have just tried this piece of code: nua_invite(nh, TAG_END()); Problem is that the invite is sent, but it's not challenged. (Don't have an idea why. Proxy is Alcatel OmniPCX enterprise.) 3) I have tried to debug deep into the bovels of sofia and I have found that in the function nua_stack_authenticate value of nh->nh_ds->ds_cr is NULL. Also nh_authorize returns 0. I don't know what might help you in tracking down the issue, but if you give me some more pointers I will try to find more. Thanks Martin -- Martin Drasar, Developer / Analyst OptimSys, s.r.o. [EMAIL PROTECTED] Tel: +420 541 143 065 Fax: +420 541 143 066 http://www.optimsys.cz ------------------------------------------------------------------------- This SF.net email is sponsored by: Microsoft Defy all challenges. Microsoft(R) Visual Studio 2008. http://clk.atdmt.com/MRT/go/vse0120000070mrt/direct/01/ _______________________________________________ Sofia-sip-devel mailing list Sofia-sip-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/sofia-sip-devel