spark-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Brahma Reddy Battula (JIRA)" <>
Subject [jira] [Created] (SPARK-24000) S3A: Create Table should fail on invalid AK/SK
Date Tue, 17 Apr 2018 13:06:00 GMT
Brahma Reddy Battula created SPARK-24000:

             Summary: S3A: Create Table should fail on invalid AK/SK
                 Key: SPARK-24000
             Project: Spark
          Issue Type: Bug
          Components: Spark Shell
    Affects Versions: 2.3.0
            Reporter: Brahma Reddy Battula

Currently, When we pass the i{color:#FF0000}nvalid ak&&sk{color} *create table* will
be the *success*.

when the S3AFileSystem is initialized, *verifyBucketExists*() is called, which will return
*True* as the status code 403 (*_BUCKET_ACCESS_FORBIDDEN_STATUS_CODE)_*  _from following
as bucket exists._
public boolean doesBucketExist(String bucketName)
         throws AmazonClientException, AmazonServiceException {
     try {
         headBucket(new HeadBucketRequest(bucketName));
         return true;
     } catch (AmazonServiceException ase) {
         // A redirect error or a forbidden error means the bucket exists. So
         // returning true.
         if ((ase.getStatusCode() == Constants.BUCKET_REDIRECT_STATUS_CODE)
                 || (ase.getStatusCode() == Constants.BUCKET_ACCESS_FORBIDDEN_STATUS_CODE))
             return true;
         if (ase.getStatusCode() == Constants.NO_SUCH_BUCKET_STATUS_CODE) {
             return false;
         throw ase;

This message was sent by Atlassian JIRA

To unsubscribe, e-mail:
For additional commands, e-mail:

View raw message