Jump to content
Welcome to our new Citrix community!

RTSP Content Switching Expression


Recommended Posts

We have multiple ip-cameras on our administrative network.

want to access those from internet.

So we put up a couple of CNAMEs (camera01.domain.com, camera02.domain.com, camera03.domain.com) pointing to a RTSP content switching vserver on our netscaler.

Made a CS Policy for camera01.domain.com, binded an CS action the policy, added the LBVS that connects to camera01.

 

Put "true" as an expression in the CS Policy, we can connect to the camera via rtsp from the internet through our firewall, down to the netscaler CSvserver and LBVS.

We are now stuck trying to figure out how to write an relevant CS expression to differentiate the cameras to their own LBVS.

 

Traffic from client to camera initiates with this:

 

rtsp://camera01.domain.com:554/Streaming/channels/101 RTSP/1.0
Accept: application/sdp
CSeq: 3
User-Agent: Lavf57.71.100
Authorization: Digest username="user", realm="IP Camera(D7627)", nonce="0a0a0a0a0a0a0a0a0a0a0", uri="rtsp://camera01.domain.com:554/Streaming/channels/101", response="0a0a0a0a0a0a0a0a0a0a0a00a0a", algorithm="MD5"

Link to comment
Share on other sites

you need to narrow your cs policy expression. Since you put "true" no matter what the client enter it will always match and send it to camera #1.

 

you need to build your cs_policy with expression that match only a specific condition. We use alot of FQDN to decide where to send the traffic:

 

add cs policy CSPol_LB_camera01 -rule "HTTP.REQ.HOSTNAME.SET_TEXT_MODE(IGNORECASE).EQ(\"camera01.domain.com\")" -action ACT_SEND_LB_LB_camera01

add cs policy CSPol_LB_camera02 -rule "HTTP.REQ.HOSTNAME.SET_TEXT_MODE(IGNORECASE).EQ(\"camera02.domain.com\")" -action ACT_SEND_LB_LB_camera02

 

points all your dns to your Content switching vserver and the Netscaler will redirect to the right camera using the condition in the cs policy. You can use the GUI to find out what condition you can use by using the expression editor (ctrl+space).

 

 

Link to comment
Share on other sites

The problem is you can't bind HTTP based expressions to an RTSP cs vserver (limited testing on my part; would love to be wrong about this).

So while RTSP might be somewhat web-based, there's no rtsp policy expressions to look at headers and the http policies won't bind to an rtsp vserver.

 

So I don't know if you can do this.

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...