Hi,
In some scenarios, it happens that a request is received with the
following characteristics:
IP xxx.xxx.xxx.xxx:14000 -> server:5060
Via: SIP/2.0/xxx.xxx.xxx.xxx:5060;branch=9hG4bKblah;rport
Normally, we just force_rport() on all incoming requests so that we
reply to the real source port of the request, since most endpoints on
this installation are NAT'd.
However, occasionally we run into a scenario where an ALG or
misconfigured client incorrectly inserts an rport attribute into its
topmost Via, and really expects to receive a response at the
address/port indicated in the Via (i.e. 5060).
Does Kamailio offer a means of dealing with these on a selective basis?
Would refraining from calling force_rport() be enough? Or would it be
necessary to set reply_to_via=1 as well, thus breaking symmetrical
behaviour for the vast majority of the NAT'd endpoints?
In other words, I'm not 100% clear on the following:
1) What impact does force_rport() have if an 'rport' attribute is sent
by the client?
In this case, there should be nothing to "force"; I assume that if the
'rport' attribute is placed by the client, then the proxy will return
replies to the source port of the request even if force_rport() is not
called, because that's the RFC 3581-compatible thing to do. Right?
2) Does reply_to_via=1 override the behaviour hypothesised in #1?
3) Does reply_to_via=1 override force_rport()?
Thanks!
-- Alex
--
Alex Balashov | Principal | Evariste Systems LLC
Tel: +1-706-510-6800 (direct) / +1-800-250-5920 (toll-free)
Web: http://www.evaristesys.com/, http://www.csrpswitch.com/
Dear list,
i have developed a tool that automatically stop the call after some
trigger i use..
For do that i use the kamcmd dlg.end_dlg command.
It work perfectly but i have noticed a problem over the kamailio acc table.
When i kill a specific call using this command.. the acc table don't
write the BYE record for the dialog..
Is that correct ? how can i fix..
I'm using ngrep for verify the SIP dialog and i see the BYE command
correctly on the A and B leg of the call..
Thanks for any idea.
Laura
Hi Guys,
I am using the ndb_mongodb module, and Im just trying to return values from the dispatcher table, in particular the setid of a particular entry depending on its attrs value.
If I query using mongodb shell command it works fine, here I enter test.com and it returns only the setid value, or 2;
db.dispatcher.find( { attrs: "test.com" }, { setid: 1, _id: 0 } ){ "setid" : 2 }
However I have been having issues getting this to work using mongodb_find_one, as I would of thought the following route return the same;
if(mongodb_find_one("ml-mongodb", "kamailiosbc", "dispatcher", "{ \"attrs\" : \"test.com\" },{ \"setid\": \"1\", \"_id\": \"0\" }", "mgr1"))
However it returns all the entries relating to that attrs columm from dispatcher table, instead of just setid.
Is it possible to do this? I am stuggling to find the json format to acheive the same thing.
Also in terms of the mgr1 response, I see its contained within the $mongodb(key), can I drill down to get specific fields from it or would I need to use transformations or jansson to do this?
Many thanks
Jon
Hello,
I have some STUN questions. My plan is to build a P2P connection with ICE
(psua2 or libnice).
1) According to the cookbook (
http://www.kamailio.org/wiki/cookbooks/4.0.x/core) one can activate an
internal STUN server:
stun_allow_stun = 0 | 1 (off | on); default 1
This is followed by:
"Note: STUN support is only available if sip-router/Kamailio was compiled
with STUN support (“make STUN=1 cfg”)"
I did an installation with sudo apt-get ... Is STUN support availbable? How
do I check for STUN support?
2) I ICE it seems to be usual that the body of the SIP request contains an
SDP message that includes the IP addresses and ports to be used. So the
results of the STUN request (and TURN request possibily) are already
included. How does the kamailio STUN server work? Is it an independent STUN
server (caller asks the kamailio STUN server - gets an answer - encodes an
SDP with the external IP adress an port information - starts the SIP
INVITE) ? Or does Kamailio change SDP lines after contacting the internal
STUN server?
3) Is the kanailio STUN server prefered to other STUN servers, for instance
stun.stunprotocol.org?
Thanks
Hermann
Hi all,
I'm facing a strange problem using ds_is_from_list in the failure_route block.
I have 4 servers in a dispatcher group 8201.
Scenario:
A call comes in, gets routed to a backend server from 8201 dispatcher group, the backend replies with a 480.
Then we have:
onreply_route[MANAGE_REPLY] {
[...]
if (ds_is_from_list("8201")) && t_check_status("480") { <<<<<< This gets executed, because the node is in 8201 and the reply was a 480
if (is_present_hf("X-UserID")) {
$var(UserId) = $hdr(X-UserID);
}
}
[...]
}
So far so good, next is:
failure_route[MANAGE_FAILURE] {
[...]
if (ds_is_from_list("8201")) && (t_check_status("480")) { <<<<<< This does NOT get executed.
append_hf("X-UserID: $var(UserId)\r\n");
if (!ds_select_domain("8205","4")) {
xlog("L_ERR", "[$ci] - No additional gateways\n");
t_reply("502","Bad Gateway");
exit;
}
t_set_fr(0,2000);
route(RELAY);
}
[...]
}
To find the problem, I added some logging in the failure_route before entering the IF statement:
if (ds_is_from_list("8201")) xlog("L_NOTICE", "DS is in group 8201"); <<<<< No log, so did NOT match.
if (t_check_status("480")) xlog("L_NOTICE", "Status is 480"); <<<<< Yes log, so DID match.
According to the docs, ds_is_from_list can be used in any route block, so I think I am definitely doing something wrong... or maybe it's a bug??
The idea is to achieve this:
Call comes in from softphone into proxy, proxy sends it to backend, if backend replies with a 480, send it to another dispatcher set (8205). If the 480 comes from somewhere that is not the backend (8201), then do nothing.
Any suggestions?
Thanks in advanced.
Best regards,
Joel.
Este mensaje y, en su caso, los ficheros anexos son confidenciales, especialmente en lo que respecta a los datos personales, y se dirigen exclusivamente al destinatario referenciado.Les informamos que los datos contenidos en el presente mail, han sido facilitados por usted o recogidos de Fuentes Accesibles al Público. Dicha información personal, será incluida en un fichero bajo la responsabilidad de VOZELIA TELECOM S.L.Todos los ficheros que trata nuestra empresa se encuentran debidamente inscritos ante la Agencia Española de Protección de Datos.Vd. Como propio interesado podrá ejercitar sus derechos de Acceso, Cancelación, Rectificación u Oposición, en el mail: administracion(a)vozelia.com o en la dirección Avenida de Manoteras 8 escalera 3 2ºB, 28050 Madrid.Tal y como establece la Ley Orgánica de Protección de Datos 15/1999 de 13 de Diciembre.Para ejercer sus derechos desde Panama podrá hacerlo en la dirección Vía Argentina, Edificio Mediteranean Loft. Panama.En caso
de no ser el destinatario y haya recibido este mensaje por error, agradeceremos que nos lo comunique inmediatamente al remitente sin difundir, almacenar o copiar su contenido.La divulgación o el suministro, en todo o en parte, a cualquier tercero, no podrá ser realizada sin el previo, expreso y escrito consentimiento de VOZELIA TELECOM S.L. .
Iam new in kamailio.
When I try to create the data base with kamdbctl y have the following error
root@diogenes-Inspiron-1525:/usr/local/sbin# kamdbctl create
MySQL password for root:
INFO: test server charset
ERROR 2002 (HY000): Can't connect to local MySQL server through socket
'/var/run/mysqld/mysqld.sock' (2 "No such file or directory")
ERROR 2002 (HY000): Can't connect to local MySQL server through socket
'/var/run/mysqld/mysqld.sock' (2 "No such file or directory")
Usage: grep [OPTION]... PATTERN [FILE]...
Try 'grep --help' for more information.
/usr/local/lib/kamailio//kamctl/kamdbctl.mysql: line 111: [: =: unary
operator expected
INFO: creating database kamailio ...
ERROR 2002 (HY000): Can't connect to local MySQL server through socket
'/var/run/mysqld/mysqld.sock' (2 "No such file or directory")
ERROR: Creating database kamailio failed!
root@diogenes-Inspiron-1525:/usr/local/sbin# mysql
ERROR 2002 (HY000): Can't connect to local MySQL server through socket
'/var/run/mysqld/mysqld.sock' (2 "No such file or directory")
Thank you for your hrlp
Diogenes Marcano
Hi all,
I am trying to limit concurrent calls, using dialog, or rather, I want to try it. I have now only added loadmodule "dialog.so" and a series of modparam commands to my config file and already I am running into problems:
ERROR: <core> [modparam.c:139]: set_mod_param_regex(): parameter <toroute_column> of type <1> not found in module <dialog>
It fails on the last modparam line, but if I remove it (by commenting it), it fails on whatever the latest modparam line is after that. I have tried removing multiple calls, but every time it fails on whatever is the last line.
I have the required modules already loaded (tm.so, rr.so and pv.so), so that's not it I guess.
Any idea what might be causing this issue? Also, I noticed (when calling locate dialog.so on the Linux machine) that there is also an ims_dialog.so, if I replace dialog with ims_dialog, I run into the exact same issues.
Any help is greatly appreciated!
Best regards,
Michael Jepson
CM Telecom
I am using kamailio 4.4.2 IMS
Registration completes successfully, but S-CSCF gives the following error
when P-CSCF relays INVITE to S-CSCF:
32(1349) ERROR: ims_dialog [dlg_handlers.c:190]: populate_leg_info(): bad
sip message or missing Contact hdr
32(1349) ERROR: ims_dialog [dlg_handlers.c:1352]: dlg_onreply(): could not
add further info to the dlg out
Resultantly, P-CSCF returns a 403 with: "Forbidden - You must register
first with a S-CSCF"
It appears that pcscf_is_registered("location") is unable to lookup the
location although the database seems to have valid entries.
Any hints on how I can get the INVITE processed without this issue?
Regards,
Owais
Hi,
I was reading some docs on Kamailio 5 and saw in the ToDo list an item about implementing the dynamic object mechanism for Mono.
Would it be possible to implement it directly for .NET Core, since the official .NET support has been added to Linux some time ago?
Regards,
Grant
I send INVITE via uac_send_req() and receive "183" and "200"responses.
Only "200" appears in the log of event_route[uac:reply].
Is event_route[uac:reply] executed only for final responses?
Thank you,
Julia