lib/httpx/plugins/auth/digest.rb in httpx-1.2.3 vs lib/httpx/plugins/auth/digest.rb in httpx-1.2.4
- old
+ new
@@ -28,10 +28,11 @@
def generate_header(meth, uri, authenticate)
# discard first token, it's Digest
auth_info = authenticate[/^(\w+) (.*)/, 2]
params = auth_info.split(/ *, */)
- .to_h { |val| val.split("=") }.transform_values { |v| v.delete("\"") }
+ .to_h { |val| val.split("=", 2) }
+ .transform_values { |v| v.delete("\"") }
nonce = params["nonce"]
nc = next_nonce
# verify qop
qop = params["qop"]