Skip to content

Commit

Permalink
uac: updated notes about uac_auth()
Browse files Browse the repository at this point in the history
  • Loading branch information
miconda committed Jun 11, 2015
1 parent 9529a6b commit db829aa
Showing 1 changed file with 29 additions and 3 deletions.
32 changes: 29 additions & 3 deletions modules/uac/doc/uac_admin.xml
Expand Up @@ -42,8 +42,10 @@
</listitem>
<listitem>
<para>
CSeq is not increased during authentication - the response
may be rejected.
CSeq is not increased automatically by uac_auth() during authentication
- the follow up request may be rejected. CSeq can be increased when
authenticating INVITE requests - dialog module has to be used, with
CSeq tracking feature enabled (see the readme of dialog module).
</para>
</listitem>
<listitem>
Expand Down Expand Up @@ -688,7 +690,31 @@ uac_restore_to();
<title><function>uac_auth</function> usage</title>
<programlisting format="linespecific">
...
uac_auth();
modparam("uac","auth_username_avp","$avp(auser)")
modparam("uac","auth_password_avp","$avp(apass)")
modparam("uac","auth_realm_avp","$avp(arealm)")

request_route {
...
if(is_method("INVITE")) {
t_on_failure("TRUNKAUTH");
}
...
}

failure_route[TRUNKAUTH] {

if (t_is_canceled()) {
exit;
}
if(t_check_status("401|407")) {
$avp(auser) = "test";
$avp(apass) = "test";
uac_auth();
t_relay();
exit;
}
}
...
</programlisting>
</example>
Expand Down

0 comments on commit db829aa

Please sign in to comment.