How to decode x-amz-meta-file-acl

0

When using an SMB file share on S3 File Gateway, the file level ACLs at the windows as stored as object meta data on s3. What format is this attribute being stored as? How can I decode it to a human readable format?

"file-acl" or "x-amz-meta-file-acl"

$ aws s3api head-object --bucket storage-gateway-user1581 --key user1581/filename.xlsx
{
    "AcceptRanges": "bytes",
    "LastModified": "2023-10-25T19:58:22+00:00",
    "ContentLength": 14984,
    "ETag": "\"25b3b9c62nned0fgffat5b28f3b21d6f\"",
    "ContentType": "application/octet-stream",
    "ServerSideEncryption": "AES256",
    "Metadata": {
        "user-agent": "aws-storage-gateway",
        "user-agent-id": "sgw-84178D7XD",
        "aws-sgw": "fe2e0cfb07ecdf5d1c094b26c5630853780877025edfb37f3f2b6c0cf2407694",
        "file-acl": "EQUFFajv2K4G2IvQ7QSHyu/ZAtHUGgUFFajv2F6G2IvQ7QSHyu/ZAoEEjAQDAACQqQUFFajv2K4G2IvQ7QSHyu/ZAtb4xAYAAJCpBAAVqO/YrgbYi9DtBIfK79kCs9WIBgAQ+f8BGQA=",
        "file-ctime": "1698263901160000000ns",
        "file-dosattr": "32",
        "file-owner": "503483",
        "file-permissions": "0777",
        "file-group": "67179",
        "file-mtime": "1696618082735595800ns"
    }
}

Ashok M
asked 6 months ago444 views
1 Answer
0

The ACLs are encoded for use by the storage gateway only and are required to keep the gateway working correctly. You should not modify these fields outside the gateway.

AWS
answered 6 months ago
  • I have data in S3 bucket and I want to now present is as SMB share(using file gateway). We know which ACLs to apply to specific files before they are accessed via file gateway. Knowing how to decode will help me apply the permissions by updating object metadata(even before they are presented via file gateway) rather than mounting the smb fileshare on a different server, then apply ACLs and then re-share to end users.

You are not logged in. Log in to post an answer.

A good answer clearly answers the question and provides constructive feedback and encourages professional growth in the question asker.

Guidelines for Answering Questions