ZoneMinder/ZoneMinder — pull request #608 by knnniggett (2014-11-29 14:31:49+00:00)
Title: echo the URL to the RTSP device during the OPTIONS directive

The RTSP code in zoneminder follows RFC 2326 pretty closely, as it should.

The initial handshake between zoneminder and rtsp camera is broken down into directives. The first directive sent to the camera is called OPTIONS and, according to RFC 2326, it should look like this:
`OPTIONS * RTSP/1.0`

Indeed that is exactly what zoneminder does. However, over the years of using zoneminder, I have never had a camera that accepted this. Each camera would immediately respond with "Bad Request".

The interesting this is, the [WiKi](http://en.wikipedia.org/wiki/Real_Time_Streaming_Protocol#Protocol_directives) shows a different OPTIONS directive.

Instead of sending "*", it sends the devices own URL back to it. Further investigation using wireshark reveals that is exactly what ffmpeg & vlc do. They don't send "*" with their OPTIONS directive. Instead, they send the URL.

This pull request brings zoneminder in-line with what ffmepg & vlc do. I can't explain why the RTSP RFC isn't being followed in this case, but it appears that is what we need to do (e.g. everyone else is doing it!).

I've tested this on my Foscam 9821. Foscam is not only fairly popular, but its firmware is cloned by many other manufacturers. That means this should allow the RTSP method to work with a lot of cameras now.