<?xml version="1.0" encoding="UTF-8"?><rss xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:atom="http://www.w3.org/2005/Atom" version="2.0" xmlns:cc="http://cyber.law.harvard.edu/rss/creativeCommonsRssModule.html">
    <channel>
        <title><![CDATA[Stories by O.K on Medium]]></title>
        <description><![CDATA[Stories by O.K on Medium]]></description>
        <link>https://medium.com/@orhankutlu?source=rss-71ae60422323------2</link>
        <image>
            <url>https://cdn-images-1.medium.com/fit/c/150/150/1*aD6ISPegC5ZA2Cx8gYiH1Q.png</url>
            <title>Stories by O.K on Medium</title>
            <link>https://medium.com/@orhankutlu?source=rss-71ae60422323------2</link>
        </image>
        <generator>Medium</generator>
        <lastBuildDate>Sat, 05 Dec 2026 17:56:40 GMT</lastBuildDate>
        <atom:link href="https://medium.com/@orhankutlu/feed" rel="self" type="application/rss+xml"/>
        <webMaster><![CDATA[yourfriends@medium.com]]></webMaster>
        <atom:link href="http://medium.superfeedr.com/" rel="hub"/>
        <item>
            <title><![CDATA[How to give “Upload Only” permissions to S3 users using IAM]]></title>
            <link>https://medium.com/@orhankutlu/how-to-give-upload-only-permissions-to-s3-users-using-iam-898be202199?source=rss-71ae60422323------2</link>
            <guid isPermaLink="false">https://medium.com/p/898be202199</guid>
            <category><![CDATA[s3]]></category>
            <category><![CDATA[development]]></category>
            <category><![CDATA[engineering]]></category>
            <category><![CDATA[aws]]></category>
            <dc:creator><![CDATA[O.K]]></dc:creator>
            <pubDate>Thu, 06 Jan 2022 14:59:03 GMT</pubDate>
            <atom:updated>2022-01-06T14:59:03.415Z</atom:updated>
            <content:encoded><![CDATA[<p>We had a use case that we needed to give some of our developers to upload assets to specific S3 buckets and making sure that they can not delete any objects but upload &amp; make the objects public.</p><p><strong>TL;DR</strong> — You can find the final JSON right below this line. The rest of the article just explains the sections in the JSON.</p><p>Final file:</p><pre>{<br>    &quot;Statement&quot;: [<br>        {<br>            &quot;Action&quot;: [<br>                &quot;s3:DeleteBucket&quot;,<br>                &quot;s3:DeleteBucketPolicy&quot;,<br>                &quot;s3:DeleteBucketWebsite&quot;,<br>                &quot;s3:DeleteObject&quot;,<br>                &quot;s3:DeleteObjectVersion&quot;<br>            ],<br>            &quot;Effect&quot;: &quot;Deny&quot;,<br>            &quot;Resource&quot;: [<br>                &quot;arn:aws:s3:::*&quot;<br>            ],<br>            &quot;Sid&quot;: &quot;DenyDeleteForAnyObject&quot;<br>        },<br>        {<br>            &quot;Action&quot;: [<br>                &quot;s3:ListAllMyBuckets&quot;,<br>                &quot;s3:GetBucketLocation&quot;<br>            ],<br>            &quot;Effect&quot;: &quot;Allow&quot;,<br>            &quot;Resource&quot;: &quot;arn:aws:s3:::*&quot;<br>        },<br>        {<br>            &quot;Action&quot;: [<br>                &quot;s3:ListBucket&quot;,<br>                &quot;s3:GetBucketLocation&quot;,<br>                &quot;s3:GetBucketAcl&quot;,<br>                &quot;s3:GetObject&quot;,<br>                &quot;s3:PutObject&quot;,<br>                &quot;s3:GetObjectAcl&quot;,<br>                &quot;s3:PutObjectAcl&quot;<br>            ],<br>            &quot;Effect&quot;: &quot;Allow&quot;,<br>            &quot;Resource&quot;: [<br>                &quot;arn:aws:s3:::my-bucket&quot;,<br>                &quot;arn:aws:s3:::my-bucket/*&quot;<br>            ]<br>        }<br>    ],<br>    &quot;Version&quot;: &quot;2012-10-17&quot;<br>}</pre><h3><strong>Sections in the JSON</strong></h3><p>First of all, we need to make sure that the developers can view the buckets in our account so they can view &amp; go to the specific bucket using AWS console. The permission for that is as following.</p><pre>{<br>    &quot;Action&quot;: [<br>        &quot;s3:ListAllMyBuckets&quot;, // allow listing all buckets<br>        &quot;s3:GetBucketLocation&quot; // allow getting the bucket location<br>    ],<br>    &quot;Effect&quot;: &quot;Allow&quot;,<br>    &quot;Resource&quot;: &quot;arn:aws:s3:::*&quot; // on all s3 resources<br>}</pre><p>The second part is that we need to make sure that they <strong>can’t delete any objects</strong> in the S3 buckets.</p><p><strong>(PS: If you want to disallow deleting objects on the particular buckets you just need to define the resource ARNs)</strong></p><pre>{<br>    &quot;Action&quot;: [<br>        &quot;s3:DeleteBucket&quot;, // disallow deleting bucket<br>        &quot;s3:DeleteBucketPolicy&quot;, // disallow deleting bucket policy<br>        &quot;s3:DeleteBucketWebsite&quot;, // disallow deleting bucket website<br>        &quot;s3:DeleteObject&quot;, // disallow deleting an object<br>        &quot;s3:DeleteObjectVersion&quot; // disallow deleting object version<br>    ],<br>    &quot;Effect&quot;: &quot;Deny&quot;,<br>    &quot;Resource&quot;: [<br>        &quot;arn:aws:s3:::*&quot; // <strong>on all S3 Bucket, you can change it here if you like</strong> <br>    ]<br>}</pre><p>And lastly we give permissions for uploading objects to the bucket we specify:</p><pre>{<br>    &quot;Action&quot;: [<br>        &quot;s3:ListBucket&quot;, // list bucket<br>        &quot;s3:GetBucketLocation&quot;, // get bucket location<br>        &quot;s3:GetBucketAcl&quot;, // get bucket acl<br>        &quot;s3:GetObject&quot;, // get objects in the bucket<br>        &quot;s3:PutObject&quot;, // put object to the bucket<br>        &quot;s3:GetObjectAcl&quot;, // get object ACL<br>        &quot;s3:PutObjectAcl&quot; <strong>// put object ACL - so they can make the object public</strong><br>        <br>    ],<br>    &quot;Effect&quot;: &quot;Allow&quot;,<br>    &quot;Resource&quot;: [<br>        &quot;arn:aws:s3:::my-bucket&quot;, // your bucket ARN<br>        &quot;arn:aws:s3:::my-bucket/*&quot;, // your bucket ARN<br>    ]<br>}</pre><p>Once you have this file, you need create a group on IAM. You can call it something like “AssetUploaderGroup” and assign users to this group.</p><p>I hope it helps!</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=898be202199" width="1" height="1" alt="">]]></content:encoded>
        </item>
    </channel>
</rss>