Archive for December, 2024

OpenSIPS: dialplan module usage examples

Sunday, December 8th, 2024

Use case 1:
convert the username consisting of letters in incoming INVITE from your VoIP provider to digits
(e.g. INVITE: rt_user1@192.168.1.203 -> INVITE: 13511654321@192.168.1.203, where country-city-subscriber is 1-3511-654321):

Add to your dialplan table:

So, the SQL record is as follows:

(more…)

Linux Application Firewall

Wednesday, December 4th, 2024

OpenSnitch – a Linux firewall for applications – interactive outbound connections filtering.
https://www.linux-magazine.com/index.php/Issues/2022/259/OpenSnitch
https://github.com/evilsocket/opensnitch

A Bash web server

Wednesday, December 4th, 2024

Nice oneliners which may be useful to show some console output via HTTP.

An example of showing the iptables FORWARD chain:

Then go to http://ip.add.re.ss:8080 and you will see the output as a web page. In case of adding new rules renew the webpage and you will see the newly added rules.

To report file system disk space usage:

More info: https://www.linux-magazine.com/Issues/2021/250/Bash-Web-Server/(offset)/3/(tagID)/92#