![JAR search and dependency download from the Maven repository](/logo.png)
com.boozallen.aissemble.security.authorization.AissembleSimpleSecureTokenServiceClient Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of extensions-authzforce Show documentation
Show all versions of extensions-authzforce Show documentation
Authzforce implementation of a Policy Decision Point (PDP)
The newest version!
package com.boozallen.aissemble.security.authorization;
/*-
* #%L
* aiSSEMBLE::Extensions::Security::Authzforce::Extensions::Security::Authzforce
* %%
* Copyright (C) 2021 Booz Allen
* %%
* This software package is licensed under the Booz Allen Public License. All Rights Reserved.
* #L%
*/
import io.jsonwebtoken.Claims;
import io.jsonwebtoken.Jws;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
/**
* Client for authenticating via a simple JWT token.
*/
public class AissembleSimpleSecureTokenServiceClient implements AissembleSecureTokenServiceClient {
static final Logger logger = LoggerFactory.getLogger(AissembleSimpleSecureTokenServiceClient.class);
/**
* {@inheritDoc}
*/
@Override
public String authenticate(String username, String password) {
logger.info("Generating simple jwt token");
return JsonWebTokenUtil.createToken(username, "audience", null);
}
/**
* {@inheritDoc}
*/
@Override public Jws parseToken(String token) {
return JsonWebTokenUtil.parseToken(token);
}
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy