@Test(groups = INTEGRATION) public void testBearerTokenFilter() throws Exception { mockLogin(); ClientRequestContext context = stubRequestContext(); auth.filter(context); assert context.getHeaders().get("Authorization") != null; }
@Override public void filter(ClientRequestContext requestContext) throws IOException { requestSessionCredentialsIfNeeded(); requestContext .getHeaders() .putSingle(AUTHORIZATION, session.getToken().toHeaderString()); }
BearerAuthentication implements ClientRequestFilter { @Override public void filter(ClientRequestContext requestContext) throws IOException { requestSessionCredentialsIfNeeded(); requestContext .getHeaders() .putSingle(AUTHORIZATION, session.getToken().toHeaderString()); } }
BearerAuthentication implements ClientRequestFilter { @Override public void filter(ClientRequestContext requestContext) throws IOException { requestSessionCredentialsIfNeeded(); requestContext .getHeaders() .putSingle(AUTHORIZATION, session.getToken().toHeaderString()); } BearerAuthentication(CredentialsProvider credentialsProvider, LoginClient client); }
BearerAuthentication implements ClientRequestFilter { @Override public void filter(ClientRequestContext requestContext) throws IOException { requestSessionCredentialsIfNeeded(); requestContext .getHeaders() .putSingle(AUTHORIZATION, session.getToken().toHeaderString()); } BearerAuthentication(CredentialsProvider credentialsProvider, LoginClient client); LoginClient getLoginClient(); @Override void filter(ClientRequestContext requestContext); String getAccountAlias(); }
BearerAuthentication implements ClientRequestFilter { @Override public void filter(ClientRequestContext requestContext) throws IOException { requestSessionCredentialsIfNeeded(); requestContext .getHeaders() .putSingle(AUTHORIZATION, session.getToken().toHeaderString()); } BearerAuthentication(CredentialsProvider credentialsProvider, LoginClient client); LoginClient getLoginClient(); @Override void filter(ClientRequestContext requestContext); String getAccountAlias();  }