<div dir="ltr">Hi,<br><br>If topos is activated and kamailio responds with a 407 "proxy authentication required" to an initial INVITE, INVITE received after with credentials (MD5 response in Proxy-Authorization header) is badly managed. Credentials are never validated and Kamailio responds 407 again. If topoh is used instead topos all works fine and credentials are validated.<br><br>call flow is:<br>Phone sends INVITE to kamailio SBC<br>kamailio respond 407  "proxy authentication required" because SBC wants to authenticate caller<br>Phone resends INVITE with Proxy-Authorization header with all valid information<br>kamailio responds 407 again instead forwarding INVITE.<br><br>My code:<br>        if (!pv_auth_check("$fd", "$sht(auth_cache=>$var(key))", "0", "1")) {<br>    auth_challenge("$fd", “1”);<br>    exit;<br>        }<br>     # user authenticated - remove auth header<br>consume_credentials();<br><br>So if topos is used, pv_auth_check always returns false even if the phone sets valid information.<br>If topoh is activated, pv_auth_check 

always 

returns true (same phone and same kamailio SBC versioning)<br><br>I made my tests with kamailio 5.4.3 on centos 7.<br><br>Regards,<br>Frédéric Gaisnon<br></div>