Skip to contentSkip to conversation

RTSP alg

DISCUSSION Joe McEachern 1 participant 1 message Nov 3, 2004

lore
Share & tools
lore
#0 lore raw

I've been looking at the behavior of the RTSP alg extension. When it parses a RTSP Transport that contains a RTP/AVP/UDP port range, it creates a conntrack update for the RTP port (low port), but not the RTCP port (high port). This prevents the server side from sending RTCP sender reports.

+ case pb_range:
+ for (loport = prtspexp->loport; loport != 0; loport += 2) /* XXX:
improper wrap? */
+ {

+            t.dst.u.udp.port = htons(loport);
+            if (ip_conntrack_change_expect(exp, &t) == 0)
+            {
+                hiport = loport + ~exp->mask.dst.u.udp.port;
+                DEBUGP("using ports %hu-%hu\n", loport, hiport);
+                break;
+            }
+        }
+        if (loport != 0)
+        {

+ rbuf1len = sprintf(rbuf1, "%hu", loport);
+ rbufalen = sprintf(rbufa, "%hu-%hu", loport, loport+1);
+ }
+ break;

It looks like RTSP clients can still function without this behind a NAT device - at least real player.

Has anyone created a setup that is allowing RTCP packets from the server to the client?

Regards,

Joe