mirror of
https://github.com/AlexxIT/go2rtc.git
synced 2025-10-19 06:34:43 +08:00
Fix RTSP auth for RtspServer project #244
This commit is contained in:
@@ -70,7 +70,9 @@ func (a *Auth) Write(req *Request) {
|
|||||||
case AuthBasic:
|
case AuthBasic:
|
||||||
req.Header.Set("Authorization", a.header)
|
req.Header.Set("Authorization", a.header)
|
||||||
case AuthDigest:
|
case AuthDigest:
|
||||||
uri := req.URL.RequestURI()
|
// important to use String except RequestURL for RtspServer:
|
||||||
|
// https://github.com/AlexxIT/go2rtc/issues/244
|
||||||
|
uri := req.URL.String()
|
||||||
h2 := HexMD5(req.Method, uri)
|
h2 := HexMD5(req.Method, uri)
|
||||||
response := HexMD5(a.h1nonce, h2)
|
response := HexMD5(a.h1nonce, h2)
|
||||||
header := a.header + fmt.Sprintf(
|
header := a.header + fmt.Sprintf(
|
||||||
|
Reference in New Issue
Block a user