SinglePortConfidentialityHandler
| Modifier and Type | Field and Description |
|---|---|
| private final ConfidentialPortManager |
| Access | Constructor and Description |
|---|---|
| public | ServletConfidentialityConstraintHandler(final ConfidentialPortManager portManager, final HttpHandler next)
|
| Modifier and Type | Method and Description |
|---|---|
| protected boolean | confidentialityRequired(HttpServerExchange
- The exchange)HttpServerExchange for the request being processed.Overrides io. Use the HttpServerExchange to identify if confidentiality is required. |
| protected URI | getRedirectURI(HttpServerExchange
- The exchange)HttpServerExchange for the request being processed.Overrides io. All sub-classes are required to provide an implementation of this method, using the HttpServerExchange for the current request return the address to use for a redirect should confidentiality be required and the request not be confidential. |
| public void | handleRequest(HttpServerExchange
the HTTP request/response exchange exchange)Overrides io. Implements io. Handle the request. |
| protected boolean | Returns: true if the request is 'sufficiently' confidential, false otherwise.- The exchange)HttpServerExchange for the request being processed.Overrides io. Use the HttpServerExchange supplied to check if this request is already 'sufficiently' confidential. |
| portManager | back to summary |
|---|---|
| private final ConfidentialPortManager portManager | |
| ServletConfidentialityConstraintHandler | back to summary |
|---|---|
| public ServletConfidentialityConstraintHandler(final ConfidentialPortManager portManager, final HttpHandler next) | |
| confidentialityRequired | back to summary |
|---|---|
| protected boolean confidentialityRequired(HttpServerExchange exchange) Overrides io. Doc from io. Use the HttpServerExchange to identify if confidentiality is required. This method currently returns true for all requests, sub-classes can override this to provide a custom check. Todo we should deprecate this and just use a predicate to decide to execute the handler instead
| |
| getRedirectURI | back to summary |
|---|---|
| protected URI getRedirectURI(HttpServerExchange exchange) throws URISyntaxException Overrides io. Doc from io. All sub-classes are required to provide an implementation of this method, using the HttpServerExchange for the current request return the address to use for a redirect should confidentiality be required and the request not be confidential.
| |
| handleRequest | back to summary |
|---|---|
| public void handleRequest(HttpServerExchange exchange) throws Exception Overrides io. Implements io. Doc from io. Handle the request.
| |
| isConfidential | back to summary |
|---|---|
| protected boolean isConfidential(final HttpServerExchange exchange) Overrides io. Use the HttpServerExchange supplied to check if this request is already 'sufficiently' confidential. Here we say 'sufficiently' as sub-classes can override this and maybe even go so far as querying the actual SSLSession.
| |