Added decoder for HTML-encoded and URL-encoded passwords and usernames.

This prevents special characters from not being recognized. Reported by P.H.Vos.
Also updated gnulib and added c-strncasecmp
This commit is contained in:
Nikos Mavrogiannopoulos
2013-07-10 15:52:26 +02:00
parent 90c2f89c4d
commit 2af67c4aff
22 changed files with 356 additions and 33 deletions

View File

@@ -39,6 +39,12 @@ echo "Connecting to obtain cookie with wrong username..."
( echo "tost" | openconnect -q localhost:4443 -u tost --servercert=d66b507ae074d03b02eafca40d35f87dd81049d3 --cookieonly >/dev/null 2>&1 ) &&
fail $PID "Received cookie when we shouldn't"
#test special characters
echo "Connecting to obtain cookie..."
( echo "!@#$%^&*()<>" | openconnect -q localhost:4443 -u special --servercert=d66b507ae074d03b02eafca40d35f87dd81049d3 --cookieonly >/dev/null 2>&1 ) ||
fail $PID "Could not receive cookie from server"
#echo "Normal connection..."
#( echo "test" | openconnect -q localhost:4443 -u test --servercert=d66b507ae074d03b02eafca40d35f87dd81049d3 --script=/bin/true ) ||
# fail $PID "Could not connect to server"

View File

@@ -1 +1,2 @@
test:tost:$5$i6SNmLDCgBNjyJ7q$SZ4bVJb7I/DLgXo3txHBVohRFBjOtdbxGQZp.DOnrA.
special:*:$5$kDNrlGibUoktiQ0n$mE/ys1XehvvoWQiSqAfB.Aw1WbAYayMV/ZYTX/6IlkC