Package io.undertow.util
Class Headers
- java.lang.Object
-
- io.undertow.util.Headers
-
public final class Headers extends Object
NOTE: if you add a new header here you must also add it toHttpRequestParser
- Author:
- David M. Lloyd
-
-
Field Summary
-
Method Summary
All Methods Static Methods Concrete Methods Deprecated Methods Modifier and Type Method Description static String
extractQuotedValueFromHeader(String header, String key)
Extracts a quoted value from a header that has a given key.static String
extractQuotedValueFromHeaderWithEncoding(String header, String key)
Extracts a quoted value from a header that has a given key.static String
extractTokenFromHeader(String header, String key)
Deprecated.static HttpString
fromCache(String string)
-
-
-
Field Detail
-
ACCEPT_STRING
public static final String ACCEPT_STRING
- See Also:
- Constant Field Values
-
ACCEPT_CHARSET_STRING
public static final String ACCEPT_CHARSET_STRING
- See Also:
- Constant Field Values
-
ACCEPT_ENCODING_STRING
public static final String ACCEPT_ENCODING_STRING
- See Also:
- Constant Field Values
-
ACCEPT_LANGUAGE_STRING
public static final String ACCEPT_LANGUAGE_STRING
- See Also:
- Constant Field Values
-
ACCEPT_RANGES_STRING
public static final String ACCEPT_RANGES_STRING
- See Also:
- Constant Field Values
-
AGE_STRING
public static final String AGE_STRING
- See Also:
- Constant Field Values
-
ALLOW_STRING
public static final String ALLOW_STRING
- See Also:
- Constant Field Values
-
AUTHENTICATION_INFO_STRING
public static final String AUTHENTICATION_INFO_STRING
- See Also:
- Constant Field Values
-
AUTHORIZATION_STRING
public static final String AUTHORIZATION_STRING
- See Also:
- Constant Field Values
-
CACHE_CONTROL_STRING
public static final String CACHE_CONTROL_STRING
- See Also:
- Constant Field Values
-
COOKIE_STRING
public static final String COOKIE_STRING
- See Also:
- Constant Field Values
-
COOKIE2_STRING
public static final String COOKIE2_STRING
- See Also:
- Constant Field Values
-
CONNECTION_STRING
public static final String CONNECTION_STRING
- See Also:
- Constant Field Values
-
CONTENT_DISPOSITION_STRING
public static final String CONTENT_DISPOSITION_STRING
- See Also:
- Constant Field Values
-
CONTENT_ENCODING_STRING
public static final String CONTENT_ENCODING_STRING
- See Also:
- Constant Field Values
-
CONTENT_LANGUAGE_STRING
public static final String CONTENT_LANGUAGE_STRING
- See Also:
- Constant Field Values
-
CONTENT_LENGTH_STRING
public static final String CONTENT_LENGTH_STRING
- See Also:
- Constant Field Values
-
CONTENT_LOCATION_STRING
public static final String CONTENT_LOCATION_STRING
- See Also:
- Constant Field Values
-
CONTENT_MD5_STRING
public static final String CONTENT_MD5_STRING
- See Also:
- Constant Field Values
-
CONTENT_RANGE_STRING
public static final String CONTENT_RANGE_STRING
- See Also:
- Constant Field Values
-
CONTENT_SECURITY_POLICY_STRING
public static final String CONTENT_SECURITY_POLICY_STRING
- See Also:
- Constant Field Values
-
CONTENT_TYPE_STRING
public static final String CONTENT_TYPE_STRING
- See Also:
- Constant Field Values
-
DATE_STRING
public static final String DATE_STRING
- See Also:
- Constant Field Values
-
ETAG_STRING
public static final String ETAG_STRING
- See Also:
- Constant Field Values
-
EXPECT_STRING
public static final String EXPECT_STRING
- See Also:
- Constant Field Values
-
EXPIRES_STRING
public static final String EXPIRES_STRING
- See Also:
- Constant Field Values
-
FORWARDED_STRING
public static final String FORWARDED_STRING
- See Also:
- Constant Field Values
-
FROM_STRING
public static final String FROM_STRING
- See Also:
- Constant Field Values
-
HOST_STRING
public static final String HOST_STRING
- See Also:
- Constant Field Values
-
IF_MATCH_STRING
public static final String IF_MATCH_STRING
- See Also:
- Constant Field Values
-
IF_MODIFIED_SINCE_STRING
public static final String IF_MODIFIED_SINCE_STRING
- See Also:
- Constant Field Values
-
IF_NONE_MATCH_STRING
public static final String IF_NONE_MATCH_STRING
- See Also:
- Constant Field Values
-
IF_RANGE_STRING
public static final String IF_RANGE_STRING
- See Also:
- Constant Field Values
-
IF_UNMODIFIED_SINCE_STRING
public static final String IF_UNMODIFIED_SINCE_STRING
- See Also:
- Constant Field Values
-
LAST_MODIFIED_STRING
public static final String LAST_MODIFIED_STRING
- See Also:
- Constant Field Values
-
LOCATION_STRING
public static final String LOCATION_STRING
- See Also:
- Constant Field Values
-
MAX_FORWARDS_STRING
public static final String MAX_FORWARDS_STRING
- See Also:
- Constant Field Values
-
ORIGIN_STRING
public static final String ORIGIN_STRING
- See Also:
- Constant Field Values
-
PRAGMA_STRING
public static final String PRAGMA_STRING
- See Also:
- Constant Field Values
-
PROXY_AUTHENTICATE_STRING
public static final String PROXY_AUTHENTICATE_STRING
- See Also:
- Constant Field Values
-
PROXY_AUTHORIZATION_STRING
public static final String PROXY_AUTHORIZATION_STRING
- See Also:
- Constant Field Values
-
RANGE_STRING
public static final String RANGE_STRING
- See Also:
- Constant Field Values
-
REFERER_STRING
public static final String REFERER_STRING
- See Also:
- Constant Field Values
-
REFERRER_POLICY_STRING
public static final String REFERRER_POLICY_STRING
- See Also:
- Constant Field Values
-
REFRESH_STRING
public static final String REFRESH_STRING
- See Also:
- Constant Field Values
-
RETRY_AFTER_STRING
public static final String RETRY_AFTER_STRING
- See Also:
- Constant Field Values
-
SEC_WEB_SOCKET_ACCEPT_STRING
public static final String SEC_WEB_SOCKET_ACCEPT_STRING
- See Also:
- Constant Field Values
-
SEC_WEB_SOCKET_EXTENSIONS_STRING
public static final String SEC_WEB_SOCKET_EXTENSIONS_STRING
- See Also:
- Constant Field Values
-
SEC_WEB_SOCKET_KEY_STRING
public static final String SEC_WEB_SOCKET_KEY_STRING
- See Also:
- Constant Field Values
-
SEC_WEB_SOCKET_KEY1_STRING
public static final String SEC_WEB_SOCKET_KEY1_STRING
- See Also:
- Constant Field Values
-
SEC_WEB_SOCKET_KEY2_STRING
public static final String SEC_WEB_SOCKET_KEY2_STRING
- See Also:
- Constant Field Values
-
SEC_WEB_SOCKET_LOCATION_STRING
public static final String SEC_WEB_SOCKET_LOCATION_STRING
- See Also:
- Constant Field Values
-
SEC_WEB_SOCKET_ORIGIN_STRING
public static final String SEC_WEB_SOCKET_ORIGIN_STRING
- See Also:
- Constant Field Values
-
SEC_WEB_SOCKET_PROTOCOL_STRING
public static final String SEC_WEB_SOCKET_PROTOCOL_STRING
- See Also:
- Constant Field Values
-
SEC_WEB_SOCKET_VERSION_STRING
public static final String SEC_WEB_SOCKET_VERSION_STRING
- See Also:
- Constant Field Values
-
SERVER_STRING
public static final String SERVER_STRING
- See Also:
- Constant Field Values
-
SERVLET_ENGINE_STRING
public static final String SERVLET_ENGINE_STRING
- See Also:
- Constant Field Values
-
SET_COOKIE_STRING
public static final String SET_COOKIE_STRING
- See Also:
- Constant Field Values
-
SET_COOKIE2_STRING
public static final String SET_COOKIE2_STRING
- See Also:
- Constant Field Values
-
SSL_CLIENT_CERT_STRING
public static final String SSL_CLIENT_CERT_STRING
- See Also:
- Constant Field Values
-
SSL_CIPHER_STRING
public static final String SSL_CIPHER_STRING
- See Also:
- Constant Field Values
-
SSL_SESSION_ID_STRING
public static final String SSL_SESSION_ID_STRING
- See Also:
- Constant Field Values
-
SSL_CIPHER_USEKEYSIZE_STRING
public static final String SSL_CIPHER_USEKEYSIZE_STRING
- See Also:
- Constant Field Values
-
STATUS_STRING
public static final String STATUS_STRING
- See Also:
- Constant Field Values
-
STRICT_TRANSPORT_SECURITY_STRING
public static final String STRICT_TRANSPORT_SECURITY_STRING
- See Also:
- Constant Field Values
-
TE_STRING
public static final String TE_STRING
- See Also:
- Constant Field Values
-
TRAILER_STRING
public static final String TRAILER_STRING
- See Also:
- Constant Field Values
-
TRANSFER_ENCODING_STRING
public static final String TRANSFER_ENCODING_STRING
- See Also:
- Constant Field Values
-
UPGRADE_STRING
public static final String UPGRADE_STRING
- See Also:
- Constant Field Values
-
USER_AGENT_STRING
public static final String USER_AGENT_STRING
- See Also:
- Constant Field Values
-
VARY_STRING
public static final String VARY_STRING
- See Also:
- Constant Field Values
-
VIA_STRING
public static final String VIA_STRING
- See Also:
- Constant Field Values
-
WARNING_STRING
public static final String WARNING_STRING
- See Also:
- Constant Field Values
-
WWW_AUTHENTICATE_STRING
public static final String WWW_AUTHENTICATE_STRING
- See Also:
- Constant Field Values
-
X_CONTENT_TYPE_OPTIONS_STRING
public static final String X_CONTENT_TYPE_OPTIONS_STRING
- See Also:
- Constant Field Values
-
X_DISABLE_PUSH_STRING
public static final String X_DISABLE_PUSH_STRING
- See Also:
- Constant Field Values
-
X_FORWARDED_FOR_STRING
public static final String X_FORWARDED_FOR_STRING
- See Also:
- Constant Field Values
-
X_FORWARDED_PROTO_STRING
public static final String X_FORWARDED_PROTO_STRING
- See Also:
- Constant Field Values
-
X_FORWARDED_HOST_STRING
public static final String X_FORWARDED_HOST_STRING
- See Also:
- Constant Field Values
-
X_FORWARDED_PORT_STRING
public static final String X_FORWARDED_PORT_STRING
- See Also:
- Constant Field Values
-
X_FORWARDED_SERVER_STRING
public static final String X_FORWARDED_SERVER_STRING
- See Also:
- Constant Field Values
-
X_FRAME_OPTIONS_STRING
public static final String X_FRAME_OPTIONS_STRING
- See Also:
- Constant Field Values
-
X_XSS_PROTECTION_STRING
public static final String X_XSS_PROTECTION_STRING
- See Also:
- Constant Field Values
-
ACCEPT
public static final HttpString ACCEPT
-
ACCEPT_CHARSET
public static final HttpString ACCEPT_CHARSET
-
ACCEPT_ENCODING
public static final HttpString ACCEPT_ENCODING
-
ACCEPT_LANGUAGE
public static final HttpString ACCEPT_LANGUAGE
-
ACCEPT_RANGES
public static final HttpString ACCEPT_RANGES
-
AGE
public static final HttpString AGE
-
ALLOW
public static final HttpString ALLOW
-
AUTHENTICATION_INFO
public static final HttpString AUTHENTICATION_INFO
-
AUTHORIZATION
public static final HttpString AUTHORIZATION
-
CACHE_CONTROL
public static final HttpString CACHE_CONTROL
-
CONNECTION
public static final HttpString CONNECTION
-
CONTENT_DISPOSITION
public static final HttpString CONTENT_DISPOSITION
-
CONTENT_ENCODING
public static final HttpString CONTENT_ENCODING
-
CONTENT_LANGUAGE
public static final HttpString CONTENT_LANGUAGE
-
CONTENT_LENGTH
public static final HttpString CONTENT_LENGTH
-
CONTENT_LOCATION
public static final HttpString CONTENT_LOCATION
-
CONTENT_MD5
public static final HttpString CONTENT_MD5
-
CONTENT_RANGE
public static final HttpString CONTENT_RANGE
-
CONTENT_SECURITY_POLICY
public static final HttpString CONTENT_SECURITY_POLICY
-
CONTENT_TYPE
public static final HttpString CONTENT_TYPE
-
COOKIE
public static final HttpString COOKIE
-
COOKIE2
public static final HttpString COOKIE2
-
DATE
public static final HttpString DATE
-
ETAG
public static final HttpString ETAG
-
EXPECT
public static final HttpString EXPECT
-
EXPIRES
public static final HttpString EXPIRES
-
FORWARDED
public static final HttpString FORWARDED
-
FROM
public static final HttpString FROM
-
HOST
public static final HttpString HOST
-
IF_MATCH
public static final HttpString IF_MATCH
-
IF_MODIFIED_SINCE
public static final HttpString IF_MODIFIED_SINCE
-
IF_NONE_MATCH
public static final HttpString IF_NONE_MATCH
-
IF_RANGE
public static final HttpString IF_RANGE
-
IF_UNMODIFIED_SINCE
public static final HttpString IF_UNMODIFIED_SINCE
-
LAST_MODIFIED
public static final HttpString LAST_MODIFIED
-
LOCATION
public static final HttpString LOCATION
-
MAX_FORWARDS
public static final HttpString MAX_FORWARDS
-
ORIGIN
public static final HttpString ORIGIN
-
PRAGMA
public static final HttpString PRAGMA
-
PROXY_AUTHENTICATE
public static final HttpString PROXY_AUTHENTICATE
-
PROXY_AUTHORIZATION
public static final HttpString PROXY_AUTHORIZATION
-
RANGE
public static final HttpString RANGE
-
REFERER
public static final HttpString REFERER
-
REFERRER_POLICY
public static final HttpString REFERRER_POLICY
-
REFRESH
public static final HttpString REFRESH
-
RETRY_AFTER
public static final HttpString RETRY_AFTER
-
SEC_WEB_SOCKET_ACCEPT
public static final HttpString SEC_WEB_SOCKET_ACCEPT
-
SEC_WEB_SOCKET_EXTENSIONS
public static final HttpString SEC_WEB_SOCKET_EXTENSIONS
-
SEC_WEB_SOCKET_KEY
public static final HttpString SEC_WEB_SOCKET_KEY
-
SEC_WEB_SOCKET_KEY1
public static final HttpString SEC_WEB_SOCKET_KEY1
-
SEC_WEB_SOCKET_KEY2
public static final HttpString SEC_WEB_SOCKET_KEY2
-
SEC_WEB_SOCKET_LOCATION
public static final HttpString SEC_WEB_SOCKET_LOCATION
-
SEC_WEB_SOCKET_ORIGIN
public static final HttpString SEC_WEB_SOCKET_ORIGIN
-
SEC_WEB_SOCKET_PROTOCOL
public static final HttpString SEC_WEB_SOCKET_PROTOCOL
-
SEC_WEB_SOCKET_VERSION
public static final HttpString SEC_WEB_SOCKET_VERSION
-
SERVER
public static final HttpString SERVER
-
SERVLET_ENGINE
public static final HttpString SERVLET_ENGINE
-
SET_COOKIE
public static final HttpString SET_COOKIE
-
SET_COOKIE2
public static final HttpString SET_COOKIE2
-
SSL_CIPHER
public static final HttpString SSL_CIPHER
-
SSL_CIPHER_USEKEYSIZE
public static final HttpString SSL_CIPHER_USEKEYSIZE
-
SSL_CLIENT_CERT
public static final HttpString SSL_CLIENT_CERT
-
SSL_SESSION_ID
public static final HttpString SSL_SESSION_ID
-
STATUS
public static final HttpString STATUS
-
STRICT_TRANSPORT_SECURITY
public static final HttpString STRICT_TRANSPORT_SECURITY
-
TE
public static final HttpString TE
-
TRAILER
public static final HttpString TRAILER
-
TRANSFER_ENCODING
public static final HttpString TRANSFER_ENCODING
-
UPGRADE
public static final HttpString UPGRADE
-
USER_AGENT
public static final HttpString USER_AGENT
-
VARY
public static final HttpString VARY
-
VIA
public static final HttpString VIA
-
WARNING
public static final HttpString WARNING
-
WWW_AUTHENTICATE
public static final HttpString WWW_AUTHENTICATE
-
X_CONTENT_TYPE_OPTIONS
public static final HttpString X_CONTENT_TYPE_OPTIONS
-
X_DISABLE_PUSH
public static final HttpString X_DISABLE_PUSH
-
X_FORWARDED_FOR
public static final HttpString X_FORWARDED_FOR
-
X_FORWARDED_HOST
public static final HttpString X_FORWARDED_HOST
-
X_FORWARDED_PORT
public static final HttpString X_FORWARDED_PORT
-
X_FORWARDED_PROTO
public static final HttpString X_FORWARDED_PROTO
-
X_FORWARDED_SERVER
public static final HttpString X_FORWARDED_SERVER
-
X_FRAME_OPTIONS
public static final HttpString X_FRAME_OPTIONS
-
X_XSS_PROTECTION
public static final HttpString X_XSS_PROTECTION
-
COMPRESS
public static final HttpString COMPRESS
-
X_COMPRESS
public static final HttpString X_COMPRESS
-
DEFLATE
public static final HttpString DEFLATE
-
IDENTITY
public static final HttpString IDENTITY
-
GZIP
public static final HttpString GZIP
-
X_GZIP
public static final HttpString X_GZIP
-
CHUNKED
public static final HttpString CHUNKED
-
KEEP_ALIVE
public static final HttpString KEEP_ALIVE
-
CLOSE
public static final HttpString CLOSE
-
CONTENT_TRANSFER_ENCODING_STRING
public static final String CONTENT_TRANSFER_ENCODING_STRING
- See Also:
- Constant Field Values
-
CONTENT_TRANSFER_ENCODING
public static final HttpString CONTENT_TRANSFER_ENCODING
-
BASIC
public static final HttpString BASIC
-
DIGEST
public static final HttpString DIGEST
-
NEGOTIATE
public static final HttpString NEGOTIATE
-
ALGORITHM
public static final HttpString ALGORITHM
-
AUTH_PARAM
public static final HttpString AUTH_PARAM
-
CNONCE
public static final HttpString CNONCE
-
DOMAIN
public static final HttpString DOMAIN
-
NEXT_NONCE
public static final HttpString NEXT_NONCE
-
NONCE
public static final HttpString NONCE
-
NONCE_COUNT
public static final HttpString NONCE_COUNT
-
OPAQUE
public static final HttpString OPAQUE
-
QOP
public static final HttpString QOP
-
REALM
public static final HttpString REALM
-
RESPONSE
public static final HttpString RESPONSE
-
RESPONSE_AUTH
public static final HttpString RESPONSE_AUTH
-
STALE
public static final HttpString STALE
-
URI
public static final HttpString URI
-
USERNAME
public static final HttpString USERNAME
-
-
Method Detail
-
fromCache
public static HttpString fromCache(String string)
-
extractTokenFromHeader
@Deprecated public static String extractTokenFromHeader(String header, String key)
Deprecated.Extracts a token from a header that has a given key. For instance if the header iscontent-type=multipart/form-data boundary=myboundary and the key is boundary the myboundary will be returned.
- Parameters:
header
- The headerkey
- The key that identifies the token to extract- Returns:
- The token, or null if it was not found
-
extractQuotedValueFromHeader
public static String extractQuotedValueFromHeader(String header, String key)
Extracts a quoted value from a header that has a given key. For instance if the header iscontent-disposition=form-data; name="my field" and the key is name then "my field" will be returned without the quotes.
- Parameters:
header
- The headerkey
- The key that identifies the token to extract- Returns:
- The token, or null if it was not found
-
extractQuotedValueFromHeaderWithEncoding
public static String extractQuotedValueFromHeaderWithEncoding(String header, String key)
Extracts a quoted value from a header that has a given key. For instance if the header iscontent-disposition=form-data; filename*="utf-8''test.txt" and the key is filename* then "test.txt" will be returned after extracting character set and language (following RFC 2231) and performing URL decoding to the value using the specified encoding
- Parameters:
header
- The headerkey
- The key that identifies the token to extract- Returns:
- The token, or null if it was not found
-
-