use of com.hazelcast.security.RealmConfigCallback in project hazelcast by hazelcast.
the class ClientCallbackHandler method handleCallback.
protected void handleCallback(Callback cb) throws UnsupportedCallbackException {
if (cb instanceof RealmConfigCallback) {
RealmConfigCallback realmCb = (RealmConfigCallback) cb;
RealmConfig realmCfg = null;
if (clientConfig != null && clientConfig.getSecurityConfig() != null) {
realmCfg = clientConfig.getSecurityConfig().getRealmConfig(realmCb.getRealmName());
}
realmCb.setRealmConfig(realmCfg);
} else {
throw new UnsupportedCallbackException(cb);
}
}
Aggregations