OpenSIPS fork=yes required when listening on multiple ports? - kamailio

If I set OpenSIPS to listen on multiple ports on the same IP, do I need to set fork=yes or is that an old option no longer needed? Thanks

The fork= option was removed in OpenSIPS 2.2

The parameter 'listen' can be set multiple times in the same configuration file. Doing so will instruct opensips to listen on all protocol:addresses:ports specified.
Example: listen to UDP ports 5060 and 5070 on the (fake) address 10.10.10.10
listen = udp:10.10.10.10:5060
listen = udp:10.10.10.10:5070
You can even mix different protocols and interface like:
listen = udp:eth0:5080
listen = tcp:eth1:5090
Cheers.

Related

NGINX tcp stream on port 443

Is it possible to have nginx host a website on standard ports 80 and 443 while at the same time having it proxy a tcp stream on the same port 443 ?
In which case, how does nginx know when to route the client to the website and when to route to the stream ? It seems like tcp streams don't support the "server_name" value.
It is not possible to use both stream and http on one port. HTTP has the concept of routing based on server name while a tcp stream cannot route based on a server name.

Squid proxy : Is there a way to block source ports or only accept proxy requests from a specific port?

I have a scenario where I need to allow access only from a specific source port. I know how to block access to a destination port, say for example for HTTPS:
acl SSL_ports port 443
http_access deny !Safe_ports
My understanding is that this will ensure that the destination port 443 alone will be serviced. But Im not able to see any case when a source port can be filtered. Is this possible at all?

GCP : Classic LoadBalancer with single IP for ports 80 and 443

I am working on managing one of the instance on GCP. We have a domain with UnitedDomains, where we can add a single IP address pointing to our domain.
Unfortunately, GCP is providing us with 2 IP addresses when we are creating a load-balancer, one for port-80, another one for port-443.
Now, if I add the IP address of port-80 in domain mappings, then port-443 doesn't work as the IP is completely different and vice-versa.
I also tried adding a redirect in Nginx, and in a single block listen to both port80 and 443... Doesn't help.
What am I doing wrong?
Nginx code :
server {
listen 80;
listen 443 ssl http2;
server_name NAME;
ssl on;
}

Session Initiation Protocol

Does SIP v2.0 permit to have the protocol running over non-standard ports
(not 5060)? I've checked through the specification, but wasn't able to find
an answer. It looks like a port can be negotiated and determined during a
registration phase, but I could not confirm this with RFC.
Yes, port 5060/5061 are just the default ports if no other port is given. RFC3261 also only gives listening to port 5060/5061 as a recommendation;
It is also RECOMMENDED that a server
listen for requests on the default SIP ports (5060 for TCP and UDP,
5061 for TLS over TCP) on all public interfaces.
For example, if you use DNS lookup according to RFC3263, the port is looked up at the same time as the address;
That lookup would return:
;; Priority Weight Port Target
IN SRV 0 1 5060 server1.example.com
IN SRV 0 2 5060 server2.example.com
Well Yes you can use the other ports for sending Sip packets... Port Forwarding is a Hint...

How to listen to a well-known tcp port using QTcpServer

I want to listen to a well-known tcp port ,say 80 or 25 . How can I do this in Qt and using QTcpServer class? Or to be more generally, a port that is being used by someone else?
Thanks in advance.
you can not open server on the port that someone else listens to unless they stop it. Ports below 1025 belong to privileged range and depending on your Os your program may have to elevated permissions
Well you can pick different network interface, but perhaps this is not what you are after

Resources