Re: [OpenSIPS-Users] check_source_address not working with upgrade
Hi all, i would arise this post because it's happening same thing to me. Opensips v. : OpenSIPS (1.9.0-notls (i386/linux)) Database entries: mysql select * from address; ++-+---+--+--+---+-+--+ | id | grp | ip| mask | port | proto | pattern | context_info | ++-+---+--+--+---+-+--+ | 6 | 0 | 10.9.6.3 | 24 |0 | ANY | | | | 5 | 0 | 172.16.55.201 | 24 |0 | ANY | | | ++-+---+--+--+---+-+--+ Subnet Dump: root@opensips:./opensipsctl fifo subnet_dump 0 0, 10.9.6.0, 255.255.255.0, 0 1 0, 172.16.55.0, 255.255.255.0, 0 Address Relod log; *Apr 10 10:50:44 opensips /usr/local/opensips_proxy_1.9.0/sbin/opensips[2812]: DBG:permissions:reload_address_table: number of rows in address table: 2 Apr 10 10:50:44 opensips /usr/local/opensips_proxy_1.9.0/sbin/opensips[2812]: DBG:permissions:reload_address_table: Tuple 10.9.6.3, 0, 24, 0 inserted into subnet table Apr 10 10:50:44 opensips /usr/local/opensips_proxy_1.9.0/sbin/opensips[2812]: DBG:permissions:reload_address_table: Tuple 172.16.55.201, 0, 24, 0 inserted into subnet table Apr 10 10:50:44 opensips /usr/local/opensips_proxy_1.9.0/sbin/opensips[2812]: DBG:permissions:reload_address_table: address table reloaded successfully.* Call logs: *Apr 10 10:52:00 opensips /usr/local/opensips_proxy_1.9.0/sbin/opensips[2819]: DBG:permissions:check_src_addr_3: Looking for : 0, 172.16.55.201, 53109, 2 in tables Apr 10 10:52:00 opensips /usr/local/opensips_proxy_1.9.0/sbin/opensips[2819]: DBG:permissions:hash_match: no match in the hash table Apr 10 10:52:00 opensips /usr/local/opensips_proxy_1.9.0/sbin/opensips[2819]: DBG:permissions:match_subnet_table: match found in the subnet table * Snippet of code: *if(!check_source_address(0)){ if (!proxy_authorize(, subscriber)) { proxy_challenge(, 0); exit; * Any idea? Regards -- View this message in context: http://opensips-open-sip-server.1449251.n2.nabble.com/check-source-address-not-working-with-upgrade-tp7247511p7585766.html Sent from the OpenSIPS - Users mailing list archive at Nabble.com. ___ Users mailing list Users@lists.opensips.org http://lists.opensips.org/cgi-bin/mailman/listinfo/users
Re: [OpenSIPS-Users] check_source_address not working with upgrade
Răzvan has fixed this issue with the latest trunk. I have tested and all is good now. Thanks Razvan and Ovidiu. On Thu, Feb 2, 2012 at 1:03 PM, duane.lar...@gmail.com wrote: I talked a little with Ovidiu offline so I went ahead and opened a bug ticket. Ticket is 3483337 check_source_address broken in latest trunk Open 2012-02-02 nobody duanelarson123 None 5 Thanks for the help Ovidiu. On , Duane Larson duane.lar...@gmail.com wrote: Yeah. It is the first one in the list (Number 15 in the dump). Like I said this worked before I upgraded. On Thu, Feb 2, 2012 at 10:56 AM, Ovidiu Sas o...@voipembedded.com wrote: The subnet is empty because you don't have any subnets (the mask is set to 32 and therefore you have full IP matching). Is the message source IP in the address_dump? Regards, Ovidiu Sas -- VoIP Embedded, Inc. http://www.voipembedded.com On Thu, Feb 2, 2012 at 11:52 AM, Duane Larson duane.lar...@gmail.com wrote: This is what I see Proxy01:/var/log# opensipsctl fifo address_dump 15 20 34 50 63 85 Proxy01:/var/log# Proxy01:/var/log# Proxy01:/var/log# Proxy01:/var/log# Proxy01:/var/log# opensipsctl fifo subnet_dump So the subnet_dump is empty. On Thu, Feb 2, 2012 at 10:48 AM, Ovidiu Sas o...@voipembedded.com wrote: Check the in memory cache: http://www.opensips.org/html/docs/modules/devel/permissions.html#id293903 See address_dump and subnet_dump. At start up, opensips will cache everything in memory. Regards, Ovidiu Sas -- VoIP Embedded, Inc. http://www.voipembedded.com On Thu, Feb 2, 2012 at 11:38 AM, duane.lar...@gmail.com wrote: I just upgraded my b2bua opensips server to the latest trunk version and now my if statements using check_source_address from the permissions module isn't working. I have the following set up loadmodule permissions.so modparam(permissions,db_url,mysql://adfasdf:dfasdf...@108.xxx.xxx.xxx /opensips) if (check_source_address(2) || check_source_address(3) || check_source_address(4)) { The INVITE comes from my SIP Proxy and worked before the upgrade without issue Feb 1 22:41:01 proxy01 /usr/local/sbin/opensips[30163]: DBG:permissions:check_src_addr_3: Looking for : 5060, 1 in tables Feb 1 22:41:01 proxy01 /usr/local/sbin/opensips[30163]: DBG:permissions:hash_match: specified group does not exist in hash table Feb 1 22:41:01 proxy01 /usr/local/sbin/opensips[30163]: DBG:permissions:match_subnet_table: subnet table is empty Feb 1 22:41:01 proxy01 /usr/local/sbin/opensips[30163]: DBG:permissions:check_src_addr_3: Looking for : 5060, 1 in tables Feb 1 22:41:01 proxy01 /usr/local/sbin/opensips[30163]: DBG:permissions:hash_match: specified group does not exist in hash table Feb 1 22:41:01 proxy01 /usr/local/sbin/opensips[30163]: DBG:permissions:match_subnet_table: subnet table is empty Feb 1 22:41:01 proxy01 /usr/local/sbin/opensips[30163]: DBG:permissions:check_src_addr_3: Looking for : 5060, 1 in tables Feb 1 22:41:01 proxy01 /usr/local/sbin/opensips[30163]: DBG:permissions:hash_match: specified group does not exist in hash table Feb 1 22:41:01 proxy01 /usr/local/sbin/opensips[30163]: DBG:permissions:match_subnet_table: subnet table is empty This is what I have in the database Proxy01:/var/log# opensipsctl db show address +-+-++--+--+---+-+--+ | id | grp | ip | mask | port | proto | pattern | context_info | +-+-++--+--+---+-+--+ | 3 | 2 | 216.XXX.XXX.202 | 32 | 5060 | any | NULL | NULL | | 258 | 4 | 64.XXX.XXX.15 | 32 | 5060 | any | NULL | NULL | | 1 | 10 | 173.XXX.XXX.XXX | 32 | 5060 | any | NULL | NULL | | 2 | 10 | 173.XXX.XXX.XXX | 32 | 5060 | any | NULL | NULL | | 257 | 3 | 173.XXX.XXX.XXX | 32 | 5060 | any | NULL | NULL | | 4 | 2 | 216.XXX.XXX.202 | 32 | 5060 | any | NULL | NULL | +-+-++--+--+---+-+--+ I am not sure if OpenSIPS is really querying the mysql database because I don't really see any connections from the server when a call is made. How could this be possible? When I start OpenSIPS I see that it talks to the database. ___ Users mailing list Users@lists.opensips.org http://lists.opensips.org/cgi-bin/mailman/listinfo/users
Re: [OpenSIPS-Users] check_source_address not working with upgrade
I will chime into say that I ran into the same issue when attempting to upgrade to the latest trunk. I just have not had time to open a bug and get a test setup to do in-depth trouble shooting. On Thu, Feb 2, 2012 at 8:38 AM, duane.lar...@gmail.com wrote: I just upgraded my b2bua opensips server to the latest trunk version and now my if statements using check_source_address from the permissions module isn't working. I have the following set up loadmodule permissions.so modparam(permissions,db_url,mysql://adfasdf:dfasdf...@108.xxx.xxx.xxx/opensips) if (check_source_address(2) || check_source_address(3) || check_source_address(4)) { The INVITE comes from my SIP Proxy and worked before the upgrade without issue Feb 1 22:41:01 proxy01 /usr/local/sbin/opensips[30163]: DBG:permissions:check_src_addr_3: Looking for : 2, 173.XXX.XXX.XXX, 5060, 1 in tables Feb 1 22:41:01 proxy01 /usr/local/sbin/opensips[30163]: DBG:permissions:hash_match: specified group does not exist in hash table Feb 1 22:41:01 proxy01 /usr/local/sbin/opensips[30163]: DBG:permissions:match_subnet_table: subnet table is empty Feb 1 22:41:01 proxy01 /usr/local/sbin/opensips[30163]: DBG:permissions:check_src_addr_3: Looking for : 3, 173.XXX.XXX.XXX, 5060, 1 in tables Feb 1 22:41:01 proxy01 /usr/local/sbin/opensips[30163]: DBG:permissions:hash_match: specified group does not exist in hash table Feb 1 22:41:01 proxy01 /usr/local/sbin/opensips[30163]: DBG:permissions:match_subnet_table: subnet table is empty Feb 1 22:41:01 proxy01 /usr/local/sbin/opensips[30163]: DBG:permissions:check_src_addr_3: Looking for : 4, 173.XXX.XXX.XXX, 5060, 1 in tables Feb 1 22:41:01 proxy01 /usr/local/sbin/opensips[30163]: DBG:permissions:hash_match: specified group does not exist in hash table Feb 1 22:41:01 proxy01 /usr/local/sbin/opensips[30163]: DBG:permissions:match_subnet_table: subnet table is empty This is what I have in the database Proxy01:/var/log# opensipsctl db show address +-+-++--+--+---+-+--+ | id | grp | ip | mask | port | proto | pattern | context_info | +-+-++--+--+---+-+--+ | 3 | 2 | 216.XXX.XXX.202 | 32 | 5060 | any | NULL | NULL | | 258 | 4 | 64.XXX.XXX.15 | 32 | 5060 | any | NULL | NULL | | 1 | 10 | 173.XXX.XXX.XXX | 32 | 5060 | any | NULL | NULL | | 2 | 10 | 173.XXX.XXX.XXX | 32 | 5060 | any | NULL | NULL | | 257 | 3 | 173.XXX.XXX.XXX | 32 | 5060 | any | NULL | NULL | | 4 | 2 | 216.XXX.XXX.202 | 32 | 5060 | any | NULL | NULL | +-+-++--+--+---+-+--+ I am not sure if OpenSIPS is really querying the mysql database because I don't really see any connections from the server when a call is made. How could this be possible? When I start OpenSIPS I see that it talks to the database. ___ Users mailing list Users@lists.opensips.org http://lists.opensips.org/cgi-bin/mailman/listinfo/users ___ Users mailing list Users@lists.opensips.org http://lists.opensips.org/cgi-bin/mailman/listinfo/users
Re: [OpenSIPS-Users] check_source_address not working with upgrade
Hmmm. That would suck if its a bug. Just to follow up on my last email here is what I see when I start OpenSIPS. You can see that OpenSIPS grabs all the info from the address table Feb 2 10:39:32 proxy01 /usr/local/sbin/opensips[14584]: DBG:permissions:reload_address_table: number of rows in address table: 6 Feb 2 10:39:32 proxy01 /usr/local/sbin/opensips[14584]: DBG:permissions:reload_address_table: Tuple 216.82.224.202, 2, 5060, 0, , inserted into address hash table Feb 2 10:39:32 proxy01 /usr/local/sbin/opensips[14584]: DBG:permissions:reload_address_table: Tuple 64.2.142.15, 4, 5060, 0, , inserted into address hash table Feb 2 10:39:32 proxy01 /usr/local/sbin/opensips[14584]: DBG:permissions:reload_address_table: Tuple 173.XXX.XXX.63, 10, 5060, 0, , inserted into address hash table Feb 2 10:39:32 proxy01 /usr/local/sbin/opensips[14584]: DBG:permissions:reload_address_table: Tuple 173.XXX.XXX.10, 10, 5060, 0, , inserted into address hash table Feb 2 10:39:32 proxy01 /usr/local/sbin/opensips[14584]: DBG:permissions:reload_address_table: Tuple 173.XXX.XXX.107, 3, 5060, 0, , inserted into address hash table Feb 2 10:39:32 proxy01 /usr/local/sbin/opensips[14584]: DBG:permissions:reload_address_table: Tuple 216.82.225.202, 2, 5060, 0, , inserted into address hash table Feb 2 10:39:32 proxy01 /usr/local/sbin/opensips[14584]: DBG:core:db_free_columns: freeing result columns at 0x7fd95d243710 Feb 2 10:39:32 proxy01 /usr/local/sbin/opensips[14584]: DBG:core:db_free_rows: freeing 6 rows Feb 2 10:39:32 proxy01 /usr/local/sbin/opensips[14584]: DBG:core:db_free_row: freeing row values at 0x7fd95d244248 Feb 2 10:39:32 proxy01 /usr/local/sbin/opensips[14584]: DBG:core:db_free_row: freeing row values at 0x7fd95d244348 Feb 2 10:39:32 proxy01 /usr/local/sbin/opensips[14584]: DBG:core:db_free_row: freeing row values at 0x7fd95d28 Feb 2 10:39:32 proxy01 /usr/local/sbin/opensips[14584]: DBG:core:db_free_row: freeing row values at 0x7fd95d244548 Feb 2 10:39:32 proxy01 /usr/local/sbin/opensips[14584]: DBG:core:db_free_row: freeing row values at 0x7fd95d244648 Feb 2 10:39:32 proxy01 /usr/local/sbin/opensips[14584]: DBG:core:db_free_row: freeing row values at 0x7fd95d244748 Feb 2 10:39:32 proxy01 /usr/local/sbin/opensips[14584]: DBG:core:db_free_rows: freeing rows at 0x7fd95d2441e8 Feb 2 10:39:32 proxy01 /usr/local/sbin/opensips[14584]: DBG:core:db_free_result: freeing result set at 0x7fd95d2358e8 Feb 2 10:39:32 proxy01 /usr/local/sbin/opensips[14584]: DBG:permissions:reload_address_table: address table reloaded successfully. Feb 2 10:39:32 proxy01 /usr/local/sbin/opensips[14584]: DBG:core:pool_remove: removing connection from the pool Feb 2 10:39:32 proxy01 /usr/local/sbin/opensips[14584]: DBG:core:init_mod: register MI for permissions Feb 2 10:39:32 proxy01 /usr/local/sbin/opensips[14584]: DBG:core:init_mod: initializing module uri On Thu, Feb 2, 2012 at 10:43 AM, Ryan Bullock rrb3...@gmail.com wrote: I will chime into say that I ran into the same issue when attempting to upgrade to the latest trunk. I just have not had time to open a bug and get a test setup to do in-depth trouble shooting. On Thu, Feb 2, 2012 at 8:38 AM, duane.lar...@gmail.com wrote: I just upgraded my b2bua opensips server to the latest trunk version and now my if statements using check_source_address from the permissions module isn't working. I have the following set up loadmodule permissions.so modparam(permissions,db_url,mysql://adfasdf:dfasdf...@108.xxx.xxx.xxx /opensips) if (check_source_address(2) || check_source_address(3) || check_source_address(4)) { The INVITE comes from my SIP Proxy and worked before the upgrade without issue Feb 1 22:41:01 proxy01 /usr/local/sbin/opensips[30163]: DBG:permissions:check_src_addr_3: Looking for : 2, 173.XXX.XXX.XXX, 5060, 1 in tables Feb 1 22:41:01 proxy01 /usr/local/sbin/opensips[30163]: DBG:permissions:hash_match: specified group does not exist in hash table Feb 1 22:41:01 proxy01 /usr/local/sbin/opensips[30163]: DBG:permissions:match_subnet_table: subnet table is empty Feb 1 22:41:01 proxy01 /usr/local/sbin/opensips[30163]: DBG:permissions:check_src_addr_3: Looking for : 3, 173.XXX.XXX.XXX, 5060, 1 in tables Feb 1 22:41:01 proxy01 /usr/local/sbin/opensips[30163]: DBG:permissions:hash_match: specified group does not exist in hash table Feb 1 22:41:01 proxy01 /usr/local/sbin/opensips[30163]: DBG:permissions:match_subnet_table: subnet table is empty Feb 1 22:41:01 proxy01 /usr/local/sbin/opensips[30163]: DBG:permissions:check_src_addr_3: Looking for : 4, 173.XXX.XXX.XXX, 5060, 1 in tables Feb 1 22:41:01 proxy01 /usr/local/sbin/opensips[30163]: DBG:permissions:hash_match: specified group does not exist in hash table Feb 1 22:41:01 proxy01 /usr/local/sbin/opensips[30163]: DBG:permissions:match_subnet_table: subnet table is empty This is what I have in the database
Re: [OpenSIPS-Users] check_source_address not working with upgrade
Check the in memory cache: http://www.opensips.org/html/docs/modules/devel/permissions.html#id293903 See address_dump and subnet_dump. At start up, opensips will cache everything in memory. Regards, Ovidiu Sas -- VoIP Embedded, Inc. http://www.voipembedded.com On Thu, Feb 2, 2012 at 11:38 AM, duane.lar...@gmail.com wrote: I just upgraded my b2bua opensips server to the latest trunk version and now my if statements using check_source_address from the permissions module isn't working. I have the following set up loadmodule permissions.so modparam(permissions,db_url,mysql://adfasdf:dfasdf...@108.xxx.xxx.xxx/opensips) if (check_source_address(2) || check_source_address(3) || check_source_address(4)) { The INVITE comes from my SIP Proxy and worked before the upgrade without issue Feb 1 22:41:01 proxy01 /usr/local/sbin/opensips[30163]: DBG:permissions:check_src_addr_3: Looking for : 2, 173.XXX.XXX.XXX, 5060, 1 in tables Feb 1 22:41:01 proxy01 /usr/local/sbin/opensips[30163]: DBG:permissions:hash_match: specified group does not exist in hash table Feb 1 22:41:01 proxy01 /usr/local/sbin/opensips[30163]: DBG:permissions:match_subnet_table: subnet table is empty Feb 1 22:41:01 proxy01 /usr/local/sbin/opensips[30163]: DBG:permissions:check_src_addr_3: Looking for : 3, 173.XXX.XXX.XXX, 5060, 1 in tables Feb 1 22:41:01 proxy01 /usr/local/sbin/opensips[30163]: DBG:permissions:hash_match: specified group does not exist in hash table Feb 1 22:41:01 proxy01 /usr/local/sbin/opensips[30163]: DBG:permissions:match_subnet_table: subnet table is empty Feb 1 22:41:01 proxy01 /usr/local/sbin/opensips[30163]: DBG:permissions:check_src_addr_3: Looking for : 4, 173.XXX.XXX.XXX, 5060, 1 in tables Feb 1 22:41:01 proxy01 /usr/local/sbin/opensips[30163]: DBG:permissions:hash_match: specified group does not exist in hash table Feb 1 22:41:01 proxy01 /usr/local/sbin/opensips[30163]: DBG:permissions:match_subnet_table: subnet table is empty This is what I have in the database Proxy01:/var/log# opensipsctl db show address +-+-++--+--+---+-+--+ | id | grp | ip | mask | port | proto | pattern | context_info | +-+-++--+--+---+-+--+ | 3 | 2 | 216.XXX.XXX.202 | 32 | 5060 | any | NULL | NULL | | 258 | 4 | 64.XXX.XXX.15 | 32 | 5060 | any | NULL | NULL | | 1 | 10 | 173.XXX.XXX.XXX | 32 | 5060 | any | NULL | NULL | | 2 | 10 | 173.XXX.XXX.XXX | 32 | 5060 | any | NULL | NULL | | 257 | 3 | 173.XXX.XXX.XXX | 32 | 5060 | any | NULL | NULL | | 4 | 2 | 216.XXX.XXX.202 | 32 | 5060 | any | NULL | NULL | +-+-++--+--+---+-+--+ I am not sure if OpenSIPS is really querying the mysql database because I don't really see any connections from the server when a call is made. How could this be possible? When I start OpenSIPS I see that it talks to the database. ___ Users mailing list Users@lists.opensips.org http://lists.opensips.org/cgi-bin/mailman/listinfo/users ___ Users mailing list Users@lists.opensips.org http://lists.opensips.org/cgi-bin/mailman/listinfo/users
Re: [OpenSIPS-Users] check_source_address not working with upgrade
This is what I see Proxy01:/var/log# opensipsctl fifo address_dump 15 173.XXX.XXX.XXX,3, 5060, 0, NULL, NULL 20 216.82.224.202,2, 5060, 0, NULL, NULL 34 64.2.142.15,4, 5060, 0, NULL, NULL 50 216.82.225.202,2, 5060, 0, NULL, NULL 63 173.XXX.XXX.XXX,10, 5060, 0, NULL, NULL 85 173.XXX.XXX.XXX,10, 5060, 0, NULL, NULL Proxy01:/var/log# Proxy01:/var/log# Proxy01:/var/log# Proxy01:/var/log# Proxy01:/var/log# opensipsctl fifo subnet_dump So the subnet_dump is empty. On Thu, Feb 2, 2012 at 10:48 AM, Ovidiu Sas o...@voipembedded.com wrote: Check the in memory cache: http://www.opensips.org/html/docs/modules/devel/permissions.html#id293903 See address_dump and subnet_dump. At start up, opensips will cache everything in memory. Regards, Ovidiu Sas -- VoIP Embedded, Inc. http://www.voipembedded.com On Thu, Feb 2, 2012 at 11:38 AM, duane.lar...@gmail.com wrote: I just upgraded my b2bua opensips server to the latest trunk version and now my if statements using check_source_address from the permissions module isn't working. I have the following set up loadmodule permissions.so modparam(permissions,db_url,mysql://adfasdf:dfasdf...@108.xxx.xxx.xxx /opensips) if (check_source_address(2) || check_source_address(3) || check_source_address(4)) { The INVITE comes from my SIP Proxy and worked before the upgrade without issue Feb 1 22:41:01 proxy01 /usr/local/sbin/opensips[30163]: DBG:permissions:check_src_addr_3: Looking for : 2, 173.XXX.XXX.XXX, 5060, 1 in tables Feb 1 22:41:01 proxy01 /usr/local/sbin/opensips[30163]: DBG:permissions:hash_match: specified group does not exist in hash table Feb 1 22:41:01 proxy01 /usr/local/sbin/opensips[30163]: DBG:permissions:match_subnet_table: subnet table is empty Feb 1 22:41:01 proxy01 /usr/local/sbin/opensips[30163]: DBG:permissions:check_src_addr_3: Looking for : 3, 173.XXX.XXX.XXX, 5060, 1 in tables Feb 1 22:41:01 proxy01 /usr/local/sbin/opensips[30163]: DBG:permissions:hash_match: specified group does not exist in hash table Feb 1 22:41:01 proxy01 /usr/local/sbin/opensips[30163]: DBG:permissions:match_subnet_table: subnet table is empty Feb 1 22:41:01 proxy01 /usr/local/sbin/opensips[30163]: DBG:permissions:check_src_addr_3: Looking for : 4, 173.XXX.XXX.XXX, 5060, 1 in tables Feb 1 22:41:01 proxy01 /usr/local/sbin/opensips[30163]: DBG:permissions:hash_match: specified group does not exist in hash table Feb 1 22:41:01 proxy01 /usr/local/sbin/opensips[30163]: DBG:permissions:match_subnet_table: subnet table is empty This is what I have in the database Proxy01:/var/log# opensipsctl db show address +-+-++--+--+---+-+--+ | id | grp | ip | mask | port | proto | pattern | context_info | +-+-++--+--+---+-+--+ | 3 | 2 | 216.XXX.XXX.202 | 32 | 5060 | any | NULL | NULL | | 258 | 4 | 64.XXX.XXX.15 | 32 | 5060 | any | NULL | NULL | | 1 | 10 | 173.XXX.XXX.XXX | 32 | 5060 | any | NULL | NULL | | 2 | 10 | 173.XXX.XXX.XXX | 32 | 5060 | any | NULL | NULL | | 257 | 3 | 173.XXX.XXX.XXX | 32 | 5060 | any | NULL | NULL | | 4 | 2 | 216.XXX.XXX.202 | 32 | 5060 | any | NULL | NULL | +-+-++--+--+---+-+--+ I am not sure if OpenSIPS is really querying the mysql database because I don't really see any connections from the server when a call is made. How could this be possible? When I start OpenSIPS I see that it talks to the database. ___ Users mailing list Users@lists.opensips.org http://lists.opensips.org/cgi-bin/mailman/listinfo/users ___ Users mailing list Users@lists.opensips.org http://lists.opensips.org/cgi-bin/mailman/listinfo/users -- -- *--*--*--*--*--* Duane *--*--*--*--*--* -- ___ Users mailing list Users@lists.opensips.org http://lists.opensips.org/cgi-bin/mailman/listinfo/users
Re: [OpenSIPS-Users] check_source_address not working with upgrade
Yeah. It is the first one in the list (Number 15 in the dump). Like I said this worked before I upgraded. On Thu, Feb 2, 2012 at 10:56 AM, Ovidiu Sas o...@voipembedded.com wrote: The subnet is empty because you don't have any subnets (the mask is set to 32 and therefore you have full IP matching). Is the message source IP in the address_dump? Regards, Ovidiu Sas -- VoIP Embedded, Inc. http://www.voipembedded.com On Thu, Feb 2, 2012 at 11:52 AM, Duane Larson duane.lar...@gmail.com wrote: This is what I see Proxy01:/var/log# opensipsctl fifo address_dump 15 173.XXX.XXX.XXX,3, 5060, 0, NULL, NULL 20 216.82.224.202,2, 5060, 0, NULL, NULL 34 64.2.142.15,4, 5060, 0, NULL, NULL 50 216.82.225.202,2, 5060, 0, NULL, NULL 63 173.XXX.XXX.XXX,10, 5060, 0, NULL, NULL 85 173.XXX.XXX.XXX,10, 5060, 0, NULL, NULL Proxy01:/var/log# Proxy01:/var/log# Proxy01:/var/log# Proxy01:/var/log# Proxy01:/var/log# opensipsctl fifo subnet_dump So the subnet_dump is empty. On Thu, Feb 2, 2012 at 10:48 AM, Ovidiu Sas o...@voipembedded.com wrote: Check the in memory cache: http://www.opensips.org/html/docs/modules/devel/permissions.html#id293903 See address_dump and subnet_dump. At start up, opensips will cache everything in memory. Regards, Ovidiu Sas -- VoIP Embedded, Inc. http://www.voipembedded.com On Thu, Feb 2, 2012 at 11:38 AM, duane.lar...@gmail.com wrote: I just upgraded my b2bua opensips server to the latest trunk version and now my if statements using check_source_address from the permissions module isn't working. I have the following set up loadmodule permissions.so modparam(permissions,db_url,mysql://adfasdf:dfasdf...@108.xxx.xxx.xxx /opensips) if (check_source_address(2) || check_source_address(3) || check_source_address(4)) { The INVITE comes from my SIP Proxy and worked before the upgrade without issue Feb 1 22:41:01 proxy01 /usr/local/sbin/opensips[30163]: DBG:permissions:check_src_addr_3: Looking for : 2, 173.XXX.XXX.XXX, 5060, 1 in tables Feb 1 22:41:01 proxy01 /usr/local/sbin/opensips[30163]: DBG:permissions:hash_match: specified group does not exist in hash table Feb 1 22:41:01 proxy01 /usr/local/sbin/opensips[30163]: DBG:permissions:match_subnet_table: subnet table is empty Feb 1 22:41:01 proxy01 /usr/local/sbin/opensips[30163]: DBG:permissions:check_src_addr_3: Looking for : 3, 173.XXX.XXX.XXX, 5060, 1 in tables Feb 1 22:41:01 proxy01 /usr/local/sbin/opensips[30163]: DBG:permissions:hash_match: specified group does not exist in hash table Feb 1 22:41:01 proxy01 /usr/local/sbin/opensips[30163]: DBG:permissions:match_subnet_table: subnet table is empty Feb 1 22:41:01 proxy01 /usr/local/sbin/opensips[30163]: DBG:permissions:check_src_addr_3: Looking for : 4, 173.XXX.XXX.XXX, 5060, 1 in tables Feb 1 22:41:01 proxy01 /usr/local/sbin/opensips[30163]: DBG:permissions:hash_match: specified group does not exist in hash table Feb 1 22:41:01 proxy01 /usr/local/sbin/opensips[30163]: DBG:permissions:match_subnet_table: subnet table is empty This is what I have in the database Proxy01:/var/log# opensipsctl db show address +-+-++--+--+---+-+--+ | id | grp | ip | mask | port | proto | pattern | context_info | +-+-++--+--+---+-+--+ | 3 | 2 | 216.XXX.XXX.202 | 32 | 5060 | any | NULL | NULL | | 258 | 4 | 64.XXX.XXX.15 | 32 | 5060 | any | NULL | NULL | | 1 | 10 | 173.XXX.XXX.XXX | 32 | 5060 | any | NULL | NULL | | 2 | 10 | 173.XXX.XXX.XXX | 32 | 5060 | any | NULL | NULL | | 257 | 3 | 173.XXX.XXX.XXX | 32 | 5060 | any | NULL | NULL | | 4 | 2 | 216.XXX.XXX.202 | 32 | 5060 | any | NULL | NULL | +-+-++--+--+---+-+--+ I am not sure if OpenSIPS is really querying the mysql database because I don't really see any connections from the server when a call is made. How could this be possible? When I start OpenSIPS I see that it talks to the database. ___ Users mailing list Users@lists.opensips.org http://lists.opensips.org/cgi-bin/mailman/listinfo/users ___ Users mailing list Users@lists.opensips.org http://lists.opensips.org/cgi-bin/mailman/listinfo/users -- -- *--*--*--*--*--* Duane *--*--*--*--*--* -- ___ Users mailing list Users@lists.opensips.org http://lists.opensips.org/cgi-bin/mailman/listinfo/users ___ Users mailing list Users@lists.opensips.org http://lists.opensips.org/cgi-bin/mailman/listinfo/users -- --
Re: [OpenSIPS-Users] check_source_address not working with upgrade
I talked a little with Ovidiu offline so I went ahead and opened a bug ticket. Ticket is 3483337 check_source_address broken in latest trunk Open 2012-02-02 nobody duanelarson123 None 5 Thanks for the help Ovidiu. On , Duane Larson duane.lar...@gmail.com wrote: Yeah. It is the first one in the list (Number 15 in the dump). Like I said this worked before I upgraded. On Thu, Feb 2, 2012 at 10:56 AM, Ovidiu Sas o...@voipembedded.com wrote: The subnet is empty because you don't have any subnets (the mask is set to 32 and therefore you have full IP matching). Is the message source IP in the address_dump? Regards, Ovidiu Sas -- VoIP Embedded, Inc. http://www.voipembedded.com On Thu, Feb 2, 2012 at 11:52 AM, Duane Larson duane.lar...@gmail.com wrote: This is what I see Proxy01:/var/log# opensipsctl fifo address_dump 15 20 34 50 63 85 Proxy01:/var/log# Proxy01:/var/log# Proxy01:/var/log# Proxy01:/var/log# Proxy01:/var/log# opensipsctl fifo subnet_dump So the subnet_dump is empty. On Thu, Feb 2, 2012 at 10:48 AM, Ovidiu Sas o...@voipembedded.com wrote: Check the in memory cache: http://www.opensips.org/html/docs/modules/devel/permissions.html#id293903 See address_dump and subnet_dump. At start up, opensips will cache everything in memory. Regards, Ovidiu Sas -- VoIP Embedded, Inc. http://www.voipembedded.com On Thu, Feb 2, 2012 at 11:38 AM, duane.lar...@gmail.com wrote: I just upgraded my b2bua opensips server to the latest trunk version and now my if statements using check_source_address from the permissions module isn't working. I have the following set up loadmodule permissions.so modparam(permissions,db_url,mysql://adfasdf:dfasdf...@108.xxx.xxx.xxx/opensips) if (check_source_address(2) || check_source_address(3) || check_source_address(4)) { The INVITE comes from my SIP Proxy and worked before the upgrade without issue Feb 1 22:41:01 proxy01 /usr/local/sbin/opensips[30163]: DBG:permissions:check_src_addr_3: Looking for : 5060, 1 in tables Feb 1 22:41:01 proxy01 /usr/local/sbin/opensips[30163]: DBG:permissions:hash_match: specified group does not exist in hash table Feb 1 22:41:01 proxy01 /usr/local/sbin/opensips[30163]: DBG:permissions:match_subnet_table: subnet table is empty Feb 1 22:41:01 proxy01 /usr/local/sbin/opensips[30163]: DBG:permissions:check_src_addr_3: Looking for : 5060, 1 in tables Feb 1 22:41:01 proxy01 /usr/local/sbin/opensips[30163]: DBG:permissions:hash_match: specified group does not exist in hash table Feb 1 22:41:01 proxy01 /usr/local/sbin/opensips[30163]: DBG:permissions:match_subnet_table: subnet table is empty Feb 1 22:41:01 proxy01 /usr/local/sbin/opensips[30163]: DBG:permissions:check_src_addr_3: Looking for : 5060, 1 in tables Feb 1 22:41:01 proxy01 /usr/local/sbin/opensips[30163]: DBG:permissions:hash_match: specified group does not exist in hash table Feb 1 22:41:01 proxy01 /usr/local/sbin/opensips[30163]: DBG:permissions:match_subnet_table: subnet table is empty This is what I have in the database Proxy01:/var/log# opensipsctl db show address +-+-++--+--+---+-+--+ | id | grp | ip | mask | port | proto | pattern | context_info | +-+-++--+--+---+-+--+ | 3 | 2 | 216.XXX.XXX.202 | 32 | 5060 | any | NULL | NULL | | 258 | 4 | 64.XXX.XXX.15 | 32 | 5060 | any | NULL | NULL | | 1 | 10 | 173.XXX.XXX.XXX | 32 | 5060 | any | NULL | NULL | | 2 | 10 | 173.XXX.XXX.XXX | 32 | 5060 | any | NULL | NULL | | 257 | 3 | 173.XXX.XXX.XXX | 32 | 5060 | any | NULL | NULL | | 4 | 2 | 216.XXX.XXX.202 | 32 | 5060 | any | NULL | NULL | +-+-++--+--+---+-+--+ I am not sure if OpenSIPS is really querying the mysql database because I don't really see any connections from the server when a call is made. How could this be possible? When I start OpenSIPS I see that it talks to the database. ___ Users mailing list Users@lists.opensips.org http://lists.opensips.org/cgi-bin/mailman/listinfo/users ___ Users mailing list Users@lists.opensips.org http://lists.opensips.org/cgi-bin/mailman/listinfo/users -- -- *--*--*--*--*--* Duane *--*--*--*--*--* -- ___ Users mailing list