public io.vertx.rxjava.ext.auth.oauth2.OAuth2Auth rbacHandler(io.vertx.rxjava.ext.auth.oauth2.OAuth2RBAC rbac) { delegate.rbacHandler(rbac.getDelegate()); return this; }
public io.vertx.rxjava.ext.auth.oauth2.OAuth2Auth rbacHandler(io.vertx.rxjava.ext.auth.oauth2.OAuth2RBAC rbac) { delegate.rbacHandler(rbac.getDelegate()); return this; }
/** * Create a OAuth2Auth provider for OpenID Connect Discovery. The discovery will use the default site in the * configuration options and attempt to load the well known descriptor. If a site is provided (for example when * running on a custom instance) that site will be used to do the lookup. * <p> * If the discovered config includes a json web key url, it will be also fetched and the JWKs will be loaded * into the OAuth provider so tokens can be decoded. * * @param vertx the vertx instance * @param config the initial config * @param handler the instantiated Oauth2 provider instance handler */ static void discover(final Vertx vertx, final OAuth2ClientOptions config, final Handler<AsyncResult<OAuth2Auth>> handler) { final OAuth2ClientOptions options = new OAuth2ClientOptions(config); OpenIDConnectAuth.discover(vertx, options, discover -> { // apply the Keycloak RBAC if (discover.succeeded()) { discover.result().rbacHandler(KeycloakRBAC.create(options)); } handler.handle(discover); }); } }
.rbacHandler(KeycloakRBAC.create(options));
.rbacHandler(MicroProfileRBAC.create());