Java Code Examples for org.apache.shiro.authc.credential.PasswordMatcher#setPasswordService()

The following examples show how to use org.apache.shiro.authc.credential.PasswordMatcher#setPasswordService() . You can vote up the ones you like or vote down the ones you don't like, and go to the original project or source file by following the links above each example. You may check out the related API usage on the sidebar.
Example 1
Source File: PasswordAuthorizingRealm.java    From onedev with MIT License 6 votes vote down vote up
@Inject
  public PasswordAuthorizingRealm(UserManager userManager, SettingManager settingManager, 
  		MembershipManager membershipManager, GroupManager groupManager, 
  		ProjectManager projectManager, SessionManager sessionManager, 
  		TransactionManager transactionManager, SshKeyManager sshKeyManager, 
  		PasswordService passwordService) {
super(userManager, groupManager, projectManager, sessionManager);

   PasswordMatcher passwordMatcher = new PasswordMatcher();
   passwordMatcher.setPasswordService(passwordService);
setCredentialsMatcher(passwordMatcher);

  	this.settingManager = settingManager;
  	this.transactionManager = transactionManager;
  	this.membershipManager = membershipManager;
  	this.sshKeyManager = sshKeyManager;
  }
 
Example 2
Source File: AuthenticatingRealmImpl.java    From nexus-public with Eclipse Public License 1.0 5 votes vote down vote up
@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);
}
 
Example 3
Source File: PasswordRealmMixin.java    From attic-polygene-java with Apache License 2.0 5 votes vote down vote up
public PasswordRealmMixin()
{
    super();
    passwordService = new DefaultPasswordService();
    PasswordMatcher matcher = new PasswordMatcher();
    matcher.setPasswordService( passwordService );
    setCredentialsMatcher( matcher );
}
 
Example 4
Source File: RealmServiceTest.java    From attic-polygene-java with Apache License 2.0 5 votes vote down vote up
public MyRealmMixin()
{
    super();
    passwordService = new DefaultPasswordService();
    PasswordMatcher matcher = new PasswordMatcher();
    matcher.setPasswordService( passwordService );
    setCredentialsMatcher( matcher );
}
 
Example 5
Source File: WebRealmServiceTest.java    From attic-polygene-java with Apache License 2.0 5 votes vote down vote up
public MyRealmMixin()
{
    super();
    passwordService = new DefaultPasswordService();
    PasswordMatcher matcher = new PasswordMatcher();
    matcher.setPasswordService( passwordService );
    setCredentialsMatcher( matcher );
}