Hello Dears
i'm trying to send POST HTTP request with JSON content on Kamailio V 5.2.0.
i have two main headers "content type" & "Authentication " in addition i have the json content .
when i'm using curl request it look like :
Curl -H "Authentication ket = xxxxx" -H "content type : JSON" -d " {the JSON content}" https://xxxxx.com/send
So how can i use the Http_client module to send such requests ??
thanks in advance .
Hi,
I have a use case where I need to send a statefull (or stateless) reply to
non-INVITE SIP transaction from PERL script using app_perl module's
"moduleFunction" method,
https://kamailio.org/docs/modules/5.0.x/modules/app_perl.html#ID-7b0efd72c8…
It fails with error "function not found, missing load module?", even though
the documentation says that at least "sl_send_reply" method should work.
As an alternative, I tried to use JSONRPCS module to call RPC methods
"tm.reply" and "tm.reply_callid" from PERL script (using libcurl),
https://kamailio.org/docs/modules/5.0.x/modules/jsonrpcs.htmlhttps://kamailio.org/docs/modules/5.0.x/modules/tm.html#tm.rpc.replyhttps://kamailio.org/docs/modules/5.0.x/modules/tm.html#tm.rpc.reply_callid
However, they only seems to work for INVITE transactions. If I try to use
them for e.g. MESSAGE request I get "Request Timeout" on libcurl and "500 I
am terribly sorry" on SIP client.
Are these bugs or suppose to work this way? If so, then, is there any way i
can send a SIP reply to non-INVITE SIP transaction from outside of the
kamailio.cfg script?
Please help.
P.S. I am using Kamailio 5.0.x on debian wheezy 32bit virtual machine.
Thank you.
Thanks Henning and Carsten.
It should also be noted that the module is required by both IMS_ISC and IMS_REGISTRAR_SCSCF. The lacking documentation of IMS_USRLOC_SCSCF also make those modules difficult to implement.
Pan B. Christensen
Developer
Phonect AS
> -----Original Message-----
> From: Henning Westerholt <hw(a)kamailio.org>
> Sent: tirsdag 16. oktober 2018 20:27
> To: sr-users(a)lists.kamailio.org
> Cc: Carsten Bock <carsten(a)ng-voice.com>; Pan Christensen
> <pan.christensen(a)phonect.no>
> Subject: *** SPAM *** Re: [SR-Users] Missing documentation
> ims_usrloc_scscf module
>
> Am Dienstag, 16. Oktober 2018, 13:31:08 CEST schrieb Carsten Bock:
> > can you open a ticket on the GitHub Tracker for this? Otherwise this
> > might get lost at some point... I don't have time to take care of it
> > immediately as I am travelling this and next week, more likely I would
> > take care of it later in November.
>
> Hello Carsten,
>
> i have opened already a ticket about that one month ago. It is already
> assigned to ngvoice. ;-)
>
> https://github.com/kamailio/kamailio/issues/1644
>
> Best regards,
>
> Henning
>
> --
> Henning Westerholt - https://skalatan.de/blog/ Kamailio security assessment
> - https://skalatan.de/de/assessment
Hi!
Is there any possibility to share xavp’s between Kamailio nodes? Idea is to share result of ds_select_dst between several nodes and as 5.2 Kamailio stores result in xavp - need to share this structure as well
Right now sharing between nodes is done on sht + dmq and I’m not sure I can save xavp in sht.
Regards, Igor
Hello,
kamcli tool just got its first official release, a step forward in the
process of packaging it.
It is a command line tool that aims to be a modern alternative to the
venerable kamctl, being written in Python and having already a large set
of implemented sub-commands, such as:
* subscriber – manage SIP subscribers
* ul – manage user location records
* address – manage permissions address records
* aliasdb – manage database aliases
* db – manage kamailio database content
* dialog – manage active calls (dialog)
* dialplan – manage dialplan records
* dispatcher – manage load balancer (dispatcher)
* group – manage group membership records (acl)
* moni – continuous refresh of the values for a list of statistics
* mtree – manage memory trees (mtree)
* ps – print the details for kamailio running processes
* rpc – interact with kamailio via jsonrpc control commands (alias of
jsonrpc)
* rpcmethods – return the list of available RPC methods (commands)
* speeddial – manage speed dial records
* srv – server management commands (sockets, aliases, …)
* stats – get kamailio internal statistics
* tls – management commands for TLS profiles and connections
* uptime – print the uptime for kamailio instance
The news article for this release is available at:
* https://www.kamailio.org/w/2018/10/kamcli-v1-1-0-released/
The corresponding tag in the github repository being:
* https://github.com/kamailio/kamcli/releases/tag/v1.1.0
How to install kamcli and examples of usage can be found at:
* https://github.com/kamailio/kamcli/blob/v1.1/README.md
Cheers,
Daniel
--
Daniel-Constantin Mierla -- www.asipto.comwww.twitter.com/miconda -- www.linkedin.com/in/miconda
Kamailio World Conference -- www.kamailioworld.com
Kamailio Advanced Training, Nov 12-14, 2018, in Berlin -- www.asipto.com
Hi all,
I noticed that using the module TOPOH with the parameter mask call id
enabled and the t_check_trans together isn't working correctly.
When i receive the BYE message my script call the function t_check_trans()
in order to check if a message belongs or is related to a transaction. This
function always returns false when used with the topoh mask call id
enabled, once that the BYE belongs to an existing dialog it must return
true.
In the logs it says something like transaction doesn't match dialog using
the RFC3261.
If the TOPOH mask call id option is disabled everything works perfectly.
Anyone here already faced this behavior?
Thanks
Regards
--
José Seabra
Hello.
The documentation for the ims_usrloc_scscf module seems to be missing:
Not Found
The requested URL /docs/modules/stable/modules/ims_usrloc_scscf.html was not found on this server.
________________________________
Apache/2.4.10 (Debian) Server at www.kamailio.org Port 443
Pan B. Christensen
Utvikler
Phonect AS
Mail: pan.christensen(a)phonect.no<mailto:pan.christensen@phonect.no>
+ 47 41 88 88 00
[mail_footer]
If no operator is matched in the first two characters of expression part
for $shtcn(...), then regexp is used. That's because initially the
$shtcn() was doing only regexp matching, later it was added support for
additional operators.
Yes, == is the operator for equal.
Cheers,
Daniel
On 16.10.18 11:53, jenus(a)cyberchaos.nl wrote:
> Daniel,
>
> Ok so if i'm correct i can prefix the callid with for example 1234 to
> avoid matching the eq. In other words eq will only match the regex
> code if the callid string starts with it?
>
> And by mathing on equal you mean: $shtcn(ht_test=>==$var(htid)) ?
>
> Thanks,
>
> Jan
>
> Daniel-Constantin Mierla schreef op 2018-10-16 10:16:
>> Just to add that regexp matching when using keys from the sip message
>> such as call-id is exposed further to some issues -- for example, it is
>> common to have . (dot) in call-id, which for a regexp is matching any
>> char, so a call id having 123.456 is matching 123x456. So depending on
>> what you want to count, might be better to match by equal or prefix
>> rules.
>>
>> Cheers,
>> Daniel
>>
>> On 16.10.18 10:03, jenus(a)cyberchaos.nl wrote:
>>> Daniel,
>>>
>>> Thanks for the quick response, that indeed solves my problem.
>>>
>>>
>>> Jan
>>>
>>> Daniel-Constantin Mierla schreef op 2018-10-16 09:55:
>>>> Hello,
>>>>
>>>> the expression in the $shtcn(table=>exp) can have some operators at
>>>> the
>>>> beginning, see:
>>>>
>>>> -
>>>> https://www.kamailio.org/wiki/cookbooks/devel/pseudovariables#shtcn_htable_…
>>>>
>>>>
>>>>
>>>> So, eq is one of them, the safest is to explicitly set the operator if
>>>> you cannot predict what is the key, like in this case. If the operator
>>>> is missing, then the exp is matched as regular expression, so you can
>>>> do:
>>>>
>>>> $shtcn(ht_test=>~~$var(htid))
>>>>
>>>> Cheers,
>>>> Daniel
>>>>
>>>>
>>>> On 16.10.18 09:47, jenus(a)cyberchaos.nl wrote:
>>>>> Hello,
>>>>>
>>>>> I'm running kamailio 5.1.4 and running into a issue with htable. I
>>>>> use
>>>>> it to store some dialog data so i can use it in a http route. When i
>>>>> use the callid as a key it creates a issue for callid's starting with
>>>>> eq. Here some example code that i use to reproduce the issue:
>>>>>
>>>>>
>>>>> modparam("htable", "htable", "ht_test=>size=16;autoexpire=10")
>>>>>
>>>>> $var(htable-val) = $_s($dlg(h_entry)) + "::" + $_s($dlg(h_id)) + "::"
>>>>> + $Ts;
>>>>> xlog("L_WARN", "HT_TEST: Adding $var(htable-val) to ht_test with key
>>>>> eq1234");
>>>>> $var(htid) = "eq1234";
>>>>> $sht(ht_test=>$var(htid)) = $var(htable-val);
>>>>> $var(htable-val) = $null;
>>>>>
>>>>> if ($shtcn(ht_test=>$var(htid)) > 0)
>>>>> {
>>>>> xlog("L_WARN", "HT_TEST: Key eq1234 found!");
>>>>> } else {
>>>>> xlog("L_WARN", "HT_TEST: Key eq1234 NOT found!");
>>>>> }
>>>>> $var(htid) = $null;
>>>>>
>>>>> Results in :
>>>>>
>>>>> Oct 16 09:36:31 sip03 /usr/sbin/kamailio[22344]: WARNING: <script>:
>>>>> HT_TEST: Adding 531::926::1539675391 to ht_test with key eq1234
>>>>> Oct 16 09:36:31 sip03 /usr/sbin/kamailio[22344]: WARNING: <script>:
>>>>> HT_TEST: Key eq1234 NOT found!
>>>>>
>>>>>
>>>>> When i prefix eq with a 1 it works fine:
>>>>>
>>>>> modparam("htable", "htable", "ht_test=>size=16;autoexpire=10")
>>>>>
>>>>> $var(htable-val) = $_s($dlg(h_entry)) + "::" + $_s($dlg(h_id)) + "::"
>>>>> + $Ts;
>>>>> xlog("L_WARN", "HT_TEST: Adding $var(htable-val) to ht_test with key
>>>>> eq1234");
>>>>> $var(htid) = "1eq1234";
>>>>> $sht(ht_test=>$var(htid)) = $var(htable-val);
>>>>> $var(htable-val) = $null;
>>>>>
>>>>> if ($shtcn(ht_test=>$var(htid)) > 0)
>>>>> {
>>>>> xlog("L_WARN", "HT_TEST: Key eq1234 found!");
>>>>> } else {
>>>>> xlog("L_WARN", "HT_TEST: Key eq1234 NOT found!");
>>>>> }
>>>>> $var(htid) = $null;
>>>>>
>>>>> Results in:
>>>>>
>>>>> Oct 16 09:37:25 sip03 /usr/sbin/kamailio[22555]: WARNING: <script>:
>>>>> HT_TEST: Adding 3050::1098::1539675445 to ht_test with key eq1234
>>>>> Oct 16 09:37:25 sip03 /usr/sbin/kamailio[22555]: WARNING: <script>:
>>>>> HT_TEST: Key eq1234 found!
>>>>>
>>>>>
>>>>> Am i running into a bug? Or are there some restrictions on the
>>>>> key's i
>>>>> can use? I'm still going trough the logs to check if there are more
>>>>> callid's that have a issue with matching.
>>>>>
>>>>>
>>>>> Thanks,
>>>>>
>>>>> Jan Hazenberg
>>>>>
>>>>> _______________________________________________
>>>>> Kamailio (SER) - Users Mailing List
>>>>> sr-users(a)lists.kamailio.org
>>>>> https://lists.kamailio.org/cgi-bin/mailman/listinfo/sr-users
>>>
>
--
Daniel-Constantin Mierla -- www.asipto.comwww.twitter.com/miconda -- www.linkedin.com/in/miconda
Kamailio World Conference -- www.kamailioworld.com
Kamailio Advanced Training, Nov 12-14, 2018, in Berlin -- www.asipto.com