[ 
https://issues.apache.org/jira/browse/HADOOP-16482?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16897499#comment-16897499
 ] 

Steve Loughran commented on HADOOP-16482:
-----------------------------------------

Shows up on trunk now my cloudstore JAR has just added a {{filestatus}} command 
and I tried it with two paths, one referencing a bucket which doesn't exist

{code}
 bin/hadoop jar  cloudstore-0.1-SNAPSHOT.jar \
            filestatus \
            s3a://guarded-table/example s3a://guarded-example2/example
2019-07-31 21:17:15,372 [main] INFO  commands.PrintStatus 
(DurationInfo.java:<init>(53)) - Starting: get path status
s3a://guarded-table/example     S3AFileStatus{path=s3a://guarded-table/example; 
isDirectory=false; length=0; replication=1; blocksize=33554432; 
modification_time=1564602680000; access_time=0; owner=stevel; group=stevel; 
permission=rw-rw-rw-; isSymlink=false; hasAcl=false; isEncrypted=true; 
isErasureCoded=false} isEmptyDirectory=FALSE 
eTag=d41d8cd98f00b204e9800998ecf8427e versionId=null
s3a://guarded-example2/example  
S3AFileStatus{path=s3a://guarded-example2/example; isDirectory=false; length=0; 
replication=1; blocksize=33554432; modification_time=1564602680000; 
access_time=0; owner=stevel; group=stevel; permission=rw-rw-rw-; 
isSymlink=false; hasAcl=false; isEncrypted=true; isErasureCoded=false} 
isEmptyDirectory=FALSE eTag=d41d8cd98f00b204e9800998ecf8427e versionId=null
2019-07-31 21:17:17,234 [main] INFO  commands.PrintStatus 
(DurationInfo.java:close(100)) - get path status: duration 0:01:863

Retrieved the status of 2 files, 932 milliseconds per file
{code}

> S3A doesn't actually verify paths have the correct authority
> ------------------------------------------------------------
>
>                 Key: HADOOP-16482
>                 URL: https://issues.apache.org/jira/browse/HADOOP-16482
>             Project: Hadoop Common
>          Issue Type: Sub-task
>          Components: fs/s3
>    Affects Versions: 3.1.0
>            Reporter: Steve Loughran
>            Priority: Major
>
> Probably been around a *long* time, but we've never noticed, assuming that 
> {{Path.makeQualified(uri, workingDir)}} did the right thing.
> You can provide any s3a URI to an S3 command and it'll get mapped to the 
> current bucket without any validation that the authorities are equal. Oops.



--
This message was sent by Atlassian JIRA
(v7.6.14#76016)

---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to