11 <carsten@ng-voice.com>
13 Copyright © 2011 Carsten Bock, carsten@ng-voice.com,
14 http://www.ng-voice.com
15 __________________________________________________________________
25 2.2. External Libraries or Applications
29 3.1. default_domain(str)
30 3.2. publish_reginfo(int)
31 3.3. outbound_proxy(str)
32 3.4. server_address(str)
36 4.1. reginfo_handle_notify(uldomain)
37 4.2. reginfo_subscribe(uri[, expires])
41 1.1. Set default_domain parameter
42 1.2. Set publish_reginfo parameter
43 1.3. Set outbound_proxy parameter
44 1.4. Set server_address parameter
45 1.5. reginfo_handle_notify usage
46 1.6. reginfo_subscribe usage
48 Chapter 1. Admin Guide
56 2.2. External Libraries or Applications
60 3.1. default_domain(str)
61 3.2. publish_reginfo(int)
62 3.3. outbound_proxy(str)
63 3.4. server_address(str)
67 4.1. reginfo_handle_notify(uldomain)
68 4.2. reginfo_subscribe(uri[, expires])
72 This modules publishes information about "reg"-events according to to
73 RFC 3680. This can be used distribute the registration-info status to
74 the subscribed watchers.
76 This module "PUBLISH"es information when a new user registers at this
77 server (e.g. when "save()" is called) to users, which have subscribed
78 for the reg-info for this user.
80 This module can "SUBSCRIBE" for information at another server, so it
81 will receive "NOTIFY"-requests, when the information about a user
84 And finally, it can process received "NOTIFY" requests and it will
85 update the local registry accordingly.
87 Use cases for this might be:
88 * Keeping different Servers in Sync regarding the location database
89 * Get notified, when a user registers: A presence-server, which
90 handles offline message storage for an account, would get notified,
91 when the user comes online.
92 * A client could subscribe to it's own registration-status, so he
93 would get notified as soon as his account gets administratively
100 2.2. External Libraries or Applications
102 2.1. Kamailio Modules
104 The following modules must be loaded before this module:
108 2.2. External Libraries or Applications
114 3.1. default_domain(str)
115 3.2. publish_reginfo(int)
116 3.3. outbound_proxy(str)
117 3.4. server_address(str)
119 3.1. default_domain(str)
121 The default domain for the registered users to be used when
122 constructing the uri for the registrar callback.
124 Default value is “NULL”.
126 Example 1.1. Set default_domain parameter
128 modparam("pua_reginfo", "default_domain", "kamailio.org")
131 3.2. publish_reginfo(int)
133 Whether or not to generate PUBLISH requests.
135 Default value is “1” (enabled).
137 Example 1.2. Set publish_reginfo parameter
139 modparam("pua_reginfo", "publish_reginfo", 0)
142 3.3. outbound_proxy(str)
144 The outbound_proxy uri to be used when sending Subscribe and Publish
147 Default value is “NULL”.
149 Example 1.3. Set outbound_proxy parameter
151 modparam("pua_reginfo", "outbound_proxy", "sip:proxy@kamailio.org")
154 3.4. server_address(str)
156 The IP address of the server.
158 Example 1.4. Set server_address parameter
160 modparam("pua_reginfo", "server_address", "sip:reginfo@160.34.23.12")
165 4.1. reginfo_handle_notify(uldomain)
166 4.2. reginfo_subscribe(uri[, expires])
168 4.1. reginfo_handle_notify(uldomain)
170 This function processes received "NOTIFY"-requests and updates the
171 local registry accordingly.
173 This method does not create any SIP-Reponse, this has to be done the
176 The parameter has to correspond to user location table (domain) where
180 * 2 - contacts successfully updated, but no more contacts online now.
181 1 - contacts successfully updated and at at least one contact still
183 -1 - Invalid NOTIFY or other error (see log-file)
185 Example 1.5. reginfo_handle_notify usage
187 if(is_method("NOTIFY"))
188 if (reginfo_handle_notify("location"))
189 send_reply("202", "Accepted");
192 4.2. reginfo_subscribe(uri[, expires])
194 This function will subscribe for reginfo-information at the given
197 Meaning of the parameters is as follows:
198 * uri - SIP-URI of the server, where to subscribe, may contain
200 expires - Expiration date for this subscription, in seconds
203 Example 1.6. reginfo_subscribe usage
211 if (t_check_status("200"))
212 reginfo_subscribe("$ru");