public static class UrlQuerySanitizer.IllegalCharacterValueSanitizer extends Object implements UrlQuerySanitizer.ValueSanitizer
Modifier and Type | Field and Description |
---|---|
static int |
ALL_BUT_NUL_AND_ANGLE_BRACKETS_LEGAL
Allow all but.
|
static int |
ALL_BUT_NUL_LEGAL
Allow all special characters except Nul.
|
static int |
ALL_BUT_WHITESPACE_LEGAL
Allow all special characters except for:
whitespace characters
Nul ('\0')
Allow script URLs.
|
static int |
ALL_ILLEGAL
Deny all special characters.
|
static int |
ALL_OK
Mask with all fields set to OK
|
static int |
ALL_WHITESPACE_OK
Mask with both regular space and other whitespace OK
|
static int |
AMP_AND_SPACE_LEGAL
Allow ampersand.
|
static int |
AMP_LEGAL
Allow ampersand.
|
static int |
AMP_OK
Allow ampersand characters ('&')
|
static int |
DQUOTE_OK
Allow double quote characters.
|
static int |
GT_OK
Allow greater-than characters.
|
static int |
LT_OK
Allow less-than characters.
|
static int |
NON_7_BIT_ASCII_OK
Allow characters with character codes 128 to 255.
|
static int |
NUL_OK
Allow nul characters ('\0')
|
static int |
OTHER_WHITESPACE_OK
Allow whitespace characters other than space.
|
static int |
PCT_OK
Allow percent-sign characters ('%')
|
static int |
SCRIPT_URL_OK
Allow text to start with a script URL
such as "javascript:" or "vbscript:"
|
static int |
SPACE_LEGAL
Allow space.
|
static int |
SPACE_OK
Allow space (' ') characters.
|
static int |
SQUOTE_OK
Allow single quote characters.
|
static int |
URL_AND_SPACE_LEGAL
Allow characters used by encoded URLs.
|
static int |
URL_LEGAL
Allow characters used by encoded URLs.
|
Constructor and Description |
---|
UrlQuerySanitizer.IllegalCharacterValueSanitizer(int flags)
Construct a sanitizer.
|
public static final int SPACE_OK
public static final int OTHER_WHITESPACE_OK
public static final int NON_7_BIT_ASCII_OK
public static final int DQUOTE_OK
public static final int SQUOTE_OK
public static final int LT_OK
public static final int GT_OK
public static final int AMP_OK
public static final int PCT_OK
public static final int NUL_OK
public static final int SCRIPT_URL_OK
public static final int ALL_OK
public static final int ALL_WHITESPACE_OK
public static final int ALL_ILLEGAL
public static final int ALL_BUT_NUL_LEGAL
public static final int ALL_BUT_WHITESPACE_LEGAL
public static final int URL_LEGAL
public static final int URL_AND_SPACE_LEGAL
public static final int AMP_LEGAL
public static final int AMP_AND_SPACE_LEGAL
public static final int SPACE_LEGAL
public static final int ALL_BUT_NUL_AND_ANGLE_BRACKETS_LEGAL
public UrlQuerySanitizer.IllegalCharacterValueSanitizer(int flags)
flags
- some combination of the XXX_OK flags.public String sanitize(String value)
sanitize
in interface UrlQuerySanitizer.ValueSanitizer
value
-