Skip to content
This repository

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Newer
Older
100644 427 lines (387 sloc) 22.207 kb
a0fb4e8b » Michal Matyska
2005-12-20 History rewritten, new files GPLized
1 /*
2 * $Id$
3 *
4 * Copyright (C) 2005-2006 iptelorg GmbH
5 *
6 * This file is part of ser, a free SIP server.
7 *
8 * ser is free software; you can redistribute it and/or modify
9 * it under the terms of the GNU General Public License as published by
10 * the Free Software Foundation; either version 2 of the License, or
11 * (at your option) any later version
12 *
13 * For a license to use the ser software under conditions
14 * other than those described here, or to purchase support for this
15 * software, please contact iptel.org by e-mail at the following addresses:
16 * info@iptel.org
17 *
18 * ser is distributed in the hope that it will be useful,
19 * but WITHOUT ANY WARRANTY; without even the implied warranty of
20 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
21 * GNU General Public License for more details.
22 *
23 * You should have received a copy of the GNU General Public License
24 * along with this program; if not, write to the Free Software
25 * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
26 *
27 * History:
28 * --------
29 * 2005-12-19 select framework, basic core functions (mma)
43f88e4f » Michal Matyska
2006-01-19 - multiple nested calls allowed
30 * 2006-01-19 multiple nested calls, IS_ALIAS -> NESTED flag renamed (mma)
e7317b87 » Gergely Kovacs
2007-03-08 Date, Identity, Identity-info HF support added
31 * 2007-01-26 date, identity, identity_info support added (gergo)
a0fb4e8b » Michal Matyska
2005-12-20 History rewritten, new files GPLized
32 */
33
34
3fb428ed » Michal Matyska
2005-12-20 New script element, Jan's select function framework (@xxx), extended for
35 #ifndef _SELECT_CORE_H
36 #define _SELECT_CORE_H
37
38 #include "str.h"
39 #include "parser/msg_parser.h"
40 #include "select.h"
41
d6f89ee4 » Michal Matyska
2005-12-20 Message core select functions implemented:
42 enum {
43 SEL_PARAM_TAG,
b4fb73d0 » janakj
2009-03-19 Rename Contact parameter select 'method' to 'methods'
44 SEL_PARAM_Q, SEL_PARAM_EXPIRES, SEL_PARAM_METHODS, SEL_PARAM_RECEIVED, SEL_PARAM_INSTANCE,
d6f89ee4 » Michal Matyska
2005-12-20 Message core select functions implemented:
45 SEL_PARAM_BRANCH, SEL_PARAM_RPORT, SEL_PARAM_I, SEL_PARAM_ALIAS
46 };
47
3917797b » janakj
2006-06-27 - support for digest credentials selects, supported is:
48 enum {
49 SEL_AUTH_PROXY,
50 SEL_AUTH_WWW,
51 SEL_AUTH_USERNAME,
52 SEL_AUTH_USER,
53 SEL_AUTH_DOMAIN,
54 SEL_AUTH_REALM,
55 SEL_AUTH_NONCE,
56 SEL_AUTH_URI,
57 SEL_AUTH_CNONCE,
58 SEL_AUTH_NC,
59 SEL_AUTH_RESPONSE,
60 SEL_AUTH_OPAQUE,
61 SEL_AUTH_ALG,
62 SEL_AUTH_QOP
63 };
64
c51c5eb6 » Michal Matyska
2006-10-20 new select functions:
65 enum {
66 SEL_SRC = 1<<0,
67 SEL_DST = 1<<1,
68 SEL_RCV = 1<<2,
69 SEL_PROTO= 1<<5,
70 SEL_IP = 1<<6,
71 SEL_PORT = 1<<7,
72 SEL_IP_PORT = SEL_IP | SEL_PORT,
73 };
74
7e381ae0 » Tomas Mandys
2007-02-18 - added (uint|int|str)_to_static_buffer functions to select_buffer
75 enum {
76 SEL_NOW_GMT = 1,
77 SEL_NOW_LOCAL = 2
78 };
79
80 enum {
81 SEL_BRANCH_URI = 1<<0,
82 SEL_BRANCH_Q = 1<<1,
83 SEL_BRANCH_DST_URI = 1<<2
84 };
85
04023b50 » Michal Matyska
2006-03-21 Core select R-URI splitting into parts introduced: @ruri.(type|user|h…
86 SELECT_F(select_ruri)
eea15f43 » Miklos Tirpak
2006-12-12 @dst_uri and @next_hop select calls are introduced:
87 SELECT_F(select_dst_uri)
88 SELECT_F(select_next_hop)
3d55e464 » Tomas Mandys
2009-06-02 - @next_hop.src_ip: source ip of outgoing message
89 SELECT_F(select_next_hop_src_ip)
d6f89ee4 » Michal Matyska
2005-12-20 Message core select functions implemented:
90 SELECT_F(select_from)
91 SELECT_F(select_from_uri)
92 SELECT_F(select_from_tag)
93 SELECT_F(select_from_name)
94 SELECT_F(select_from_params)
95 SELECT_F(select_to)
96 SELECT_F(select_to_uri)
97 SELECT_F(select_to_tag)
98 SELECT_F(select_to_name)
99 SELECT_F(select_to_params)
7e381ae0 » Tomas Mandys
2007-02-18 - added (uint|int|str)_to_static_buffer functions to select_buffer
100 SELECT_F(select_refer_to)
101 SELECT_F(select_refer_to_uri)
102 SELECT_F(select_refer_to_tag)
103 SELECT_F(select_refer_to_name)
104 SELECT_F(select_refer_to_params)
105 SELECT_F(select_rpid)
106 SELECT_F(select_rpid_uri)
107 SELECT_F(select_rpid_tag)
108 SELECT_F(select_rpid_name)
109 SELECT_F(select_rpid_params)
d6f89ee4 » Michal Matyska
2005-12-20 Message core select functions implemented:
110 SELECT_F(select_contact)
111 SELECT_F(select_contact_uri)
112 SELECT_F(select_contact_name)
113 SELECT_F(select_contact_params)
114 SELECT_F(select_contact_params_spec)
115 SELECT_F(select_via)
116 SELECT_F(select_via_name)
117 SELECT_F(select_via_version)
118 SELECT_F(select_via_transport)
119 SELECT_F(select_via_host)
120 SELECT_F(select_via_port)
121 SELECT_F(select_via_comment)
122 SELECT_F(select_via_params)
123 SELECT_F(select_via_params_spec)
124
7e381ae0 » Tomas Mandys
2007-02-18 - added (uint|int|str)_to_static_buffer functions to select_buffer
125 SELECT_F(select_msg)
126 SELECT_F(select_msg_first_line)
127 SELECT_F(select_msg_flags)
128 SELECT_F(select_msg_type)
129 SELECT_F(select_msg_len)
130 SELECT_F(select_msg_id)
131 SELECT_F(select_msg_id_hex)
132 SELECT_F(select_msg_body)
6f2858cb » Miklos Tirpak
2008-05-22 @msg.body.sdp select call is introduced, that returns the sdp part
133 SELECT_F(select_msg_body_sdp)
54b827f3 » Miklos Tirpak
2008-05-22 @msg.body.sdp.line.line_name select call is implemented.
134 SELECT_F(select_sdp_line)
7e381ae0 » Tomas Mandys
2007-02-18 - added (uint|int|str)_to_static_buffer functions to select_buffer
135 SELECT_F(select_msg_header)
d6f89ee4 » Michal Matyska
2005-12-20 Message core select functions implemented:
136 SELECT_F(select_anyheader)
60c006fa » Michal Matyska
2006-06-30 params retrieving extended to
137 SELECT_F(select_anyheader_params)
7e381ae0 » Tomas Mandys
2007-02-18 - added (uint|int|str)_to_static_buffer functions to select_buffer
138 SELECT_F(select_msg_request)
139 SELECT_F(select_msg_request_method)
140 SELECT_F(select_msg_request_uri)
141 SELECT_F(select_msg_request_version)
142 SELECT_F(select_msg_response)
143 SELECT_F(select_msg_response_version)
144 SELECT_F(select_msg_response_status)
145 SELECT_F(select_msg_response_reason)
146 SELECT_F(select_version)
d6f89ee4 » Michal Matyska
2005-12-20 Message core select functions implemented:
147
84b87bd3 » Michal Matyska
2006-06-27 nameaddr support in select framework
148 SELECT_F(select_any_nameaddr)
149 SELECT_F(select_nameaddr_name)
150 SELECT_F(select_nameaddr_uri)
60c006fa » Michal Matyska
2006-06-30 params retrieving extended to
151 SELECT_F(select_nameaddr_params)
152 SELECT_F(select_any_params)
84b87bd3 » Michal Matyska
2006-06-27 nameaddr support in select framework
153
d6f89ee4 » Michal Matyska
2005-12-20 Message core select functions implemented:
154 SELECT_F(select_any_uri)
155 SELECT_F(select_uri_type)
156 SELECT_F(select_uri_user)
c98100c7 » Miklos Tirpak
2009-05-13 @ruri.rn_user is introduced.
157 SELECT_F(select_uri_rn_user)
d6f89ee4 » Michal Matyska
2005-12-20 Message core select functions implemented:
158 SELECT_F(select_uri_pwd)
159 SELECT_F(select_uri_host)
160 SELECT_F(select_uri_port)
8c5e4afe » Michal Matyska
2006-06-21 select_buf:
161 SELECT_F(select_uri_hostport)
d6f89ee4 » Michal Matyska
2005-12-20 Message core select functions implemented:
162 SELECT_F(select_uri_params)
f90ef683 » Michal Matyska
2008-02-15 - adding any_uri.transport select
163 SELECT_F(select_uri_proto)
d6f89ee4 » Michal Matyska
2005-12-20 Message core select functions implemented:
164
750057b9 » janakj
2006-02-16 - support for @event
165 SELECT_F(select_event)
166
167 SELECT_F(select_rr)
168 SELECT_F(select_rr_uri)
169 SELECT_F(select_rr_name)
170 SELECT_F(select_rr_params)
171
172 SELECT_F(select_cseq)
173 SELECT_F(select_cseq_method)
174 SELECT_F(select_cseq_num)
175
3917797b » janakj
2006-06-27 - support for digest credentials selects, supported is:
176 SELECT_F(select_auth)
177 SELECT_F(select_auth_param)
178 SELECT_F(select_auth_username)
179 SELECT_F(select_auth_username_comp)
180
c51c5eb6 » Michal Matyska
2006-10-20 new select functions:
181 SELECT_F(select_src)
182 SELECT_F(select_dst)
183 SELECT_F(select_rcv)
184 SELECT_F(select_ip_port)
185
7e381ae0 » Tomas Mandys
2007-02-18 - added (uint|int|str)_to_static_buffer functions to select_buffer
186 SELECT_F(select_call_id)
187 SELECT_F(select_expires)
188 SELECT_F(select_max_forwards)
189 SELECT_F(select_content_type)
190 SELECT_F(select_content_length)
191 SELECT_F(select_subject)
192 SELECT_F(select_organization)
193 SELECT_F(select_priority)
194 SELECT_F(select_session_expires)
195 SELECT_F(select_min_se)
196 SELECT_F(select_user_agent)
197 SELECT_F(select_sip_if_match)
198
199 SELECT_F(select_sys)
200 SELECT_F(select_sys_pid)
4bb044d3 » janakj
2008-04-16 - added @sys.server_id select, this select will obtain the ID of the SER
201 SELECT_F(select_sys_server_id)
7e381ae0 » Tomas Mandys
2007-02-18 - added (uint|int|str)_to_static_buffer functions to select_buffer
202 SELECT_F(select_sys_unique)
203 SELECT_F(select_sys_now)
204 SELECT_F(select_sys_now_fmt)
205
206 SELECT_F(select_branch)
207 SELECT_F(select_branch_count)
208 SELECT_F(select_branch_uri)
209 SELECT_F(select_branch_dst_uri)
210 SELECT_F(select_branch_uriq)
211 SELECT_F(select_branch_q)
212
e7317b87 » Gergely Kovacs
2007-03-08 Date, Identity, Identity-info HF support added
213 SELECT_F(select_date)
214 SELECT_F(select_identity)
215 SELECT_F(select_identity_info)
216
79c64f4c » Miklos Tirpak
2008-01-11 configuration values can be retrieved in the script via selects:
217 SELECT_F(select_cfg_var)
5afd88dd » Miklos Tirpak
2011-01-31 cfg framework: @cfg_get supports nested calls
218 SELECT_F(select_cfg_var1)
f9ad9ccf » Miklos Tirpak
2011-01-31 cfg framework: @cfg_selected.group added
219 SELECT_F(cfg_selected_inst)
79c64f4c » Miklos Tirpak
2008-01-11 configuration values can be retrieved in the script via selects:
220
3fb428ed » Michal Matyska
2005-12-20 New script element, Jan's select function framework (@xxx), extended for
221 static select_row_t select_core[] = {
7e381ae0 » Tomas Mandys
2007-02-18 - added (uint|int|str)_to_static_buffer functions to select_buffer
222 { NULL, SEL_PARAM_STR, STR_STATIC_INIT("ruri"), select_ruri, 0}, /* not the same as request.uri because it is involved by new_uri */
223 { NULL, SEL_PARAM_STR, STR_STATIC_INIT("request_uri"), select_ruri, 0},
04023b50 » Michal Matyska
2006-03-21 Core select R-URI splitting into parts introduced: @ruri.(type|user|h…
224 { select_ruri, SEL_PARAM_STR, STR_NULL, select_any_uri, NESTED},
eea15f43 » Miklos Tirpak
2006-12-12 @dst_uri and @next_hop select calls are introduced:
225 { NULL, SEL_PARAM_STR, STR_STATIC_INIT("dst_uri"), select_dst_uri, 0},
226 { select_dst_uri, SEL_PARAM_STR, STR_NULL, select_any_uri, NESTED},
227 { NULL, SEL_PARAM_STR, STR_STATIC_INIT("next_hop"), select_next_hop, 0},
3d55e464 » Tomas Mandys
2009-06-02 - @next_hop.src_ip: source ip of outgoing message
228 { select_next_hop, SEL_PARAM_STR, STR_STATIC_INIT("src_ip"), select_next_hop_src_ip, 0},
eea15f43 » Miklos Tirpak
2006-12-12 @dst_uri and @next_hop select calls are introduced:
229 { select_next_hop, SEL_PARAM_STR, STR_NULL, select_any_uri, NESTED},
ec2b7f55 » Michal Matyska
2006-01-07 PARAM_xxx changed into SEL_PARAM_xxx to avoid conflict with global
230 { NULL, SEL_PARAM_STR, STR_STATIC_INIT("from"), select_from, 0},
231 { NULL, SEL_PARAM_STR, STR_STATIC_INIT("f"), select_from, 0},
232 { select_from, SEL_PARAM_STR, STR_STATIC_INIT("uri"), select_from_uri, 0},
233 { select_from, SEL_PARAM_STR, STR_STATIC_INIT("tag"), select_from_tag, 0},
234 { select_from, SEL_PARAM_STR, STR_STATIC_INIT("name"), select_from_name, 0},
235 { select_from, SEL_PARAM_STR, STR_STATIC_INIT("params"), select_from_params, CONSUME_NEXT_STR},
236 { NULL, SEL_PARAM_STR, STR_STATIC_INIT("to"), select_to, 0},
237 { NULL, SEL_PARAM_STR, STR_STATIC_INIT("t"), select_to, 0},
238 { select_to, SEL_PARAM_STR, STR_STATIC_INIT("uri"), select_to_uri, 0},
239 { select_to, SEL_PARAM_STR, STR_STATIC_INIT("tag"), select_to_tag, 0},
240 { select_to, SEL_PARAM_STR, STR_STATIC_INIT("name"), select_to_name, 0},
241 { select_to, SEL_PARAM_STR, STR_STATIC_INIT("params"), select_to_params, CONSUME_NEXT_STR},
7e381ae0 » Tomas Mandys
2007-02-18 - added (uint|int|str)_to_static_buffer functions to select_buffer
242 { NULL, SEL_PARAM_STR, STR_STATIC_INIT("refer_to"), select_refer_to, 0},
243 { select_refer_to, SEL_PARAM_STR, STR_STATIC_INIT("uri"), select_refer_to_uri, 0},
244 { select_refer_to, SEL_PARAM_STR, STR_STATIC_INIT("tag"), select_refer_to_tag, 0},
245 { select_refer_to, SEL_PARAM_STR, STR_STATIC_INIT("name"), select_refer_to_name, 0},
246 { select_refer_to, SEL_PARAM_STR, STR_STATIC_INIT("params"), select_refer_to_params, CONSUME_NEXT_STR},
247 { NULL, SEL_PARAM_STR, STR_STATIC_INIT("remote_party_id"), select_rpid, 0},
248 { NULL, SEL_PARAM_STR, STR_STATIC_INIT("rpid"), select_rpid, 0},
249 { select_rpid, SEL_PARAM_STR, STR_STATIC_INIT("uri"), select_rpid_uri, 0},
250 { select_rpid, SEL_PARAM_STR, STR_STATIC_INIT("tag"), select_rpid_tag, 0},
251 { select_rpid, SEL_PARAM_STR, STR_STATIC_INIT("name"), select_rpid_name, 0},
252 { select_rpid, SEL_PARAM_STR, STR_STATIC_INIT("params"), select_rpid_params, CONSUME_NEXT_STR},
ec2b7f55 » Michal Matyska
2006-01-07 PARAM_xxx changed into SEL_PARAM_xxx to avoid conflict with global
253 { NULL, SEL_PARAM_STR, STR_STATIC_INIT("contact"), select_contact, 0},
254 { NULL, SEL_PARAM_STR, STR_STATIC_INIT("m"), select_contact, 0},
255 { select_contact, SEL_PARAM_STR, STR_STATIC_INIT("uri"), select_contact_uri, 0},
256 { select_contact, SEL_PARAM_STR, STR_STATIC_INIT("name"), select_contact_name, 0},
257 { select_contact, SEL_PARAM_STR, STR_STATIC_INIT("q"), select_contact_params_spec, DIVERSION | SEL_PARAM_Q},
258 { select_contact, SEL_PARAM_STR, STR_STATIC_INIT("expires"), select_contact_params_spec, DIVERSION | SEL_PARAM_EXPIRES},
b4fb73d0 » janakj
2009-03-19 Rename Contact parameter select 'method' to 'methods'
259 { select_contact, SEL_PARAM_STR, STR_STATIC_INIT("methods"), select_contact_params_spec, DIVERSION | SEL_PARAM_METHODS},
ec2b7f55 » Michal Matyska
2006-01-07 PARAM_xxx changed into SEL_PARAM_xxx to avoid conflict with global
260 { select_contact, SEL_PARAM_STR, STR_STATIC_INIT("received"), select_contact_params_spec, DIVERSION | SEL_PARAM_RECEIVED},
261 { select_contact, SEL_PARAM_STR, STR_STATIC_INIT("instance"), select_contact_params_spec, DIVERSION | SEL_PARAM_INSTANCE},
262 { select_contact, SEL_PARAM_STR, STR_STATIC_INIT("params"), select_contact_params, CONSUME_NEXT_STR},
263 { NULL, SEL_PARAM_STR, STR_STATIC_INIT("via"), select_via, OPTIONAL | CONSUME_NEXT_INT},
264 { NULL, SEL_PARAM_STR, STR_STATIC_INIT("v"), select_via, OPTIONAL | CONSUME_NEXT_INT},
265 { select_via, SEL_PARAM_STR, STR_STATIC_INIT("name"), select_via_name, 0},
266 { select_via, SEL_PARAM_STR, STR_STATIC_INIT("version"), select_via_version, 0},
267 { select_via, SEL_PARAM_STR, STR_STATIC_INIT("transport"), select_via_transport, 0},
268 { select_via, SEL_PARAM_STR, STR_STATIC_INIT("host"), select_via_host, 0},
269 { select_via, SEL_PARAM_STR, STR_STATIC_INIT("port"), select_via_port, 0},
270 { select_via, SEL_PARAM_STR, STR_STATIC_INIT("comment"), select_via_comment, 0},
271 { select_via, SEL_PARAM_STR, STR_STATIC_INIT("branch"), select_via_params_spec, DIVERSION | SEL_PARAM_BRANCH},
272 { select_via, SEL_PARAM_STR, STR_STATIC_INIT("received"), select_via_params_spec, DIVERSION | SEL_PARAM_RECEIVED},
273 { select_via, SEL_PARAM_STR, STR_STATIC_INIT("rport"), select_via_params_spec, DIVERSION | SEL_PARAM_RPORT},
274 { select_via, SEL_PARAM_STR, STR_STATIC_INIT("i"), select_via_params_spec, DIVERSION | SEL_PARAM_I},
275 { select_via, SEL_PARAM_STR, STR_STATIC_INIT("alias"), select_via_params_spec, DIVERSION | SEL_PARAM_ALIAS},
276 { select_via, SEL_PARAM_STR, STR_STATIC_INIT("params"), select_via_params, CONSUME_NEXT_STR},
d6f89ee4 » Michal Matyska
2005-12-20 Message core select functions implemented:
277
43f88e4f » Michal Matyska
2006-01-19 - multiple nested calls allowed
278 { select_from_uri, SEL_PARAM_INT, STR_NULL, select_any_uri, NESTED},
279 { select_to_uri, SEL_PARAM_INT, STR_NULL, select_any_uri, NESTED},
7e381ae0 » Tomas Mandys
2007-02-18 - added (uint|int|str)_to_static_buffer functions to select_buffer
280 { select_refer_to_uri, SEL_PARAM_INT, STR_NULL, select_any_uri, NESTED},
281 { select_rpid_uri, SEL_PARAM_INT, STR_NULL, select_any_uri, NESTED},
43f88e4f » Michal Matyska
2006-01-19 - multiple nested calls allowed
282 { select_contact_uri, SEL_PARAM_INT, STR_NULL, select_any_uri, NESTED},
750057b9 » janakj
2006-02-16 - support for @event
283 { select_rr_uri, SEL_PARAM_INT, STR_NULL, select_any_uri, NESTED},
ec2b7f55 » Michal Matyska
2006-01-07 PARAM_xxx changed into SEL_PARAM_xxx to avoid conflict with global
284 { select_any_uri, SEL_PARAM_STR, STR_STATIC_INIT("type"), select_uri_type, 0},
285 { select_any_uri, SEL_PARAM_STR, STR_STATIC_INIT("user"), select_uri_user, 0},
c98100c7 » Miklos Tirpak
2009-05-13 @ruri.rn_user is introduced.
286 { select_any_uri, SEL_PARAM_STR, STR_STATIC_INIT("rn_user"), select_uri_rn_user, 0},
ec2b7f55 » Michal Matyska
2006-01-07 PARAM_xxx changed into SEL_PARAM_xxx to avoid conflict with global
287 { select_any_uri, SEL_PARAM_STR, STR_STATIC_INIT("pwd"), select_uri_pwd, 0},
288 { select_any_uri, SEL_PARAM_STR, STR_STATIC_INIT("host"), select_uri_host, 0},
289 { select_any_uri, SEL_PARAM_STR, STR_STATIC_INIT("port"), select_uri_port, 0},
1ee35cdc » Michal Matyska
2006-06-27 uri.params.XXXX now acceped and returns value of that parameter, or e…
290 { select_any_uri, SEL_PARAM_STR, STR_STATIC_INIT("params"), select_uri_params, CONSUME_NEXT_STR | OPTIONAL | FIXUP_CALL },
8c5e4afe » Michal Matyska
2006-06-21 select_buf:
291 { select_any_uri, SEL_PARAM_STR, STR_STATIC_INIT("hostport"), select_uri_hostport, 0},
f90ef683 » Michal Matyska
2008-02-15 - adding any_uri.transport select
292 { select_any_uri, SEL_PARAM_STR, STR_STATIC_INIT("transport"), select_uri_proto, 0},
d0cf3d0b » Michal Matyska
2006-06-27 select core extension:
293
750057b9 » janakj
2006-02-16 - support for @event
294 { NULL, SEL_PARAM_STR, STR_STATIC_INIT("event"), select_event, 0},
295
296 { NULL, SEL_PARAM_STR, STR_STATIC_INIT("record_route"), select_rr, 0},
297 { NULL, SEL_PARAM_STR, STR_STATIC_INIT("rr"), select_rr, 0},
298 { select_rr, SEL_PARAM_STR, STR_STATIC_INIT("uri"), select_rr_uri, 0},
299 { select_rr, SEL_PARAM_STR, STR_STATIC_INIT("name"), select_rr_name, 0},
300 { select_rr, SEL_PARAM_STR, STR_STATIC_INIT("params"), select_rr_params, CONSUME_NEXT_STR},
301
b9e4bf3f » Michal Matyska
2006-02-17 Select framework extended to "fixup call" if demanded using flag FIXU…
302 { NULL, SEL_PARAM_STR, STR_STATIC_INIT("cseq"), select_cseq, 0},
303 { select_cseq, SEL_PARAM_STR, STR_STATIC_INIT("num"), select_cseq_num, 0},
304 { select_cseq, SEL_PARAM_STR, STR_STATIC_INIT("method"), select_cseq_method, 0},
750057b9 » janakj
2006-02-16 - support for @event
305
84b87bd3 » Michal Matyska
2006-06-27 nameaddr support in select framework
306 { select_any_nameaddr, SEL_PARAM_STR, STR_STATIC_INIT("name"), select_nameaddr_name, 0},
307 { select_any_nameaddr, SEL_PARAM_STR, STR_STATIC_INIT("uri"), select_nameaddr_uri, 0},
eefc1a3a » Michal Matyska
2006-06-30 nameaddr.params corrected (when used from nested selects)
308 { select_any_nameaddr, SEL_PARAM_STR, STR_STATIC_INIT("params"), select_nameaddr_params, OPTIONAL | CONSUME_NEXT_STR},
84b87bd3 » Michal Matyska
2006-06-27 nameaddr support in select framework
309 { select_nameaddr_uri, SEL_PARAM_INT, STR_NULL, select_any_uri, NESTED},
310
7e381ae0 » Tomas Mandys
2007-02-18 - added (uint|int|str)_to_static_buffer functions to select_buffer
311 { NULL, SEL_PARAM_STR, STR_STATIC_INIT("msg"), select_msg, 0},
312 { NULL, SEL_PARAM_STR, STR_STATIC_INIT("message"), select_msg, 0},
313 { select_msg, SEL_PARAM_STR, STR_STATIC_INIT("first_line"), select_msg_first_line, 0},
314 { select_msg, SEL_PARAM_STR, STR_STATIC_INIT("flags"), select_msg_flags, 0},
315 { select_msg, SEL_PARAM_STR, STR_STATIC_INIT("len"), select_msg_len, 0},
316 { select_msg, SEL_PARAM_STR, STR_STATIC_INIT("id"), select_msg_id, 0},
317 { select_msg_id, SEL_PARAM_STR, STR_STATIC_INIT("hex"), select_msg_id_hex, 0},
318 { select_msg, SEL_PARAM_STR, STR_STATIC_INIT("type"), select_msg_type, 0},
319 { select_msg, SEL_PARAM_STR, STR_STATIC_INIT("header"), select_msg_header, 0},
320 { select_msg, SEL_PARAM_STR, STR_STATIC_INIT("h"), select_msg_header, 0},
321 { select_msg_header, SEL_PARAM_STR, STR_NULL, select_anyheader, OPTIONAL | CONSUME_NEXT_INT | FIXUP_CALL},
60c006fa » Michal Matyska
2006-06-30 params retrieving extended to
322 { select_anyheader, SEL_PARAM_STR, STR_STATIC_INIT("nameaddr"), select_any_nameaddr, NESTED | CONSUME_NEXT_STR},
323 { select_anyheader, SEL_PARAM_STR, STR_STATIC_INIT("params"), select_anyheader_params, NESTED},
324 { select_anyheader_params, SEL_PARAM_STR, STR_STATIC_INIT("params"), select_any_params, CONSUME_NEXT_STR},
7e381ae0 » Tomas Mandys
2007-02-18 - added (uint|int|str)_to_static_buffer functions to select_buffer
325 { select_msg, SEL_PARAM_STR, STR_STATIC_INIT("body"), select_msg_body, 0},
326 { select_msg, SEL_PARAM_STR, STR_STATIC_INIT("content"), select_msg_body, 0},
6f2858cb » Miklos Tirpak
2008-05-22 @msg.body.sdp select call is introduced, that returns the sdp part
327 { select_msg_body, SEL_PARAM_STR, STR_STATIC_INIT("sdp"), select_msg_body_sdp, 0},
54b827f3 » Miklos Tirpak
2008-05-22 @msg.body.sdp.line.line_name select call is implemented.
328 { select_msg_body_sdp, SEL_PARAM_STR, STR_STATIC_INIT("line"), select_sdp_line, CONSUME_NEXT_STR | FIXUP_CALL},
7e381ae0 » Tomas Mandys
2007-02-18 - added (uint|int|str)_to_static_buffer functions to select_buffer
329 { select_msg, SEL_PARAM_STR, STR_STATIC_INIT("request"), select_msg_request, 0},
330 { select_msg, SEL_PARAM_STR, STR_STATIC_INIT("req"), select_msg_request, 0},
331 { select_msg_request, SEL_PARAM_STR, STR_STATIC_INIT("method"), select_msg_request_method, 0},
332 { select_msg_request, SEL_PARAM_STR, STR_STATIC_INIT("uri"), select_msg_request_uri, 0},
333 { select_msg_request_uri, SEL_PARAM_STR, STR_NULL, select_any_uri, NESTED},
334 { select_msg_request, SEL_PARAM_STR, STR_STATIC_INIT("version"), select_msg_request_version, 0},
335 { select_msg, SEL_PARAM_STR, STR_STATIC_INIT("response"), select_msg_response, 0},
336 { select_msg, SEL_PARAM_STR, STR_STATIC_INIT("res"), select_msg_response, 0},
337 { select_msg_response, SEL_PARAM_STR, STR_STATIC_INIT("version"), select_msg_response_version, 0},
338 { select_msg_response, SEL_PARAM_STR, STR_STATIC_INIT("status"), select_msg_response_status, 0},
339 { select_msg_response, SEL_PARAM_STR, STR_STATIC_INIT("code"), select_msg_response_status, 0},
340 { select_msg_response, SEL_PARAM_STR, STR_STATIC_INIT("reason"), select_msg_response_reason, 0},
341 /*short aliases*/
342 { NULL, SEL_PARAM_STR, STR_STATIC_INIT("method"), select_msg_request_method, 0},
343 { NULL, SEL_PARAM_STR, STR_STATIC_INIT("version"), select_version, 0},
344 { NULL, SEL_PARAM_STR, STR_STATIC_INIT("status"), select_msg_response_status, 0},
345 { NULL, SEL_PARAM_STR, STR_STATIC_INIT("code"), select_msg_response_status, 0},
346 { NULL, SEL_PARAM_STR, STR_STATIC_INIT("reason"), select_msg_response_reason, 0},
3917797b » janakj
2006-06-27 - support for digest credentials selects, supported is:
347
ebf528da » Michal Matyska
2007-09-06 fixes SER-304
348 { NULL, SEL_PARAM_STR, STR_STATIC_INIT("proxy_authorization"), select_auth, CONSUME_NEXT_STR | DIVERSION | SEL_AUTH_PROXY | FIXUP_CALL},
349 { NULL, SEL_PARAM_STR, STR_STATIC_INIT("authorization"), select_auth, CONSUME_NEXT_STR | DIVERSION | SEL_AUTH_WWW | FIXUP_CALL},
3917797b » janakj
2006-06-27 - support for digest credentials selects, supported is:
350 { select_auth, SEL_PARAM_STR, STR_STATIC_INIT("username"), select_auth_username, DIVERSION | SEL_AUTH_USERNAME},
351 { select_auth, SEL_PARAM_STR, STR_STATIC_INIT("realm"), select_auth_param, DIVERSION | SEL_AUTH_REALM},
352 { select_auth, SEL_PARAM_STR, STR_STATIC_INIT("nonce"), select_auth_param, DIVERSION | SEL_AUTH_NONCE},
353 { select_auth, SEL_PARAM_STR, STR_STATIC_INIT("uri"), select_auth_param, DIVERSION | SEL_AUTH_URI},
354 { select_auth, SEL_PARAM_STR, STR_STATIC_INIT("cnonce"), select_auth_param, DIVERSION | SEL_AUTH_CNONCE},
355 { select_auth, SEL_PARAM_STR, STR_STATIC_INIT("nc"), select_auth_param, DIVERSION | SEL_AUTH_NC},
356 { select_auth, SEL_PARAM_STR, STR_STATIC_INIT("response"), select_auth_param, DIVERSION | SEL_AUTH_RESPONSE},
357 { select_auth, SEL_PARAM_STR, STR_STATIC_INIT("opaque"), select_auth_param, DIVERSION | SEL_AUTH_OPAQUE},
358 { select_auth, SEL_PARAM_STR, STR_STATIC_INIT("algorithm"), select_auth_param, DIVERSION | SEL_AUTH_ALG},
359 { select_auth, SEL_PARAM_STR, STR_STATIC_INIT("qop"), select_auth_param, DIVERSION | SEL_AUTH_QOP},
360 { select_auth_username, SEL_PARAM_STR, STR_STATIC_INIT("user"), select_auth_username_comp, DIVERSION | SEL_AUTH_USER},
361 { select_auth_username, SEL_PARAM_STR, STR_STATIC_INIT("domain"), select_auth_username_comp, DIVERSION | SEL_AUTH_DOMAIN},
362
c51c5eb6 » Michal Matyska
2006-10-20 new select functions:
363 { NULL, SEL_PARAM_STR, STR_STATIC_INIT("src"), select_src, SEL_PARAM_EXPECTED},
364 { select_src, SEL_PARAM_STR, STR_STATIC_INIT("ip"), select_ip_port, DIVERSION | SEL_SRC | SEL_IP},
365 { select_src, SEL_PARAM_STR, STR_STATIC_INIT("port"), select_ip_port, DIVERSION | SEL_SRC | SEL_PORT},
366 { select_src, SEL_PARAM_STR, STR_STATIC_INIT("ip_port"), select_ip_port, DIVERSION | SEL_SRC | SEL_IP_PORT},
367 { NULL, SEL_PARAM_STR, STR_STATIC_INIT("dst"), select_dst, SEL_PARAM_EXPECTED},
368 { select_dst, SEL_PARAM_STR, STR_STATIC_INIT("ip"), select_ip_port, DIVERSION | SEL_DST | SEL_IP},
369 { select_dst, SEL_PARAM_STR, STR_STATIC_INIT("port"), select_ip_port, DIVERSION | SEL_DST | SEL_PORT},
370 { select_dst, SEL_PARAM_STR, STR_STATIC_INIT("ip_port"), select_ip_port, DIVERSION | SEL_DST | SEL_IP_PORT},
371 { NULL, SEL_PARAM_STR, STR_STATIC_INIT("received"), select_rcv, SEL_PARAM_EXPECTED},
372 { select_rcv, SEL_PARAM_STR, STR_STATIC_INIT("proto"), select_ip_port, DIVERSION | SEL_RCV | SEL_PROTO},
373 { select_rcv, SEL_PARAM_STR, STR_STATIC_INIT("ip"), select_ip_port, DIVERSION | SEL_RCV | SEL_IP},
374 { select_rcv, SEL_PARAM_STR, STR_STATIC_INIT("port"), select_ip_port, DIVERSION | SEL_RCV | SEL_PORT},
375 { select_rcv, SEL_PARAM_STR, STR_STATIC_INIT("ip_port"), select_ip_port, DIVERSION | SEL_RCV | SEL_IP_PORT},
376 { select_rcv, SEL_PARAM_STR, STR_STATIC_INIT("proto_ip_port"), select_ip_port, DIVERSION | SEL_RCV | SEL_PROTO | SEL_IP_PORT},
377
7e381ae0 » Tomas Mandys
2007-02-18 - added (uint|int|str)_to_static_buffer functions to select_buffer
378 { NULL, SEL_PARAM_STR, STR_STATIC_INIT("call_id"), select_call_id, 0},
379 { NULL, SEL_PARAM_STR, STR_STATIC_INIT("expires"), select_expires, 0},
380 { NULL, SEL_PARAM_STR, STR_STATIC_INIT("max_forwards"), select_max_forwards, 0},
381 { NULL, SEL_PARAM_STR, STR_STATIC_INIT("content_type"), select_content_type, 0},
382 { NULL, SEL_PARAM_STR, STR_STATIC_INIT("content_length"), select_content_length, 0},
383 { NULL, SEL_PARAM_STR, STR_STATIC_INIT("subject"), select_subject, 0},
384 { NULL, SEL_PARAM_STR, STR_STATIC_INIT("organization"), select_organization, 0},
385 { NULL, SEL_PARAM_STR, STR_STATIC_INIT("priority"), select_priority, 0},
386 { NULL, SEL_PARAM_STR, STR_STATIC_INIT("session_expires"), select_session_expires, 0},
387 { NULL, SEL_PARAM_STR, STR_STATIC_INIT("min_se"), select_min_se, 0},
388 { NULL, SEL_PARAM_STR, STR_STATIC_INIT("user_agent"), select_user_agent, 0},
389 { NULL, SEL_PARAM_STR, STR_STATIC_INIT("sip_if_match"), select_sip_if_match, 0},
390
391 { NULL, SEL_PARAM_STR, STR_STATIC_INIT("sys"), select_sys, SEL_PARAM_EXPECTED},
392 { select_sys, SEL_PARAM_STR, STR_STATIC_INIT("pid"), select_sys_pid, 0},
393 { select_sys, SEL_PARAM_STR, STR_STATIC_INIT("unique"), select_sys_unique, 0},
394 { select_sys, SEL_PARAM_STR, STR_STATIC_INIT("now"), select_sys_now, 0},
395 { select_sys_now, SEL_PARAM_STR, STR_STATIC_INIT("local"), select_sys_now_fmt, OPTIONAL | CONSUME_NEXT_STR | DIVERSION | SEL_NOW_LOCAL},
396 { select_sys_now, SEL_PARAM_STR, STR_STATIC_INIT("gmt"), select_sys_now_fmt, OPTIONAL | CONSUME_NEXT_STR | DIVERSION | SEL_NOW_GMT},
397 { select_sys_now, SEL_PARAM_STR, STR_STATIC_INIT("utc"), select_sys_now_fmt, OPTIONAL | CONSUME_NEXT_STR | DIVERSION | SEL_NOW_GMT},
4bb044d3 » janakj
2008-04-16 - added @sys.server_id select, this select will obtain the ID of the SER
398 { select_sys, SEL_PARAM_STR, STR_STATIC_INIT("server_id"), select_sys_server_id, 0},
7e381ae0 » Tomas Mandys
2007-02-18 - added (uint|int|str)_to_static_buffer functions to select_buffer
399
400 { NULL, SEL_PARAM_STR, STR_STATIC_INIT("branch"), select_branch, SEL_PARAM_EXPECTED},
401 { select_branch, SEL_PARAM_STR, STR_STATIC_INIT("count"), select_branch_count, 0},
402 { select_branch, SEL_PARAM_STR, STR_STATIC_INIT("uri"), select_branch_uri, OPTIONAL | CONSUME_NEXT_INT | DIVERSION | SEL_BRANCH_URI },
403 { select_branch, SEL_PARAM_STR, STR_STATIC_INIT("dst_uri"), select_branch_dst_uri, OPTIONAL | CONSUME_NEXT_INT | DIVERSION | SEL_BRANCH_DST_URI},
404 { select_branch_uri, SEL_PARAM_STR, STR_NULL, select_any_uri, NESTED},
405 { select_branch_dst_uri, SEL_PARAM_STR, STR_NULL, select_any_uri, NESTED},
406 { select_branch, SEL_PARAM_STR, STR_STATIC_INIT("uriq"), select_branch_uriq, OPTIONAL | CONSUME_NEXT_INT | DIVERSION | SEL_BRANCH_URI | SEL_BRANCH_Q},
407 { select_branch_uriq, SEL_PARAM_STR, STR_NULL, select_any_nameaddr, NESTED},
408 { select_branch, SEL_PARAM_STR, STR_STATIC_INIT("q"), select_branch_q, OPTIONAL | CONSUME_NEXT_INT | DIVERSION | SEL_BRANCH_Q},
409
e7317b87 » Gergely Kovacs
2007-03-08 Date, Identity, Identity-info HF support added
410 { NULL, SEL_PARAM_STR, STR_STATIC_INIT("date"), select_date, 0},
411 { NULL, SEL_PARAM_STR, STR_STATIC_INIT("identity"), select_identity, 0},
412 { NULL, SEL_PARAM_STR, STR_STATIC_INIT("identity_info"), select_identity_info, 0},
413
5afd88dd » Miklos Tirpak
2011-01-31 cfg framework: @cfg_get supports nested calls
414 { NULL, SEL_PARAM_STR, STR_STATIC_INIT("cfg_get"), select_cfg_var1, SEL_PARAM_EXPECTED | CONSUME_NEXT_STR},
415 { select_cfg_var1, SEL_PARAM_STR, STR_NULL, select_cfg_var, FIXUP_CALL },
f9ad9ccf » Miklos Tirpak
2011-01-31 cfg framework: @cfg_selected.group added
416 { NULL, SEL_PARAM_STR, STR_STATIC_INIT("cfg_selected"), cfg_selected_inst, CONSUME_NEXT_STR | FIXUP_CALL },
79c64f4c » Miklos Tirpak
2008-01-11 configuration values can be retrieved in the script via selects:
417
5afd88dd » Miklos Tirpak
2011-01-31 cfg framework: @cfg_get supports nested calls
418 { select_cfg_var, SEL_PARAM_STR, STR_STATIC_INIT("nameaddr"), select_any_nameaddr, NESTED | CONSUME_NEXT_STR},
419 { select_cfg_var, SEL_PARAM_STR, STR_STATIC_INIT("uri"), select_any_uri, NESTED | CONSUME_NEXT_STR},
420 { select_cfg_var, SEL_PARAM_STR, STR_STATIC_INIT("params"), select_anyheader_params, NESTED},
421
ec2b7f55 » Michal Matyska
2006-01-07 PARAM_xxx changed into SEL_PARAM_xxx to avoid conflict with global
422 { NULL, SEL_PARAM_INT, STR_NULL, NULL, 0}
3fb428ed » Michal Matyska
2005-12-20 New script element, Jan's select function framework (@xxx), extended for
423 };
424
425 static select_table_t select_core_table = {select_core, NULL};
426
427 #endif // _SELECT_CORE_H
Something went wrong with that request. Please try again.