Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

Minor tweaks

darcs-hash:20070403205913-5d7f7-1a97dde96ab1faac90eaa00f547ac4c3fdf51069.gz
  • Loading branch information...
commit cbfe6717e30557e10aa8a68155a2bf022147b7da 1 parent 9191ff3
@tim tim authored
View
3  lib/rack/auth/abstract/handler.rb
@@ -12,6 +12,9 @@ def initialize(app, &authenticator)
@app, @authenticator = app, authenticator
end
+
+ private
+
def unauthorized(www_authenticate = challenge)
return [ 401, { 'WWW-Authenticate' => www_authenticate.to_s }, [] ]
end
View
5 lib/rack/auth/digest/md5.rb
@@ -113,8 +113,9 @@ def A2(auth)
end
def digest(auth, password)
- KD passwords_hashed? ? password : H(A1(auth, password)),
- [ auth.nonce, auth.nc, auth.cnonce, QOP, H(A2(auth)) ] * ':'
+ password_hash = passwords_hashed? ? password : H(A1(auth, password))
+
+ KD(password_hash, [ auth.nonce, auth.nc, auth.cnonce, QOP, H(A2(auth)) ] * ':')
end
end
Please sign in to comment.
Something went wrong with that request. Please try again.