Hi Bob,
Thanks for the help. I found the problem. I was using the userid as [EMAIL PROTECTED] in my credentials.xml my client was using "user1" as user id to construct the authentication digest.
Just so that someone in future may benefit, I am going to state the obvoius here again.
The REGISTER message has a nonce='xahsofhsdhfpu304ndroureu0eursdf' and this is constructed by doing the following
MD5( userName + ":" + realm + ":" + password )
The sipregistry server collects the same information using data from the credentials.xml
Thanks again for the help.
regards,
Soma
Note: forwarded message attached.
Soma
Note: forwarded message attached.
Do you Yahoo!?
Everyone is raving about the all-new Yahoo! Mail Beta.
--- Begin Message ---I recommend searching this mailing list for instructions on manually generating the authentication digest and verifying this by hand... I originally posted on this, and I believe my example was off, but the approach was correct. I also recommend double-checking your configuration (best to do that first). I suspect you have some different in your configuration -- I also believe someone on this list needs to validate what you did on the server side (e.g. manually modifying the .xml files).- Bob On Monday, August 7, 2006, 11:47:55 AM, Lih Tzeng wrote: > > > Somasundaram, > > > > May I suggest that you use the newly created sipxtapi-dev mailing > list? You should get better attention on that mailing list. > > > > Thanks, > > Lih > > > > From: [EMAIL PROTECTED] > [mailto:[EMAIL PROTECTED] On Behalf Of somasundaram easwaramoorthy > Sent: Monday, August 07, 2006 5:22 AM > To: [EMAIL PROTECTED] > Subject: [sipX-dev] Need help to fix REGISTER problem > > > Hi Friends, > > > > I have a soft phone that calls the following API > sipxInitialize(&g_hInst, iSipPort, iSipPort, PORT_NONE, iRtpPort) > sipxEventListenerAdd(g_hInst, EventCallBack, this) > sipxLineAdd(g_hInst, "sip:[EMAIL PROTECTED]", &g_hLine) > sipxLineAddCredential(g_hLine, "user1", "pwd", "voiceicon") > sipxConfigSetRegisterExpiration(g_hInst, 60) > SLEEP(1500) ; > sipxLineRegister(g_hLine, true) > > > > On the registry server, I created the credential.xml manually by > using sample file sipXconmmserverLib/doc/credential.xml and > command line utility sipXconmmserverLib/doc/update-passtokens > > After setting up the credentials.xml when I execute my client code I am > getting a 401. > I am also providing the SIP messages that I captured using > Ethereal. Can you please help me understand why I am getting 401 and how > to fix this problem. > > > > regards, > Soma > > REGISTER sip:voiceicon SIP/2.0 > From: sip:[EMAIL PROTECTED];tag=224951ef > To: sip:[EMAIL PROTECTED] > Call-Id: d8764b424f68fdfb6612d73edb52a446 > Cseq: 1 REGISTER > Contact: > <sip:[EMAIL PROTECTED];LINEID=5d5b5f9f0771c7433ef5ca38031cf807> > Expires: 60 > Date: Mon, 07 Aug 2006 08:33:52 GMT > Max-Forwards: 20 > User-Agent: sipX/2.5.2 (WinNT) > Accept-Language: en > Supported: replaces > Via: SIP/2.0/TCP > 192.168.1.5;branch=z9hG4bK-814984e23a28e6321e713609630246e4 > Content-Length: 0 > > SIP/2.0 401 Unauthorized > From: sip:[EMAIL PROTECTED];tag=224951ef > To: sip:[EMAIL PROTECTED] > Call-Id: d8764b424f68fdfb6612d73edb52a446 > Cseq: 1 REGISTER > Via: SIP/2.0/TCP > 192.168.1.5;branch=z9hG4bK-814984e23a28e6321e713609630246e4 > Www-Authenticate: Digest realm="voiceicon", > nonce="5dcdad89cdfe4211c7f8cb2809a2831a1154934790" > Date: Mon, 07 Aug 2006 07:13:10 GMT > Allow: INVITE, ACK, CANCEL, BYE, REFER, OPTIONS, REGISTER, NOTIFY, > SUBSCRIBE, INFO > User-Agent: sipX/2.6.0 (Linux) > Accept-Language: en > Supported: sip-cc-01, timer > Content-Length: 0 > > REGISTER sip:voiceicon SIP/2.0 > From: sip:[EMAIL PROTECTED];tag=224951ef > To: sip:[EMAIL PROTECTED] > Call-Id: d8764b424f68fdfb6612d73edb52a446 > Cseq: 2 REGISTER > Contact: > <sip:[EMAIL PROTECTED];LINEID=5d5b5f9f0771c7433ef5ca38031cf807> > Expires: 60 > Date: Mon, 07 Aug 2006 08:33:52 GMT > Max-Forwards: 20 > User-Agent: sipX/2.5.2 (WinNT) > Accept-Language: en > Supported: replaces > Authorization: Digest username="user1", realm="voiceicon", > nonce="5dcdad89cdfe4211c7f8cb2809a2831a1154934790", > uri="sip:voiceicon", response="95fc375a2698e744309c21f3143d40b1" > Via: SIP/2.0/TCP > 192.168.1.5;branch=z9hG4bK-07df73bde9bdd1312099f2bb96f565f3 > Content-Length: 0 > > SIP/2.0 401 Unauthorized > From: sip:[EMAIL PROTECTED];tag=224951ef > To: sip:[EMAIL PROTECTED] > Call-Id: d8764b424f68fdfb6612d73edb52a446 > Cseq: 2 REGISTER > Via: SIP/2.0/TCP > 192.168.1.5;branch=z9hG4bK-07df73bde9bdd1312099f2bb96f565f3 > Www-Authenticate: Digest realm="voiceicon", > nonce="5dcdad89cdfe4211c7f8cb2809a2831a1154934790" > Date: Mon, 07 Aug 2006 07:13:10 GMT > Allow: INVITE, ACK, CANCEL, BYE, REFER, OPTIONS, REGISTER, NOTIFY, > SUBSCRIBE, INFO > User-Agent: sipX/2.6.0 (Linux) > Accept-Language: en > Supported: sip-cc-01, timer > Content-Length: 0 > > > Talk is cheap. Use Yahoo! Messenger to make PC-to-Phone calls. > Great rates starting at 1¢/min. >
--- End Message ---
_______________________________________________ sipxtapi-dev mailing list [email protected] List Archive: http://list.sipfoundry.org/archive/sipxtapi-dev/
