Azure auth functionality.
import fun.mike.azure.auth.Authenticator;
import fun.mike.azure.auth.AuthenticationResult;
final String tenantId = "c834c34e-bbd3-4ea1-c2c2-51daeff91aa32";
final String clientId = "ae33c32e-d2f2-4992-a4b2-51d03e7c8677"
final String header = "Authorization eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJzdWIiOiIxMjM0NTY3ODkwIiwibmFtZSI6IkpvaG4gRG9lIiwiaWF0IjoxNTE2MjM5MDIyfQ.XbPfbIHMI6arZ3Y922BhjWgQzWXcXNrz0ogtVhfEd2o";
String header = ctx.getHeaderString(HttpHeaders.AUTHORIZATION);
Authenticator authenticator = AuthenticatorFactory.build(tenantId, clientId);
AuthenticationResult result = authenticator.authenticate(header);
result.valid()
=> true
result.getClaims()
=> {sub=1234567890, name=John Doe, iat=1516239022} (java.util.Map<String, Object>)
This project is licensed under the terms of the Apache 2.0 license.