[OpenSIPS-Users] CANCEL auth

Bogdan-Andrei Iancu bogdan at opensips.org
Fri Jun 24 16:22:01 CEST 2011


Hi Victor,

ACK and CANCELs are no authenticated. These methods must have same seq 
as the corresponding INVITE, so auth cannot be done (as cseq is 
increased during the challenge process).

No, of course, the problem is for challenge and not for auth itself, and 
because of this reason the RFC3261 says that if the INVITE carried 
credentials, the CANCEL and ACK for it must do it also (without challenge).

And because most of the UACs do not do that, opensips simply skips the 
auth for CANCEL and ACK - and the vars you are looking at are populated 
during the auth process (which is not done in your case).

Regards,
Bogdan

On 06/24/2011 04:51 PM, Victor Gamov wrote:
> Hi All
>
> I have following config code:
>
> --------------------
> if ( is_method("INVITE|UPDATE|SUBSCRIBE|MESSAGE|CANCEL") ) {
>   if ( ! proxy_authorize("", "subscriber") ) {
>     proxy_challenge("", "1");
>     return;
>   } else {
>     xlog("L_DBG", "route[0]: au=$au; ar=$ar; fU=$fU; fd=$fd\n");
>   }
> }
> --------------------
>
> When following CANCEL comes to OpenSIPS-1.6.4-2-notls then debug prints:
> au=<null>; ar=<null>; fU=vit; fd=domain.ru
>
> Why $au and $ar is null? Is it correct?
>
>
> --------------------
> CANCEL sip:132 at domain.ru;user=phone SIP/2.0.
> Via: SIP/2.0/UDP 
> 192.168.100.114:5060;branch=z9hG4bKee2799df33a1f9d47606713ceef0cf63;rport.
> From: "vit at domain" <sip:vit at domain.ru>;tag=1863488453.
> To: <sip:132 at domain.ru;user=phone>.
> Call-ID: 1575274528 at 192_168_100_114.
> CSeq: 3 CANCEL.
> Contact: <sip:vit at 192.168.100.114:5060>.
> Proxy-Authorization: Digest username="vit", realm="domain.ru", 
> qop=auth, uri="sip:132 at domain.ru;user=phone", 
> nonce="4e04936f0000000153cdf04ef598707f3849686bee7b566a", nc=00000002, 
> cnonce="85b6b55d74844e156b6858a1a881f174", 
> response="1210aa91a7507e4af9a035dfadb969bc".
> Max-Forwards: 70.
> User-Agent: C470 IP/022270000000.
> Content-Length: 0.
> --------------------
>
>

-- 
Bogdan-Andrei Iancu
OpenSIPS solutions and "know-how"




More information about the Users mailing list