Skip to content

Commit

Permalink
Rename method to indicate non-deprecated usage
Browse files Browse the repository at this point in the history
  • Loading branch information
wendigo committed Jan 12, 2024
1 parent d51e3e2 commit 5649d31
Showing 1 changed file with 3 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -99,7 +99,7 @@ public AppConfigurationEntry[] getAppConfigurationEntry(String name)
loginContext.login();

GSSName gssName = config.getNameType().getGSSName(gssManager, config.getServiceName(), hostname);
serverCredential = doAs(loginContext.getSubject(), () -> gssManager.createCredential(
serverCredential = callAs(loginContext.getSubject(), () -> gssManager.createCredential(
gssName,
INDEFINITE_LIFETIME,
new Oid[] {
Expand Down Expand Up @@ -166,7 +166,7 @@ public Identity authenticate(ContainerRequestContext request)

private Optional<Principal> authenticate(String token)
{
GSSContext context = doAs(loginContext.getSubject(), () -> gssManager.createContext(serverCredential));
GSSContext context = callAs(loginContext.getSubject(), () -> gssManager.createContext(serverCredential));

try {
byte[] inputToken = Base64.getDecoder().decode(token);
Expand Down Expand Up @@ -201,7 +201,7 @@ T get()
throws GSSException;
}

private static <T> T doAs(Subject subject, GssSupplier<T> action)
private static <T> T callAs(Subject subject, GssSupplier<T> action)
{
return Subject.callAs(subject, () -> {
try {
Expand Down

0 comments on commit 5649d31

Please sign in to comment.