Re: [OpenSIPS-Users] opensips-cli skipping module tls

2023-09-26 Thread L S
I apologize if this is a duplicate post - ran into some errors while
posting the first time.

Thanks Razvan. Installing cryptography fixed that issue. I was able to run
-x tls rootCA and userCERT, and create the certificates.

However, when running Opensips I get this error now:

ERROR:tls_wolfssl:load_private_key: key
'/usr/local/etc/opensips/tls/server/privkey.pem' does not match the public
key of the certificate

I had created and used certificates with opensips-cli before without any
issues. Opensips-cli.cfg is the same except for a small change to CN. All
the paths are the same as before and correct.

I compared the modulus of the server private key to the public key using
openssl, and they are different. Btw I created certificates both in Centos
7 and Ubuntu Focal just to see if it matters; got the same error for both.

Any ideas why this is happening?

Thanks,
Matt

On Tue, Sep 26, 2023, 9:56 AM Răzvan Crainea  wrote:

> Can you double check whether you have the python-openssl or
> python-cryptography libraries?
>
> Best regards,
>
> Răzvan Crainea
> OpenSIPS Core Developer / SIPhub CTO
> http://www.opensips-solutions.com / https://www.siphub.com
>
> On 9/26/23 16:38, L S wrote:
> > I'm trying to create certificates using opensips-cli:
> >
> > opensips-cli - f /usr/local/etc/opensips-cli.cfg -d -x tls rootCA
> > DEBUG: Skipping module 'tls' - excluded on purpose
> >
> > ERROR: No module 'tls' loaded
> >
> > Trying to find out why I am getting this message now - it used to work
> > fine. All other modules are loaded.
> >
> > Thaks,
> > Matt
> >
> > ___
> > 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
>
___
Users mailing list
Users@lists.opensips.org
http://lists.opensips.org/cgi-bin/mailman/listinfo/users


[OpenSIPS-Users] dbalias and location lookup branching

2023-09-26 Thread John Sliney
Hi,

I’m currently attempting to take an INVITE from an Asterisk server that is 
requesting an extension number, perform dbalias lookups to have extensions 
turned into sip users (x1000 -> test_hardphone) and then do location lookups on 
those sip users.  There can be multiple sip users for each extension and 
multiple locations for each sip user.

Using the code below partially works but when there are no location entries for 
the requested sip user, OpenSIPS returns a 500 and prints out “ERROR:  
t_forward_nonack failed” how can I have OpenSIPS instead respond with a 404?

### CODE ###

modparam("alias_db","append_branches",  1)

route {
if ( is_from_gw() ) {
alias_db_lookup("dbaliases");
t_on_branch("sip_user_branch");
}
route(relay);
return(0);
}

branch_route[sip_user_branch] {
route(lookup_sip_user);
}

route[lookup_sip_user] {
if ( ! lookup("location")  ) {
drop();
}
}

route[relay] {
if ( ! t_relay() ) {
sl_reply_error();
rtpproxy_unforce();
return(0);
}
}

### CODE ###

Any help would be appreciated, Thanks
___
Users mailing list
Users@lists.opensips.org
http://lists.opensips.org/cgi-bin/mailman/listinfo/users


[OpenSIPS-Users] Multiple TLS server domain setup

2023-09-26 Thread L S
Hi,
I'm trying to set up two tls domains for two sets of clients. First one
requires TLSv1 (higher not supported), and the other one requires TLSv1_2
or higher.
Right now the domain with tlsv1 is active on 5061 and has no issues. I'm
trying to add the second domain.

As far as I understand (do not have much experience with tls config), for
incoming traffic (server domain), we can either ask them to use port 5062
or provide SNI so that they can also connect thru 5061. Not sure if they
want to/can do that. Is there any other way we can distinguish these two
clients; e.g. from the source ip?

Thanks,
Matt
___
Users mailing list
Users@lists.opensips.org
http://lists.opensips.org/cgi-bin/mailman/listinfo/users


Re: [OpenSIPS-Users] opensips-cli skipping module tls

2023-09-26 Thread L S
Thanks Razvan. Installing the cryptography module fixed it - I was able to
run both -x tls rootCA and userCERT, and create the certificates.

However, when I start Opensips, I get the following error:
ERROR:tls_wolfssl:load_private_key: key
'/usr/local/etc/opensips/tls/server/privkey.pem' does not match the public
key of the certificate

I tried creating the certificates both on Centos 7 and Ubuntu Focal, and
they both gave the same error.
The data for the certificates comes from opensips-cli.cfg. I had created
certificates with that cfg 3 months ago, and used in Opensips script
without any issues.
 I only changed the domain name this time.

Any suggestions?
Thanks,
Matt


On Tue, Sep 26, 2023, 9:56 AM Răzvan Crainea  wrote:

> Can you double check whether you have the python-openssl or
> python-cryptography libraries?
>
> Best regards,
>
> Răzvan Crainea
> OpenSIPS Core Developer / SIPhub CTO
> http://www.opensips-solutions.com / https://www.siphub.com
>
> On 9/26/23 16:38, L S wrote:
> > I'm trying to create certificates using opensips-cli:
> >
> > opensips-cli - f /usr/local/etc/opensips-cli.cfg -d -x tls rootCA
> > DEBUG: Skipping module 'tls' - excluded on purpose
> >
> > ERROR: No module 'tls' loaded
> >
> > Trying to find out why I am getting this message now - it used to work
> > fine. All other modules are loaded.
> >
> > Thaks,
> > Matt
> >
> > ___
> > 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
>
___
Users mailing list
Users@lists.opensips.org
http://lists.opensips.org/cgi-bin/mailman/listinfo/users


Re: [OpenSIPS-Users] opensips-cli skipping module tls

2023-09-26 Thread Răzvan Crainea
Can you double check whether you have the python-openssl or 
python-cryptography libraries?


Best regards,

Răzvan Crainea
OpenSIPS Core Developer / SIPhub CTO
http://www.opensips-solutions.com / https://www.siphub.com

On 9/26/23 16:38, L S wrote:

I'm trying to create certificates using opensips-cli:

opensips-cli - f /usr/local/etc/opensips-cli.cfg -d -x tls rootCA
DEBUG: Skipping module 'tls' - excluded on purpose

ERROR: No module 'tls' loaded

Trying to find out why I am getting this message now - it used to work 
fine. All other modules are loaded.


Thaks,
Matt

___
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


[OpenSIPS-Users] opensips-cli skipping module tls

2023-09-26 Thread L S
I'm trying to create certificates using opensips-cli:

opensips-cli - f /usr/local/etc/opensips-cli.cfg -d -x tls rootCA
DEBUG: Skipping module 'tls' - excluded on purpose

ERROR: No module 'tls' loaded

Trying to find out why I am getting this message now - it used to work
fine. All other modules are loaded.

Thaks,
Matt
___
Users mailing list
Users@lists.opensips.org
http://lists.opensips.org/cgi-bin/mailman/listinfo/users


[OpenSIPS-Users] Code of conduct

2023-09-26 Thread Bogdan-Andrei Iancu

Hi,

Following the abundance of emails and GH tickets from B.Prathibha, I 
want to point out some important aspects of the code of conduct here:


1) BEFORE considering the community help, be sure you checked the 
available documentation and did any online research on the matter


2) BEFORE consider posting, pick the right channel - if you suspect a 
coding bug, use the GitHub ticket, otherwise post on the user's mailing list


3) DO NOT DOUBLE POST on several channels (list and GH tracker)

4) POST only when you understand the problem you have - avoid fast 
rounds of posts where you are just scratchpad'ing


5) POST only for topics related to OpenSIPS / SIP

6) DO NOT ASK people to solve you problem or do your script - ask for 
guidance, help and info



Keep in mind, the community help is here for all, so respect the rest of 
the people on the list and AVOID spamming or abusing the channels we have.


Best regards,

--
Bogdan-Andrei Iancu

OpenSIPS Founder and Developer
  https://www.opensips-solutions.com
  https://www.siphub.com


___
Users mailing list
Users@lists.opensips.org
http://lists.opensips.org/cgi-bin/mailman/listinfo/users


[OpenSIPS-Users] unexpect EOF while reading

2023-09-26 Thread Prathibha B
opensips version: 3.3

Error:
I am using websocket. I am using the letsencrypt certifcate. When I
connected from web to web and when verify_cert is 1 and require_cert is 1,
get the following errors:

ERROR:tls_openssl:openssl_tls_accept: New TLS connection from
14.139.183.221:53946 failed to accept
ERROR:tls_openssl:tls_print_errstack: TLS errstack: error:0A000126:SSL
routines::unexpected eof while reading
ERROR:proto_wss:wss_read_req: cannot fix read connection

-- 
Regards,
B.Prathibha


opensips.cfg.rtpengine
Description: Binary data
___
Users mailing list
Users@lists.opensips.org
http://lists.opensips.org/cgi-bin/mailman/listinfo/users


Re: [OpenSIPS-Users] Opensips 3.4 Not sending hep to homer server

2023-09-26 Thread Vincent Horst via Users
Thanks @Michel,

hep socket is indeed the local host.
step I missed, installing heplify agent on the opensips system.
Forward the received packets towards Homer :)

case closed.
Vincent


Op di 26 sep 2023 om 08:21 schreef Michel crans :

> If you're not seeing any packets received on the Homer server, there could
> be several reasons for this issue. Let's go through some troubleshooting
> steps:
>
>1.
>
>Check Network Connectivity:
>- Ensure that there is network connectivity between your OpenSIPS
>   server and the Homer server. You should be able to ping the Homer server
>   from the OpenSIPS server.
>2.
>
>Homer Server Configuration:
>- Verify that your Homer server is correctly configured to receive HEP
>   packets on the specified IP and port (in this case, 127.0.0.1:6061).
>   Check Homer's logs for any incoming connection attempts or errors.
>3.
>
>Socket Configuration:
>- It seems you are using 127.0.0.1 as the IP address in your socket
>   configuration (socket=hep_udp:127.0.0.1:6061). This means OpenSIPS
>   will send HEP packets to localhost (the same server it's running on).
>   Ensure that this is the correct configuration. If Homer is on a 
> different
>   server, you should use the Homer server's IP address instead.
>4.
>
>Firewall and Security Rules:
>- Make sure that there are no firewall rules or security policies
>   blocking traffic on the specified HEP port (6061) or the network 
> interface
>   being used for communication.
>5.
>
>Logging and Debugging:
>- Enable verbose logging in OpenSIPS to see if there are any error
>   messages related to HEP. You can do this by setting the log_level
>   parameter in your OpenSIPS configuration file.
>
>cfgCopy code
>modparam("log", "log_level", 3)
>
>This will increase the logging verbosity, and you can check the
>OpenSIPS logs for any relevant error messages.
>6.
>
>Verify Route Execution:
>- Ensure that your route[to_homer] block is being executed when you
>   expect it to. You can add additional log messages in this block to 
> verify
>   that it's being triggered.
>7.
>
>Check HEP Configuration:
>- Review your HEP configuration parameters, such as hep_id and trace_id,
>   to ensure they are correctly set. Make sure they match the 
> configuration on
>   the Homer server.
>8.
>
>Firewall on Homer Server:
>- Check if there is any firewall or security software running on the
>   Homer server that might be blocking incoming HEP packets.
>9.
>
>Homer Server Logs:
>- Examine the logs on your Homer server to see if there are any error
>   messages or indications of failed connections.
>10.
>
>Packet Capture:
>- You can use tools like Wireshark to capture network traffic on the
>   OpenSIPS server and check if the HEP packets are actually being sent. 
> This
>   can help you confirm whether the issue is with OpenSIPS or the network.
>
> By systematically going through these troubleshooting steps, you should be
> able to identify the root cause of why OpenSIPS is not sending HEP packets
> to your Homer server. Remember to make configuration adjustments as needed
> to match your specific network setup and requirements.
>
> Op ma 25 sep 2023 om 22:34 schreef Vincent Horst via Users <
> users@lists.opensips.org>:
>
>> Hi All,
>>
>> I have a issue where opensips is not sending the hep files towards homer.
>> I have used a manual and have add below to the .cfg file.
>>
>> Sockets: (It is unclear for my why I should put here the local adres,
>> when I put the remote IP of homer, I get an error in the config:
>> socket=hep_udp:127.0.0.1:6061
>> socket=hep_tcp:127.0.0.1:6061
>> If I remove them from the config the hep module gives an error.
>>
>> Second part in the .cfg:
>> ### Configure an HEP Endpoint
>> loadmodule "proto_hep.so"
>> modparam("proto_hep", "hep_id", "[hid]10.0.0.216:9060
>> ;transport=udp;version=3")
>>  Configure Tracer module to use the HEP Protocol instance id [hid]
>> loadmodule "tracer.so"
>> modparam("tracer", "trace_on", 1)
>> modparam("tracer", "trace_id", "[tid]uri=hep:hid")
>>
>> And then the third part,
>> I noticed that it make no different when I put it above in the route
>> logic or below.
>>
>> route[to_homer] {
>> $var(trace_id) = "tid";
>> if (!has_totag()) {
>> if (is_method("INVITE")) { $var(trace_type) = "dialog"; }
>> else if (!is_method("CANCEL")) { $var(trace_type) = "transaction"; }
>> } else { $var(trace_type) = NULL; }
>> switch ($var(trace_type)) {
>> case "dialog":
>> trace("$var(trace_id)", "d", "sip|xlog|rest");
>> break;
>> case "transaction":
>> trace("$var(trace_id)", "t", "sip|xlog");
>> break;
>> }
>> }
>>
>> I'm not getting an error, but I'm also not seeing any packets received on
>> the homer server.
>> Can someone point me in the right direction or explain how I can add
>> details to 

Re: [OpenSIPS-Users] Temporarily unavailable

2023-09-26 Thread Prathibha B
When user2 accepts the call, the above error occurs.

On Tue, 26 Sept 2023 at 14:08, Prathibha B  wrote:

> I'm getting this error in log:
>
>  New TLS connection from 45.33.68.226:42316 failed to accept
> ERROR:tls_openssl:tls_print_errstack: TLS errstack: error:0AEA:SSL
> routines::callback failed
> ERROR:proto_wss:wss_read_req: cannot fix read connection
>
> On Tue, 26 Sept 2023 at 13:41, Prathibha B 
> wrote:
>
>> I am using websocket. I am trying web to web call.
>>
>>
>> On Tue, 26 Sept 2023 at 13:40, Prathibha B 
>> wrote:
>>
>>> I've created two users and they are registered to opensips. When I try
>>> to connect, user 1 to user 2, I get temporarily unavailable. Config file is
>>> attached with this email.
>>>
>>> --
>>> Regards,
>>> B.Prathibha
>>>
>>
>>
>> --
>> Regards,
>> B.Prathibha
>>
>
>
> --
> Regards,
> B.Prathibha
>


-- 
Regards,
B.Prathibha
___
Users mailing list
Users@lists.opensips.org
http://lists.opensips.org/cgi-bin/mailman/listinfo/users


Re: [OpenSIPS-Users] Temporarily unavailable

2023-09-26 Thread Prathibha B
I'm getting this error in log:

 New TLS connection from 45.33.68.226:42316 failed to accept
ERROR:tls_openssl:tls_print_errstack: TLS errstack: error:0AEA:SSL
routines::callback failed
ERROR:proto_wss:wss_read_req: cannot fix read connection

On Tue, 26 Sept 2023 at 13:41, Prathibha B  wrote:

> I am using websocket. I am trying web to web call.
>
>
> On Tue, 26 Sept 2023 at 13:40, Prathibha B 
> wrote:
>
>> I've created two users and they are registered to opensips. When I try to
>> connect, user 1 to user 2, I get temporarily unavailable. Config file is
>> attached with this email.
>>
>> --
>> Regards,
>> B.Prathibha
>>
>
>
> --
> Regards,
> B.Prathibha
>


-- 
Regards,
B.Prathibha
___
Users mailing list
Users@lists.opensips.org
http://lists.opensips.org/cgi-bin/mailman/listinfo/users


Re: [OpenSIPS-Users] Wrong TCP socket being used on TLS registrations

2023-09-26 Thread Bogdan-Andrei Iancu

Hi Ray,

The "tcp_accept_aliases" should be harmless if there is no "alias" param 
received in the incoming requests. If no such parameter is pushed by the 
end-devices, there is 0 impact.


And indeed, this has a really ugly side effect for the (CG)NAT'd 
devices. But let's give it a try, disable this option and try the 
testing again, to see if the right conn is selected.


Regards,

Bogdan-Andrei Iancu

OpenSIPS Founder and Developer
  https://www.opensips-solutions.com
  https://www.siphub.com

On 9/22/23 5:03 AM, Ray Jackson wrote:


Hi Bogdan,

Yes, we have the following enabled in our config:

tcp_accept_aliases=1

I assume this is the culprit then and we are inadvertently sending 
calls down the wrong TCP socket here to the wrong user due to this 
being enabled?  This is quite a nasty setting to have enabled when we 
are dealing with CGNAT'd customers who are sharing public IP addresses 
but are completely unrelated users!


I will disable this setting and see if that clears up the issue for 
us.  We have in fact had another case just today of the same issue 
happening (User A is receiving User B's incoming calls!)


Thanks for highlighting this and let me know if there is anything else 
I should look at in our config.


Thanks,

Ray

On 19/09/23 9:30 pm, Bogdan-Andrei Iancu wrote:


Hi Ray,

Do you use any TCP aliasing options in your cfg ?

Regards,
Bogdan-Andrei Iancu

OpenSIPS Founder and Developer
   https://www.opensips-solutions.com
   https://www.siphub.com
On 9/2/23 3:17 AM, Ray Jackson wrote:


Hi all,

I'm facing a weird issue which I think is related to broken TCP 
socket reuse logic where the wrong client is receiving incoming 
calls due to the wrong socket being used for the incoming INVITE.


The scenario is when I have 2 clients registering using TLS behind 
NAT at the same Public IPv4 address and both clients are using the 
same private port number.  So client 1 registers and the Via and 
contact header looks like:


Via: SIP/2.0/TLS 
192.168.42.162:5062;branch=z9hG4bK1409895926;rport;alias Contact: 
;reg-id=2;+sip.instance=""


Client 2 registers from behind the same Public IPv4 address and the 
Via and contact header looks like:


Via: SIP/2.0/TLS 192.168.42.186:5062;branch=z9hG4bK-aff1f3b3 
Contact: ;expires=300


The location table shows Client 1 received field of 103.212.1.2:5062 
and Client 103.212.1.2:23456


When a call comes in for Client 1 the location lookup seems to 
return the correct 'received' address and port (e.g. 
103.212.1.2:5062) and all the logs indicate that this is where the 
SIP INVITE *should* be going to (in the $du field).  However when 
you check the SIP traffic it selects Client 2's socket and the 
traffic goes to port 23456 instead of 5062.


I think this is related somehow to the TCP port reuse logic inside 
Opensips.  My suspicion is that Opensips is looking at the Contact 
or Via port number (which is the same for both client 1 and 2) and 
then somehow mapping this to the wrong TCP received socket.


Does anybody have any suggestions here?  Should I be fixing the NAT 
in the Contact header (using fix_nated_contact).  I read somewhere 
that you shouldn't rewrite the Contact header to avoid problems with 
sending a different Contact URI to the client on calls.  Or is this 
issue more related to the Via header and the TCP port reuse logic 
looking at this port instead of the actual received port when 
choosing the outgoing socket?


FYI: I am using both force_rport() and fix_nated_register() for 
incoming registrations from these clients and matching_mode of 0 in 
usrloc.  However, I am not using fix_nated_contact() for registrations.


Thanks,

Ray



___
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


[OpenSIPS-Users] Temporarily unavailable

2023-09-26 Thread Prathibha B
I've created two users and they are registered to opensips. When I try to
connect, user 1 to user 2, I get temporarily unavailable. Config file is
attached with this email.

-- 
Regards,
B.Prathibha
#
# OpenSIPS residential configuration script
# by OpenSIPS Solutions 
#
# Please refer to the Core CookBook at:
#  http://www.opensips.org/Resources/DocsCookbooks
# for a explanation of possible statements, functions and parameters.
#


### Global Parameters #

log_level=5
xlog_level=5
log_stderror=no
log_facility=LOG_LOCAL0

open_files_limit=4096

udp_workers=4

/* uncomment the next line to enable the auto temporary blacklisting of
   not available destinations (default disabled) */
#disable_dns_blacklist=no

/* uncomment the next line to enable IPv6 lookup after IPv4 dns
   lookup failures (default disabled) */
#dns_try_ipv6=yes


socket=udp:172.31.34.24:5060 as 65.2.167.22:5060  # CUSTOMIZE ME
socket=tcp:172.31.34.24:5060 as 65.2.167.22:5060  # CUSTOMIZE ME
socket=tls:172.31.34.24:5061 as 65.2.167.22:5061  # CUSTOMIZE ME
socket=ws:172.31.34.24:8080 as 65.2.167.22:8080
socket=wss:172.31.34.24:7443 as 65.2.167.22:7443
### Modules Section 

#set module path
mpath="/usr/lib/x86_64-linux-gnu/opensips/modules/"

 SIGNALING module
loadmodule "signaling.so"

 StateLess module
loadmodule "sl.so"

 Transaction Module
loadmodule "tm.so"
modparam("tm", "fr_timeout", 5)
modparam("tm", "fr_inv_timeout", 30)
modparam("tm", "restart_fr_on_each_reply", 0)
modparam("tm", "onreply_avp_mode", 1)

 Record Route Module
loadmodule "rr.so"
/* do not append from tag to the RR (no need for this script) */
modparam("rr", "append_fromtag", 0)

 MAX ForWarD module
loadmodule "maxfwd.so"

 SIP MSG OPerationS module
loadmodule "sipmsgops.so"

 FIFO Management Interface
loadmodule "mi_fifo.so"
modparam("mi_fifo", "fifo_name", "/tmp/opensips_fifo")
modparam("mi_fifo", "fifo_mode", 0666)

 MYSQL module
loadmodule "db_mysql.so"

 HTTPD module
loadmodule "httpd.so"
modparam("httpd", "port", )

 USeR LOCation module
loadmodule "usrloc.so"
modparam("usrloc", "nat_bflag", "NAT")
modparam("usrloc", "working_mode_preset", "single-instance-sql-write-back")
modparam("usrloc", "db_url",
"mysql://root:root@localhost/opensips") # CUSTOMIZE ME


 REGISTRAR module
loadmodule "registrar.so"
modparam("registrar", "tcp_persistent_flag", "TCP_PERSISTENT")
modparam("registrar", "received_avp", "$avp(received_nh)")/* uncomment the next 
line not to allow more than 10 contacts per AOR */
#modparam("registrar", "max_contacts", 10)

 ACCounting module
loadmodule "acc.so"
/* what special events should be accounted ? */
modparam("acc", "early_media", 0)
modparam("acc", "report_cancels", 0)
/* by default we do not adjust the direct of the sequential requests.
   if you enable this parameter, be sure to enable "append_fromtag"
   in "rr" module */
modparam("acc", "detect_direction", 0)
modparam("acc", "db_url",
"mysql://root:root@localhost/opensips") # CUSTOMIZE ME

 AUTHentication modules
loadmodule "auth.so"
loadmodule "auth_db.so"
modparam("auth_db", "calculate_ha1", yes)
modparam("auth_db", "password_column", "password")
modparam("auth_db", "db_url",
"mysql://root:root@localhost/opensips") # CUSTOMIZE ME
modparam("auth_db", "load_credentials", "")

 ALIAS module
loadmodule "alias_db.so"
modparam("alias_db", "db_url",
"mysql://root:root@localhost/opensips") # CUSTOMIZE ME

 DIALOG module
loadmodule "dialog.so"
modparam("dialog", "dlg_match_mode", 1)
modparam("dialog", "default_timeout", 21600)  # 6 hours timeout
modparam("dialog", "db_mode", 2)
modparam("dialog", "db_url",
"mysql://root:root@localhost/opensips") # CUSTOMIZE ME

  NAT modules
loadmodule "nathelper.so"
modparam("nathelper", "natping_interval", 10)
modparam("nathelper", "ping_nated_only", 1)
modparam("nathelper", "sipping_bflag", "SIP_PING_FLAG")
modparam("nathelper", "sipping_from", "sip:pinger@127.0.0.1") #CUSTOMIZE ME
modparam("nathelper", "received_avp", "$avp(received_nh)")

loadmodule "rtpengine.so"
modparam("rtpengine", "rtpengine_sock", "udp:172.31.34.24:2225")

  DIALPLAN module
loadmodule "dialplan.so"
modparam("dialplan", "db_url",
"mysql://root:root@localhost/opensips") # CUSTOMIZE ME

  MI_HTTP module
loadmodule "mi_http.so"

loadmodule "proto_udp.so"
loadmodule "proto_tcp.so"
loadmodule "proto_tls.so"
loadmodule "proto_ws.so"
loadmodule "proto_wss.so"
modparam("proto_wss", "wss_port", 7443)
modparam("proto_wss", "wss_max_msg_chunks", 16)

loadmodule "tls_openssl.so"
#loadmodule "tls_wolfssl.so"
loadmodule "tls_mgm.so"
modparam("tls_mgm","server_domain", "default")
modparam("tls_mgm","verify_cert", "[default]0")
modparam("tls_mgm","require_cert", "[default]0")
#modparam("tls_mgm","certificate", 
"[default]/etc/opensips/tls/rootCA/cacert.pem")
#modparam("tls_mgm","private_key", 
"[default]/etc/opensips/tls/rootCA/private/cakey.pem")

Re: [OpenSIPS-Users] Temporarily unavailable

2023-09-26 Thread Prathibha B
I am using websocket. I am trying web to web call.


On Tue, 26 Sept 2023 at 13:40, Prathibha B  wrote:

> I've created two users and they are registered to opensips. When I try to
> connect, user 1 to user 2, I get temporarily unavailable. Config file is
> attached with this email.
>
> --
> Regards,
> B.Prathibha
>


-- 
Regards,
B.Prathibha
___
Users mailing list
Users@lists.opensips.org
http://lists.opensips.org/cgi-bin/mailman/listinfo/users


Re: [OpenSIPS-Users] Opensips 3.4 Not sending hep to homer server

2023-09-26 Thread Michel crans
If you're not seeing any packets received on the Homer server, there could
be several reasons for this issue. Let's go through some troubleshooting
steps:

   1.

   Check Network Connectivity:
   - Ensure that there is network connectivity between your OpenSIPS server
  and the Homer server. You should be able to ping the Homer
server from the
  OpenSIPS server.
   2.

   Homer Server Configuration:
   - Verify that your Homer server is correctly configured to receive HEP
  packets on the specified IP and port (in this case, 127.0.0.1:6061).
  Check Homer's logs for any incoming connection attempts or errors.
   3.

   Socket Configuration:
   - It seems you are using 127.0.0.1 as the IP address in your socket
  configuration (socket=hep_udp:127.0.0.1:6061). This means OpenSIPS
  will send HEP packets to localhost (the same server it's running on).
  Ensure that this is the correct configuration. If Homer is on a different
  server, you should use the Homer server's IP address instead.
   4.

   Firewall and Security Rules:
   - Make sure that there are no firewall rules or security policies
  blocking traffic on the specified HEP port (6061) or the network
interface
  being used for communication.
   5.

   Logging and Debugging:
   - Enable verbose logging in OpenSIPS to see if there are any error
  messages related to HEP. You can do this by setting the log_level
  parameter in your OpenSIPS configuration file.

   cfgCopy code
   modparam("log", "log_level", 3)

   This will increase the logging verbosity, and you can check the OpenSIPS
   logs for any relevant error messages.
   6.

   Verify Route Execution:
   - Ensure that your route[to_homer] block is being executed when you
  expect it to. You can add additional log messages in this block to verify
  that it's being triggered.
   7.

   Check HEP Configuration:
   - Review your HEP configuration parameters, such as hep_id and trace_id,
  to ensure they are correctly set. Make sure they match the
configuration on
  the Homer server.
   8.

   Firewall on Homer Server:
   - Check if there is any firewall or security software running on the
  Homer server that might be blocking incoming HEP packets.
   9.

   Homer Server Logs:
   - Examine the logs on your Homer server to see if there are any error
  messages or indications of failed connections.
   10.

   Packet Capture:
   - You can use tools like Wireshark to capture network traffic on the
  OpenSIPS server and check if the HEP packets are actually being
sent. This
  can help you confirm whether the issue is with OpenSIPS or the network.

By systematically going through these troubleshooting steps, you should be
able to identify the root cause of why OpenSIPS is not sending HEP packets
to your Homer server. Remember to make configuration adjustments as needed
to match your specific network setup and requirements.

Op ma 25 sep 2023 om 22:34 schreef Vincent Horst via Users <
users@lists.opensips.org>:

> Hi All,
>
> I have a issue where opensips is not sending the hep files towards homer.
> I have used a manual and have add below to the .cfg file.
>
> Sockets: (It is unclear for my why I should put here the local adres, when
> I put the remote IP of homer, I get an error in the config:
> socket=hep_udp:127.0.0.1:6061
> socket=hep_tcp:127.0.0.1:6061
> If I remove them from the config the hep module gives an error.
>
> Second part in the .cfg:
> ### Configure an HEP Endpoint
> loadmodule "proto_hep.so"
> modparam("proto_hep", "hep_id", "[hid]10.0.0.216:9060
> ;transport=udp;version=3")
>  Configure Tracer module to use the HEP Protocol instance id [hid]
> loadmodule "tracer.so"
> modparam("tracer", "trace_on", 1)
> modparam("tracer", "trace_id", "[tid]uri=hep:hid")
>
> And then the third part,
> I noticed that it make no different when I put it above in the route logic
> or below.
>
> route[to_homer] {
> $var(trace_id) = "tid";
> if (!has_totag()) {
> if (is_method("INVITE")) { $var(trace_type) = "dialog"; }
> else if (!is_method("CANCEL")) { $var(trace_type) = "transaction"; }
> } else { $var(trace_type) = NULL; }
> switch ($var(trace_type)) {
> case "dialog":
> trace("$var(trace_id)", "d", "sip|xlog|rest");
> break;
> case "transaction":
> trace("$var(trace_id)", "t", "sip|xlog");
> break;
> }
> }
>
> I'm not getting an error, but I'm also not seeing any packets received on
> the homer server.
> Can someone point me in the right direction or explain how I can add
> details to trouble shoot?
>
> Cheers,
> Vincent
> ___
> 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