ZoneMinder/ZoneMinder — pull request #407 by m-bene (2014-04-28 22:55:33+00:00)
Title: Rtsp digest

First shot at adding RTSP digest authentication to remote monitors as requested in #399
* only implements most basic version of digest auth as described by RFC 2069. This should however be supported by all Servers as a valid fallback mode (and the implementation doesn't have issues with order of options or presence of unused options like libVLC / live555)
* don't put " in username - won't work
* I tried to reuse the MD5 functions already present in zm_user.cpp with versions for both openssl and gnutls. My system uses openssl/md5.h, I haven't tried if the gnutls version actually works
* Need help for RTP_RTSP_HTTP method: mRtspSocket closes after receiving the 401 not authorized message containing the WWW-Authenticate header. I can't seem to figure out how to correctly reopen that socket (at zm_rtsp.cpp Line 316) so the retry with a valid Authenticate header gets sent and processed correctly.
* RTP/Unicast and RTP/RTSP seem to work OK.