1

我正在使用 OIDC 和 KeyCloak Quarkus 扩展。

目前,我访问令牌信息是这样的:

@Inject org.eclipse.microprofile.jwt.JsonWebToken tokenMicroProfile;
@Inject SecurityIdentity securityIdentity;

我在这些抽象中找不到 issueFor 字段。这似乎有我需要的东西。

@Inject org.keycloak.representations.JsonWebToken tokenKeyCloak;

但注入失败。那么,如何使用 quarkus-oidc 获取信息?

4

1 回答 1

1

你可以做tokenMicroProfile.getClaim("azp")tokenMicroProfile.getClaim(Claims.azp)

于 2021-03-19T10:13:55.647 回答