Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
12 changes: 10 additions & 2 deletions core/src/main/java/io/undertow/server/Connectors.java
Original file line number Diff line number Diff line change
Expand Up @@ -664,11 +664,19 @@ public static void verifyToken(HttpString header) {
* Returns true if the token character is valid according to rfc7230
*/
public static boolean isValidTokenCharacter(byte c) {
return ALLOWED_TOKEN_CHARACTERS[c];
if (c < 0 || c > ALLOWED_TOKEN_CHARACTERS.length - 1) {
return false;
} else {
return ALLOWED_TOKEN_CHARACTERS[c];
}
}

public static boolean isValidSchemeCharacter(byte c) {
return ALLOWED_SCHEME_CHARACTERS[c];
if (c < 0 || c > ALLOWED_SCHEME_CHARACTERS.length - 1) {
return false;
} else {
return ALLOWED_SCHEME_CHARACTERS[c];
}
}


Expand Down