public static boolean canProxyAs(String userNameToProxyAs, String superUserName, Path superUserKeytabLocation) {
    try {
      loginAndProxyAsUser(userNameToProxyAs, superUserName, superUserKeytabLocation);
    } catch (IOException e) {
      return false;
    }
    return true;
  }
public static boolean canProxyAs ( String userNameToProxyAs , String superUserName , Path superUserKeytabLocation ) { try { loginAndProxyAsUser ( userNameToProxyAs , superUserName , superUserKeytabLocation ) ; } catch ( IOException e ) { return false ; } return true ; }
Returns true if superUserName can proxy as userNameToProxyAs using the specified superUserKeytabLocation, false
otherwise.