[reSIProcate] registration on sipphone.com
Scott Godin
slgodin at icescape.com
Mon Aug 29 08:47:58 CDT 2005
You don't actually need to do all of this manual work. DUM handles
digest challenges for you. You only need to define your username,
password, realm, etc. in the User/MasterProfile and assign and
setClientAuthManager on DUM. See dum/test/BasicRegister.cxx for an
example.
Scott
-----Original Message-----
From: resiprocate-devel-bounces at list.sipfoundry.org
[mailto:resiprocate-devel-bounces at list.sipfoundry.org] On Behalf Of
Dmytro Bogovych
Sent: Monday, August 29, 2005 9:16 AM
To: resiprocate-devel at list.sipfoundry.org
Subject: [reSIProcate] registration on sipphone.com
Greetings.
May anyone to help me implement registration on proxy01.sipphone.com?
Looks like this registrar using WWW-Authenticate authorization scheme.
I tried to implement this as
void MyUserAgent::onFailure(ClientRegistrationHandle h, const
SipMessage&
response)
{
int responseCode = response.header(h_StatusLine).statusCode();
if ( responseCode == 401 || responseCode == 407 )
{
if (response.exists(h_WWWAuthenticates))
{
const ParserContainer<Auth>& wwwAuth =
response.header(h_WWWAuthenticates);
Data nonceData = wwwAuth.front().param(p_nonce);
//Data nonceData = wwwAuth.find(p);
Helper::addAuthorization(this->mRegMessageStored, response,
mRegistrarUri.user(), mRegistrarUri.password(), nonceData,
this->mNonceCount);
mRegMessageStored.header(h_CSeq).sequence()++;
mRegMessageStored.header(h_Vias).front().remove(p_branch);
mRegMessageStored.header(h_Vias).front().param(p_branch);
mDum.send(mRegMessageStored);
return;
}
}
}
But server doesn't respond to my second packet :(
May anyone to help me?
--
Using Opera's revolutionary e-mail client: http://www.opera.com/mail/
_______________________________________________
resiprocate-devel mailing list
resiprocate-devel at list.sipfoundry.org
https://list.sipfoundry.org/mailman/listinfo/resiprocate-devel
More information about the resiprocate-devel
mailing list