Skip to content
Snippets Groups Projects
Commit c6ae7a0d authored by Olav Morken's avatar Olav Morken
Browse files

saml2debug: Don't treat '+' as urlencoded space.

A '+' in the SAMLRequest/Response is more likely to belong to the
base64-encoding than to represent a space.

git-svn-id: https://simplesamlphp.googlecode.com/svn/trunk@1901 44740490-163a-0410-bde0-09ae8108e29a
parent 7facb172
No related branches found
No related tags found
No related merge requests found
...@@ -20,7 +20,7 @@ function getValue($raw) { ...@@ -20,7 +20,7 @@ function getValue($raw) {
if (array_key_exists('LogoutRequest', $arr)) return $arr['LogoutRequest']; if (array_key_exists('LogoutRequest', $arr)) return $arr['LogoutRequest'];
if (array_key_exists('LogoutResponse', $arr)) return $arr['LogoutResponse']; if (array_key_exists('LogoutResponse', $arr)) return $arr['LogoutResponse'];
return urldecode(stripslashes($val)); return rawurldecode(stripslashes($val));
} }
function decode($raw) { function decode($raw) {
...@@ -41,7 +41,7 @@ function encode($message) { ...@@ -41,7 +41,7 @@ function encode($message) {
if ($_REQUEST['binding'] === 'redirect') { if ($_REQUEST['binding'] === 'redirect') {
return urlencode(base64_encode(gzdeflate(stripslashes($message)))); return urlencode(base64_encode(gzdeflate(stripslashes($message))));
} else { } else {
return urlencode(base64_encode(stripslashes($message))); return base64_encode(stripslashes($message));
} }
} }
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment