Browse files

Be even more careful about our "secure" parsing.

  • Loading branch information...
1 parent b7f1cea commit f33aa76e13b90556e47e5230184d2b4f4595b31f @eric eric committed Mar 23, 2011
Showing with 1 addition and 1 deletion.
  1. +1 −1 lib/rack/ssl.rb
View
2 lib/rack/ssl.rb
@@ -70,7 +70,7 @@ def hsts_headers
def flag_cookies_as_secure!(headers)
if cookies = headers['Set-Cookie']
headers['Set-Cookie'] = cookies.split("\n").map { |cookie|
- if cookie !~ / secure(;|$)/
+ if cookie !~ /; secure(;|$)/
"#{cookie}; secure"
else
cookie

0 comments on commit f33aa76

Please sign in to comment.