[sr-dev] Re: [kamailio/kamailio] new db_mysql warnings when Kamailio starts (Issue #3884)

2024-06-19 Thread juha-h via sr-dev
Reopened #3884.

-- 
Reply to this email directly or view it on GitHub:
https://github.com/kamailio/kamailio/issues/3884#event-13214523439
You are receiving this because you are subscribed to this thread.

Message ID: ___
Kamailio (SER) - Development Mailing List
To unsubscribe send an email to sr-dev-le...@lists.kamailio.org


[sr-dev] Re: [kamailio/kamailio] new db_mysql warnings when Kamailio starts (Issue #3884)

2024-06-19 Thread juha-h via sr-dev
This issue was about `opt_ssl_ca option` warnings and they still show up.

-- 
Reply to this email directly or view it on GitHub:
https://github.com/kamailio/kamailio/issues/3884#issuecomment-2178390317
You are receiving this because you are subscribed to this thread.

Message ID: ___
Kamailio (SER) - Development Mailing List
To unsubscribe send an email to sr-dev-le...@lists.kamailio.org


[sr-dev] [kamailio/kamailio] new db_mysql warnings when Kamailio starts (Issue #3884)

2024-06-19 Thread juha-h via sr-dev
When I start Kamailio master version that has been built on Debian 12 with 
default-libmysqlclient-dev depending on libmariadb-dev-compat, several warnings 
like this are produced:
```
2024-06-17T14:48:27.702827+03:00 siika /usr/bin/sip-proxy[297246]: WARNING: 
db_mysql
[km_my_con.c:187]: db_mysql_new_connection(): opt_ssl_ca option not supported 
by mysql
version (value (null)) - ignoring
```
The only db_mysql configuration option used in the config is ping_interval.

I would expect that the warnings are not produced like it is the case when I 
build Kamailio branch 5.8.


-- 
Reply to this email directly or view it on GitHub:
https://github.com/kamailio/kamailio/issues/3884
You are receiving this because you are subscribed to this thread.

Message ID: ___
Kamailio (SER) - Development Mailing List
To unsubscribe send an email to sr-dev-le...@lists.kamailio.org


[sr-dev] Re: [kamailio/kamailio] tm: add mandatory Max-Forwards header to local ACK (PR #3856)

2024-05-20 Thread juha-h via sr-dev
Daniel-Constantin Mierla writes:

> Yes, it can be cherry-picked, it is about a mandatory header.

Done.


-- 
Reply to this email directly or view it on GitHub:
https://github.com/kamailio/kamailio/pull/3856#issuecomment-2120834113
You are receiving this because you are subscribed to this thread.

Message ID: ___
Kamailio (SER) - Development Mailing List
To unsubscribe send an email to sr-dev-le...@lists.kamailio.org


[sr-dev] Re: [kamailio/kamailio] tm: add mandatory Max-Forwards header to local ACK (PR #3856)

2024-05-20 Thread juha-h via sr-dev
Is it OK to cherry-pick this to 5.8 branch?

-- 
Reply to this email directly or view it on GitHub:
https://github.com/kamailio/kamailio/pull/3856#issuecomment-2120256287
You are receiving this because you are subscribed to this thread.

Message ID: ___
Kamailio (SER) - Development Mailing List
To unsubscribe send an email to sr-dev-le...@lists.kamailio.org


[sr-dev] Re: [kamailio/kamailio] tm: add mandatory Max-Forwards header to local ACK (PR #3856)

2024-05-20 Thread juha-h via sr-dev
juha-h writes:

> Goes beyond me.  In baresip project, nothing like that needs to be
> done.  If there is new commit to PR, all checks are automatically
> re-run.

... and red marks turn green without any extra action.



-- 
Reply to this email directly or view it on GitHub:
https://github.com/kamailio/kamailio/pull/3856#issuecomment-2120106704
You are receiving this because you are subscribed to this thread.

Message ID: ___
Kamailio (SER) - Development Mailing List
To unsubscribe send an email to sr-dev-le...@lists.kamailio.org


[sr-dev] Re: [kamailio/kamailio] tm: add mandatory Max-Forwards header to local ACK (PR #3856)

2024-05-20 Thread juha-h via sr-dev
Victor Seva writes:

> Just create one commit with the proper commit message prefix squashing
> both previous commits in the branch.

Goes beyond me.  In baresip project, nothing like that needs to be
done.  If there is new commit to PR, all checks are automatically
re-run.


-- 
Reply to this email directly or view it on GitHub:
https://github.com/kamailio/kamailio/pull/3856#issuecomment-2120096511
You are receiving this because you are subscribed to this thread.

Message ID: ___
Kamailio (SER) - Development Mailing List
To unsubscribe send an email to sr-dev-le...@lists.kamailio.org


[sr-dev] Re: [kamailio/kamailio] Add mandatory Max-Forwards header to local ACK (PR #3856)

2024-05-20 Thread juha-h via sr-dev
Same checks bug as earlier: according to Details, check-format PASSED, but 
there still claim that `Some checks were not successful`.

-- 
Reply to this email directly or view it on GitHub:
https://github.com/kamailio/kamailio/pull/3856#issuecomment-2120012806
You are receiving this because you are subscribed to this thread.

Message ID: ___
Kamailio (SER) - Development Mailing List
To unsubscribe send an email to sr-dev-le...@lists.kamailio.org


[sr-dev] Re: [kamailio/kamailio] Add mandatory Max-Forwards header to local ACK (PR #3856)

2024-05-20 Thread juha-h via sr-dev
@juha-h pushed 1 commit.

91747524b2e4b34fa1b68c8d5b0e0473cf2f2ff8  Run clang-format on the file

-- 
View it on GitHub:
https://github.com/kamailio/kamailio/pull/3856/files/b9b90eb6ea5cb20466a74a739338d6fe25226438..91747524b2e4b34fa1b68c8d5b0e0473cf2f2ff8
You are receiving this because you are subscribed to this thread.

Message ID: 
___
Kamailio (SER) - Development Mailing List
To unsubscribe send an email to sr-dev-le...@lists.kamailio.org


[sr-dev] [kamailio/kamailio] Add mandatory Max-Forwards header to local ACK (PR #3856)

2024-05-20 Thread juha-h via sr-dev
 Type Of Change
- [ x]  Bug fix (non-breaking change which fixes an issue)
- [ ] New feature (non-breaking change which adds new functionality)
- [ ] Breaking change (fix or feature that would change existing functionality)

 Checklist:
- [x ] PR should be backported to stable branches
- [ x] Tested changes locally
- [ ] Related to issue # (replace  with an open issue number)

 Description
Add mandatory Max-Forwards header to local ACK

You can view, comment on, or merge this pull request online at:

  https://github.com/kamailio/kamailio/pull/3856

-- Commit Summary --

  * Add mandatory Max-Forwards header to local AC

-- File Changes --

M src/modules/tm/t_msgbuilder.c (5)

-- Patch Links --

https://github.com/kamailio/kamailio/pull/3856.patch
https://github.com/kamailio/kamailio/pull/3856.diff

-- 
Reply to this email directly or view it on GitHub:
https://github.com/kamailio/kamailio/pull/3856
You are receiving this because you are subscribed to this thread.

Message ID: kamailio/kamailio/pull/3...@github.com
___
Kamailio (SER) - Development Mailing List
To unsubscribe send an email to sr-dev-le...@lists.kamailio.org


[sr-dev] Re: [kamailio/kamailio] Added new auth module function auth_algorithm (PR #3849)

2024-05-14 Thread juha-h via sr-dev
After the first commit. there was format issues that I tried to fix manually 
and pushed another commit.  After that, format check was re-run automatically 
and one more format issue remained.  I fixed also that, push a new commit, and 
again format check was re-run automatically.  Now the format check passed, but 
still the web page showed that format check failed.

-- 
Reply to this email directly or view it on GitHub:
https://github.com/kamailio/kamailio/pull/3849#issuecomment-2110830547
You are receiving this because you are subscribed to this thread.

Message ID: ___
Kamailio (SER) - Development Mailing List
To unsubscribe send an email to sr-dev-le...@lists.kamailio.org


[sr-dev] Re: [kamailio/kamailio] Added new auth module function auth_algorithm (PR #3849)

2024-05-14 Thread juha-h via sr-dev
How about the failing format check?

-- 
Reply to this email directly or view it on GitHub:
https://github.com/kamailio/kamailio/pull/3849#issuecomment-2110621100
You are receiving this because you are subscribed to this thread.

Message ID: ___
Kamailio (SER) - Development Mailing List
To unsubscribe send an email to sr-dev-le...@lists.kamailio.org


[sr-dev] Re: [kamailio/kamailio] Added new auth module function auth_algorithm (PR #3849)

2024-05-14 Thread juha-h via sr-dev
> If you want to test README generation locally, then you are missing some 
> dockbook-relate packages, likely `docbook-xsl`.

README generation worked after I installed Debian package `docbook-xsl`.  For 
some reason make command as described here 
[https://www.kamailio.org/wikidocs/devel/module-docbook-readme/]() was not able 
to load it from source repo.

-- 
Reply to this email directly or view it on GitHub:
https://github.com/kamailio/kamailio/pull/3849#issuecomment-2110617698
You are receiving this because you are subscribed to this thread.

Message ID: ___
Kamailio (SER) - Development Mailing List
To unsubscribe send an email to sr-dev-le...@lists.kamailio.org


[sr-dev] Re: [kamailio/kamailio] Added new auth module function auth_algorithm (PR #3849)

2024-05-14 Thread juha-h via sr-dev
Daniel-Constantin Mierla writes:

> One can generate readme locally only for checking it if it is correct,
> but then reverted before committing.

That is exactly what I tried to do according to instructions, but
generation failed.

Also, there is something wrong with the format check.  It shows red even
when the Details shows OK:

6992d1784aa3e1f96aa3a406f25675178605108d... PASSED
3bcedc47e381d22521aeb544b0d27180786d7039... PASSED

-- Juha


-- 
Reply to this email directly or view it on GitHub:
https://github.com/kamailio/kamailio/pull/3849#issuecomment-2110471230
You are receiving this because you are subscribed to this thread.

Message ID: ___
Kamailio (SER) - Development Mailing List
To unsubscribe send an email to sr-dev-le...@lists.kamailio.org


[sr-dev] Re: [kamailio/kamailio] Added new auth module function auth_algorithm (PR #3849)

2024-05-14 Thread juha-h via sr-dev
@juha-h pushed 1 commit.

6992d1784aa3e1f96aa3a406f25675178605108d  More format changes

-- 
View it on GitHub:
https://github.com/kamailio/kamailio/pull/3849/files/4ccadb7ed3a762ec1d2781e783f760f6de4b588e..6992d1784aa3e1f96aa3a406f25675178605108d
You are receiving this because you are subscribed to this thread.

Message ID: 
___
Kamailio (SER) - Development Mailing List
To unsubscribe send an email to sr-dev-le...@lists.kamailio.org


[sr-dev] Re: [kamailio/kamailio] Added new auth module function auth_algorithm (PR #3849)

2024-05-14 Thread juha-h via sr-dev
@juha-h pushed 1 commit.

4ccadb7ed3a762ec1d2781e783f760f6de4b588e  Format changes

-- 
View it on GitHub:
https://github.com/kamailio/kamailio/pull/3849/files/4a1aa23d6b1d8bb90f267b64a33b25beb2b0977c..4ccadb7ed3a762ec1d2781e783f760f6de4b588e
You are receiving this because you are subscribed to this thread.

Message ID: 
___
Kamailio (SER) - Development Mailing List
To unsubscribe send an email to sr-dev-le...@lists.kamailio.org


[sr-dev] [kamailio/kamailio] Added new auth module function auth_algorithm (PR #3849)

2024-05-14 Thread juha-h via sr-dev
 Type Of Change
- [ ] Small bug fix (non-breaking change which fixes an issue)
- [x] New feature (non-breaking change which adds new functionality)
- [ ] Breaking change (fix or feature that would change existing functionality)

 Checklist:
- [ ] PR should be backported to stable branches
- [x] Tested changes locally
- [ ] Related to issue # (replace  with an open issue number)

 Description
Added new Added new auth module function auth_algorithm that can be used to 
dynamically override algorithm parameter value.

 Note
I was not able to test check README, because of this error:
```
/usr/src/orig/kamailio$ make modules-readme modules=modules/auth
make -C src/ modules-readme 
make[1]: Entering directory /usr/src/orig/kamailio/src
make --no-print-directory -C doc auth.txt
xsltproc  --novalid \
--nonet \
--novalid \
--stringparam output auth.d \
../../../../doc/docbook/dep.xsl auth.xml 
xsltproc  --novalid \
--xinclude \
../../../../doc/docbook/txt.xsl auth.xml | lynx -nolist -stdin -dump 
 auth.txt
error : Unknown IO error
warning: failed to load external entity 
http://docbook.sourceforge.net/release/xsl/current/xhtml/docbook.xsl;
compilation error: file ../../../../doc/docbook/txt.xsl line 6 element import
xsl:import : unable to load 
http://docbook.sourceforge.net/release/xsl/current/xhtml/docbook.xsl
```


You can view, comment on, or merge this pull request online at:

  https://github.com/kamailio/kamailio/pull/3849

-- Commit Summary --

  * Added new auth module function auth_algorithm

-- File Changes --

M src/modules/auth/auth_mod.c (37)
M src/modules/auth/doc/auth_functions.xml (16)

-- Patch Links --

https://github.com/kamailio/kamailio/pull/3849.patch
https://github.com/kamailio/kamailio/pull/3849.diff

-- 
Reply to this email directly or view it on GitHub:
https://github.com/kamailio/kamailio/pull/3849
You are receiving this because you are subscribed to this thread.

Message ID: kamailio/kamailio/pull/3...@github.com
___
Kamailio (SER) - Development Mailing List
To unsubscribe send an email to sr-dev-le...@lists.kamailio.org


[sr-dev] Re: [kamailio/kamailio] sql_query fails from tcp:closed event_route (Issue #3843)

2024-05-07 Thread juha-h via sr-dev
I'm fine with the above solution and can close this issue.

-- 
Reply to this email directly or view it on GitHub:
https://github.com/kamailio/kamailio/issues/3843#issuecomment-2098939975
You are receiving this because you are subscribed to this thread.

Message ID: ___
Kamailio (SER) - Development Mailing List
To unsubscribe send an email to sr-dev-le...@lists.kamailio.org


[sr-dev] Re: [kamailio/kamailio] sql_query fails from tcp:closed event_route (Issue #3843)

2024-05-07 Thread juha-h via sr-dev
Closed #3843 as completed.

-- 
Reply to this email directly or view it on GitHub:
https://github.com/kamailio/kamailio/issues/3843#event-12732879781
You are receiving this because you are subscribed to this thread.

Message ID: ___
Kamailio (SER) - Development Mailing List
To unsubscribe send an email to sr-dev-le...@lists.kamailio.org


[sr-dev] Re: [kamailio/kamailio] sql_query fails from tcp:closed event_route (Issue #3843)

2024-05-07 Thread juha-h via sr-dev
With async_task_data() I got it working like this:
```
event_route [tcp:closed] {  # Handle TCP connection close
# Delete possible leftover registration
if ($conid) {
async_task_data("clean_location", "$conid");
}

route [clean_location] {
sql_query_async("sip_proxy_cache", "DELETE FROM location WHERE server_id=0 
AND connection_id=$async(data)");
}

-- 
Reply to this email directly or view it on GitHub:
https://github.com/kamailio/kamailio/issues/3843#issuecomment-2098879746
You are receiving this because you are subscribed to this thread.

Message ID: ___
Kamailio (SER) - Development Mailing List
To unsubscribe send an email to sr-dev-le...@lists.kamailio.org


[sr-dev] Re: [kamailio/kamailio] sql_query fails from tcp:closed event_route (Issue #3843)

2024-05-07 Thread juha-h via sr-dev
Yes, I'm getting the same error message with sql_query_async:
```
2024-05-07T19:02:24.167462+03:00 siika /usr/bin/sip-proxy[2948257]: CRITICAL: 
sqlops [sqlops.c:213]: sql_check_connection(): no database handle with 
reconnect disabled
2024-05-07T19:02:24.167640+03:00 siika /usr/bin/sip-proxy[2948257]: ERROR: 
sqlops [sqlops.c:251]: sql_query_async(): invalid connection to database
```
I can try with `async_task_data()`.

-- 
Reply to this email directly or view it on GitHub:
https://github.com/kamailio/kamailio/issues/3843#issuecomment-2098813053
You are receiving this because you are subscribed to this thread.

Message ID: ___
Kamailio (SER) - Development Mailing List
To unsubscribe send an email to sr-dev-le...@lists.kamailio.org


[sr-dev] Re: [kamailio/kamailio] sql_query fails from tcp:closed event_route (Issue #3843)

2024-05-07 Thread juha-h via sr-dev
I tried with async module, but always got error
```
2024-05-07T17:31:16.143660+03:00 siika /usr/bin/sip-proxy[2910444]: ERROR: 
async [async_mod.c:462]: ki_async_task_group_route(): invalid usage for faked 
message
```
and when I read async module README, all its functions deal with SIP request 
processing.  `tcp:closed` event route does not have any SIP request.

So please restore the old working behavior.

-- 
Reply to this email directly or view it on GitHub:
https://github.com/kamailio/kamailio/issues/3843#issuecomment-2098560918
You are receiving this because you are subscribed to this thread.

Message ID: ___
Kamailio (SER) - Development Mailing List
To unsubscribe send an email to sr-dev-le...@lists.kamailio.org


[sr-dev] Re: [kamailio/kamailio] sql_query fails from tcp:closed event_route (Issue #3843)

2024-05-07 Thread juha-h via sr-dev
In order to avoid any performance issues, I tried to change the query from
```
sql_query("sip_proxy_cache", "DELETE FROM location WHERE server_id=0 AND 
connection_id=$conid", "result");
```
to
``` 
sql_query_async("sip_proxy_cache", "DELETE FROM location WHERE server_id=0 AND 
connection_id=$conid");
```
but got the same error.

So please make the sql connections available in event routes as they have been 
before.


-- 
Reply to this email directly or view it on GitHub:
https://github.com/kamailio/kamailio/issues/3843#issuecomment-2098488770
You are receiving this because you are subscribed to this thread.

Message ID: ___
Kamailio (SER) - Development Mailing List
To unsubscribe send an email to sr-dev-le...@lists.kamailio.org


[sr-dev] Re: [kamailio/kamailio] sql_query fails from tcp:closed event_route (Issue #3843)

2024-05-07 Thread juha-h via sr-dev
As I wrote, this used to work for many years and now it does not.  It is very 
important to be able to delete the possible leftover registration if tcp 
connection from the SIP UA get closed due to some failure situation.

Is there somewhere an example how to migrate the above event route action to an 
async worker?

-- 
Reply to this email directly or view it on GitHub:
https://github.com/kamailio/kamailio/issues/3843#issuecomment-2098424031
You are receiving this because you are subscribed to this thread.

Message ID: ___
Kamailio (SER) - Development Mailing List
To unsubscribe send an email to sr-dev-le...@lists.kamailio.org


[sr-dev] Re: [kamailio/kamailio] sql_query fails from tcp:closed event_route (Issue #3843)

2024-05-07 Thread juha-h via sr-dev
Same error with `event_route [websocket:closed]`.

-- 
Reply to this email directly or view it on GitHub:
https://github.com/kamailio/kamailio/issues/3843#issuecomment-2097918824
You are receiving this because you are subscribed to this thread.

Message ID: ___
Kamailio (SER) - Development Mailing List
To unsubscribe send an email to sr-dev-le...@lists.kamailio.org


[sr-dev] [kamailio/kamailio] sql_query fails from tcp:closed event_route (Issue #3843)

2024-05-07 Thread juha-h via sr-dev
### Description

I noticed that sql_query does not work (using latest 5.8 on Debian 12) when 
called from `tcp:closed` event_route:
```
event_route [tcp:closed] {  # Handle TCP connection close
# Delete possible leftover registration
if ($conid)
sql_query("sip_proxy_cache", "DELETE FROM location WHERE server_id=0 
AND connection_id=$conid", "result");
}
```
The query produces errors:
```
2024-05-07T11:30:14.785915+03:00 siika /usr/bin/sip-proxy[2848078]: CRITICAL: 
sqlops
[sqlops.c:213]: sql_check_connection(): no database handle with reconnect 
disabled
2024-05-07T11:30:14.785978+03:00 siika /usr/bin/sip-proxy[2848078]: ERROR: 
sqlops
[sqlops.c:232]: sql_query(): invalid connection to database
2024-05-07T11:30:14.786013+03:00 siika /usr/bin/sip-proxy[2848078]: ERROR: 
sqlops
[sqlops.c:237]: sql_query(): with query [DELETE FROM location WHERE server_id=0 
AND
connection_id=7]
```
I added the last debug message in order to find out where the error comes from.

The same query works fine when executed from regular route and earlier (but 
don't remember when), the same query worked fine also from `tcp:closed` 
event_route.

This may be related to https://github.com/kamailio/kamailio/issues/3768.




-- 
Reply to this email directly or view it on GitHub:
https://github.com/kamailio/kamailio/issues/3843
You are receiving this because you are subscribed to this thread.

Message ID: ___
Kamailio (SER) - Development Mailing List
To unsubscribe send an email to sr-dev-le...@lists.kamailio.org


[sr-dev] Re: [kamailio/kamailio] Make tcp_check_timer default to depend on tcp_msg_data_timeout and tcp_msg_read_timeout values (PR #3608)

2023-10-19 Thread juha-h via sr-dev
Don't know why `check-format (pull_request)` failed again, because latest 
commit 38a1c736fa3ebef8827a0f3ef645e7e4fa165b5a... PASSED.

-- 
Reply to this email directly or view it on GitHub:
https://github.com/kamailio/kamailio/pull/3608#issuecomment-1770663120
You are receiving this because you are subscribed to this thread.

Message ID: ___
Kamailio (SER) - Development Mailing List
To unsubscribe send an email to sr-dev-le...@lists.kamailio.org


[sr-dev] Re: [kamailio/kamailio] Make tcp_check_timer default to depend on tcp_msg_data_timeout and tcp_msg_read_timeout values (PR #3608)

2023-10-19 Thread juha-h via sr-dev
@juha-h pushed 1 commit.

38a1c736fa3ebef8827a0f3ef645e7e4fa165b5a  Trying to fix format

-- 
View it on GitHub:
https://github.com/kamailio/kamailio/pull/3608/files/dd9d828a782c0c132c536a97beb792176928a716..38a1c736fa3ebef8827a0f3ef645e7e4fa165b5a
You are receiving this because you are subscribed to this thread.

Message ID: 
___
Kamailio (SER) - Development Mailing List
To unsubscribe send an email to sr-dev-le...@lists.kamailio.org


[sr-dev] [kamailio/kamailio] Make tcp_check_timer default to depend on tcp_msg_data_timeout and tcp_msg_read_timeout values (PR #3608)

2023-10-19 Thread juha-h via sr-dev
If  `tcp_check_timer` is not set, use default value that is half of 
`tcp_msg_data_timeout` or `tcp_msg_read_timeout` value depending on which one 
is smaller and not zero.


You can view, comment on, or merge this pull request online at:

  https://github.com/kamailio/kamailio/pull/3608

-- Commit Summary --

  * Make tcp_check_timer default to depend on tcp_msg_data_timeout and

-- File Changes --

M src/main.c (22)

-- Patch Links --

https://github.com/kamailio/kamailio/pull/3608.patch
https://github.com/kamailio/kamailio/pull/3608.diff

-- 
Reply to this email directly or view it on GitHub:
https://github.com/kamailio/kamailio/pull/3608
You are receiving this because you are subscribed to this thread.

Message ID: kamailio/kamailio/pull/3...@github.com
___
Kamailio (SER) - Development Mailing List
To unsubscribe send an email to sr-dev-le...@lists.kamailio.org


[sr-dev] Re: [kamailio/kamailio] build warnings on bookworm (Issue #3484)

2023-06-23 Thread juha-h
Closed #3484 as completed.

-- 
Reply to this email directly or view it on GitHub:
https://github.com/kamailio/kamailio/issues/3484#event-9614691197
You are receiving this because you commented.

Message ID: ___
Kamailio (SER) - Development Mailing List
To unsubscribe send an email to sr-dev-le...@lists.kamailio.org


[sr-dev] Re: [kamailio/kamailio] build warnings on bookworm (Issue #3484)

2023-06-23 Thread juha-h
Yes, all warnings are now gone.  Thanks.


-- 
Reply to this email directly or view it on GitHub:
https://github.com/kamailio/kamailio/issues/3484#issuecomment-1603835571
You are receiving this because you commented.

Message ID: ___
Kamailio (SER) - Development Mailing List
To unsubscribe send an email to sr-dev-le...@lists.kamailio.org


[sr-dev] Re: [kamailio/kamailio] build warnings on bookworm (Issue #3484)

2023-06-23 Thread juha-h
Here is diff to get rid of the curl warning:
```
*** /usr/src/orig/kamailio/src/modules/http_client/functions.c  2023-06-21 
13:15:29.682303834 +0300
--- src/opensipg-sip-proxy/src/modules/http_client/functions.c  2023-06-23 
09:00:14.403813698 +0300
***
*** 162,168 
curl, CURLOPT_PROTOCOLS, CURLPROTO_HTTP | 
CURLPROTO_HTTPS);
  #endif
res = curl_easy_setopt(
!   curl, CURLOPT_REDIR_PROTOCOLS, CURLPROTO_HTTP | 
CURLPROTO_HTTPS);
  
if(_met != NULL) {
/* Enforce method (GET, PUT, ...) */
--- 162,168 
curl, CURLOPT_PROTOCOLS, CURLPROTO_HTTP | 
CURLPROTO_HTTPS);
  #endif
res = curl_easy_setopt(
!   curl, CURLOPT_REDIR_PROTOCOLS_STR, "http,https");
  
if(_met != NULL) {
/* Enforce method (GET, PUT, ...) */
```

-- 
Reply to this email directly or view it on GitHub:
https://github.com/kamailio/kamailio/issues/3484#issuecomment-1603728827
You are receiving this because you commented.

Message ID: ___
Kamailio (SER) - Development Mailing List
To unsubscribe send an email to sr-dev-le...@lists.kamailio.org


[sr-dev] Re: [kamailio/kamailio] build warnings on bookworm (Issue #3484)

2023-06-21 Thread juha-h
This one is still left:
```
C (gcc) [M http_client.so]  functions.o
functions.c: In function 'curL_request_url':
functions.c:164:9: warning: 'CURLOPT_REDIR_PROTOCOLS' is deprecated: since 
7.85.0. Use CURLOPT_REDIR_PROTOCOLS_STR [-Wdeprecated-declarations]
  164 | res = curl_easy_setopt(
  | ^~~
In file included from http_client.h:36,
 from functions.c:45:
/usr/include/x86_64-linux-gnu/curl/curl.h:1755:3: note: declared here
 1755 |   CURLOPTDEPRECATED(CURLOPT_REDIR_PROTOCOLS, CURLOPTTYPE_LONG, 182,
  |   ^

```

-- 
Reply to this email directly or view it on GitHub:
https://github.com/kamailio/kamailio/issues/3484#issuecomment-1601389758
You are receiving this because you commented.

Message ID: ___
Kamailio (SER) - Development Mailing List
To unsubscribe send an email to sr-dev-le...@lists.kamailio.org


[sr-dev] Re: [kamailio/kamailio] build warnings on bookworm (Issue #3484)

2023-06-20 Thread juha-h
With this kind of tls.cfg
```
[client:default]
verify_certificate = yes
require_certificate = yes
tls_method = TLSv1.2+
private_key = /etc/sip-proxy/certs/siika-key.pem
certificate = /etc/sip-proxy/certs/siika-cert.pem
ca_list = /etc/sip-proxy/certs/ca_list.pem

[server:default]
verify_certificate = yes
require_certificate = no
server_name = test.tutpro.com
tls_method = TLSv1.2+
private_key = /etc/sip-proxy/certs/siika-key.pem
certificate = /etc/sip-proxy/certs/siika-cert.pem
ca_list = /etc/sip-proxy/certs/ca_list.pem
```
SIP Proxy was able to verify client certificate and vice versa.


-- 
Reply to this email directly or view it on GitHub:
https://github.com/kamailio/kamailio/issues/3484#issuecomment-1599227744
You are receiving this because you commented.

Message ID: ___
Kamailio (SER) - Development Mailing List
To unsubscribe send an email to sr-dev-le...@lists.kamailio.org


[sr-dev] Re: [kamailio/kamailio] build warnings on bookworm (Issue #3484)

2023-06-20 Thread juha-h
Daniel-Constantin Mierla writes:

> @juha-h: backporting to 5.7 may take a while, because support for
> libssl 3.0 is not validated yet. Those are deprecating warnings, so
> normally things should still work fine with them, but as reported on
> other issues, there are crashes with libssl 3.0. Therefore it is
> expected there are other internal changes in libssl 3.0 that need to
> be handled.

Yes, I understand, but lots of warnings when building stable, production
version of my SIP Proxy based on stable version of Kamailio, does not
look good.  So, lets keep this issue open until the backport is done to
5.7.

> Maybe you can help testing tls master branch and if proves stable,
> then can be backported. Just getting rid of changes in this case does
> not seem enough at this moment.

I'm using master in my own test setup and will report if I find TLS
related issues.

-- Juha


-- 
Reply to this email directly or view it on GitHub:
https://github.com/kamailio/kamailio/issues/3484#issuecomment-1599028823
You are receiving this because you commented.

Message ID: ___
Kamailio (SER) - Development Mailing List
To unsubscribe send an email to sr-dev-le...@lists.kamailio.org


[sr-dev] Re: [kamailio/kamailio] build warnings on bookworm (Issue #3484)

2023-06-20 Thread juha-h
Reopened #3484.

-- 
Reply to this email directly or view it on GitHub:
https://github.com/kamailio/kamailio/issues/3484#event-9580837229
You are receiving this because you commented.

Message ID: ___
Kamailio (SER) - Development Mailing List
To unsubscribe send an email to sr-dev-le...@lists.kamailio.org


[sr-dev] Re: [kamailio/kamailio] build warnings on bookworm (Issue #3484)

2023-06-20 Thread juha-h
Sorry, but the warnings have not been fixed in 5.7, which was the topic of this 
issue.

-- 
Reply to this email directly or view it on GitHub:
https://github.com/kamailio/kamailio/issues/3484#issuecomment-1598966691
You are receiving this because you commented.

Message ID: ___
Kamailio (SER) - Development Mailing List
To unsubscribe send an email to sr-dev-le...@lists.kamailio.org


[sr-dev] [kamailio/kamailio] build warnings on bookworm (Issue #3484)

2023-06-15 Thread juha-h
### Description

Kamailio 5.7 build on Debian Bookworm gave me the following build warnings.  
The only curl related build dependency that I have is
libcurl4-openssl-dev and the only openssl build dependency is libssl-dev.

```
CC (gcc) [M http_client.so] functions.o
functions.c: In function 'curL_request_url':
functions.c:158:9: warning: 'CURLOPT_PROTOCOLS' is deprecated: since 7.85.0. 
Use CURLOPT_PROTOCOLS_STR [-Wdeprecated-declarations]
  158 | res = curl_easy_setopt(
  | ^~~
In file included from http_client.h:36,
 from functions.c:45:
/usr/include/x86_64-linux-gnu/curl/curl.h:1749:3: note: declared here
 1749 |   CURLOPTDEPRECATED(CURLOPT_PROTOCOLS, CURLOPTTYPE_LONG, 181,
  |   ^
functions.c:160:9: warning: 'CURLOPT_REDIR_PROTOCOLS' is deprecated: since 
7.85.0. Use CURLOPT_REDIR_PROTOCOLS_STR [-Wdeprecated-declarations]
  160 | res = curl_easy_setopt(
  | ^~~
/usr/include/x86_64-linux-gnu/curl/curl.h:1755:3: note: declared here
 1755 |   CURLOPTDEPRECATED(CURLOPT_REDIR_PROTOCOLS, CURLOPTTYPE_LONG, 182,
  |   ^
functions.c:387:17: warning: 'CURLINFO_SIZE_DOWNLOAD' is deprecated: since 
7.55.0. Use CURLINFO_SIZE_DOWNLOAD_T [-Wdeprecated-declarations]
  387 | curl_easy_getinfo(curl, CURLINFO_SIZE_DOWNLOAD, 
_size);
  | ^
/usr/include/x86_64-linux-gnu/curl/curl.h:2841:3: note: declared here
 2841 |   CURLINFO_SIZE_DOWNLOAD
  |   ^~



CC (gcc) [M tls.so] tls_mod.o
tls_mod.c: In function 'mod_child':
tls_mod.c:455:25: warning: 'OPENSSL_fork_prepare' is deprecated: Since OpenSSL 
3.0 [-Wdeprecated-declarations]
  455 | OPENSSL_fork_prepare();
  | ^~~~
In file included from /usr/include/openssl/comp.h:22,
 from /usr/include/openssl/ssl.h:28,
 from tls_init.h:30,
 from tls_mod.c:45:
/usr/include/openssl/crypto.h:427:28: note: declared here
  427 | OSSL_DEPRECATEDIN_3_0 void OPENSSL_fork_prepare(void);
  |^~~~
tls_mod.c:467:25: warning: 'OPENSSL_fork_parent' is deprecated: Since OpenSSL 
3.0 [-Wdeprecated-declarations]
  467 | OPENSSL_fork_parent();
  | ^~~
/usr/include/openssl/crypto.h:428:28: note: declared here
  428 | OSSL_DEPRECATEDIN_3_0 void OPENSSL_fork_parent(void);
  |^~~
tls_mod.c:471:25: warning: 'OPENSSL_fork_child' is deprecated: Since OpenSSL 
3.0 [-Wdeprecated-declarations]
  471 | OPENSSL_fork_child();
  | ^~
/usr/include/openssl/crypto.h:429:28: note: declared here
  429 | OSSL_DEPRECATEDIN_3_0 void OPENSSL_fork_child(void);
  |^~
tls_mod.c: In function 'ksr_rand_engine_param':
tls_mod.c:514:17: warning: 'RAND_set_rand_method' is deprecated: Since OpenSSL 
3.0 [-Wdeprecated-declarations]
  514 | RAND_set_rand_method(RAND_ksr_krand_method());
  | ^~~~
In file included from tls_rand.h:26,
 from tls_mod.c:54:
/usr/include/openssl/rand.h:49:27: note: declared here
   49 | OSSL_DEPRECATEDIN_3_0 int RAND_set_rand_method(const RAND_METHOD *meth);
  |   ^~~~
tls_mod.c:517:17: warning: 'RAND_set_rand_method' is deprecated: Since OpenSSL 
3.0 [-Wdeprecated-declarations]
  517 | RAND_set_rand_method(RAND_ksr_fastrand_method());
  | ^~~~
/usr/include/openssl/rand.h:49:27: note: declared here
   49 | OSSL_DEPRECATEDIN_3_0 int RAND_set_rand_method(const RAND_METHOD *meth);
  |   ^~~~
tls_mod.c:520:17: warning: 'RAND_set_rand_method' is deprecated: Since OpenSSL 
3.0 [-Wdeprecated-declarations]
  520 | RAND_set_rand_method(RAND_ksr_cryptorand_method());
  | ^~~~
/usr/include/openssl/rand.h:49:27: note: declared here
   49 | OSSL_DEPRECATEDIN_3_0 int RAND_set_rand_method(const RAND_METHOD *meth);
  |   ^~~~
tls_mod.c:523:17: warning: 'RAND_set_rand_method' is deprecated: Since OpenSSL 
3.0 [-Wdeprecated-declarations]
  523 | RAND_set_rand_method(RAND_ksr_kxlibssl_method());
  | ^~~~
/usr/include/openssl/rand.h:49:27: note: declared here
   49 | OSSL_DEPRECATEDIN_3_0 int RAND_set_rand_method(const RAND_METHOD *meth);
  |   ^~~~
tls_mod.c: In function 'mod_register':
tls_mod.c:674:9: warning: 'RAND_set_rand_method' is deprecated: Since OpenSSL 
3.0 [-Wdeprecated-declarations]
  674 | 

[sr-dev] Re: [kamailio/kamailio] lcr: crash on ki_load_gws*() if called via KEMI (Issue #3435)

2023-05-04 Thread juha-h
KEMI was introduced to lcr module by this commit: 
https://github.com/kamailio/kamailio/commit/8fbf7d83b1dbeedf1ee53895aadbf6e99321432d.

-- 
Reply to this email directly or view it on GitHub:
https://github.com/kamailio/kamailio/issues/3435#issuecomment-1535234476
You are receiving this because you are subscribed to this thread.

Message ID: ___
Kamailio (SER) - Development Mailing List
To unsubscribe send an email to sr-dev-le...@lists.kamailio.org


[sr-dev] Re: [kamailio/kamailio] lcr: crash on ki_load_gws*() if called via KEMI (Issue #3435)

2023-05-04 Thread juha-h
Victor Seva writes:

> Assigned #3435 to @juha-h.

Victor,

Anything related to KEMI is not written me and I don't know anything
about it.

-- Juha


-- 
Reply to this email directly or view it on GitHub:
https://github.com/kamailio/kamailio/issues/3435#issuecomment-1535226928
You are receiving this because you are subscribed to this thread.

Message ID: ___
Kamailio (SER) - Development Mailing List
To unsubscribe send an email to sr-dev-le...@lists.kamailio.org


[sr-dev] Re: [kamailio/kamailio] crash when handling SUBSCRIBE message (Issue #3417)

2023-04-18 Thread juha-h
Closed #3417 as completed.

-- 
Reply to this email directly or view it on GitHub:
https://github.com/kamailio/kamailio/issues/3417#event-9038721707
You are receiving this because you are subscribed to this thread.

Message ID: ___
Kamailio (SER) - Development Mailing List
To unsubscribe send an email to sr-dev-le...@lists.kamailio.org


[sr-dev] Re: [kamailio/kamailio] crash when handling SUBSCRIBE message (Issue #3417)

2023-04-18 Thread juha-h
Daniel-Constantin Mierla writes:

> Can you try with latest devel version? I pushed a commit to fix this.

Thanks, the crash does not happen anymore.

-- Juha


-- 
Reply to this email directly or view it on GitHub:
https://github.com/kamailio/kamailio/issues/3417#issuecomment-1513577881
You are receiving this because you are subscribed to this thread.

Message ID: ___
Kamailio (SER) - Development Mailing List
To unsubscribe send an email to sr-dev-le...@lists.kamailio.org


[sr-dev] Re: [kamailio/kamailio] crash when handling SUBSCRIBE message (Issue #3417)

2023-04-16 Thread juha-h
K at this commit works OK: 
https://github.com/kamailio/kamailio/commit/ea30efdbae2b33988e6157ba5e17aba16db156d4
 and crashes at this commit: 
https://github.com/kamailio/kamailio/commit/c7e228eae76a432ea93fac7e95f50fe50979d79e.

-- 
Reply to this email directly or view it on GitHub:
https://github.com/kamailio/kamailio/issues/3417#issuecomment-1510297347
You are receiving this because you are subscribed to this thread.

Message ID: ___
Kamailio (SER) - Development Mailing List
To unsubscribe send an email to sr-dev-le...@lists.kamailio.org


[sr-dev] [kamailio/kamailio] crash when handling SUBSCRIBE message (Issue #3417)

2023-04-13 Thread juha-h
### Description

Latest K master crashes on Debian 11 when handling SUBSCRIBE message.

 Reproduction

Happens every time in my test and I can thus provide more information if needed.

 Debugging Data
```
GNU gdb (Debian 10.1-1.7) 10.1.90.20210103-git
Copyright (C) 2021 Free Software Foundation, Inc.
License GPLv3+: GNU GPL version 3 or later 
This is free software: you are free to change and redistribute it.
There is NO WARRANTY, to the extent permitted by law.
Type "show copying" and "show warranty" for details.
This GDB was configured as "x86_64-linux-gnu".
Type "show configuration" for configuration details.
For bug reporting instructions, please see:
.
Find the GDB manual and other documentation resources online at:
.

For help, type "help".
Type "apropos word" to search for commands related to "word"...
Reading symbols from /usr/bin/pres-serv...
[New LWP 342614]
[Thread debugging using libthread_db enabled]
Using host libthread_db library "/lib/x86_64-linux-gnu/libthread_db.so.1".
Core was generated by `/usr/bin/pres-serv -f /etc/pres-serv/pres-serv.cfg -P 
/run/pres-serv/pres-serv.'.
Program terminated with signal SIGSEGV, Segmentation fault.
#0  0x7f58c362cad0 in trim_leading (_s=0x7f58bceeb558) at 
../../core/trim.h:59
[?2004h(gdb) bt full
[?2004l
#0  0x7f58c362cad0 in trim_leading (_s=0x7f58bceeb558) at 
../../core/trim.h:59
No locals.
#1  0x7f58c362cbc0 in trim (_s=0x7f58bceeb558) at ../../core/trim.h:90
No locals.
#2  0x7f58c363f51c in print_callid (w=0x7f58bceed731 "", 
dialog=0x7f58c378c350, t=0x7f58bceeb4f0) at t_msgbuilder.c:1531
No locals.
#3  0x7f58c3640d78 in build_uac_req (method=0x7ffc2c640ae0, 
headers=0x7ffc2c640af0, body=0x0, dialog=0x7f58c378c350, 
branch=0, t=0x7f58bceeb4f0, len=0x7ffc2c64023c, dst=0x7ffc2c640380) at 
t_msgbuilder.c:1649
buf = 0x7f58bceed5d0 "NOTIFY 
sip:t...@test.tutpro.com;gr=urn:uuid:9b21c1a8-dc58-a3d6-83d5-7be67cbe70ce 
SIP/2.0\r\nVia: SIP/2.0/TCP 127.0.0.1:5080;branch=z9hG4bK64ba.0bec0511", '0' 
, ".0\r\nTo:  "0", len = 1}
cseq = {s = 0x7f58c36f77e0  "2", len = 1}
via = {
  s = 0x7f58c378c590 "Via: SIP/2.0/TCP 
127.0.0.1:5080;branch=z9hG4bK64ba.0bec0511", '0' , ".0\r\n", 
  len = 87}
maxfwd_len = 0
tbracket = 1
fbracket = 1
fromtag = {s = 0x0, len = 0}
loc_tag = {s = 0x0, len = 0}
__func__ = "build_uac_req"
#4  0x7f58c36b9e34 in t_uac_prepare (uac_r=0x7ffc2c640b40, 
dst_req=0x7ffc2c640498, dst_cell=0x7ffc2c6404a0) at uac.c:541
dst = {send_sock = 0x7f58c3795bb0, to = {s = {sa_family = 2, 
  sa_data = 
"\023\316\177\000\000\001\000\000\000\000\000\000\000"}, sin = {sin_family = 2, 
sin_port = 52755, 
  sin_addr = {s_addr = 16777343}, sin_zero = 
"\000\000\000\000\000\000\000"}, sin6 = {sin6_family = 2, 
  sin6_port = 52755, sin6_flowinfo = 16777343, sin6_addr = {__in6_u 
= {__u6_addr8 = '\000' , 
  __u6_addr16 = {0, 0, 0, 0, 0, 0, 0, 0}, __u6_addr32 = {0, 0, 
0, 0}}}, sin6_scope_id = 0}, sas = {
  ss_family = 2, __ss_padding = "\023\316\177\000\000\001", '\000' 
, __ss_align = 0}}, id = 0, 
  send_flags = {f = 4, blst_imask = 0}, proto = 2 '\002', proto_pad0 = 
0 '\000', proto_pad1 = 0}
new_cell = 0x7f58bceeb4f0
request = 0x7f58bceeb7c0
buf = 0x0
buf_len = 665
ret = -1
hi = 43846
is_ack = 0
lifetime = 512
nhtype = 256
snd_flags = {f = 4, blst_imask = 0}
backup_xd = {uri_avps_from = 0x7f58bcee78a0, uri_avps_to = 
0x7f58bcee78a8, user_avps_from = 0x7f58bcee78b0, 
  user_avps_to = 0x7f58bcee78b8, domain_avps_from = 0x557db2f646c0 
, 
  domain_avps_to = 0x557db2f646c8 , xavps_list = 
0x7f58bcee78d0, xavus_list = 0x7f58bcee78d8, 
  xavis_list = 0x7f58bcee78e0}
local_xd = {uri_avps_from = 0x0, uri_avps_to = 0x0, user_avps_from = 
0x0, user_avps_to = 0x0, domain_avps_from = 0x0, 
  domain_avps_to = 0x0, xavps_list = 0x0, xavus_list = 0x0, xavis_list 
= 0x0}
refresh_shortcuts = 0
sip_msg_len = 0
lreq = {id = 0, pid = 0, tval = {tv_sec = 0, tv_usec = 0}, 
fwd_send_flags = {f = 0, blst_imask = 0}, 
  rpl_send_flags = {f = 0, blst_imask = 0}, first_line = {type = 0, 
flags = 0, len = 0, u = {request = {method = {
  s = 0x0, len = 0}, uri = {s = 0x0, len = 0}, version = {s = 
0x0, len = 0}, method_value = 0}, reply = {
version = {s = 0x0, len = 0}, status = {s = 0x0, len = 0}, 
reason = {s = 0x0, len = 0}, statuscode = 0}}}, 
  via1 = 0x0, via2 = 0x0, headers = 0x0, last_header = 0x0, parsed_flag 
= 0, h_via1 = 0x0, h_via2 = 0x0, 
  callid = 0x0, to = 0x0, cseq = 0x0, from = 0x0, contact = 0x0, 
maxforwards = 0x0, route = 0x0, record_route = 

[sr-dev] Re: [kamailio/kamailio] lcr: add counters per gateway (PR #3391)

2023-03-14 Thread juha-h
Alessio Garzi writes:

> Yes,counters will be only incremented if ip and port are maching as you said.
> This is because ip and port is how I usually store in the lcr table and my 
> commit is just based on my needs.
> Maybe someone in the future can improve my commit to cover all cases.
> For now I just added a notice on the docs describing this behaviour.

As I wrote, I don't consider it a good idea to include a feature that
only works in some situations.

Is there some reason why you can't implement the same in the script
without modifying lcr module?


-- 
Reply to this email directly or view it on GitHub:
https://github.com/kamailio/kamailio/pull/3391#issuecomment-1467938755
You are receiving this because you are subscribed to this thread.

Message ID: ___
Kamailio (SER) - Development Mailing List
To unsubscribe send an email to sr-dev-le...@lists.kamailio.org


[sr-dev] Re: [kamailio/kamailio] lcr: add counters per gateway (PR #3391)

2023-03-11 Thread juha-h
I did some reading of the code and looks like it does not affect current 
behavior nor have any performance impact if the the stats are off.

But if I understood correctly, in the PR, matching of a SIP request/reply to an 
lcr gw is done based on IP address/port (`fetch_gw_id` function).  On my LCR 
module web page, I have:
```
LCR Instance 'default' Gateway 'test'

Inbound Properties
Common Name or IP Address | Transport

Outbound Properties
IP Address or Domain Name | Port | Transport
```
That is, it is possible that LCR  module does not have any knowledge of the IP 
address/port of a gateway.

The only way I can find if a request comes from a gateway specified by Common 
Name is in the script like this:
```
$var(gw_in_id) = $sht(htable=>cn::$tls_peer_subject_cn::gw_id);
```
That is, looking a common name match from htable.

So unless I didn't read the code correctly, I don't consider it a good idea to 
have a stats feature that applies only to some gateways.











-- 
Reply to this email directly or view it on GitHub:
https://github.com/kamailio/kamailio/pull/3391#issuecomment-1465001446
You are receiving this because you are subscribed to this thread.

Message ID: ___
Kamailio (SER) - Development Mailing List
To unsubscribe send an email to sr-dev-le...@lists.kamailio.org


Re: [sr-dev] [kamailio/kamailio] lcr: improve the search for GW when IP address and src_port are used (#2876)

2021-10-08 Thread juha-h
Victor Seva writes:

> Assigned #2876 to @juha-h.

OK with me to merge the PR because it only deals with the newly
introduced port feature.


-- 
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
https://github.com/kamailio/kamailio/pull/2876#issuecomment-938725693___
Kamailio (SER) - Development Mailing List
sr-dev@lists.kamailio.org
https://lists.kamailio.org/cgi-bin/mailman/listinfo/sr-dev


Re: [sr-dev] [kamailio/kamailio] lcr: improve binary search to support a match including src port (#2859)

2021-09-20 Thread juha-h
Indentation does not look good  in the if statement.

-- 
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
https://github.com/kamailio/kamailio/pull/2859#issuecomment-923101655___
Kamailio (SER) - Development Mailing List
sr-dev@lists.kamailio.org
https://lists.kamailio.org/cgi-bin/mailman/listinfo/sr-dev


Re: [sr-dev] [kamailio/kamailio] lcr: improve binary search to support a match including src port (#2859)

2021-09-18 Thread juha-h
After the binary match change, is it so that there is no need to change this 
test?
```
/* Store tag and flags and return result */
if((res != NULL)
&& ((transport == PROTO_NONE) || 
(res->transport_code == transport))
&& ((src_port == 0) || (res->port == 
src_port))) {
```

-- 
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
https://github.com/kamailio/kamailio/pull/2859#issuecomment-922213175___
Kamailio (SER) - Development Mailing List
sr-dev@lists.kamailio.org
https://lists.kamailio.org/cgi-bin/mailman/listinfo/sr-dev


Re: [sr-dev] [kamailio/kamailio] lcr: source port check for from_any_gw() and from_gw(). (#2832)

2021-08-24 Thread juha-h
I haven't tested the new feature, but from backwards compatibility point of 
view, the implementation looks good to me.  Thus I have nothing against the 
merge.

-- 
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
https://github.com/kamailio/kamailio/pull/2832#issuecomment-904808255___
Kamailio (SER) - Development Mailing List
sr-dev@lists.kamailio.org
https://lists.kamailio.org/cgi-bin/mailman/listinfo/sr-dev


Re: [sr-dev] [kamailio/kamailio] add ca_path param to tls module (#2682)

2021-03-24 Thread juha-h
Both as client and as server work after command `c_rehash .` is executed in 
ca_path directory.  It creates two (why two?) links to each ca certificate 
file, for example:
```
$ ls -ls
total 16
0 lrwxrwxrwx 1 jh jh   18 Mar 24 07:58 12d55845.0 -> dst_root_ca_x3.pem
0 lrwxrwxrwx 1 jh jh   18 Mar 24 07:58 2e5ac55d.0 -> dst_root_ca_x3.pem
0 lrwxrwxrwx 1 jh jh   32 Mar 24 07:58 4a0a35c0.0 -> 
lets-encrypt-x3-cross-signed.pem
0 lrwxrwxrwx 1 jh jh   32 Mar 24 07:58 4f06f81d.0 -> 
lets-encrypt-x3-cross-signed.pem
0 lrwxrwxrwx 1 jh jh   14 Mar 24 07:58 590d426f.0 -> class3_X0E.crt
0 lrwxrwxrwx 1 jh jh   12 Mar 24 07:58 5ed36f99.0 -> root_X0F.crt
0 lrwxrwxrwx 1 jh jh   12 Mar 24 07:58 99d0fa06.0 -> root_X0F.crt
4 -rw-r--r-- 1 jh jh 2427 Mar 23 16:40 class3_X0E.crt
4 -rw-r--r-- 1 jh jh 1200 Mar 23 16:40 dst_root_ca_x3.pem
0 lrwxrwxrwx 1 jh jh   14 Mar 24 07:58 e5662767.0 -> class3_X0E.crt
4 -rw-r--r-- 1 jh jh 1647 Mar 23 16:40 lets-encrypt-x3-cross-signed.pem
4 -rw-r--r-- 1 jh jh 2464 Mar 23 16:40 root_X0F.crt
```
Text on page 
[https://www.openssl.org/docs/man1.0.2/man3/SSL_CTX_load_verify_locations.html](url)
 is not very clear about the links:

`
If CApath is not NULL, it points to a directory containing CA certificates in 
PEM format. The files each contain one CA certificate. The files are looked up 
by the CA subject name hash value, which must hence be available. If more than 
one CA certificate with the same name hash value exist, the extension must be 
different (e.g. 9d66eef0.0, 9d66eef0.1 etc). The search is performed in the 
ordering of the extension number, regardless of other properties of the 
certificates. Use the c_rehash utility to create the necessary links.
`


-- 
You are receiving this because you commented.
Reply to this email directly or view it on GitHub:
https://github.com/kamailio/kamailio/issues/2682#issuecomment-805528425___
Kamailio (SER) - Development Mailing List
sr-dev@lists.kamailio.org
https://lists.kamailio.org/cgi-bin/mailman/listinfo/sr-dev


Re: [sr-dev] [kamailio/kamailio] add ca_path param to tls module (#2682)

2021-03-24 Thread juha-h
Closed #2682.

-- 
You are receiving this because you commented.
Reply to this email directly or view it on GitHub:
https://github.com/kamailio/kamailio/issues/2682#event-4499952619___
Kamailio (SER) - Development Mailing List
sr-dev@lists.kamailio.org
https://lists.kamailio.org/cgi-bin/mailman/listinfo/sr-dev


Re: [sr-dev] [kamailio/kamailio] add ca_path param to tls module (#2682)

2021-03-23 Thread juha-h
Daniel-Constantin Mierla writes:

> As I said, I added the parameter based on the description of the
> feature request, but the manual suggested it might not be enough when
> acting as a tls server, see my first comment above. 
> 
> Probably works when it acts as a client (when opens the connection).

Yes, it does work as client.  I have two kamailios A - B using TLS between
them. When A uses ca_path and B uses ca_list, A can connect to B without
errors.  But when I change also B to use ca_path, I get errors on both.

On A:
Mar 23 15:32:58 lohi /usr/bin/sip-proxy[18482]: ERROR: tls [tls_server.c:1283]: 
tls_h_read_f(): protocol level error
Mar 23 15:32:58 lohi /usr/bin/sip-proxy[18482]: ERROR: tls [tls_util.h:42]: 
tls_err_ret(): TLS read:error:14094418:SSL routines:ssl3_read_bytes:tlsv1 alert 
unknown ca
Mar 23 15:32:58 lohi /usr/bin/sip-proxy[18482]: ERROR: tls [tls_server.c:1287]: 
tls_h_read_f(): source IP: 192.26.134.10
Mar 23 15:32:58 lohi /usr/bin/sip-proxy[18482]: ERROR: tls [tls_server.c:1290]: 
tls_h_read_f(): destination IP: 192.168.43.160

On B:
 Mar 23 15:32:58 buster /usr/bin/sip-proxy[2266]: ERROR: tls 
[tls_server.c:1283]: tls_h_read_f(): protocol level error
Mar 23 15:32:58 buster /usr/bin/sip-proxy[2266]: ERROR: tls [tls_util.h:42]: 
tls_err_ret(): TLS accept:error:1417C086:SSL 
routines:tls_process_client_certificate:certificate verify failed
Mar 23 15:32:58 buster /usr/bin/sip-proxy[2266]: ERROR: tls 
[tls_server.c:1287]: tls_h_read_f(): source IP: 192.168.43.160
Mar 23 15:32:58 buster /usr/bin/sip-proxy[2266]: ERROR: tls 
[tls_server.c:1290]: tls_h_read_f(): destination IP: 192.26.134.10

-- Juha


-- 
You are receiving this because you commented.
Reply to this email directly or view it on GitHub:
https://github.com/kamailio/kamailio/issues/2682#issuecomment-804910135___
Kamailio (SER) - Development Mailing List
sr-dev@lists.kamailio.org
https://lists.kamailio.org/cgi-bin/mailman/listinfo/sr-dev


Re: [sr-dev] [kamailio/kamailio] add ca_path param to tls module (#2682)

2021-03-23 Thread juha-h
Daniel-Constantin Mierla writes:

> Being Kamailio specific coding, I added the config option and set it
> value as parameter to SSL_CTX_load_verify_locations() based on the
> feature request description, but it might not be complete
> implementation because its manual specify that the folder content is
> not send to client via SSL_CTX_set_client_CA_list(): 
> 
>   * 
> https://www.openssl.org/docs/man1.1.1/man3/SSL_CTX_load_verify_locations.html

Neither is contents of CAfile sent to client:

  In server mode, when requesting a client certificate, the server must
  send the list of CAs of which it will accept client certificates. This
  list is not influenced by the contents of CAfile or CApath and must
  explicitly be set using the SSL_CTX_set_client_CA_list(3) family of
  functions.

-- Juha


-- 
You are receiving this because you commented.
Reply to this email directly or view it on GitHub:
https://github.com/kamailio/kamailio/issues/2682#issuecomment-804840617___
Kamailio (SER) - Development Mailing List
sr-dev@lists.kamailio.org
https://lists.kamailio.org/cgi-bin/mailman/listinfo/sr-dev


Re: [sr-dev] [kamailio/kamailio] add ca_path param to tls module (#2682)

2021-03-23 Thread juha-h
Daniel-Constantin Mierla writes:

> The error message seems to be related to failure to open `ca_list`
> file, not to `ca_path` -- can you check if `ca_list` is still set
> somewhere there to an invalid file path?

I checked and config file has only this:

modparam("tls", "config", "/etc/sip-proxy/tls.cfg")

and tls.cfg contains:

# more tls.cfg
[client:default]
verify_certificate = yes
require_certificate = yes
tls_method = TLSv1.2+
private_key = /etc/sip-proxy/certs/key.pem
certificate = /etc/sip-proxy/certs/cert.pem
ca_path = /etc/sip-proxy/certs/ca_list

[server:default]
verify_certificate = yes
require_certificate = no
server_name = lohi.tutpro.com
tls_method = TLSv1.1+
private_key = /etc/sip-proxy/certs/key.pem
certificate = /etc/sip-proxy/certs/cert.pem
ca_path = /etc/sip-proxy/certs/ca_list

There is no trace of ca_list anywhere.  Also syslog shows that ca_list
is null:

Mar 23 13:19:03 lohi /usr/bin/sip-proxy[13983]: INFO: tls [tls_domain.c:322]: 
ksr_tls_fill_missing(): TLSs: 
certificate='/etc/sip-proxy/certs/cert.pem'
Mar 23 13:19:03 lohi /usr/bin/sip-proxy[13983]: INFO: tls [tls_domain.c:329]: 
ksr_tls_fill_missing(): TLSs: ca_list='(null)'
Mar 23 13:19:03 lohi /usr/bin/sip-proxy[13983]: INFO: tls [tls_domain.c:336]: 
ksr_tls_fill_missing(): TLSs: ca_path='/etc/sip-proxy/certs/ca_list'


-- 
You are receiving this because you commented.
Reply to this email directly or view it on GitHub:
https://github.com/kamailio/kamailio/issues/2682#issuecomment-804822963___
Kamailio (SER) - Development Mailing List
sr-dev@lists.kamailio.org
https://lists.kamailio.org/cgi-bin/mailman/listinfo/sr-dev


Re: [sr-dev] [kamailio/kamailio] add ca_path param to tls module (#2682)

2021-03-23 Thread juha-h
Looks like installation of new version of kamailio had failed and tls
module was not updated.  Trying again ...


-- 
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
https://github.com/kamailio/kamailio/issues/2682#issuecomment-804775191___
Kamailio (SER) - Development Mailing List
sr-dev@lists.kamailio.org
https://lists.kamailio.org/cgi-bin/mailman/listinfo/sr-dev


Re: [sr-dev] [kamailio/kamailio] add ca_path param to tls module (#2682)

2021-03-23 Thread juha-h
Thanks for your work on ca_path. It is so that currently ca_path can
only be given as tls module config parameter and not in tls config
file.   I tried like this:

modparam("tls", "config", "/etc/sip-proxy/tls.cfg")

tls.cfg:

[server:default]
verify_certificate = yes
require_certificate = no
server_name = lohi.tutpro.com
tls_method = TLSv1.1+
private_key = /etc/sip-proxy/certs/key.pem
certificate = /etc/sip-proxy/certs/cert.pem
ca_path = /etc/sip-proxy/certs/ca_list

and got error at start:

Mar 23 11:47:18 lohi /usr/bin/sip-proxy[25175]: ERROR:  
[core/cfg_parser.c:731]: sr_cfg_parse(): tls.cfg:7:1: Unsupported option 
'ca_path'


-- 
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
https://github.com/kamailio/kamailio/issues/2682#issuecomment-804768330___
Kamailio (SER) - Development Mailing List
sr-dev@lists.kamailio.org
https://lists.kamailio.org/cgi-bin/mailman/listinfo/sr-dev


[sr-dev] [kamailio/kamailio] add ca_path param to tls module (#2682)

2021-03-17 Thread juha-h
Currently tls module has `ca_list` param that

`Sets the CA list file name. This file contains a list of all the trusted CAs 
certificates used when connecting to other SIP implementations. If a signature 
in a certificate chain belongs to one of the listed CAs, the verification of 
that certificate will succeed.` 

This issue proposes adding a new tls param `ca_path`.  Its value would be a 
directory that contains any number of CA certificate files thus making it 
unnecessary to cat these files to a single `ca_list` file.

Implementation could be based on SSL_CTX_set_default_verify_dir() OpenSSL API 
function.

-- 
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
https://github.com/kamailio/kamailio/issues/2682___
Kamailio (SER) - Development Mailing List
sr-dev@lists.kamailio.org
https://lists.kamailio.org/cgi-bin/mailman/listinfo/sr-dev


Re: [sr-dev] [kamailio/kamailio] Added ; sn param check to loose.c is_myself() (#2643)

2021-02-21 Thread juha-h
Closed #2643.

-- 
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
https://github.com/kamailio/kamailio/pull/2643#event-4356256325___
Kamailio (SER) - Development Mailing List
sr-dev@lists.kamailio.org
https://lists.kamailio.org/cgi-bin/mailman/listinfo/sr-dev


Re: [sr-dev] [kamailio/kamailio] Added ; sn param check to loose.c is_myself() (#2643)

2021-02-21 Thread juha-h
Can be replaced by corex alias_subdomains.

-- 
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
https://github.com/kamailio/kamailio/pull/2643#issuecomment-782843733___
Kamailio (SER) - Development Mailing List
sr-dev@lists.kamailio.org
https://lists.kamailio.org/cgi-bin/mailman/listinfo/sr-dev


Re: [sr-dev] [kamailio/kamailio] Added ; sn param check to loose.c is_myself() (#2643)

2021-02-21 Thread juha-h
Daniel-Constantin Mierla writes:

> What I said that the list of FQDNs for tenants can be specified via
> alias global params, corex or domain modules to Kamailio, then this
> patch is not needed, the loose route should do its job. It is
> irrelevant for what loose route is supposed to do that you need it to
> interconnect with MS Teams.

I'll give corex alias_subdomains a try and close the pull request if it
works as expected.

--- Juha


-- 
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
https://github.com/kamailio/kamailio/pull/2643#issuecomment-782841064___
Kamailio (SER) - Development Mailing List
sr-dev@lists.kamailio.org
https://lists.kamailio.org/cgi-bin/mailman/listinfo/sr-dev


Re: [sr-dev] [kamailio/kamailio] Added ; sn param check to loose.c is_myself() (#2643)

2021-02-21 Thread juha-h
Daniel-Constantin Mierla writes:

> The commit message first line has to start with the name of the module
> ("rr: ...") like per contributing guide: 
> 
>   * 
> https://github.com/kamailio/kamailio/blob/master/.github/CONTRIBUTING.md#commit-message-format
> 
> It is important for generating changelogs and releases. I made a
> similar remark to your latest commit as well.

OK, will add if this leads to anywhere.

> Then, related to the commit itself, `myself` matching is related to
> routing address (ip/domain) matching of the server, this should be the
> default behaviour. Otherwise, on this case, it can happen that is
> matching headers added by another node using same socket names, which
> can have unexpected side effects in processing .

If such conflicts can happen or not, depends on the proxy deployment
environment.

> Personally I do not really see the need for what this patch brings,
> because you can specify the domains associated with the sever on
> several ways: config alias parameters, domain module (with register
> myself) for dynamic or large number of domains and corex module for
> subdomains.

In multi-tenant setup, MS Teams does not know which tenant INVITE from
Kamailio tries to reach if first R-R URI does not contain FQDN of the
tenant and, like everyone knows, MS does not care sh*t about standards
compatibility.  So the FQDN needs to be there and also loose_route()
needs to work.  I don't think that the other options you mention in the
above can help here.

> However, I am fine to add the behaviour of the patch, but controlled
> by a new rr module parameter (e.g, myself_mode) , default being
> disabled (e.g., myself_mode=0) so the match is done like so far, on
> address elements only.

OK, I'll try to add if the patch otherwise is OK.

-- Juha


-- 
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
https://github.com/kamailio/kamailio/pull/2643#issuecomment-782832420___
Kamailio (SER) - Development Mailing List
sr-dev@lists.kamailio.org
https://lists.kamailio.org/cgi-bin/mailman/listinfo/sr-dev


[sr-dev] [kamailio/kamailio] Added ; sn param check to loose.c is_myself() (#2643)

2021-02-21 Thread juha-h
Added ;sn param check to loose.c is_myself() so that loose_route() would 
recognize such a Route URI denoting itself.
You can view, comment on, or merge this pull request online at:

  https://github.com/kamailio/kamailio/pull/2643

-- Commit Summary --

  * Added ;sn param check to loose.c is_myself()

-- File Changes --

M src/modules/rr/loose.c (27)

-- Patch Links --

https://github.com/kamailio/kamailio/pull/2643.patch
https://github.com/kamailio/kamailio/pull/2643.diff

-- 
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
https://github.com/kamailio/kamailio/pull/2643
___
Kamailio (SER) - Development Mailing List
sr-dev@lists.kamailio.org
https://lists.kamailio.org/cgi-bin/mailman/listinfo/sr-dev


Re: [sr-dev] [kamailio/kamailio] add_rr_param() call has no effect after record_route_preset() call (#2634)

2021-02-11 Thread juha-h
Closed #2634.

-- 
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
https://github.com/kamailio/kamailio/issues/2634#event-4320536416___
Kamailio (SER) - Development Mailing List
sr-dev@lists.kamailio.org
https://lists.kamailio.org/cgi-bin/mailman/listinfo/sr-dev


Re: [sr-dev] [kamailio/kamailio] add_rr_param() call has no effect after record_route_preset() call (#2634)

2021-02-11 Thread juha-h
Fixed by 
https://github.com/kamailio/kamailio/commit/76b886da8ddf11a94a62850c19bad8c83bd113fc

-- 
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
https://github.com/kamailio/kamailio/issues/2634#issuecomment-777587369___
Kamailio (SER) - Development Mailing List
sr-dev@lists.kamailio.org
https://lists.kamailio.org/cgi-bin/mailman/listinfo/sr-dev


Re: [sr-dev] [kamailio/kamailio] add_rr_param() call has no effect after record_route_preset() call (#2634)

2021-02-11 Thread juha-h
Checked and in OpenSIPS add_rr_param() works also after record_route_preset(). 
It may not be a bug in K, since r-r code has evolved quite a bit in OpenSIPS 
and now supports it.

-- 
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
https://github.com/kamailio/kamailio/issues/2634#issuecomment-777569327___
Kamailio (SER) - Development Mailing List
sr-dev@lists.kamailio.org
https://lists.kamailio.org/cgi-bin/mailman/listinfo/sr-dev


[sr-dev] [kamailio/kamailio] add_rr_param() call has no effect after record_route_preset() call (#2634)

2021-02-11 Thread juha-h
R-R URI parameters do not get added to outgoing R-R header(s) when 
add_rr_param() call is made after record_route_preset() call.

I don't know if this a bug or a feature, but it would be very useful if 
add_rr_param() would work same way after record_route_preset() as it works 
after record_route().


-- 
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
https://github.com/kamailio/kamailio/issues/2634___
Kamailio (SER) - Development Mailing List
sr-dev@lists.kamailio.org
https://lists.kamailio.org/cgi-bin/mailman/listinfo/sr-dev


Re: [sr-dev] [kamailio/kamailio] keepalive.add hangs (#2625)

2021-02-11 Thread juha-h
Closed #2625.

-- 
You are receiving this because you commented.
Reply to this email directly or view it on GitHub:
https://github.com/kamailio/kamailio/issues/2625#event-4318651859___
Kamailio (SER) - Development Mailing List
sr-dev@lists.kamailio.org
https://lists.kamailio.org/cgi-bin/mailman/listinfo/sr-dev


[sr-dev] [kamailio/kamailio] keepalive.add hangs (#2625)

2021-02-05 Thread juha-h
Trying to add first item to keepalive list using rpc command hangs, for example
```
kamailio_ctl> keepalive.add sip:example.com:5060 test
```


-- 
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
https://github.com/kamailio/kamailio/issues/2625___
Kamailio (SER) - Development Mailing List
sr-dev@lists.kamailio.org
https://lists.kamailio.org/cgi-bin/mailman/listinfo/sr-dev


Re: [sr-dev] [kamailio/kamailio] keepalive.list crash (#2618)

2021-02-05 Thread juha-h
Closed #2618.

-- 
You are receiving this because you commented.
Reply to this email directly or view it on GitHub:
https://github.com/kamailio/kamailio/issues/2618#event-4296761945___
Kamailio (SER) - Development Mailing List
sr-dev@lists.kamailio.org
https://lists.kamailio.org/cgi-bin/mailman/listinfo/sr-dev


Re: [sr-dev] [kamailio/kamailio] keepalive.list crash (#2618)

2021-02-02 Thread juha-h
For some reason destination list is allocated with one uninitialized  item 
already in it:
```
int ka_alloc_destinations_list()
{
if(ka_destinations_list != NULL) {
LM_DBG("ka_destinations_list already allocated\n");
return 1;
}

ka_destinations_list = (ka_destinations_list_t *)shm_malloc(
sizeof(ka_destinations_list_t));
```
It may be the source of trouble when keepalive_rpc_list tries to list it:
```
static void keepalive_rpc_list(rpc_t *rpc, void *ctx)
{
void *sub;
ka_dest_t *dest;
char t_buf[26] = {0};

for(dest = ka_destinations_list->first; dest != NULL; dest = 
dest->next) {
```



-- 
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
https://github.com/kamailio/kamailio/issues/2618#issuecomment-771830462___
Kamailio (SER) - Development Mailing List
sr-dev@lists.kamailio.org
https://lists.kamailio.org/cgi-bin/mailman/listinfo/sr-dev


[sr-dev] [kamailio/kamailio] keepalive.list crash (#2618)

2021-02-02 Thread juha-h
With Kamalio master, RPC command keepalive.list causes crash (at least when 
there is nothing in the list). 

gdb) bt full
#0  rpc_struct_add (s=0x560b4df75830, fmt=0x7f2da23322c3 "SS") at 
binrpc_run.c:1092
ap = {{gp_offset = 32, fp_offset = 48, overflow_arg_area = 
0x7ffebd54cfc0, 
reg_save_area = 0x7ffebd54ced0}}
err = -1118515440
avp = {name = {s = 0x7f2da23322bf "uri", len = 3}, type = 1, u = 
{strval = {s = 0x0, 
  len = 0}, fval = 0, intval = 0, end = 0}}
rs = 0x7ffebd54d0e0
__func__ = "rpc_struct_add"
#1  0x7f2da2322776 in keepalive_rpc_list (rpc=0x7f2da2f022e0 
, 
ctx=0x7ffebd54d0e0) at keepalive_rpc.c:86
sub = 0x560b4df75830
dest = 0x1
t_buf = '\000' 
#2  0x7f2da2ecc993 in process_rpc_req (
buf=0x560b4df55784 "\241\003\021'\332D}\221\017keepalive.list", size=24, 
bytes_needed=0x7ffebd54d1e8, sh=0x7ffebd54d250, saved_state=0x560b4df65788)
at binrpc_run.c:683
err = 0
val = {name = {s = 0x7ffebd54d1c0 " \323T\275\376\177", len = 
-1561476359}, type = 1, 
  u = {strval = {s = 0x560b4df5578d "keepalive.list", len = 14}, 
fval = 4.6741847488088159e-310, intval = 1307924365, end = 
1307924365}}
rpc_e = 0x7f2da3c91910
f_ctx = {in = {ctx = {tlen = 17, cookie = 668615805, type = 0, flags = 
1, 
  offset = 17, in_struct = 0, in_array = 0}, s = 0x560b4df5579c "", 
end = 0x560b4df5579c "", record_no = 0, in_struct = 0}, out = {pkt 
= {
  body = 0x560b4df65820 "\003\203", end = 0x560b4df75820 "", 
  crt = 0x560b4df65822 ""}, structs = {next = 0x560b4df75830, 
  prev = 0x560b4df75830}}, send_h = 0x7ffebd54d250, 
  method = 0x560b4df5578d "keepalive.list", gc = 0x0, replied = 0, 
err_code = 0, 
--Type  for more, q to quit, c to continue without paging-- 
  err_phrase = {s = 0x0, len = 0}}
ctx = 0x7ffebd54d0e0
__func__ = "process_rpc_req"
#3  0x7f2da2ee9ae9 in handle_stream_read (s_c=0x560b4df55750, idx=-1) at 
io_listener.c:511
bytes_free = 65535
bytes_read = 24
bytes_needed = 1307733728
bytes_processed = 22027
r = 0x560b4df55770
sh = {fd = 15, type = 0, from = {sa_in = {s = {sa_family = 0, 
sa_data = 
"\000\000\000\000\000\000\001\000\377\377\377\377\377\377"}, sin = {
sin_family = 0, sin_port = 0, sin_addr = {s_addr = 0}, 
sin_zero = "\001\000\377\377\377\377\377\377"}, sin6 = 
{sin6_family = 0, 
sin6_port = 0, sin6_flowinfo = 0, sin6_addr = {__in6_u = {
__u6_addr8 = "\001\000", '\377' , 
__u6_addr16 = {1, 
  65535, 65535, 65535, 65535, 65535, 65535, 65535}, 
__u6_addr32 = {
  4294901761, 4294967295, 4294967295, 4294967295}}}, 
sin6_scope_id = 0}, 
  sas = {ss_family = 0, 
__ss_padding = "\000\000\000\000\000\000\001\000", '\377' 
, '\000' , 
"\001\000\000\000\000\000\000\000\260:\n\232-\177", '\000' , 
"\340\322T\275\001\000\000\000\260:\n\232-\177\000\000\340\322T\275\376\177\000\000\231{\355\242-\177\000\000\000\000\300\000\000\000\000\000\260:\n\232-\177\000",
 
__ss_align = 10513424}}, sa_un = {sun_family = 0, 
  sun_path = "\000\000\000\000\000\000\001\000", '\377' , '\000' , 
"\001\000\000\000\000\000\000\000\260:\n\232-\177", '\000' , 
"\340\322T\275\001\000\000\000\260:\n\232-\177\000\000\340\322T\275\376\177\000\000\231{\355\242-\177\000\000\000\000\300\000\000"}},
 from_len = 0}
__func__ = "handle_stream_read"
#4  0x7f2da2eeb870 in handle_io (fm=0x7f2da3ca38a8, events=1, idx=-1) at 
io_listener.c:706
--Type  for more, q to quit, c to continue without paging--
ret = 1
__func__ = "handle_io"
#5  0x7f2da2ee2092 in io_wait_loop_epoll (h=0x7f2da2f02380 , 
t=10, repeat=0)
at ../../core/io_wait.h:1070
n = 1
r = 0
fm = 0x7f2da3ca38a8
revents = 1
__func__ = "io_wait_loop_epoll"
#6  0x7f2da2ee6707 in io_listen_loop (fd_no=1, cs_lst=0x560b4df26ee0) at 
io_listener.c:281
max_fd_no = 295
poll_err = 0x0
poll_method = 2
cs = 0x0
type = 2
__func__ = "io_listen_loop"
#7  0x7f2da2ef1aa2 in mod_child (rank=0) at ctl.c:338
pid = 0
cs = 0x7f2d9a0a2850
rpc_handler = 1
__func__ = "mod_child"
#8  0x560b4d8349f7 in init_mod_child (m=0x7f2da3cc0370, rank=0) at 
core/sr_module.c:827
__func__ = "init_mod_child"
#9  0x560b4d834612 in init_mod_child (m=0x7f2da3cc07a0, rank=0) at 
core/sr_module.c:823
__func__ = "init_mod_child"
#10 0x560b4d834612 in init_mod_child (m=0x7f2da3cc0ad0, rank=0) at 
core/sr_module.c:823
__func__ = "init_mod_child"
#11 0x560b4d834612 in init_mod_child (m=0x7f2da3cc12b0, rank=0) at 
core/sr_module.c:823
__func__ = 

Re: [sr-dev] [kamailio/kamailio] sqlops sql_query() function result value has not been documented in README (#2454)

2020-08-25 Thread juha-h
Closed #2454.

-- 
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
https://github.com/kamailio/kamailio/issues/2454#event-3691126920___
Kamailio (SER) - Development Mailing List
sr-dev@lists.kamailio.org
https://lists.kamailio.org/cgi-bin/mailman/listinfo/sr-dev


Re: [sr-dev] [kamailio/kamailio] sqlops sql_query() function result value has not been documented in README (#2454)

2020-08-25 Thread juha-h
Actually, return values were described in the beginning of functions section.  
One value was missing and I added it.

-- 
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
https://github.com/kamailio/kamailio/issues/2454#issuecomment-680157264___
Kamailio (SER) - Development Mailing List
sr-dev@lists.kamailio.org
https://lists.kamailio.org/cgi-bin/mailman/listinfo/sr-dev


[sr-dev] [kamailio/kamailio] sqlops sql_query() function result value has not been documented in README (#2454)

2020-08-24 Thread juha-h
README should tell that:

- 1 is returned when query succeeds and result set is not empty
- 2 is returned when query succeeds but result set is not empty
- 3 is returned when result set is not empty, but result param was not given
- -1 is returned in case of error


-- 
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
https://github.com/kamailio/kamailio/issues/2454___
Kamailio (SER) - Development Mailing List
sr-dev@lists.kamailio.org
https://lists.kamailio.org/cgi-bin/mailman/listinfo/sr-dev


Re: [sr-dev] [kamailio/kamailio] Branch ordering behavior changed between v5.3 and v5.4 (#2449)

2020-08-24 Thread juha-h
Daniel-Constantin Mierla writes:

> Also, maybe @juha-h can comment on this issue, being the initial
> developer of these functions, to see what is the expected behaviour
> and if there is an unwanted change in the last version.

Version of tm README before mode param was added tells what the expected
behavior of t_load_contacts() is:

   Function t_load_contacts() removes all branches from the current
   destination set and stores them into the XAVP whose name is configured
   with the parameter contacts_avp.
   ...
   If the current destination set contains more than one branch, the
   function sorts them according to increasing value of the q parameter
   and then stores the branches in reverse order into the XAVP.

   The q parameter of a branch contains a value from range 0-1.0 and it
   expresses relative preference of the branch among all branches in the
   destination set. The higher the q value the more preference the user
   agent gave to the branch. Branches with higher q values will be tried
   before branches with lower ones when serial forking takes place.

If the behavior is not that anymore, there is a bug that needs to be
fixed.







-- 
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
https://github.com/kamailio/kamailio/issues/2449#issuecomment-679083935___
Kamailio (SER) - Development Mailing List
sr-dev@lists.kamailio.org
https://lists.kamailio.org/cgi-bin/mailman/listinfo/sr-dev


Re: [sr-dev] [kamailio/kamailio] pua: different behavior depending on db_mode (#2414)

2020-07-31 Thread juha-h
Victor Seva writes:

> All of that doesn't happen with 
> https://github.com/kamailio/kamailio/commit/da7f7ef082e28f81893ec06081358a9f88571bcc
> 
> Every **pua_*** module that uses pua.send_publish() except **pua_rpc** 
> doesn't set etag parameter.
> * **pua_bla**
> * **pua_dialoginfo**
> * **pua_usrloc**
> * **pua_xmpp**
> 
> So I don't get what you want to achieve. This was a bug that users
> reported and I had suffered.

Why don't these other modules keep track of the etag received from 200
ok to the initial publish and use it in subsequent ones?

Are you sure that the change you made does not have any negative
consequences to pua_rpc user that saves the etag from the initial
publish and uses it in subsequent ones?

May be there was some real reason when I made the commit many years
ago.


-- 
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
https://github.com/kamailio/kamailio/issues/2414#issuecomment-667124637___
Kamailio (SER) - Development Mailing List
sr-dev@lists.kamailio.org
https://lists.kamailio.org/cgi-bin/mailman/listinfo/sr-dev


Re: [sr-dev] [kamailio/kamailio] pua: different behavior depending on db_mode (#2414)

2020-07-30 Thread juha-h
Reopened #2414.

-- 
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
https://github.com/kamailio/kamailio/issues/2414#event-3606791058___
Kamailio (SER) - Development Mailing List
sr-dev@lists.kamailio.org
https://lists.kamailio.org/cgi-bin/mailman/listinfo/sr-dev


Re: [sr-dev] [kamailio/kamailio] pua: different behavior depending on db_mode (#2414)

2020-07-30 Thread juha-h
Isn't it so that pua module send_publish function sends exactly such publish as 
specified in its parameters?  One of the parameters is etag.  So if first or 
subsequent publish requests contain SIP-If-Match header is up to what kind of 
parameters send_publish has got.

  

-- 
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
https://github.com/kamailio/kamailio/issues/2414#issuecomment-666909531___
Kamailio (SER) - Development Mailing List
sr-dev@lists.kamailio.org
https://lists.kamailio.org/cgi-bin/mailman/listinfo/sr-dev


Re: [sr-dev] [kamailio/kamailio] pua: different behavior depending on db_mode (#2414)

2020-07-30 Thread juha-h
I cannot reproduce the issue.  In my tests after the first publish the rest
do have SIP-If-Match header, for example:
```
T 2020/07/30 20:57:06.251465 127.0.0.1:50064 -> 127.0.0.1:5080 [AP] #20
PUBLISH sip:f...@test.tutpro.com SIP/2.0.
Via: SIP/2.0/TCP 
192.168.43.82;branch=z9hG4bK549a.f9d86324.0.
To: .
From: ;tag=ded145cd44a1108aee8ba0e30b80344c-7d4055df.
CSeq: 10 PUBLISH.
Call-ID: 24b1a5bf25ad843a-12771@192.168.43.82.
Content-Length: 94.
User-Agent: OpenSIPg SIP Proxy (5.4.0-0b01 (x86_64/linux)).
Max-Forwards: 70.
Event: message-summary.
Expires: 7776001.
SIP-If-Match: a.1594729867.26073.6.12.
Content-Type: application/simple-message-summary.
P-Flags: 0.
..
Messages-Waiting: yes.
Message-Account: sip:f...@vm.test.tutpro.com.
Voice-Message: 1/0 (0/0).
```
That happens because etag param is included in the json request:
```
Jul 30 20:57:06 char /usr/bin/sip-proxy[12771]: INFO: Executing JSON request 
<{"jsonrpc":"2.0","method":"pua.publish","params":["sip:f...@test.tutpro.com","7776000","message-summary","application\/simple-message-summary",".","a.1594729867.26073.6.12","sip:127.0.0.1:5080;transport=tcp","P-Flags:
 0\r\n","Messages-Waiting: yes\r\nMessage-Account: 
sip:f...@vm.test.tutpro.com\r\nVoice-Message: 1\/0 (0\/0)\r\n"],"id":1}> from 
<127.0.0.1> with host <127.0.0.1:6060>
```
Why can't pua_dialoginfo do the same?


-- 
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
https://github.com/kamailio/kamailio/issues/2414#issuecomment-666573020___
Kamailio (SER) - Development Mailing List
sr-dev@lists.kamailio.org
https://lists.kamailio.org/cgi-bin/mailman/listinfo/sr-dev


Re: [sr-dev] [kamailio/kamailio] pua: different behavior depending on db_mode (#2414)

2020-07-30 Thread juha-h
Victor Seva writes:

> I don't think so. The purpose of E-Tag is to identify a state of the
> resource. If the resource changes a new E-Tag has to be
> generated. [Generating
> Entity-tags](https://tools.ietf.org/html/rfc5839#page-20)

That is about notifier behavior in subscribe/notify exchange and does
not deal with publish requests.

> In this case, pua_dialoginfo is changing the state so a new E-Tag has to be 
> generated and the record in db in this case must be updated. Not insert a new 
> one. 


-- 
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
https://github.com/kamailio/kamailio/issues/2414#issuecomment-666205547___
Kamailio (SER) - Development Mailing List
sr-dev@lists.kamailio.org
https://lists.kamailio.org/cgi-bin/mailman/listinfo/sr-dev


Re: [sr-dev] [kamailio/kamailio] pua: different behavior depending on db_mode (#2414)

2020-07-30 Thread juha-h
Victor Seva writes:

> https://lists.kamailio.org/pipermail/sr-users/2016-January/091492.html 
> 
> > pua - db_mode set to 0. This stops multiple states for a single dialog 
> > (early, trying, confirmed and terminated) from showing in the presentity 
> > table. I suspect this is a bug?
> 
> I still see this behavior and I think is related to this code since 
> pua_dialoginfo never sets etag when calling ``send_publish()``

Then isn't it a bug in pua_dialoginfo?

If I remember correctly, first PUBLISH is sent without SIP-If-Match
header (containing etag), then etag is obtained from 200 OK's SIP-ETag
header and placed in SIP-If-Match header of following PUBLISH requests.


-- 
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
https://github.com/kamailio/kamailio/issues/2414#issuecomment-666189711___
Kamailio (SER) - Development Mailing List
sr-dev@lists.kamailio.org
https://lists.kamailio.org/cgi-bin/mailman/listinfo/sr-dev


Re: [sr-dev] [kamailio/kamailio] pua: different behavior depending on db_mode (#2414)

2020-07-30 Thread juha-h
Victor Seva writes:
> @juha-h 
> > There is call to ``get_record_puadb``:
> 
> Well I mean if ``publ->etag`` is NULL, the previous behavior was to
> call it always

I don't remember publish details, but if there is no etag, it is the
first publish and therefore it doesn't make sense to get the record from
db.


-- 
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
https://github.com/kamailio/kamailio/issues/2414#issuecomment-666182388___
Kamailio (SER) - Development Mailing List
sr-dev@lists.kamailio.org
https://lists.kamailio.org/cgi-bin/mailman/listinfo/sr-dev


Re: [sr-dev] [kamailio/kamailio] pua: different behavior depending on db_mode (#2414)

2020-07-30 Thread juha-h
Victor Seva writes:

> @juha-h since you committed 
> https://github.com/kamailio/kamailio/commit/6822ff45e931ad3e93b22ebf7d1beb350bf27e70,
>  can you please comment why it was necessary?

I don't remember.  It was long time ago.  Perhaps there has been some
mailing list discussion related to the commit.

> Why on PUA_DB_ONLY there's no call to ``get_record_puadb``
> https://github.com/kamailio/kamailio/commit/6822ff45e931ad3e93b22ebf7d1beb350bf27e70#diff-0c68f4211a54ae66988228c3e4b61852R521-R528

There is call to ``get_record_puadb``:

```
if (dbmode==PUA_DB_ONLY)
{
if (publ->etag) {
memset(, 0, sizeof(dbpres));
dbpres.pres_uri = _uri;
dbpres.watcher_uri = _uri;
dbpres.extra_headers = _headers;
presentity = get_record_puadb(publ->id, publ->etag,
  , );
}
}
```


-- 
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
https://github.com/kamailio/kamailio/issues/2414#issuecomment-666147074___
Kamailio (SER) - Development Mailing List
sr-dev@lists.kamailio.org
https://lists.kamailio.org/cgi-bin/mailman/listinfo/sr-dev


Re: [sr-dev] [kamailio/kamailio] db_mysql: docs for opt_ssl_mode parameter (f012c52)

2020-06-21 Thread juha-h
This appears in README as its own section 4.  Should it be among other 
parameters as a section 3 subsection?


-- 
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
https://github.com/kamailio/kamailio/commit/f012c525264ed05fec2acb4b3924d4b9a1cd3ab9#commitcomment-40062216___
Kamailio (SER) - Development Mailing List
sr-dev@lists.kamailio.org
https://lists.kamailio.org/cgi-bin/mailman/listinfo/sr-dev


Re: [sr-dev] [kamailio/kamailio] LCR stopper flag doesn't allow load balance of multiple identical rules (#2105)

2019-10-21 Thread juha-h
You should not use identical rules.  Instead use one stopper rule with two 
gateways (rule targets).

-- 
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
https://github.com/kamailio/kamailio/issues/2105#issuecomment-544393723___
Kamailio (SER) - Development Mailing List
sr-dev@lists.kamailio.org
https://lists.kamailio.org/cgi-bin/mailman/listinfo/sr-dev


Re: [sr-dev] [kamailio/kamailio] rtpengine module set_rtpengine_set(set1, set2) issue (#2039)

2019-08-26 Thread juha-h
Fixed by https://github.com/kamailio/kamailio/pull/2040.

-- 
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
https://github.com/kamailio/kamailio/issues/2039#issuecomment-524987390___
Kamailio (SER) - Development Mailing List
sr-dev@lists.kamailio.org
https://lists.kamailio.org/cgi-bin/mailman/listinfo/sr-dev


Re: [sr-dev] [kamailio/kamailio] rtpengine module set_rtpengine_set(set1, set2) issue (#2039)

2019-08-26 Thread juha-h
Closed #2039.

-- 
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
https://github.com/kamailio/kamailio/issues/2039#event-2584666320___
Kamailio (SER) - Development Mailing List
sr-dev@lists.kamailio.org
https://lists.kamailio.org/cgi-bin/mailman/listinfo/sr-dev


Re: [sr-dev] [kamailio/kamailio] modules/rtpengine: set_rtpengine_set fix (#2040)

2019-08-26 Thread juha-h
Thanks for the review.

-- 
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
https://github.com/kamailio/kamailio/pull/2040#issuecomment-524980037___
Kamailio (SER) - Development Mailing List
sr-dev@lists.kamailio.org
https://lists.kamailio.org/cgi-bin/mailman/listinfo/sr-dev


Re: [sr-dev] [kamailio/kamailio] modules/rtpengine: set_rtpengine_set fix (#2040)

2019-08-26 Thread juha-h
Merged #2040 into master.

-- 
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
https://github.com/kamailio/kamailio/pull/2040#event-2584612402___
Kamailio (SER) - Development Mailing List
sr-dev@lists.kamailio.org
https://lists.kamailio.org/cgi-bin/mailman/listinfo/sr-dev


Re: [sr-dev] [kamailio/kamailio] modules/rtpengine: set_rtpengine_set fix (#2040)

2019-08-23 Thread juha-h
Daniel-Constantin Mierla writes:

> Thanks! Maybe @rfuchs wants to do a review before merging.

Sure, lets wait his review.  Looks like no-one has ever used that
feature before.


-- 
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
https://github.com/kamailio/kamailio/pull/2040#issuecomment-524354809___
Kamailio (SER) - Development Mailing List
sr-dev@lists.kamailio.org
https://lists.kamailio.org/cgi-bin/mailman/listinfo/sr-dev


[sr-dev] [kamailio/kamailio] modules/rtpengine: set_rtpengine_set fix (#2040)

2019-08-23 Thread juha-h
WIthout this fix, set_rtpengine_set(set1, set2) sets set1 twice and set2 not at 
all.


You can view, comment on, or merge this pull request online at:

  https://github.com/kamailio/kamailio/pull/2040

-- Commit Summary --

  * modules/rtpengine: set_rtpengine_set fix

-- File Changes --

M src/modules/rtpengine/rtpengine.c (11)

-- Patch Links --

https://github.com/kamailio/kamailio/pull/2040.patch
https://github.com/kamailio/kamailio/pull/2040.diff

-- 
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
https://github.com/kamailio/kamailio/pull/2040
___
Kamailio (SER) - Development Mailing List
sr-dev@lists.kamailio.org
https://lists.kamailio.org/cgi-bin/mailman/listinfo/sr-dev


Re: [sr-dev] [kamailio/kamailio] rtpengine module set_rtpengine_set(set1, set2) issue (#2039)

2019-08-22 Thread juha-h
I made this kind of patch and it seems to work in my tests, but I may have 
missed something.
```
unsigned int node_in_set(struct rtpp_node *node, struct rtpp_set *set) {
struct rtpp_node *current = set->rn_first;
while (current) {
if (current->idx == node->idx) return 1;
current = current->rn_next;
}
return 0;
}
```
```
static struct rtpp_node * select_rtpp_node(...) {
...
   // lookup node
node = select_rtpp_node_old(callid, viabranch, do_test, op);

// check node
if (!node || (node_in_set(node, active_rtpp_set) == 0)) {
...
```


-- 
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
https://github.com/kamailio/kamailio/issues/2039#issuecomment-523965844___
Kamailio (SER) - Development Mailing List
sr-dev@lists.kamailio.org
https://lists.kamailio.org/cgi-bin/mailman/listinfo/sr-dev


Re: [sr-dev] [kamailio/kamailio] rtpengine module set_rtpengine_set(set1, set2) issue (#2039)

2019-08-22 Thread juha-h
I think I found where the bug is. In select_rtpp_node() function there is this 
function call:
``` // lookup node
node = select_rtpp_node_old(callid, viabranch, do_test, op);
```
When select_rtpp_node() is called second time,  active_rttp_set is set2, but 
select_rtpp_node_old() returns the previous node from set1 and a node from set2 
is not selected.



-- 
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
https://github.com/kamailio/kamailio/issues/2039#issuecomment-523948555___
Kamailio (SER) - Development Mailing List
sr-dev@lists.kamailio.org
https://lists.kamailio.org/cgi-bin/mailman/listinfo/sr-dev


Re: [sr-dev] [kamailio/kamailio] rtpengine module set_rtpengine_set(set1, set2) issue (#2039)

2019-08-22 Thread juha-h
I added some INFO call to  set_rtpengine_set_f():
```INFO("set1/set2 = %u/%u\n", selected_rtpp_set_1->id_set,
 selected_rtpp_set_2->id_set);

return 1;
```
and it correctly printed:
```
Aug 22 17:20:47 salmon /usr/bin/sip-proxy[29734]: INFO: set_rtpengine_set(1, 0)
```
Then I added INFO call to set_rtpengine_set_from_avp():
```
if ((setid_avp_param == NULL) ||
   (avp = search_first_avp(setid_avp_type, setid_avp, _val, 0)) 
== NULL) {
if (direction == 1 || !selected_rtpp_set_2)
active_rtpp_set = selected_rtpp_set_1;
else
active_rtpp_set = selected_rtpp_set_2;
LM_INFO("active_rttp_set = %u\n", active_rtpp_set->id_set);
return 1;
}
```
and it showed that first active set is 1 and second is 0:
```
Aug 22 17:20:47 salmon /usr/bin/sip-proxy[29734]: INFO: rtpengine 
[rtpengine.c:3169]: set_rtpengine_set_from_avp(): active_rttp_set = 1
Aug 22 17:20:47 salmon /usr/bin/sip-proxy[29734]: INFO: rtpengine 
[rtpengine.c:3169]: set_rtpengine_set_from_avp(): active_rttp_set = 0
```
Still both offers are sent to engine in set 1.


-- 
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
https://github.com/kamailio/kamailio/issues/2039#issuecomment-523930224___
Kamailio (SER) - Development Mailing List
sr-dev@lists.kamailio.org
https://lists.kamailio.org/cgi-bin/mailman/listinfo/sr-dev


[sr-dev] [kamailio/kamailio] rtpengine module set_rtpengine_set(set1, set2) issue (#2039)

2019-08-20 Thread juha-h
My Kamailio master based test sip proxy has two rtpengine sets:
```
# sip-proxy_ctl rtpengine.show all
{
url: udp:192.26.134.1:6050
set: 0
index: 0
weight: 1
disabled: 0
recheck_ticks: 0
}
{
url: udp:192.26.134.40:6050
set: 1
index: 1
weight: 1
disabled: 0
recheck_ticks: 0
}
```
Config calls set_rtpengine_set() with two set argument followed by 
rtpengine_offer():
```
set_rtpengine_set("1", "0");
rtpengine_offer("...");
```
Debug shows that sip proxy sends TWO offer commands to the
rtpproxy in the first set 1 and NONE to the rtpproxy in the second set 0.  

Debug at set 1 engine:
```
Aug 19 18:06:08 buster-10-0 rtpengine[1314]: NOTICE: [5e1407211cc50fd9]: 
Creating new call
Aug 19 18:06:08 buster-10-0 rtpengine[1314]: INFO: [5e1407211cc50fd9]: Replying 
to 'offer' from 192.26.134.1:33284 (elapsed time 0.000812 sec)
Aug 19 18:06:08 buster-10-0 rtpengine[1314]: INFO: [5e1407211cc50fd9]: Received 
command 'offer' from 192.26.134.1:33284
Aug 19 18:06:08 buster-10-0 rtpengine[1314]: INFO: [5e1407211cc50fd9]: Replying 
to 'offer' from 192.26.134.1:33284 (elapsed time 0.005247 sec)
```
This looks like a bug to me, since according to README, rtpengine should first 
send the offer to an engine in the first set and then to an engine in the 
second set.

-- 
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
https://github.com/kamailio/kamailio/issues/2039___
Kamailio (SER) - Development Mailing List
sr-dev@lists.kamailio.org
https://lists.kamailio.org/cgi-bin/mailman/listinfo/sr-dev


Re: [sr-dev] [kamailio/kamailio] lcr: enhance the lcr.dump_rules with filtering params: (#1922)

2019-04-04 Thread juha-h
Looks good.  Could you also update the doc (lcr_admin.xml).

-- 
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
https://github.com/kamailio/kamailio/pull/1922#issuecomment-479770104___
Kamailio (SER) - Development Mailing List
sr-dev@lists.kamailio.org
https://lists.kamailio.org/cgi-bin/mailman/listinfo/sr-dev


[sr-dev] [kamailio/kamailio] AUTH_USERNAME_EXPIRED auth api return code (#1910)

2019-03-27 Thread juha-h
This pull request adds AUTH_USERNAME_EXPIRED auth api return code and uses it 
in ephemeral authentication when username has expired.  Script can then tell 
the user about the expiration with a suitable response.
You can view, comment on, or merge this pull request online at:

  https://github.com/kamailio/kamailio/pull/1910

-- Commit Summary --

  * - added AUTH_USERNAME_EXPIRED auth api return code and used it in auth

-- File Changes --

M src/modules/auth/api.h (1)
M src/modules/auth_ephemeral/authorize.c (26)

-- Patch Links --

https://github.com/kamailio/kamailio/pull/1910.patch
https://github.com/kamailio/kamailio/pull/1910.diff

-- 
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
https://github.com/kamailio/kamailio/pull/1910
___
Kamailio (SER) - Development Mailing List
sr-dev@lists.kamailio.org
https://lists.kamailio.org/cgi-bin/mailman/listinfo/sr-dev


Re: [sr-dev] [kamailio/kamailio] jsonrpc reply error (#1640)

2018-09-11 Thread juha-h
Closed #1640.

-- 
You are receiving this because you commented.
Reply to this email directly or view it on GitHub:
https://github.com/kamailio/kamailio/issues/1640#event-1840186627___
Kamailio (SER) - Development Mailing List
sr-dev@lists.kamailio.org
https://lists.kamailio.org/cgi-bin/mailman/listinfo/sr-dev


Re: [sr-dev] [kamailio/kamailio] jsonrpc reply error (#1640)

2018-09-11 Thread juha-h
The error message is now gone,  Thanks.

-- 
You are receiving this because you commented.
Reply to this email directly or view it on GitHub:
https://github.com/kamailio/kamailio/issues/1640#issuecomment-420517113___
Kamailio (SER) - Development Mailing List
sr-dev@lists.kamailio.org
https://lists.kamailio.org/cgi-bin/mailman/listinfo/sr-dev


  1   2   >