public abstract class BaseIntegrationTest extends Object
| Modifier and Type | Field and Description |
|---|---|
protected static String |
AUDIENCE |
protected static String |
ISSUER1 |
protected static String |
ISSUER1_EC_KEY_ID |
protected static String |
ISSUER1_ONLY_PRIV_KEY_RSA_KEY_ID |
protected static String |
ISSUER1_RSA_KEY_ID |
protected static String |
ISSUER2 |
protected static String |
ISSUER2_RSA_KEY_ID |
protected static KeyProvider<PublicKey> |
PUBLIC_KEY_PROVIDER |
protected static String |
RESOURCE |
protected static String |
UNAUTHORIZED_SUBJECT |
| Constructor and Description |
|---|
BaseIntegrationTest() |
| Modifier and Type | Method and Description |
|---|---|
protected abstract URI |
getUrlForResourceName(String resourceName) |
void |
shouldAcceptRequestWithValidES256Token()
Verifies that the server accepts requests with a valid token using ES256.
|
void |
shouldAcceptRequestWithValidPS256Token()
Verifies that the server accepts requests with a valid token using PS256.
|
void |
shouldAcceptRequestWithValidRS256Token()
Verifies that the server accepts requests with a valid token using RS256.
|
void |
shouldRejectRequestIfPublicKeyCannotBeFound()
Verifies that the server rejects requests if the public key cannot be found.
|
void |
shouldRejectRequestWithBasicAuth()
Verifies that the server rejects requests that do not have a bearer token.
|
void |
shouldRejectRequestWithMalformedToken()
Verifies that the server rejects requests which have an uparseable token.
|
void |
shouldRejectRequestWithoutAuthenticationHeader()
Verifies that the server rejects requests that lack the authentication header.
|
void |
shouldRejectRequestWithUnauthorizedIssuer()
Verifies that the server rejects requests if the issuer is not authorized.
|
void |
shouldRejectRequestWithUnauthorizedSubject()
Verifies that the server rejects requests if the subject is not authorized.
|
void |
shutdownHttpClient() |
protected static final String AUDIENCE
protected static final String ISSUER1
protected static final String ISSUER2
protected static final String ISSUER1_RSA_KEY_ID
protected static final String ISSUER1_EC_KEY_ID
protected static final String ISSUER1_ONLY_PRIV_KEY_RSA_KEY_ID
protected static final String ISSUER2_RSA_KEY_ID
protected static final KeyProvider<PublicKey> PUBLIC_KEY_PROVIDER
protected static final String RESOURCE
protected static final String UNAUTHORIZED_SUBJECT
public void shutdownHttpClient()
public void shouldRejectRequestWithoutAuthenticationHeader()
throws Exception
Exception - if the test fails to executepublic void shouldRejectRequestWithBasicAuth()
throws Exception
Exception - if the test fails to executepublic void shouldRejectRequestWithMalformedToken()
throws Exception
Exception - if the test fails to executepublic void shouldAcceptRequestWithValidRS256Token()
throws Exception
Exception - if the test fails to executepublic void shouldAcceptRequestWithValidPS256Token()
throws Exception
Exception - if the test fails to executepublic void shouldAcceptRequestWithValidES256Token()
throws Exception
Exception - if the test fails to executepublic void shouldRejectRequestWithUnauthorizedSubject()
throws Exception
Exception - if the test fails to executepublic void shouldRejectRequestIfPublicKeyCannotBeFound()
throws Exception
Exception - if the test fails to executeCopyright © 2017 Atlassian. All rights reserved.