Special If condition

classic Classic list List threaded Threaded
3 messages Options
Reply | Threaded
Open this post in threaded view
|

Special If condition

Ali Jawad-2

Hi All

I do have openser listening on tls port and udp port, the udp port is 5060, I want to apply a special condition if the user is using udp/5060.

 

I.e something like

 

If(user is coming in on port5060)

 

Or

 

If(user is using udp )

 

Any help please ?

 

Regards

 


_______________________________________________
Users mailing list
[hidden email]
http://lists.opensips.org/cgi-bin/mailman/listinfo/users
Reply | Threaded
Open this post in threaded view
|

Re: Special If condition

Ali Jawad-2

I should have checked the cookbook first

 

if(dst_port==5060)

 


From: [hidden email] [mailto:[hidden email]] On Behalf Of Ali Jawad
Sent: 2008-12-03 15:40
To: [hidden email]
Subject: [OpenSIPS-Users] Special If condition

 

Hi All

I do have openser listening on tls port and udp port, the udp port is 5060, I want to apply a special condition if the user is using udp/5060.

 

I.e something like

 

If(user is coming in on port5060)

 

Or

 

If(user is using udp )

 

Any help please ?

 

Regards

 


_______________________________________________
Users mailing list
[hidden email]
http://lists.opensips.org/cgi-bin/mailman/listinfo/users
Reply | Threaded
Open this post in threaded view
|

Re: Special If condition

Bogdan-Andrei Iancu
Hi Ali,

better use $Rp (reference to the port where the message was received) as
the dst_port will become obsolete.

Also you can directly check the protocol :
$pr or $proto ****- protocol of received message (UDP, TCP, TLS, SCTP)

Regards,
Bogdan


Ali Jawad wrote:

>
> I should have checked the cookbook first
>
>  
>
> if(dst_port==5060)
>
>  
>
> ------------------------------------------------------------------------
>
> *From:* [hidden email]
> [mailto:[hidden email]] *On Behalf Of *Ali Jawad
> *Sent:* 2008-12-03 15:40
> *To:* [hidden email]
> *Subject:* [OpenSIPS-Users] Special If condition
>
>  
>
> Hi All
>
> I do have openser listening on tls port and udp port, the udp port is
> 5060, I want to apply a special condition if the user is using udp/5060.
>
>  
>
> I.e something like
>
>  
>
> If(user is coming in on port5060)
>
>  
>
> Or
>
>  
>
> If(user is using udp )
>
>  
>
> Any help please ?
>
>  
>
> Regards
>
>  
>
> ------------------------------------------------------------------------
>
> _______________________________________________
> Users mailing list
> [hidden email]
> http://lists.opensips.org/cgi-bin/mailman/listinfo/users
>  


_______________________________________________
Users mailing list
[hidden email]
http://lists.opensips.org/cgi-bin/mailman/listinfo/users