use of org.apache.karaf.jaas.config.JaasRealm in project ddf by codice.
the class UsernameTokenValidator method removeRealm.
public void removeRealm(ServiceReference<JaasRealm> serviceReference) {
Bundle bundle = FrameworkUtil.getBundle(UsernameTokenValidator.class);
if (null != bundle) {
JaasRealm realm = bundle.getBundleContext().getService(serviceReference);
LOGGER.trace("Removing validator for JaasRealm {}", realm.getName());
validators.remove(realm.getName());
}
}
use of org.apache.karaf.jaas.config.JaasRealm in project ddf by codice.
the class UsernameTokenValidator method addRealm.
public void addRealm(ServiceReference<JaasRealm> serviceReference) {
Bundle bundle = FrameworkUtil.getBundle(UsernameTokenValidator.class);
if (null != bundle) {
JaasRealm realm = bundle.getBundleContext().getService(serviceReference);
LOGGER.trace("Adding validator for JaasRealm {}", realm.getName());
JAASUsernameTokenValidator validator = new JAASUsernameTokenValidator();
validator.setContextName(realm.getName());
validators.put(realm.getName(), validator);
}
}
use of org.apache.karaf.jaas.config.JaasRealm in project ddf by codice.
the class UPBSTValidator method addRealm.
public void addRealm(ServiceReference<JaasRealm> serviceReference) {
Bundle bundle = FrameworkUtil.getBundle(UPBSTValidator.class);
if (null != bundle) {
JaasRealm realm = bundle.getBundleContext().getService(serviceReference);
LOGGER.trace("Adding validator for JaasRealm {}", realm.getName());
JAASUsernameTokenValidator validator = new JAASUsernameTokenValidator();
validator.setContextName(realm.getName());
validators.put(realm.getName(), validator);
}
}
Aggregations