Examples of RealmException


Examples of org.butor.realm.RealmException

   * @throws RealmException if password reset fail.
   */
  public boolean resetPassword(String username_) throws RealmException {
 
    if (StringUtil.isEmpty(username_)) {
      throw new RealmException("Missing username arg!");
    }
   
    Properties props = _realmService.getUserProfile(username_);
    if (props == null) {
      throw new RealmException(String.format("Cannot find user (%s)!", username_));
    }

    String email = props.getProperty(RealmConstants.EMAIL);
    if (StringUtil.isEmpty(email)) {
      throw new RealmException("User's email is not defined!");
    }

    String newPassword = Long.toString(System.currentTimeMillis());
    if (!_realmService.resetPassword(username_, newPassword, null)) {
      return false;
View Full Code Here

Examples of org.butor.realm.RealmException

      throw new IllegalArgumentException("Last name must be defined.");
    }
  }
  public String authenticate(String id_, String pwd_) throws RealmException {
    if (_ssoManager == null)
      throw new RealmException("SSO Manager was not set!");
   
    if (!_realmService.authenticate(id_, pwd_)) {
      return null;
    }
   
View Full Code Here

Examples of org.butor.realm.RealmException

    return ssi.getSsoId();
  }
  public boolean logout(String ssoId_) throws RealmException {
    if (_ssoManager == null)
      throw new RealmException("SSO Manager was not set!");

    SSOInfo ss = _ssoManager.destroySSOSession(ssoId_);

    return ss != null;
  }
View Full Code Here

Examples of org.butor.realm.RealmException

    return ss != null;
  }
  public boolean changePassword(String id_, String pwd_, String newPwd_) throws RealmException {
    if (_ssoManager == null)
      throw new RealmException("SSO Manager was not set!");

    if (_realmService.changePassword(id_, pwd_, newPwd_)) {
      return true;
    }
View Full Code Here

Examples of org.butor.realm.RealmException

    return false;
  }

  public boolean checkSso(String ssoId_) throws RealmException {
    if (_ssoManager == null)
      throw new RealmException("SSO Manager was not set!");

    SSOInfo ss = _ssoManager.getSSOSession(ssoId_);
    return ss != null;
  }
View Full Code Here

Examples of org.butor.realm.RealmException

    SSOInfo ss = _ssoManager.getSSOSession(ssoId_);
    return ss != null;
  }
  public SSOInfo getSsoSession(String ssoId_) throws RealmException {
    if (_ssoManager == null)
      throw new RealmException("SSO Manager was not set!");

    return _ssoManager.getSSOSession(ssoId_);
  }
View Full Code Here

Examples of sun.security.krb5.RealmException

            index -= 4;
        }

        // if index is negative, the keytab format must be wrong.
        if (index < 0) {
            throw new RealmException("Keytab is corrupted");
        }

        // ignore the left bytes.
        skip(index);
View Full Code Here

Examples of sun.security.krb5.RealmException

            }
            i++;
        }
        if (result != null) {
            if (result.length() == 0)
                throw new RealmException(Krb5.REALM_NULL);
            if (!isValidRealmString(result))
                throw new RealmException(Krb5.REALM_ILLCHAR);
        }
        return result;
    }
View Full Code Here

Examples of sun.security.krb5.RealmException

    protected static String parseRealm(String name) throws RealmException {
        String result = parseRealmAtSeparator(name);
        if (result == null)
            result = name;
        if (result == null || result.length() == 0)
            throw new RealmException(Krb5.REALM_NULL);
        if (!isValidRealmString(result))
            throw new RealmException(Krb5.REALM_ILLCHAR);
        return result;
    }
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.