<?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 Common Fate on Medium]]></title>
        <description><![CDATA[Stories by Common Fate on Medium]]></description>
        <link>https://medium.com/@commonfatetech?source=rss-e4c2681ecd98------2</link>
        <image>
            <url>https://cdn-images-1.medium.com/fit/c/150/150/1*JAgsbRoLNcYUxeTNmAiPbA.jpeg</url>
            <title>Stories by Common Fate on Medium</title>
            <link>https://medium.com/@commonfatetech?source=rss-e4c2681ecd98------2</link>
        </image>
        <generator>Medium</generator>
        <lastBuildDate>Fri, 20 Nov 2026 07:58:12 GMT</lastBuildDate>
        <atom:link href="https://medium.com/@commonfatetech/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[Who Cares About Least Privilege?]]></title>
            <link>https://medium.com/@commonfatetech/who-cares-about-least-privilege-ecf47494d0d6?source=rss-e4c2681ecd98------2</link>
            <guid isPermaLink="false">https://medium.com/p/ecf47494d0d6</guid>
            <category><![CDATA[devops]]></category>
            <category><![CDATA[engineering]]></category>
            <category><![CDATA[security]]></category>
            <category><![CDATA[cybersecurity]]></category>
            <category><![CDATA[cloud-computing]]></category>
            <dc:creator><![CDATA[Common Fate]]></dc:creator>
            <pubDate>Thu, 03 Nov 2022 04:15:21 GMT</pubDate>
            <atom:updated>2022-11-03T04:15:21.767Z</atom:updated>
            <content:encoded><![CDATA[<figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*dK2VZiwB6g1Bj69QZxagCQ.png" /></figure><p><em>Security professionals agree that least privilege is a foundational part of secure design. So then why do so few organizations care about it?</em></p><p>According to most companies that sell security tools, the world is a dangerous place. Hackers are everywhere. They’re crawling around in your EC2 instances, in your employee laptops, in your Gmail inboxes. They’re hiding behind your watercoolers and under your meetings tables and in your breakout booths. Half of your employees are hackers. Hell, your CISO is probably a hacker too — you should fire her and buy more tools.</p><p>Billions of dollars are spent around this issue. State-of-the-art WAFs, AI-assisted endpoint protections, eye-wateringly priced security logging solutions that take entire teams just to set up and manage — and yet almost zero care seems to be directed towards one of the simplest and most cost-effective defenses: least privilege.</p><p>I’d like to state upfront that this won’t be a persuasive article. I have no grand idea to sell you, no concrete answer to this problem that we’re facing. I’m the Developer Advocate for a company that makes least privilege workflow software, which means the bulk of my job is arguing in comment sections about why least privilege even matters. This article, if anything, is a cry for help.</p><p>All I can really do is share the things that we’ve discovered while working in this space, and hope that you’ll share your own insights too. And maybe then we can start thinking about how to solve this thing.</p><p>So then why <em>do</em> so few organizations bother to properly scope employee privilege?</p><h3>Problem 1: They think it’s about trust</h3><p>Imagine, for the sake of argument, that there is a lava pit in the middle of your office. Most of your co-workers are so used to the lava pit that they don’t even notice it’s there, while a few others have actually created entire geothermic systems that require the lava pit to function. Occasionally someone will fall into the lava pit, suffer grievous injuries, and then be sent into lava pit awareness training.</p><p>One day you meet with one of the infrastructure teams to discuss how maybe instead of having lava pit awareness training, we should just get rid of the lava pit. The outrage is immediate: w<em>e’ve always had the lava pit! Too many systems rely on it! Getting rid of the lava pit would mean redesigning the entire floor!</em></p><p>Out of all these objections, one of them seems to stand out the most: <em>but we trust our people to not fall into it.</em></p><p>Of course, it’s a ridiculous argument. No one <em>chooses</em> to fall into the lava pit, just as no one chooses to get phished. But it’s one of the more difficult points to argue against. As an engineer, it’s hard to not feel patronized when your lava pit is taken away. Sure, maybe <em>other</em> people in the company are incompetent goons — but you’d <em>never</em> fall into the pit. You’re too smart for that.</p><p>Accepting least privilege means admitting to yourself that no matter how smart and good at computers you might be, sometimes shit happens — and you are not immune to it. This is a difficult realization for anyone.</p><h3>Problem 2: Move fast, break things</h3><p>No one ever got seed funding for not getting hacked.</p><p>Many growth-focused companies tend to sacrifice security in favor of pushing out their product quicker. The narrative is usually “we’ll make it secure once we’ve actually built it”. The issue is that security debt works just the same way that tech debt does — all these oversights and shortcuts accumulate to eventually make any sort of positive change almost impossible. Giving people sweeping amounts of access results in them creating workflows that rely on that over-privileged access, and as more time passes those processes become more ingrained. Removing people’s access is a hell of a lot harder than just not having given them that access in the first place.</p><p>This is a problem that mostly applies to startups and rapidly scaling companies (large business have no problem putting red tape around every single access request and process — most of their executives probably have KPIs based around doing so).</p><h3>Problem 3: What’s your job again?</h3><p>Implementing least privilege requires actually knowing what all your coworkers do.</p><p>That’s an easy enough thing if you work in an organization where everyone has clearly defined roles and never has to step outside those roles to help someone else or meet a changing requirement. But you don’t work in that organization, because it doesn’t exist and we live in Hell.</p><p>Any good least privilege architecture must assume that people will sometimes need to do things outside their roles. Overly broad permissions are dangerous, while extremely scoped permissions can limit cross-team functionality and kill creativity. It’s not an easy balance to strike, and ultimately this requires a lot of communication between the security team and everyone else — which, let’s face it, is a whole other article.</p><h3>Problem 4: It’s all business, baby</h3><p>This is a section that I hesitate to add, and if it’s included in the final article then it’s only due to the good grace and patience of the people who pay me. But there’s a problem in the business of security: and it’s the <em>business</em> part.</p><p>In an earlier company I worked at, I once met with the CFO to request budget approval for a new security hire. I will never forgot what he told me: “What’s the ROI on security?”</p><p>I could have replied “what’s the ROI on looking both ways when you cross the street?”, but I didn’t. That was a line that came to me months later, when I was still the only security hire and still bitter about the meeting.</p><p>At the time, I thought the CFO was naive and had no business sense. But he was right: there <em>is</em> no ROI on security, only on security optics.</p><p>Good security can save you lots of money years down the line, but businesses don’t work on a timescale of years. They work in quarters. Investors want to see what you’ve achieved in the past three months, and telling them that you’ve become unhackable by buying a machine-learning anti-virus is a hell of a lot more impressive than telling them you’ve taken away Dylan’s root access to all the customer data. The first one lets you show off slides full of cool graphs and mean-looking falcon logos, and the second one gets people asking: why the **** did Dylan have root access to all the customer data?</p><p>The problem, of course, is that buying the cool anti-virus is often a lot cheaper and less problematic than taking away Dylan’s access. So, here we are.</p><h3>Problem 5: Implementation</h3><p>In security, the most interesting (and difficult) problems tend to involve people, not technology. Unfortunately, most least privilege solutions are blatantly anti-people.</p><p>No one wants to fill out a Google document and then figure out who to email it to just to get access to a basic part of their job. No one wants to look at tickets on a kanban board just to figure out who they need to give access to. And no one wants to go through all the IAM roles to discover that the penetration tester from two years ago still has AWS access just because no one remembered to revoke it.</p><p>So that’s why we’ve created <a href="https://commonfate.io/">Common Fate</a>, an open-source developer workflow tool that helps you request and approve specific, timeboxed permissions with just a few clicks.</p><p>What? Did you think we were going to write this whole thing without advertising our product even once? Nah.</p><h3>So what do we do about all this?</h3><p>Honestly? I don’t know. On a more granular level, each of the above problems have their own solution. Talk to your coworkers about how you <em>trust</em> them, you just don’t want to take unnecessary risks. Make sure to do good security design <em>before</em> you need to pay KPMG $25 million to fix it for you. Talk to your coworkers about what their jobs actually are. Check out our <a href="https://github.com/common-fate/granted-approvals">Github repo</a>, etc. etc.</p><p>On a more holistic level, many of these problems are underpinned by a common factor: an organization’s inability or unwillingness to properly map out their structure and commit to designing better permission workflows. The inability part can be solved with a bit of time and strategy — the unwillingness part, not so much.</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=ecf47494d0d6" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Making AWS CLI Use Encrypted Credentials Instead of Plain-Text SSO Tokens]]></title>
            <link>https://medium.com/@commonfatetech/making-aws-cli-use-encrypted-credentials-instead-of-plain-text-sso-tokens-2f2794499145?source=rss-e4c2681ecd98------2</link>
            <guid isPermaLink="false">https://medium.com/p/2f2794499145</guid>
            <category><![CDATA[aws]]></category>
            <category><![CDATA[open-source]]></category>
            <category><![CDATA[security]]></category>
            <category><![CDATA[cloud-security]]></category>
            <dc:creator><![CDATA[Common Fate]]></dc:creator>
            <pubDate>Mon, 03 Oct 2022 04:25:00 GMT</pubDate>
            <atom:updated>2022-10-03T05:35:01.001Z</atom:updated>
            <content:encoded><![CDATA[<figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*QJiQCHZ-Bt9OoV4KHxA3NQ.png" /></figure><p>AWS IAM Identity Center (formally AWS SSO) is the more secure way to connect users and centrally manage their access to multiple AWS accounts. The short-lived credentials that IAM Identity Center provides mean that employees don’t have to store persistent credentials on disk or maintain them by rotating credentials manually. Which is a great alternative to how things were done in AWS IAM!</p><p>What’s <em>not</em> great is that temporary credentials in AWS IAMIC are stored in plain text. 🤦‍♂</p><p>One of the key features in <a href="https://docs.commonfate.io/granted/introduction">Granted CLI</a> is that it encrypts cached credentials to avoid plaintext SSO tokens from being saved on disk. So we’ve rolled out a change that allows you to take advantage of all the cool features of Granted, credential encryption included, <em>while using AWS CLI!</em></p><p>Is it magic? Almost. It’s config settings.</p><p>A cool thing about your <a href="https://docs.aws.amazon.com/cli/latest/userguide/cli-configure-sourcing-external.html">AWS config file</a> is that you can set a credential_process setting to specify that you want credentials to be sourced externally. This allows us to override the default behavior and instead use Granted CLI to securely log into the AWS account, cache the temporary SSO credentials in the keychain, and then return necessary credentials back to the AWS CLI process to authenticate.</p><p>So for example, if you configure credential_process to point to Granted and then run the following command:</p><pre>&gt; aws s3 ls --profile production</pre><p>Instead of AWS CLI getting credentials from a plain text SSO token in the disk, Granted will handle the login flow and return the session credentials as JSON stdout for the AWS process to use in performing the command.</p><p>Essentially, Granted CLI acts like a wrapper on top of the AWS command to do some cool custom checks before returning the correct credentials.</p><h3>How does it work?</h3><p>This change can be made by adding a credential_process setting to your ~/.aws/config file:</p><pre>[profile developer]<br>credential_process = granted credential-process --profile developer</pre><p>Of course, nothing to do with computers is ever that simple. One caveat of adding credential_process to your profile is that your profile can’t have other AWS SSO keys like below:</p><pre>[profile developer]<br>sso_account_id = 123456789012<br>sso_region = us-east-2<br>sso_role_name = AWSAdministrativeAccess<br>sso_start_url = https://example.awsapps.com/start<br>credential_process = granted credential-process --profile developer</pre><p>Doing this will make AWS CLI ignore the credential_process setting and instead use the provided keys to fetch credentials the default way. For us this was a major setback given that Granted needs those other settings to perform SSO logins.</p><p>The solution to this is adding a granted_ prefix to the settings:</p><pre>[profile developer]<br>granted_sso_account_id = 123456789012<br>granted_sso_region = us-east-2<br>granted_sso_role_name = AWSAdministrativeAccess<br>granted_sso_start_url = https://example.awsapps.com/start<br>credential_process = granted credential-process --profile developer</pre><p>Now you can use AWS CLI while encrypting your credentials with Granted! (as an extra bonus, you don’t need to authenticate with AWS SSO a second time anymore)</p><p>We have plans to also support the automatic generation of this using the Granted command. Keep an eye on our release docs! 😉</p><h3>For Granted Approvals users</h3><p>The icing on this cake is for users who use <a href="https://docs.commonfate.io/granted-approvals/introduction">Granted Approvals</a> — our open source automated permissions management framework.</p><p>Previously, Granted Approvals only supported a web UI-driven request flow:</p><ol><li>User logs in to the web app to see the roles they can request</li><li>Makes a request &amp; gets it approved</li><li>Accesses the role</li></ol><p>Which is awesome, if you ask us. However, many engineers prefer to use a CLI-first workflow. For these engineers, we’ve added an extra bit of integration between Granted CLI and Granted Approvals. Now, when they run a command like this:</p><pre>&gt; aws s3 ls —-profile needs-approval</pre><p>If they don’t have the required access yet, they’ll receive a link to their internal Granted Approvals URL where they can then request access for the role!</p><pre>&gt; Error when retrieving credentials from custom-process: You need to <br>  request access to this role:<br>&lt;https://granted.example.com/access?accountId=123456789012&amp;permissionSetArn.label=GrantedAdministratorAccess&amp;type=commonfate%2Faws-sso&gt;<br>operation error SSO: GetRoleCredentials, https response error StatusCode: 403, RequestID: 10000ff-c8fc-4066-9fbf-38c94066aa1c, api error ForbiddenException: No access</pre><p>It saves you a few clicks — but in a world of ClickOps, every click matters.</p><p>You’re welcome, Infrastructure Engineers! Good luck with those support tickets.</p><iframe src="https://cdn.embedly.com/widgets/media.html?src=https%3A%2F%2Fplayer.vimeo.com%2Fvideo%2F756258546%3Fh%3D2300822142%26app_id%3D122963&amp;dntp=1&amp;display_name=Vimeo&amp;url=https%3A%2F%2Fvimeo.com%2F756258546&amp;image=https%3A%2F%2Fi.vimeocdn.com%2Fvideo%2F1519239474-38b609155090c9769b7c8f102aeded0367e4062b39bb4454991d9a6bd866440f-d_1280&amp;key=a19fcc184b9711e1b4764040d3dc5c07&amp;type=text%2Fhtml&amp;schema=vimeo" width="1920" height="1241" frameborder="0" scrolling="no"><a href="https://medium.com/media/181ac650ae42eb86dadccb6d4dc6c47d/href">https://medium.com/media/181ac650ae42eb86dadccb6d4dc6c47d/href</a></iframe><p>Got any question or feedback? <a href="https://join.slack.com/t/commonfatecommunity/shared_invite/zt-q4m96ypu-_gYlRWD3k5rIsaSsqP7QMg">Join us on Slack!</a></p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=2f2794499145" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[How to log in to multiple AWS accounts — the easy way]]></title>
            <link>https://towardsaws.com/how-to-log-in-to-multiple-aws-accounts-the-easy-way-9cfd6ef0d628?source=rss-e4c2681ecd98------2</link>
            <guid isPermaLink="false">https://medium.com/p/9cfd6ef0d628</guid>
            <category><![CDATA[security]]></category>
            <category><![CDATA[cloud-computing]]></category>
            <category><![CDATA[aws]]></category>
            <category><![CDATA[programming]]></category>
            <category><![CDATA[devops]]></category>
            <dc:creator><![CDATA[Common Fate]]></dc:creator>
            <pubDate>Thu, 15 Sep 2022 03:32:37 GMT</pubDate>
            <atom:updated>2022-09-26T00:42:48.537Z</atom:updated>
            <content:encoded><![CDATA[<h3>How to log in to multiple AWS accounts — the easy way</h3><p>Here’s how it goes: you’ve got a Chrome window open for your Production AWS account, and a Firefox window open for the Staging account. There’s a Safari window open for the Dev account, and an incognito Firefox window open for the Sandbox account. Buried somewhere in your dock’s 200 open windows is a Chrome incognito account for the <em>other</em> Sandbox account (because your org really, really cares about account-level separation), but by the time you manage to find it your session will probably be expired and you’ll have to go through the whole kerfuffle of signing in again.</p><p>I can’t explain to you <em>why</em> AWS decided to make their user experience like this — who am I to question the will of God? But I <em>can</em> offer you a solution: a simple, open-source CLI tool that’ll take you 10 minutes to install and will save you from AWS browser window hell forever.</p><p>Here’s how <a href="https://github.com/common-fate/granted">Granted CLI</a> works. Run the assume command in your terminal and pick which AWS profile to sign in to (in my case, testing):</p><figure><img alt="A screenshot of a terminal. The command is “assume -c testing”. Running this command gives the result “Opening a console for testing in your browser…”" src="https://cdn-images-1.medium.com/max/1024/1*Y7NDWCbgSM-RFNLvUk_o-A.png" /></figure><p>And in a few seconds, it’ll open a new tab in your browser of choice (in my case, Firefox):</p><figure><img alt="An open AWS console. It’s open in a Firefox tab with the container name “testing”." src="https://cdn-images-1.medium.com/max/1024/1*G_0hIFy4A0YA17l8H-gsKw.png" /></figure><p>Now let’s say you want to work in a second AWS account simultaneously. All you have to do is run the same command, this time selecting a different profile (in my case, release):</p><figure><img alt="A screenshot of a terminal. The command is “assume -c release”. Running this command gives the result “Opening a console for release in your browser…”" src="https://cdn-images-1.medium.com/max/1024/1*9FwYdgkarFghQjvPI3T6eQ.png" /></figure><p>And then you’ll have a second tab open in a new container:</p><figure><img alt="An open AWS console. This time it’s a different Account ID, and it’s open in a Firefox tab with the container name “release”." src="https://cdn-images-1.medium.com/max/1024/1*VimVFJBinjb1roaaztEXKA.png" /></figure><p>You can switch between these tabs to work in these accounts simultaneously with no extra hassle. Opening another profile is as simple as just running assume again.</p><p>If you think this is as cool as we do, you can read our <a href="https://docs.commonfate.io/granted/getting-started/">Getting Started guide</a> to get set up with Granted — but to save you a click I’ll run through the MacOS instructions here (the Getting Started guide contains specific instructions for Linux and Windows, too).</p><p>First, you’ll need to set up at least once role in your <a href="https://docs.aws.amazon.com/cli/latest/userguide/cli-configure-files.html">AWS config file</a>. On MacOS, this is stored in ~/.aws/config. A config file for AWS SSO should look something like this:</p><pre># ~/.aws/config<br># Change the values below to match your AWS SSO configuration<br># Granted uses the profile name: in this case &#39;my-profile&#39; to choose the role.</pre><pre>[profile my-profile]<br>sso_start_url=https://mycompany.awsapps.com/start<br>sso_region=us-east-1<br>sso_account_id=123456789012<br>sso_role_name=DeveloperRole<br>region=us-east-1</pre><p>(you can use AWS IAM too — but we recommend SSO.)</p><p>Once you’ve got that set up, you can use Homebrew to install Granted:</p><pre>brew tap common-fate/granted<br>brew install granted</pre><p>And verify your installation:</p><pre>➜ granted -v</pre><pre>Granted v0.2.9</pre><p>(mine is v0.2.9 at the time of writing — yours will probably be a later version)</p><p>Once you’ve verified that Granted is installed correctly, you can run the assume command to get started with the setup wizard where you’ll be prompted to choose your browser.</p><figure><img alt="A screenshot of Granted’s install wizard. It’s asking which browser I want to use." src="https://cdn-images-1.medium.com/max/1024/1*wKeAmQ2QwxVDKK0h1RvSSg.png" /></figure><p>After setup, you can run assume again to choose roles:</p><figure><img alt="A screenshot of a terminal. Running the command “assume” lists all my available AWS roles." src="https://cdn-images-1.medium.com/max/1024/1*FZO5N50ZRbPDbk1d3ty14Q.png" /></figure><p>You can also pass the role name directly and use the -c flag to open the console, e.g. assume -c testing.</p><p>And that’s it! If you’ve got any questions, you can check out <a href="https://docs.commonfate.io/granted/getting-started">the docs</a> or join our <a href="https://join.slack.com/t/commonfatecommunity/shared_invite/zt-q4m96ypu-_gYlRWD3k5rIsaSsqP7QMg">Slack</a> where we’ll be happy to chat with you directly. And if you like Granted, you can follow our <a href="https://twitter.com/CommonFateTech">Twitter</a> for updates and terrible jokes.</p><p>Happy ClickOpsing!</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=9cfd6ef0d628" width="1" height="1" alt=""><hr><p><a href="https://towardsaws.com/how-to-log-in-to-multiple-aws-accounts-the-easy-way-9cfd6ef0d628">How to log in to multiple AWS accounts — the easy way</a> was originally published in <a href="https://towardsaws.com/">Towards AWS</a> on Medium, where people are continuing the conversation by highlighting and responding to this story.</p>]]></content:encoded>
        </item>
    </channel>
</rss>