Module: kamailio
Branch: master
Commit: 16fd5f7d25cd2743428471fcb6c768d4e71bc4c6
URL: 
https://github.com/kamailio/kamailio/commit/16fd5f7d25cd2743428471fcb6c768d4e71bc4c6

Author: Daniel-Constantin Mierla <mico...@gmail.com>
Committer: Daniel-Constantin Mierla <mico...@gmail.com>
Date: 2025-04-02T16:12:05+02:00

siputils: docs for contact_param_encode_alias()

---

Modified: src/modules/siputils/doc/siputils_admin.xml

---

Diff:  
https://github.com/kamailio/kamailio/commit/16fd5f7d25cd2743428471fcb6c768d4e71bc4c6.diff
Patch: 
https://github.com/kamailio/kamailio/commit/16fd5f7d25cd2743428471fcb6c768d4e71bc4c6.patch

---

diff --git a/src/modules/siputils/doc/siputils_admin.xml 
b/src/modules/siputils/doc/siputils_admin.xml
index e92472284df..fffdf2db361 100644
--- a/src/modules/siputils/doc/siputils_admin.xml
+++ b/src/modules/siputils/doc/siputils_admin.xml
@@ -1284,7 +1284,7 @@ if(is_first_hop("1")) { ... }
                        the sending interface.IP address.
                </para>
                <para>
-                       Return Codes: 
+                       Return Codes:
                </para>
                        <itemizedlist>
                                <listitem><para>
@@ -1351,6 +1351,28 @@ if (is_method("REGISTER") and src_ip == 10.0.0.0/8) {
     contact_param_encode("ksu", "sip:1.2.3.4:5060;transport=tcp");
 }
 ...
+</programlisting>
+               </example>
+       </section>
+       <section id="siputils.f.contact_param_encode_alias">
+               <title>
+               <function moreinfo="none">contact_param_encode_alias(pname, 
saddr)</function>
+               </title>
+               <para>
+               Similar to contact_param_encode() but it also adds the alias 
parameter
+               with the encoded source address to the original Contact URI.
+               </para>
+               <para>
+               This function can be used from REQUEST_ROUTE, ONREPLY_ROUTE.
+               </para>
+               <example>
+               <title><function>contact_param_encode_alias</function> 
usage</title>
+               <programlisting format="linespecific">
+...
+if (is_method("SUBSCRIBE") and src_ip == 10.0.0.0/8) {
+    contact_param_encode_alias("ksu", "sip:1.2.3.4:5060;transport=tcp");
+}
+...
 </programlisting>
                </example>
        </section>
@@ -1561,7 +1583,7 @@ if (sip_parse_headers()) {
                        <section id="siputils.v.pcv_status">
                                        
<title><varname>$pcv(status)</varname></title>
                                        <para>
-                                               Returns whether the PCV header 
was successfully parsed, deleted, 
+                                               Returns whether the PCV header 
was successfully parsed, deleted,
                                                newly generated or other.
                                        <itemizedlist>
                                                <listitem><para>

_______________________________________________
Kamailio - Development Mailing List -- sr-dev@lists.kamailio.org
To unsubscribe send an email to sr-dev-le...@lists.kamailio.org
Important: keep the mailing list in the recipients, do not reply only to the 
sender!

Reply via email to