public class CustomEnvironmentLoaderListener extends EnvironmentLoaderListener { @Inject private JpaRealm jpaRealm; @Override protected WebEnvironment createEnvironment(ServletContext pServletContext) { WebEnvironment environment = super.createEnvironment(pServletContext); RealmSecurityManager rsm = (RealmSecurityManager) environment.getSecurityManager(); PasswordService passwordService = new DefaultPasswordService(); PasswordMatcher passwordMatcher = new PasswordMatcher(); passwordMatcher.setPasswordService(passwordService); jpaRealm.setCredentialsMatcher(passwordMatcher); rsm.setRealm(jpaRealm); ((DefaultWebEnvironment) environment).setSecurityManager(rsm); return environment; } }
realm.setCredentialsMatcher(new PasswordMatcher());
PasswordMatcher credentialsMatcher = new PasswordMatcher(); this.setCredentialsMatcher(credentialsMatcher);
public ShiroIniRealm(IniRealm iniRealm) { super(iniRealm); realm.setCredentialsMatcher(new PasswordMatcher()); }
public ShiroIniRealm(IniRealm iniRealm) { super(iniRealm); realm.setCredentialsMatcher(new PasswordMatcher()); }
@Inject public XmlAuthenticatingRealm( @Named( "default" ) ConfigurationManager configuration, PasswordService passwordService) { this.configuration = configuration; this.passwordService = passwordService; PasswordMatcher passwordMatcher = new PasswordMatcher(); passwordMatcher.setPasswordService(this.passwordService); setCredentialsMatcher( passwordMatcher ); }
@Bean(name = "credentialsMatcher") public PasswordMatcher credentialsMatcher() { final PasswordMatcher credentialsMatcher = new PasswordMatcher(); credentialsMatcher.setPasswordService(passwordService()); return credentialsMatcher; }
@Inject public OneAuthorizingRealm(UserManager userManager, CacheManager cacheManager, SettingManager configManager, MembershipManager membershipManager, GroupManager groupManager) { PasswordMatcher passwordMatcher = new PasswordMatcher(); passwordMatcher.setPasswordService(AppLoader.getInstance(PasswordService.class)); setCredentialsMatcher(passwordMatcher); this.userManager = userManager; this.cacheManager = cacheManager; this.configManager = configManager; this.membershipManager = membershipManager; this.groupManager = groupManager; }
public PasswordRealmMixin() { super(); passwordService = new DefaultPasswordService(); PasswordMatcher matcher = new PasswordMatcher(); matcher.setPasswordService( passwordService ); setCredentialsMatcher( matcher ); }
public PasswordRealmMixin() { super(); passwordService = new DefaultPasswordService(); PasswordMatcher matcher = new PasswordMatcher(); matcher.setPasswordService( passwordService ); setCredentialsMatcher( matcher ); }
@Inject public AuthenticatingRealmImpl(final SecurityConfigurationManager configuration, final PasswordService passwordService) { this.configuration = configuration; this.passwordService = passwordService; PasswordMatcher passwordMatcher = new PasswordMatcher(); passwordMatcher.setPasswordService(this.passwordService); setCredentialsMatcher(passwordMatcher); setName(NAME); setAuthenticationCachingEnabled(true); }
protected void setup(HashService hashService, HashFormat hashFormat) { PortofinoPasswordService passwordService = new PortofinoPasswordService(); passwordService.setHashService(hashService); passwordService.setHashFormat(hashFormat); PasswordMatcher passwordMatcher = new PasswordMatcher(); passwordMatcher.setPasswordService(passwordService); setCredentialsMatcher(passwordMatcher); this.passwordService = passwordService; } }
protected void setup(HashService hashService, HashFormat hashFormat) { PortofinoPasswordService passwordService = new PortofinoPasswordService(); passwordService.setHashService(hashService); passwordService.setHashFormat(hashFormat); PasswordMatcher passwordMatcher = new PasswordMatcher(); passwordMatcher.setPasswordService(passwordService); setCredentialsMatcher(passwordMatcher); this.passwordService = passwordService; this.legacyHashing = false; } }
public MyRealmMixin() { super(); passwordService = new DefaultPasswordService(); PasswordMatcher matcher = new PasswordMatcher(); matcher.setPasswordService( passwordService ); setCredentialsMatcher( matcher ); }
public MyRealmMixin() { super(); passwordService = new DefaultPasswordService(); PasswordMatcher matcher = new PasswordMatcher(); matcher.setPasswordService( passwordService ); setCredentialsMatcher( matcher ); }