[Serusers] mediaproxy: Can I tell if two UAs are behind the same firewall?
Marian Dumitru
marian.dumitru at voice-sistem.ro
Tue Feb 15 23:38:55 CET 2005
Hi Philipp,
As time as there are other solution, IMHO the exec feature should be
avoided as much as possible - it introduce a big overhead by dynamically
creating/waitting processes for each INVITE.
Just an opinion :-)
Best regards,
Marian
Alexander Philipp Lintenhofer wrote:
> Hi,
>
> Simply use following shellscript "requestBehindSameNAT.sh":
> ##################################
> #!/bin/bash
> # Prüft anhand der Request-URI und der Contact-Adresse,
> # ob Quelle und Ziel gleich sind -> NAT-Box
>
> DESTIP=`echo $SIP_RURI | sed 's/[^0-9\.\:]//g' | cut -d":" -f2`
>
> [ $DESTIP = $SIP_SRCIP ] && exit 0
> exit 1
> ##################################
> ... and call it in ser.cfg:
> if (!exec_msg("/usr/local/share/requestBehindSameNAT.sh"))
> {
> use_media_proxy();
> t_on_reply("1");
> }
>
> regards,
> Philipp
>
> _______________________________________________
> Serusers mailing list
> serusers at lists.iptel.org
> http://lists.iptel.org/mailman/listinfo/seruser
> s
--
Voice Sistem
http://www.voice-sistem.ro
More information about the sr-users
mailing list