Package org.apache.hadoop.security.authorize

Examples of org.apache.hadoop.security.authorize.AuthorizationException


 
  @Override
  public void refreshServiceAcl() throws IOException {
    if (!conf.getBoolean(
        CommonConfigurationKeys.HADOOP_SECURITY_AUTHORIZATION, false)) {
      throw new AuthorizationException("Service Level Authorization not enabled!");
    }
    this.interTrackerServer.refreshServiceAcl(conf, new MapReducePolicyProvider());
  }
View Full Code Here


 
  @Override
  public void refreshServiceAcl() throws IOException {
    if (!conf.getBoolean(
            ServiceAuthorizationManager.SERVICE_AUTHORIZATION_CONFIG, false)) {
      throw new AuthorizationException("Service Level Authorization not enabled!");
    }
    SecurityUtil.getPolicy().refresh();
  }
View Full Code Here

    @Override
    public String getDelegationToken(final String owner, final String renewer)
        throws IOException, InterruptedException {
      if (!authenticationMethod.get().equals(AuthenticationMethod.KERBEROS)) {
        throw new AuthorizationException(
            "Delegation Token can be issued only with kerberos authentication. " +
                "Current AuthenticationMethod: " + authenticationMethod.get()
            );
      }
      //if the user asking the token is same as the 'owner' then don't do
View Full Code Here

    }

    @Override
    public long renewDelegationToken(String tokenStrForm) throws IOException {
      if (!authenticationMethod.get().equals(AuthenticationMethod.KERBEROS)) {
        throw new AuthorizationException(
            "Delegation Token can be issued only with kerberos authentication. " +
                "Current AuthenticationMethod: " + authenticationMethod.get()
            );
      }
      return secretManager.renewDelegationToken(tokenStrForm);
View Full Code Here

  }

  @Override
  public void refreshServiceAcl() throws IOException {
    if (!serviceAuthEnabled) {
      throw new AuthorizationException("Service Level Authorization not enabled!");
    }

    ServiceAuthorizationManager.refresh(
      new Configuration(), new HDFSPolicyProvider());
  }
View Full Code Here

 
  @Override
  public void refreshServiceAcl() throws IOException {
    if (!conf.getBoolean(
            ServiceAuthorizationManager.SERVICE_AUTHORIZATION_CONFIG, false)) {
      throw new AuthorizationException("Service Level Authorization not enabled!");
    }
    ServiceAuthorizationManager.refresh(conf, new MapReducePolicyProvider());
  }
View Full Code Here

    if (authorize) {
      Class<?> protocol = null;
      try {
        protocol = getProtocolClass(connection.getProtocol(), getConf());
      } catch (ClassNotFoundException cfne) {
        throw new AuthorizationException("Unknown protocol: " +
                                         connection.getProtocol());
      }
      ServiceAuthorizationManager.authorize(user, protocol, getConf(), addr);
    }
  }
View Full Code Here

    if (authorize) {
      Class<?> protocol = null;
      try {
        protocol = getProtocolClass(connection.getProtocol(), getConf());
      } catch (ClassNotFoundException cfne) {
        throw new AuthorizationException("Unknown protocol: "
            + connection.getProtocol());
      }
      ServiceAuthorizationManager authManager = new ServiceAuthorizationManager();
      authManager.authorize(user, protocol, getConf(), addr);
    }
View Full Code Here

    if (authorize) {
      Class<?> protocol = null;
      try {
        protocol = getProtocolClass(connection.getProtocol(), getConf());
      } catch (ClassNotFoundException cfne) {
        throw new AuthorizationException("Unknown protocol: " +
                                         connection.getProtocol());
      }
      serviceAuthorizationManager.authorize(user, protocol, getConf(), addr);
    }
  }
View Full Code Here

  }

  @Override
  public void refreshServiceAcl() throws IOException {
    if (!serviceAuthEnabled) {
      throw new AuthorizationException("Service Level Authorization not enabled!");
    }

    ServiceAuthorizationManager.refresh(
      new Configuration(), new HDFSPolicyProvider());
  }
View Full Code Here

TOP

Related Classes of org.apache.hadoop.security.authorize.AuthorizationException

Copyright © 2018 www.massapicom. 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.