<?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 Shaistha Khanum on Medium]]></title>
        <description><![CDATA[Stories by Shaistha Khanum on Medium]]></description>
        <link>https://medium.com/@shaika74?source=rss-d11ae9deaeb8------2</link>
        <image>
            <url>https://cdn-images-1.medium.com/fit/c/150/150/0*1xJKL61vWF9wCJyF</url>
            <title>Stories by Shaistha Khanum on Medium</title>
            <link>https://medium.com/@shaika74?source=rss-d11ae9deaeb8------2</link>
        </image>
        <generator>Medium</generator>
        <lastBuildDate>Sun, 06 Dec 2026 16:41:09 GMT</lastBuildDate>
        <atom:link href="https://medium.com/@shaika74/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[“We’ll Scope It Later”: Auditing and Fixing an Over-Privileged AWS IAM User]]></title>
            <link>https://medium.com/@shaika74/well-scope-it-later-auditing-and-fixing-an-over-privileged-aws-iam-user-89c2a3e595a2?source=rss-d11ae9deaeb8------2</link>
            <guid isPermaLink="false">https://medium.com/p/89c2a3e595a2</guid>
            <dc:creator><![CDATA[Shaistha Khanum]]></dc:creator>
            <pubDate>Thu, 01 Oct 2026 00:09:34 GMT</pubDate>
            <atom:updated>2026-10-01T01:00:15.183Z</atom:updated>
            <content:encoded><![CDATA[<p>A TryHackMe write-up: Defending AWS › Identity and Access Management › The Over-Privileged User</p><p>Every cloud environment has a Carl.</p><p>Carl is a new developer who needs AWS access on his first week. The admin is busy, the ticket is urgent, and there’s a policy called AdministratorAccess sitting right there. So Carl gets full admin, attached directly to his user, with a promise to &quot;scope it later.&quot;</p><p>Later never comes.</p><p>This TryHackMe room puts you in the position of the security analyst who finds Carl’s account weeks afterwards. The job: audit the permissions, prove the misconfiguration, replace it with least-privilege access, and design something that stops it happening again. I worked through it entirely with the AWS CLI, and this post walks through what I did, what I found, and a few things I’d do differently in a production environment.</p><p>(Everything below ran in a disposable lab account provisioned by TryHackMe.)</p><h3>Task 2: Real-World Incident</h3><h4>Why one over-privileged user is a big deal</h4><p>The room opens with the story of <strong>Code Spaces</strong>, and it’s worth retelling because it’s the whole argument in one incident.</p><p>Code Spaces was a code-hosting company built on AWS. In June 2014 it was hit by a DDoS attack, but the flood of traffic was cover. The attacker already had access to the company’s AWS console and demanded a ransom. When staff changed passwords to lock them out, it was too late: the attacker had quietly created backup IAM logins. Seeing the recovery attempt, they started deleting things: EBS snapshots, S3 buckets, AMIs, EC2 instances.</p><p>Within about 12 hours, production data and most of the backups were gone. Code Spaces told its customers it could no longer operate and shut down for good.</p><p>The root cause wasn’t a sophisticated exploit. It was a single identity that could do <em>anything</em> in the account, with no guardrails around it: no permission boundaries, no explicit denies on destructive actions, no MFA on sensitive operations, and no alerting when IAM changed.</p><p>Keep that in mind when you look at Carl’s policy.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*A3HEf4FsK04bGQ6xRpMGjQ.png" /><figcaption>Task2</figcaption></figure><h3>Task 3: Identification</h3><p>I started the audit by saving the account ID to a variable so the ARNs stay readable:</p><pre>ACCOUNT_ID=$(aws sts get-caller-identity --query Account --output text)</pre><p>Then listed the users:</p><pre>aws iam list-users \<br>  --query &quot;Users[*].[UserName,CreateDate]&quot; \<br>  --output table</pre><figure><img alt="" src="https://cdn-images-1.medium.com/max/516/1*qS_M_dGco8_gSV87ub9rzQ.png" /><figcaption>list-users output</figcaption></figure><p>Three identities: the lab operator, carl-the-dev and ci-deployer.</p><h4>Carl’s policy</h4><pre>aws iam list-attached-user-policies --user-name carl-the-dev</pre><pre>aws iam get-policy-version \<br>  --policy-arn arn:aws:iam::${ACCOUNT_ID}:policy/AWS201-DevCarlAdmin \<br>  --version-id v1</pre><figure><img alt="" src="https://cdn-images-1.medium.com/max/693/1*zG05bBexBkNnXqaxpOVt-w.png" /><figcaption>policy document</figcaption></figure><p>The document contains one statement:</p><pre>{<br>  &quot;Action&quot;: &quot;*&quot;,<br>  &quot;Resource&quot;: &quot;*&quot;,<br>  &quot;Effect&quot;: &quot;Allow&quot;,<br>  &quot;Sid&quot;: &quot;OverPrivilegedAccess&quot;<br>}</pre><p>Any action, on any resource. That’s full admin.</p><p>A quick refresher on how IAM evaluates a request, because it explains why this is so dangerous. An explicit <strong>Deny</strong> always wins. If there’s no Deny, an explicit <strong>Allow</strong> grants access. Anything left over is an <strong>implicit Deny</strong>. Carl has a blanket Allow and no Deny anywhere, so there is nothing between his credentials and every API in the account.</p><p>The tags gave it away</p><pre>aws iam list-user-tags --user-name carl-the-dev</pre><figure><img alt="" src="https://cdn-images-1.medium.com/max/784/1*a1tKNeFSamQBDAboDadMug.png" /><figcaption>User-tags</figcaption></figure><p>Two tags stood out: Role: Developer, and a Note that literally says <em>&quot;Temporary admin access - needs to be scoped down.&quot;</em> I like this detail because it&#39;s so realistic. The intent was documented; the follow-through wasn&#39;t. In a real audit, a tag like that is useful evidence of the gap between intended and actual access.</p><h4>Inline policies and groups</h4><p>Two more checks that are easy to skip:</p><pre>aws iam list-user-policies --user-name carl-the-dev     # inline policies<br>aws iam list-groups-for-user --user-name carl-the-dev   # group membership</pre><p>Inline policies don’t show up in the attached-policy list, so you always check separately. In this case there were none. Carl also wasn’t in any group, meaning his access was managed on the user directly. That works for one person and becomes unmanageable at fifty.</p><h4>What good looks like</h4><p>For contrast, the other user:</p><pre>aws iam list-groups-for-user --user-name ci-deployer<br>aws iam list-attached-user-policies --user-name ci-deployer</pre><figure><img alt="" src="https://cdn-images-1.medium.com/max/783/1*vZceghCCe46E2be5Juy6eg.png" /><figcaption>ci-deployer user</figcaption></figure><p>ci-deployer belongs to a Deployers group and has nothing attached directly to the user. All of its access comes through the group. That&#39;s the model Carl should be on.</p><h4>The verdict</h4><p>If Carl’s credentials leaked, an attacker could delete any S3 bucket, terminate EC2 instances, tamper with or delete CloudTrail logs, wipe EBS snapshots and AMIs, open up security groups, and read every secret in Secrets Manager. In other words, Code Spaces all over again.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*KF2zx_OUufmAaPdKcA9iWA.png" /><figcaption>Task 3</figcaption></figure><h3>Task 4 Remediation</h3><p>Started the remediation process by scoping Carl down; the plan was simple: work out what Carl actually needs, remove the admin policy, write a scoped policy, attach it via a group, and verify.</p><p>Carl’s real requirements as a developer:</p><ul><li>Read and list objects in the thm-app-data-&lt;account-id&gt; bucket</li><li>Describe EC2 instances</li><li>Read CloudWatch Logs for debugging</li></ul><p>That’s a long way from *:*.</p><h4>Remove the admin policy</h4><pre>aws iam detach-user-policy \<br>  --user-name carl-the-dev \<br>  --policy-arn arn:aws:iam::${ACCOUNT_ID}:policy/AWS201-DevCarlAdmin</pre><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*r_SnpnHHNm2c0PXCRoxe4A.png" /><figcaption><em>detach and verify</em></figcaption></figure><p>At this point Carl has no permissions at all. Every request hits the implicit deny.</p><h4>Write the scoped policy</h4><pre>aws iam create-policy \<br>  --policy-name AppAccess \<br>  --policy-document &#39;{<br>    &quot;Version&quot;: &quot;2012-10-17&quot;,<br>    &quot;Statement&quot;: [<br>      {<br>        &quot;Sid&quot;: &quot;S3AppBucketReadOnly&quot;,<br>        &quot;Effect&quot;: &quot;Allow&quot;,<br>        &quot;Action&quot;: [&quot;s3:GetObject&quot;, &quot;s3:ListBucket&quot;],<br>        &quot;Resource&quot;: [<br>          &quot;arn:aws:s3:::thm-app-data-&#39;&quot;$ACCOUNT_ID&quot;&#39;&quot;,<br>          &quot;arn:aws:s3:::thm-app-data-&#39;&quot;$ACCOUNT_ID&quot;&#39;/*&quot;<br>        ]<br>      },<br>      {<br>        &quot;Sid&quot;: &quot;EC2DescribeOnly&quot;,<br>        &quot;Effect&quot;: &quot;Allow&quot;,<br>        &quot;Action&quot;: [<br>          &quot;ec2:DescribeInstances&quot;,<br>          &quot;ec2:DescribeSecurityGroups&quot;,<br>          &quot;ec2:DescribeSubnets&quot;,<br>          &quot;ec2:DescribeVpcs&quot;<br>        ],<br>        &quot;Resource&quot;: &quot;*&quot;<br>      },<br>      {<br>        &quot;Sid&quot;: &quot;CloudWatchLogsReadOnly&quot;,<br>        &quot;Effect&quot;: &quot;Allow&quot;,<br>        &quot;Action&quot;: [<br>          &quot;logs:DescribeLogGroups&quot;,<br>          &quot;logs:DescribeLogStreams&quot;,<br>          &quot;logs:GetLogEvents&quot;,<br>          &quot;logs:FilterLogEvents&quot;<br>        ],<br>        &quot;Resource&quot;: &quot;arn:aws:logs:us-east-1:&#39;&quot;$ACCOUNT_ID&quot;&#39;:log-group:/aws/app/*&quot;<br>      }<br>    ]<br>  }&#39;</pre><figure><img alt="" src="https://cdn-images-1.medium.com/max/811/1*vfbkFJT_TJPbY1JvRkRLJA.png" /><figcaption><em>create-policy</em></figcaption></figure><p>A few details worth noticing. The S3 statement needs <em>two</em> ARNs, because ListBucket acts on the bucket while GetObject acts on the objects inside it (bucket/*). The EC2 statement uses &quot;Resource&quot;: &quot;*&quot;, which looks alarming but is expected: Describe* calls don&#39;t support resource-level restrictions, and they&#39;re read-only. The CloudWatch Logs statement is limited to one log-group prefix in one region rather than the whole account.</p><h4>Attach it through a group</h4><pre>aws iam create-group --group-name Developers</pre><pre>aws iam attach-group-policy \<br>  --group-name Developers \<br>  --policy-arn &quot;arn:aws:iam::${ACCOUNT_ID}:policy/AppAccess&quot;</pre><pre>aws iam add-user-to-group --group-name Developers --user-name carl-the-dev</pre><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*zfmA7X-aiQugH_TTUsDwUg.png" /><figcaption>attach group policy</figcaption></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/919/1*PH6qwjJdugtUlXyn-jOmxw.png" /><figcaption>add user to group</figcaption></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/849/1*HjiEzgTriOYpxrJ-JHwXgw.png" /><figcaption>list attached group polcies</figcaption></figure><h4>Prove it works, and prove it doesn’t</h4><p>The IAM Policy Simulator lets you test a policy without touching real resources. First the actions Carl should have:</p><pre>POLICY_DOC=$(aws iam get-policy-version \<br>  --policy-arn &quot;arn:aws:iam::${ACCOUNT_ID}:policy/AppAccess&quot; \<br>  --version-id v1 \<br>  --query &#39;PolicyVersion.Document&#39; --output json)</pre><pre>aws iam simulate-custom-policy \<br>  --policy-input-list &quot;$POLICY_DOC&quot; \<br>  --action-names &quot;s3:ListBucket&quot; &quot;s3:GetObject&quot; \<br>  --resource-arns &quot;arn:aws:s3:::thm-app-data-${ACCOUNT_ID}&quot; \<br>  --query &quot;EvaluationResults[*].[EvalActionName,EvalDecision]&quot; \<br>  --output table</pre><p>Both came back <strong>allowed</strong>. Then the more interesting test, an action he should <em>not</em> have:</p><pre>aws iam simulate-custom-policy \<br>  --policy-input-list &quot;$POLICY_DOC&quot; \<br>  --action-names &quot;s3:DeleteBucket&quot; \<br>  --resource-arns &quot;arn:aws:s3:::thm-app-data-${ACCOUNT_ID}&quot; \<br>  --query &quot;EvaluationResults[*].[EvalActionName,EvalDecision]&quot; \<br>  --output table</pre><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*qKBh6Kp1CpxP9TLpAdEPKA.png" /><figcaption>simulation results</figcaption></figure><p>s3:DeleteBucket → <strong>implicitDeny</strong>. Nothing in the policy mentions it, so it falls through to the default deny. I&#39;d argue this negative test matters more than the positive one: it&#39;s the evidence that the new policy doesn&#39;t grant more than you meant it to.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*8vvjBTehqOWFjPxq_w0lag.png" /><figcaption>Task 4</figcaption></figure><h3>Task 5 Building it securely</h3><p>Fixing Carl is reactive. The last part of the room is about not needing to.</p><p><strong>Group-based access.</strong> Define job functions as groups and manage people through membership. A new accountant joins, they go in the Accounting group. Someone leaves, they come out. No hand-crafted per-user policies to forget about.</p><p><strong>Least privilege from requirements.</strong> The Accounting team needs read/write on the app bucket, so their policy grants GetObject, PutObject and ListBucket on that bucket and nothing else.</p><p><strong>Permissions boundaries as guardrails.</strong> A permissions boundary is a managed policy that caps the <em>maximum</em> permissions a user or role can ever have. Even if someone later attaches an over-generous policy, the identity can only do what both its own policies <em>and</em> the boundary allow. It’s the control that would have limited the damage at Code Spaces.</p><pre>aws iam put-user-permissions-boundary \<br>  --user-name carl-the-dev \<br>  --permissions-boundary &quot;arn:aws:iam::${ACCOUNT_ID}:policy/CarlBoundary&quot;</pre><h4>What I’d tighten in a real environment</h4><p>The lab is deliberately simplified, which is right for teaching. A few things I’d flag if this were a real review:</p><p><strong>The lab’s boundary locks Carl out entirely.</strong> Effective permissions are the <em>intersection</em> of identity policies and the boundary. The room’s CarlBoundary contains only a Deny statement and no Allow, so the intersection is empty. Carl doesn&#39;t just lose S3; he loses his EC2 and CloudWatch access too. A production boundary is normally an Allow listing the maximum permitted actions, plus Denies for things that must never happen (IAM changes, deleting buckets, stopping CloudTrail).</p><p><strong>Simulate the principal, not just the policy.</strong> simulate-custom-policy tests a policy document in isolation. simulate-principal-policy tests what&#39;s actually attached to Carl, including group policies, and you can pass in the boundary to see the combined result.</p><p><strong>Match the ARN to the action.</strong> The lab simulates GetObject against the bucket ARN. Since GetObject acts on objects, a more accurate test targets bucket/*.</p><p><strong>Delete the old policy.</strong> Detaching AWS201-DevCarlAdmin isn&#39;t the same as removing it. It&#39;s still sitting there for anyone with IAM rights to re-attach. Check nothing else uses it, then delete it.</p><p><strong>The rest of the Code Spaces checklist.</strong> MFA for console users, short-lived credentials for humans (IAM Identity Center rather than long-lived access keys), CloudTrail logs stored where account admins can’t delete them, alerts on IAM changes, and IAM Access Analyzer to catch permissions nobody uses.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*-K6h25OcQDapYqRLk0Caxg.png" /><figcaption>task 5</figcaption></figure><h3>Key takeaways</h3><ul><li>“Temporary” admin access is permanent until someone owns removing it.</li><li>Attach permissions to groups or roles, never directly to users.</li><li>Build policies from requirements: specific actions on specific resources.</li><li>Permissions boundaries set the ceiling, and they intersect with identity policies.</li><li>Test that the right things are allowed, and that the wrong things are denied.</li><li>Audit all of it regularly: managed policies, inline policies, groups, and tags.</li></ul><p>The most useful thing about this room is how ordinary the misconfiguration is. Nobody was careless in an unusual way; an admin was just busy. That’s precisely why it’s worth auditing for.</p><p><em>Full commands, screenshots and a CLI cheat sheet are on my GitHub: </em><a href="https://github.com/shaistha74/THMJRPTPathAssessments/tree/main/rooms/over-privileged-user/over-privileged-user">https://github.com/shaistha74/THMJRPTPathAssessments/tree/main/rooms/over-privileged-user/over-privileged-user</a></p><p><em>I’m Shaistha, a cybersecurity professional focused on IAM and cloud security. I write about hands-on labs and security practice here and on </em><a href="https://www.linkedin.com/in/shaistha-khanum-33b396a4/"><em>LinkedIn</em></a><em>.</em></p><p><em>#AWS #CloudSecurity #IAM #TryHackMe #Cybersecurity #LeastPrivilege</em></p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=89c2a3e595a2" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[EC2 Enumeration: Offensive Mindset with a Protective Twist]]></title>
            <link>https://medium.com/@shaika74/ec2-enumeration-offensive-mindset-with-a-protective-twist-3cf145751583?source=rss-d11ae9deaeb8------2</link>
            <guid isPermaLink="false">https://medium.com/p/3cf145751583</guid>
            <dc:creator><![CDATA[Shaistha Khanum]]></dc:creator>
            <pubDate>Fri, 03 Oct 2025 04:15:25 GMT</pubDate>
            <atom:updated>2025-10-03T04:15:25.420Z</atom:updated>
            <content:encoded><![CDATA[<h3>My Two Mindsets: Protective Mother and Offensive Pentester</h3><p>On my journey to becoming both a good mother and a strong cloud pentester, my focus these days revolves around two things: my child and cloud security. Strangely enough, the two mindsets are not that different.</p><p>As a mother, I’m naturally protective — always scanning for risks, anticipating potential issues, and closing gaps before they can cause harm. As a pentester, I put on an offensive mindset — looking for weak spots, testing boundaries, and imagining how an attacker might exploit what defenders overlook.</p><p>While practicing in my sandbox environment, I realized that EC2 instances are often the most frequently targeted resources in AWS. For an attacker, gaining access to an EC2 instance is a <strong>low-effort entry with high impact</strong> — a single foothold that can open the door to broader compromiseAnd just as parents sometimes miss small details while managing everything else, defense teams can also unintentionally overlook critical EC2 misconfigurations.</p><p>That’s why I decided to create this checklist: a guide that reflects the attacker’s mindset during EC2 enumeration while also highlighting what defenders should focus on. It’s equally useful for pentesters and cloud engineers who want to strengthen their AWS environments.</p><h3>Why EC2 Enumeration Matters</h3><p>Amazon EC2 instances remain one of the most visible and widely used AWS resources. They host web apps, APIs, internal services, and often sensitive data. From a pentester’s perspective, they’re prime targets because a single misconfigured instance can grant access to credentials, networks, or privileged roles.</p><p>Enumeration is the foundation of an offensive assessment. It’s not about exploitation but about <strong>mapping</strong>: what exists, how it’s exposed, and where weaknesses may lie. That mindset helps attackers plan their next moves — and defenders close gaps before adversaries discover them.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/727/1*hca6Ky8ztRaIAEsfPAMSFg.png" /></figure><h3>Offensive EC2 Enumeration: What to Focus On</h3><p>Here’s the attacker’s perspective — the high-value areas to look at when enumerating EC2 instances, what makes them attractive to adversaries, and how defenders should address them.</p><h3>1. Discovery &amp; Exposure Surface</h3><ul><li><strong>Attacker’s view:</strong> Public-facing instances and open ports are the first footholds.</li><li><strong>What to look for:</strong> Public IPs, DNS entries, and tags that reveal environment or purpose.</li><li><strong>Why it matters:</strong> The broader the exposure, the easier the entry.</li><li><strong>Defence fix:</strong> Enforce tagging standards, monitor public exposure, and control instance sprawl.</li></ul><h3>2. Security Groups &amp; NACLs</h3><ul><li><strong>Attacker’s view:</strong> Overly permissive rules simplify initial access and lateral movement.</li><li><strong>What to look for:</strong> 0.0.0.0/0 on SSH, RDP, or database ports; overly broad egress.</li><li><strong>Why it matters:</strong> One open port can expose critical workloads.</li><li><strong>Defence fix:</strong> Apply least-privilege SGs, use bastions or SSM Session Manager for remote access.</li></ul><h3>3. Instance Metadata Service (IMDS)</h3><ul><li><strong>Attacker’s view:</strong> If IMDSv1 is enabled, credentials may be easier to steal.</li><li><strong>What to look for:</strong> Instances that haven’t enforced IMDSv2.</li><li><strong>Why it matters:</strong> Stolen temporary credentials = easy privilege escalation.</li><li><strong>Defence fix:</strong> Require IMDSv2 and restrict role permissions.</li></ul><h3>4. Instance Roles &amp; IAM Permissions</h3><ul><li><strong>Attacker’s view:</strong> Compromised EC2 roles can unlock S3 buckets, databases, or even other AWS accounts.</li><li><strong>What to look for:</strong> Broad instance roles with excessive privileges.</li><li><strong>Why it matters:</strong> Role chaining enables attackers to pivot into sensitive services.</li><li><strong>Defense fix:</strong> Audit and minimize role permissions; monitor STS tokens.</li></ul><h3>5. Secrets &amp; User-Data</h3><ul><li><strong>Attacker’s view:</strong> Secrets hardcoded in user-data or config files are direct golden tickets.</li><li><strong>What to look for:</strong> API keys, tokens, or passwords embedded in scripts or baked into AMIs.</li><li><strong>Why it matters:</strong> One exposed secret can bypass other controls.</li><li><strong>Defence fix:</strong> Use AWS Secrets Manager or Parameter Store; remove secrets from bootstrap code.</li></ul><h3>6. Public AMIs &amp; Snapshots</h3><ul><li><strong>Attacker’s view:</strong> Publicly shared images or snapshots may leak sensitive data.</li><li><strong>What to look for:</strong> AMIs/EBS volumes set to public.</li><li><strong>Why it matters:</strong> Attackers can clone, inspect, and extract.</li><li><strong>Defense fix:</strong> Restrict sharing; scan images for secrets before publishing.</li></ul><h3>7. OS &amp; Service Posture</h3><ul><li><strong>Attacker’s view:</strong> Outdated OS and unpatched software are easy wins.</li><li><strong>What to look for:</strong> Old Linux/Windows builds, forgotten services.</li><li><strong>Why it matters:</strong> Known CVEs make exploitation trivial.</li><li><strong>Defence fix:</strong> Automate patching with SSM Patch Manager and regular vulnerability scans.</li></ul><h3>8. Lateral Movement Vectors</h3><ul><li><strong>Attacker’s view:</strong> Once inside, internal reachability is the real prize.</li><li><strong>What to look for:</strong> Wide-open internal SGs, weak VPC peering, shared route tables.</li><li><strong>Why it matters:</strong> Attackers can pivot across accounts and environments.</li><li><strong>Defence fix:</strong> Apply microsegmentation, restrict peering, and enforce least-privilege routing.</li></ul><h3>9. Logging &amp; Telemetry Gaps</h3><ul><li><strong>Attacker’s view:</strong> If no one is watching, attacks can go unnoticed.</li><li><strong>What to look for:</strong> Disabled CloudTrail, no VPC Flow Logs, missing GuardDuty.</li><li><strong>Why it matters:</strong> Blind environments = longer dwell times.</li><li><strong>Defence fix:</strong> Enable and centralize logs (CloudTrail, GuardDuty, Security Hub) across regions.</li></ul><h3>Defender’s Quick Checklist ✅ (Verification Focus)</h3><ul><li>Confirm <strong>IMDSv2 is required</strong> on all EC2 instances</li><li>Verify <strong>instance IAM roles are least-privilege</strong></li><li>Scan for <strong>hardcoded keys or secrets</strong> in user-data/AMIs</li><li>Review <strong>security groups</strong> for open management ports</li><li>Check <strong>AMI &amp; snapshot sharing settings</strong></li><li>Ensure <strong>patch compliance</strong> via SSM Patch Manager</li><li>Validate <strong>CloudTrail &amp; GuardDuty</strong> enabled across all regions</li><li>Confirm <strong>VPC Flow Logs</strong> active and centralised.</li><li>Test <strong>network segmentation</strong> and restricted peering</li><li>Audit <strong>tags and inventory records</strong> for all instances</li></ul><h3>Offensive Findings → Defensive Action</h3><p>As a pentester, your job isn’t just to find issues—it is to prove impact and help defenders fix them. Offensive EC2 enumeration highlights weaknesses, but the real value comes when you show how attackers could chain them and then recommend actionable fixes.</p><p>For defenders, the checklist above translates enumeration insights directly into hardening steps. Close those gaps, and you deny attackers their easiest wins.</p><h3>Conclusion</h3><p>Whether you’re protecting your child or your cloud, the mindset is the same: anticipate risks, stay a step ahead, and never assume the basics are covered. The EC2 enumeration serves as a reminder that attackers&#39; success is not due to their cleverness, but rather to the fact that someone left a door unlocked.</p><p>For pentesters, EC2 enumeration is a roadmap to impactful findings. For defenders, it’s a playbook for proactive protection. Together, both mindsets lead to stronger, safer cloud environments.</p><h3>References:</h3><p><a href="https://pentestbook.six2dez.com/enumeration/cloud/aws">https://pentestbook.six2dez.com/enumeration/cloud/aws</a></p><p><a href="https://www.cyngular.com/resource-center/cloud-enumeration-the-stealthy-discovery-process-in-aws/">https://www.cyngular.com/resource-center/cloud-enumeration-the-stealthy-discovery-process-in-aws/</a></p><p><a href="https://academy.simplycyber.io/courses/2760561/lectures/60963600">https://academy.simplycyber.io/courses/2760561/lectures/60963600</a></p><p><a href="https://cybr.com/hands-on-labs/lab/compromising-ec2-imdsv2-with-rce-to-access-sensitive-s3-data/">https://cybr.com/hands-on-labs/lab/compromising-ec2-imdsv2-with-rce-to-access-sensitive-s3-data/</a></p><p><a href="https://cybr.com/courses/introduction-to-aws-security/lessons/lab-secure-ec2-access-with-ssm-session-manager-and-kms/">https://cybr.com/courses/introduction-to-aws-security/lessons/lab-secure-ec2-access-with-ssm-session-manager-and-kms/</a></p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=3cf145751583" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[AWS S3 Enumeration Basics (PWNED Labs)]]></title>
            <link>https://medium.com/@shaika74/aws-s3-enumeration-basics-pwned-labs-ceb6b528b5f8?source=rss-d11ae9deaeb8------2</link>
            <guid isPermaLink="false">https://medium.com/p/ceb6b528b5f8</guid>
            <dc:creator><![CDATA[Shaistha Khanum]]></dc:creator>
            <pubDate>Sat, 27 Sep 2025 07:21:41 GMT</pubDate>
            <atom:updated>2025-09-27T07:21:41.528Z</atom:updated>
            <content:encoded><![CDATA[<h3>TL;DR</h3><p>This Pwned Labs scenario demonstrates how misconfigured S3 buckets can leak sensitive files. By enumerating the bucket, I discovered a ZIP with hardcoded AWS keys, pivoted from a low-privilege IAM user to IT Admin, and accessed restricted data — highlighting the risks of public S3 access and credential leakage.</p><h3>Scenario</h3><p>It’s my first day on the red team for this lab. A bookmarked site from a phished user — http://dev.huge-logistics.com — is in scope, including cloud services.</p><p>Amazon S3 is commonly used for static websites. Misconfigurations and overly permissive settings have caused many breaches; this lab demonstrates a typical chain: static site → public bucket → leaked artifacts → hardcoded credentials → privilege escalation.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*ZzhtZXLPlVZQyAiV87zH7g.png" /></figure><p>Amazon S3 (Simple Storage Service) is a very popular (and the second oldest!) AWS service that is used to store files and backups, and can even be used to serve websites. This multi-use functionality has led some to argue that this service would be more secure if it were split into separate public web hosting and private file storage services. In recent years AWS have introduced more visual warnings when customers are making buckets world-readable, but still, if this setting is available, people will set it! Misconfigurations and overly permissive settings in S3 have resulted in many data breaches over the years.</p><h3>Attack:</h3><h3>Recon — page source &amp; S3 hints</h3><p>Try accessing the website</p><pre>&lt;http://dev.huge-logistics.com&gt;</pre><p>It looks like a static website, need to check page source</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*agvYpFJHtV8sbUhkrsVI_A.png" /></figure><p>Looks like website is hosted on s3 bucket</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*KPU4_78BOPcTRA2-rJEccA.png" /></figure><p>It uses an S3 bucket named dev.huge-logistics.com for storing static files, including images, CSS and JavaScript files.</p><p>S3 buckets are storage containers on Amazon’s <strong>S</strong>imple <strong>S</strong>torage <strong>S</strong>ervice (S3) where you can store files, images, and other data. Think of them like folders on your computer, but they’re online and can hold vast amounts of data.</p><pre>&lt;html lang=&quot;en&quot; &gt;<br>&lt;head&gt;<br>  &lt;meta charset=&quot;UTF-8&quot;&gt;<br>  &lt;title&gt;Huge Logistics&lt;/title&gt;<br>  &lt;link rel=&quot;stylesheet&quot; href=&quot;&lt;https://s3.amazonaws.com/dev.huge-logistics.com/static/style.css&gt;&quot;&gt;<br>&lt;/head&gt;<br>&lt;body&gt;<br>&lt;!-- partial:index.partial.html --&gt;<br>&lt;!--SHORTCUT ICONS--&gt;<br>&lt;link rel=&quot;shortcut icon&quot; href=&quot;&lt;https://s3.amazonaws.com/dev.huge-logistics.com/static/favicon.png&gt;&quot;&gt;</pre><p>Tried navigating to one of these files in a browser, and then traverse up directories to see if we can list other resources that are stored in the bucket.</p><p>For the following URL, <a href="https://s3.amazonaws.com/dev.huge-logistics.com/static/style.css">https://s3.amazonaws.com/dev.huge-logistics.com/static/style.css</a>, we can attempt the following requests in our browser:</p><pre>&lt;https://s3.amazonaws.com/dev.huge-logistics.com/static/&gt;<br>&lt;https://s3.amazonaws.com/dev.huge-logistics.com/&gt;</pre><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*F0uEQ1mSgRBULwS7RXyy-w.png" /></figure><p>Neither of these requests are successful as both result in access denied messages.</p><h3>Enumeration — AWS CLI and unsigned requests</h3><p>Tried Enumerating using AWS CLI</p><p>Tried listing the contents of s3 with the command below.</p><pre>aws s3 ls s3://dev.huge-logistics.com --no-sign-request</pre><figure><img alt="" src="https://cdn-images-1.medium.com/max/694/1*7ePZWf5rGBq5EuERLv-8Dg.png" /></figure><p>To send an unsigned request, and test the bucket for public access, we can include the --no-sign-request switch.</p><p>The command is successful, which reveals that the S3 bucket is open for the entire internet to access. This makes sense in the case where it’s being used to store public website content, but it also seems to contain other directories…</p><p>Let’s dig in. Attempting to recursively list all directories using the --recursive switch results in an access denied error.</p><pre>aws s3 ls s3://dev.huge-logistics.com --no-sign-request --recursive<br>aws s3 ls s3://dev.huge-logistics.com/admin --no-sign-request<br>aws s3 ls s3://dev.huge-logistics.com/migration-files/ --no-sign-request</pre><p>It seems that both the admin and migration-files directories don&#39;t allow public access.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/951/1*tPeXNJeu7K3kf_RWBFvClA.png" /></figure><p>The static (web) directory is available but the files don’t seem interesting from a security perspective.</p><pre>aws s3 ls s3://dev.huge-logistics.com/static/ --no-sign-request<br></pre><figure><img alt="" src="https://cdn-images-1.medium.com/max/676/1*v_umheOIQGdHuQpS7L0jKw.png" /></figure><h3>Finding secrets — the PowerShell script</h3><pre>aws s3 ls s3://dev.huge-logistics.com/shared/ --no-sign-request</pre><figure><img alt="" src="https://cdn-images-1.medium.com/max/840/1*el8oE136JQvFObOG69Hx1Q.png" /></figure><p>However, the shared directory contains that archivehl_migration_project.zip.</p><p>Let’s download it and check it out.</p><pre>aws s3 cp s3://dev.huge-logistics.com/shared/hl_migration_project.zip . --no-sign-request<br><br>After unzipping the archive with the command unzip hl_migration_project.zip , we see a PowerShell script.</pre><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*ixgKjnihRJs82n51O07K-w.png" /></figure><p>The script contains hardcoded AWS keys! the purpose of the script seems to be to take existing secrets that are stored in an XML file, and store them in AWS Secrets Manager. Secrets Manager is a service that helps securely store, manage, and retrieve secrets like API keys and database credentials.</p><pre>┌──(kali㉿kali)-[~]<br>└─$ cat migrate_secrets.ps1 <br># AWS Configuration<br>$accessKey = &quot;AKIA3SFMDAPOWOWKXEHU&quot;<br>$secretKey = &quot;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&quot;<br>$region = &quot;us-east-1&quot;<br># Set up AWS hardcoded credentials<br>Set-AWSCredentials -AccessKey $accessKey -SecretKey $secretKey<br># Set the AWS region<br>Set-DefaultAWSRegion -Region $region<br># Read the secrets from export.xml<br>[xml]$xmlContent = Get-Content -Path &quot;export.xml&quot;<br># Output log file<br>$logFile = &quot;upload_log.txt&quot;<br># Error handling with retry logic<br>function TryUploadSecret($secretName, $secretValue) {<br>    $retries = 3<br>    while ($retries -gt 0) {<br>        try {<br>            $result = New-SECSecret -Name $secretName -SecretString $secretValue<br>            $logEntry = &quot;Successfully uploaded secret: $secretName with ARN: $($result.ARN)&quot;<br>            Write-Output $logEntry<br>            Add-Content -Path $logFile -Value $logEntry<br>            return $true<br>        } catch {<br>            $retries--<br>            Write-Error &quot;Failed attempt to upload secret: $secretName. Retries left: $retries. Error: $_&quot;<br>        }<br>    }<br>    return $false<br>}<br>foreach ($secretNode in $xmlContent.Secrets.Secret) {<br>    # Implementing concurrency using jobs<br>    Start-Job -ScriptBlock {<br>        param($secretName, $secretValue)<br>        TryUploadSecret -secretName $secretName -secretValue $secretValue<br>    } -ArgumentList $secretNode.Name, $secretNode.Value<br>}<br># Wait for all jobs to finish<br>$jobs = Get-Job<br>$jobs | Wait-Job<br># Retrieve and display job results<br>$jobs | ForEach-Object {<br>    $result = Receive-Job -Job $_<br>    if (-not $result) {<br>        Write-Error &quot;Failed to upload secret: $($_.Name) after multiple retries.&quot;<br>    }<br>    # Clean up the job<br>    Remove-Job -Job $_<br>}<br>Write-Output &quot;Batch upload complete!&quot;<br># Install-Module -Name AWSPowerShell -Scope CurrentUser -Force<br># .\\migrate_secrets.ps1</pre><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*DhfQUJoCKgDcXlxhjiNVZA.png" /></figure><p>Along with the Access Key and Secret Key with see the region in the script is set to us-east-1 . When it comes to setting our keys as an attacker it&#39;s helpful to know which region to use. We can get a further clue from the S3 bucket. The cURL command below returns the headers only, which reveals that the bucket was created in the us-east-1 region .</p><pre>curl -I &lt;https://s3.amazonaws.com/dev.huge-logistics.com/&gt;</pre><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*1lkUFE69G_VSgNVEolj_Qw.png" /></figure><h3>Using the leaked credentials (lab only) — get caller identity</h3><p>I configured the AWS CLI with the leaked keys (in the lab environment only!) and checked the execution context:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/927/1*rx-g0pfUbTWuv-Gsx8ecpQ.png" /></figure><p>Instead of running whoami as we might on Linux and Windows, in AWS we can find out our execution context with the following command.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/691/1*G7R21UwVo4Cos9d1sm0wVQ.png" /></figure><p>This reveals the IAM user named pam-test . We can assume given the nature of the script that pam stands for Privileged Access Management (PAM).</p><p>Let’s now examine again the /admin directory. Note that the --no-sign-request switch has been removed, since we now have valid AWS credentials and we want to sign our request with the set keys.</p><pre>aws s3 ls s3://dev.huge-logistics.com/admin/ --profile pwnedlab</pre><figure><img alt="" src="https://cdn-images-1.medium.com/max/891/1*0UF1xybOnLeEidscIRfKDA.png" /></figure><p>This reveals a website transactions export file and also the flag. Unfortunately we are unable to download either using our current credentials.</p><h3>Further escalation — more credentials in migration-files</h3><pre>aws s3 ls s3://dev.huge-logistics.com/migration-files/ --profile pwnedlab</pre><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*KLXGue4uHbfAiQe2qc9UlQ.png" /></figure><p>Among PDFs related to the migration project are the migration_secrets.ps1 script again, and also a test-export.xml file.</p><pre>aws s3 cp s3://dev.huge-logistics.com/migration-files/test-export.xml . --profile pwnedlab</pre><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*ms7jdF1n0RBrrqxTbZi0Jw.png" /></figure><p>Downloading the file we see more high privileged credentials! This includes an AWS IT Admin entry.</p><p>Use aws configure to set the new keys. Running aws sts get-caller-identity this time reveals that we are the IAM user it-admin .</p><pre>└─$ cat test-export.xml                                                        <br>&lt;?xml version=&quot;1.0&quot; encoding=&quot;UTF-8&quot;?&gt;<br>&lt;CredentialsExport&gt;<br>    &lt;!-- Oracle Database Credentials --&gt;<br>    &lt;CredentialEntry&gt;<br>        &lt;ServiceType&gt;Oracle Database&lt;/ServiceType&gt;<br>        &lt;Hostname&gt;oracle-db-server02.prod.hl-internal.com&lt;/Hostname&gt;<br>        &lt;Username&gt;admin&lt;/Username&gt;<br>        &lt;Password&gt;Password123!&lt;/Password&gt;<br>        &lt;Notes&gt;Primary Oracle database for the financial application. Ensure strong password policy.&lt;/Notes&gt;<br>    &lt;/CredentialEntry&gt;<br>    &lt;!-- HP Server Credentials --&gt;<br>    &lt;CredentialEntry&gt;<br>        &lt;ServiceType&gt;HP Server Cluster&lt;/ServiceType&gt;<br>        &lt;Hostname&gt;hp-cluster1.prod.hl-internal.com&lt;/Hostname&gt;<br>        &lt;Username&gt;root&lt;/Username&gt;<br>        &lt;Password&gt;RootPassword456!&lt;/Password&gt;<br>        &lt;Notes&gt;HP server cluster for batch jobs. Periodically rotate this password.&lt;/Notes&gt;<br>    **&lt;/CredentialEntry&gt;<br>    &lt;!-- AWS Production Credentials --&gt;<br>    &lt;CredentialEntry&gt;<br>        &lt;ServiceType&gt;AWS IT Admin&lt;/ServiceType&gt;<br>        &lt;AccountID&gt;794929857501&lt;/AccountID&gt;<br>        &lt;AccessKeyID&gt;AKIA3SFMDAPOQRFWFGCD&lt;/AccessKeyID&gt;<br>        &lt;SecretAccessKey&gt;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&lt;/SecretAccessKey&gt;<br>        &lt;Notes&gt;AWS credentials for production workloads. Do not share these keys outside of the organization.&lt;/Notes&gt;**<br>    &lt;/CredentialEntry&gt;<br>    &lt;!-- Iron Mountain Backup Portal --&gt;<br>    &lt;CredentialEntry&gt;<br>        &lt;ServiceType&gt;Iron Mountain Backup&lt;/ServiceType&gt;<br>        &lt;URL&gt;&lt;https://backupportal.ironmountain.com&gt;&lt;/URL&gt;<br>        &lt;Username&gt;hladmin&lt;/Username&gt;<br>        &lt;Password&gt;HLPassword789!&lt;/Password&gt;<br>        &lt;Notes&gt;Account used to schedule tape collections and deliveries. Schedule regular password rotations.&lt;/Notes&gt;<br>    &lt;/CredentialEntry&gt;<br>    &lt;!-- Office 365 Admin Account --&gt;<br>    &lt;CredentialEntry&gt;<br>        &lt;ServiceType&gt;Office 365&lt;/ServiceType&gt;<br>        &lt;URL&gt;&lt;https://admin.microsoft.com&gt;&lt;/URL&gt;<br>        &lt;Username&gt;admin@company.onmicrosoft.com&lt;/Username&gt;<br>        &lt;Password&gt;O365Password321!&lt;/Password&gt;<br>        &lt;Notes&gt;Office 365 global admin account. Use for essential administrative tasks only and enable MFA.&lt;/Notes&gt;<br>    &lt;/CredentialEntry&gt;<br>    &lt;!-- Jira Admin Account --&gt;<br>    &lt;CredentialEntry&gt;<br>        &lt;ServiceType&gt;Jira&lt;/ServiceType&gt;<br>        &lt;URL&gt;&lt;https://hugelogistics.atlassian.net&gt;&lt;/URL&gt;<br>        &lt;Username&gt;jira_admin&lt;/Username&gt;<br>        &lt;Password&gt;JiraPassword654!&lt;/Password&gt;<br>        &lt;Notes&gt;Jira administrative account. Restrict access and consider using API tokens where possible.&lt;/Notes&gt;<br>    &lt;/CredentialEntry&gt;<br>&lt;/CredentialsExport&gt;</pre><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*EFrIzlTbyUnhHmPgxZkwwg.png" /></figure><p>Configure AWS account with IT Admin access keys</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/988/1*l8gqnqq425FzgfrPTYVhCQ.png" /></figure><p>The admin account is allowed to access the admin folder, and inside we see an export of users credit card numbers and other PII (personally identifiable information) in clear text! PWNED!</p><pre>aws s3 cp s3://dev.huge-logistics.com/admin/website_transactions_export.csv - --profile it-admin</pre><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*xsoeEDQI5keZUPRndvWtDw.png" /></figure><p>Download flag.txt file to get the flag</p><pre>aws s3 cp s3://dev.huge-logistics.com/admin/flag.txt - --profile it-admin</pre><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*1zhxUjLAk_1ZHIaMXhBZvA.png" /></figure><p>Successfully pawned!!!</p><h3>Why the browser request was denied but CLI worked</h3><p>Using aws s3api get-bucket-policy I inspected the bucket policy (output simplified). The policy restricts s3:ListBucket to requests that include prefix (even if empty) and delimiter=/ as query parameters. The AWS CLI issues such requests by default; a browser visiting https://dev.huge-logistics.com.s3.amazonaws.com/ typically does not include those parameters, so the request doesn’t match the policy condition — hence AccessDenied. The CLI succeeded because it matched the policy condition.</p><pre>aws s3api get-bucket-policy --bucket dev.huge-logistics.com --profile it-admin \\<br>  | jq -r &#39;.Policy | fromjson&#39;</pre><figure><img alt="" src="https://cdn-images-1.medium.com/max/814/1*n6H7UnBKbMtT9Jy6ADKEaA.png" /></figure><p>You can reproduce a browser-friendly listing by using the parameters:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*7j0JKMokc201-IYCRcQSYg.png" /></figure><h3>Lessons &amp; Mitigations</h3><p><strong>Key takeaways</strong></p><ul><li>Public buckets are common for static hosting — but sometimes sensitive artifacts get uploaded by mistake.</li><li>Hardcoded credentials in repositories, archives, or scripts are a severe risk.</li><li>Partial policy restrictions can create surprising behaviour (CLI vs browser).</li></ul><p><strong>Mitigations for owners</strong></p><ul><li>Avoid hardcoding credentials; use IAM roles and instance profiles.</li><li>Enforce least privilege and rotate keys immediately if leaked.</li><li>Turn on S3 Block Public Access unless public hosting is required.</li><li>Enable AWS Config rules and Security Hub checks for public buckets and exposed secrets.</li><li>Use Secrets Manager / Parameter Store with strict IAM access and audit logs.</li><li>Monitor for leaked keys (AWS GuardDuty, credential scanning, and automated key rotation).</li></ul><h3>Reference:</h3><p><a href="https://pwnedlabs.io/labs/aws-s3-enumeration-basics">https://pwnedlabs.io/labs/aws-s3-enumeration-basics</a></p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=ceb6b528b5f8" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Compromising Healthcare Security: A Threat Modeling Case Study on HCS]]></title>
            <link>https://medium.com/@shaika74/compromising-healthcare-security-a-threat-modeling-case-study-on-hcs-25fa684a1882?source=rss-d11ae9deaeb8------2</link>
            <guid isPermaLink="false">https://medium.com/p/25fa684a1882</guid>
            <category><![CDATA[cybersecurityinhealthcare]]></category>
            <category><![CDATA[cyber-security-awareness]]></category>
            <category><![CDATA[threat-modeling]]></category>
            <category><![CDATA[cyber-attack-prevention]]></category>
            <dc:creator><![CDATA[Shaistha Khanum]]></dc:creator>
            <pubDate>Thu, 11 Sep 2025 12:15:43 GMT</pubDate>
            <atom:updated>2025-09-11T12:15:43.940Z</atom:updated>
            <content:encoded><![CDATA[<p>As part of my academic research, I developed a Threat Modeling exercise for a hypothetical healthcare organization, Hope Care Services (HCS). This organization relies heavily on advanced medical imaging technologies — MRI, CT scanners, and ultrasound equipment — while also storing patient data on cloud-based systems. Below, I’ll walk through the assumptions that frame HCS’s threat landscape, discuss an attack tree highlighting top cyber risks, and provide recommendations to strengthen cybersecurity.</p><h3>1. Why Healthcare Needs Robust Cybersecurity</h3><p>Healthcare is a prime target for cybercriminals because:</p><ul><li>It stores sensitive patient data (personally identifiable information and protected health information).</li><li>It operates life-critical systems (imaging devices, patient monitors, infusion pumps).</li><li>It often relies on legacy protocols or specialized systems (like DICOM) that may not have been built with modern cybersecurity in mind.</li></ul><p>The European Union Agency for Cybersecurity (ENISA) notes a surge in ransomware, DDoS, and data manipulation attacks in healthcare (EU Agency for Cybersecurity, 2023). This risk is echoed by SOCRadar (2023), which highlights healthcare as a top target for financially motivated hackers and state-sponsored actors.</p><h3>2. Assumptions: HCS’s Infrastructure and Vulnerabilities</h3><ol><li>Use of DICOM: HCS employs the Digital Imaging and Communications in Medicine (DICOM) standard for MRI, CT, and ultrasound equipment, facilitating data exchange, storage, and transmission.</li><li>PACS Connectivity: HCS utilizes a network-based Picture Archiving and Communication System (PACS) for medical imaging (Moshe, N. 2023).</li><li>Data Tampering Risks: Attackers can manipulate MRI scan results, creating or removing evidence of tumors (Moshe, N. 2023).</li><li>Ransomware on Imaging Devices: Ransomware attacks can encrypt critical images during emergencies (Burke, G. and Saxena, N. 2021).</li><li>Weak Authentication: DICOM protocol currently has weak username/password-based authentication, lacking MFA and robust ACLs.</li><li>Lack of Encryption: No encryption is in place for the DICOM protocol.</li><li>Misconfigured Cloud Storage: DICOM files are stored on cloud repositories with misconfigurations, making them accessible to brute force or blob-hunting attacks.</li><li>Threat Profile: HCS faces threats from cybercriminals, hacktivists, and nation-state actors targeting patient data, imaging devices, and corporate networks.</li></ol><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/0*d-x3XdbH_01XvKdM" /></figure><p>Fig. 1. Hope Care Services (HCS) Assumed Threat Profile (Microsoft Word)</p><h3>3. The Attack Tree: Key Threats to HCS</h3><p>Below is a simplified breakdown of the Attack Tree (see figure) for compromising Confidentiality, Integrity, and Availability (CIA) at HCS:</p><p>Ransomware Attack</p><ul><li>Encrypting or exfiltrating MRI/CT scans</li><li>Exploiting DICOM server vulnerabilities (e.g., buffer overflows, credential stuffing)</li><li>Demanding ransom to decrypt or not leak sensitive images</li></ul><p>Information Manipulation &amp; Interference</p><ul><li>Tampering with lab results or imaging data (adding non-existent tumors, removing real findings)</li><li>Spreading misinformation that undermines patient trust</li></ul><p>Social Engineering</p><ul><li>Spear Phishing: Sending malicious attachments to healthcare staff</li><li>Baiting: Tricking users into downloading fake software updates or freebies</li></ul><p>Malware Attack</p><ul><li>Remote Code Execution (RCE) on DICOM servers</li><li>Installing rootkits on PACS systems to gain persistent access</li></ul><p>Distributed Denial-of-Service (DDoS)</p><ul><li>Flooding the hospital network, preventing staff from accessing patient records</li><li>Exploiting known vulnerabilities in DICOM libraries (CVE-2022–2121)</li></ul><p>Each branch of the attack tree reflects how adversaries can exploit vulnerabilities at HCS to compromise patient data, disrupt critical services, or gain illicit financial gain (EU Agency for Cybersecurity, 2023; SOCRadar, 2023).</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/891/0*cJLd7aDA09u37bZZ" /></figure><p>Fig. 2. Threat Model of Hope Care Services (HCS) (Lucid Chart app)</p><h3>4. Security Recommendations</h3><ol><li>Implement MFA &amp; Strong ACLs: Strengthen DICOM authentication by using multi-factor authentication and role-based access controls (Moshe, N. 2023).</li><li>Encrypt DICOM Data: Enable end-to-end encryption for data at rest and in transit to protect patient images from interception.</li><li>Network Segmentation: Separate medical imaging networks (PACS) from administrative networks to contain breaches (Fortinet, 2023).</li><li>Patch &amp; Update Regularly: Patch management is critical: unpatched vulnerabilities in DICOM servers or PACS devices open the door to RCE attacks (Fortinet, 2023).</li><li>Cloud Storage Hardening: Configure access controls for storage buckets, disable public access by default, and monitor for misconfigurations (Horev, R., 2022).</li><li>Backup &amp; Recovery: Maintain offline backups of imaging data to counter ransomware attempts (Burke, G. and Saxena, N. 2021).</li><li>Employee Training: Conduct phishing simulations and continuous cybersecurity awareness sessions to prevent social engineering (McKeon, J. 2022).</li><li>DDoS Protection: Deploy Web Application Firewalls (WAF) and rate-limiting solutions to mitigate large-scale traffic floods (Amazon Web Services, 2022).</li></ol><h3>5. Conclusion &amp; Next Steps</h3><p>Threat modeling provides a holistic view of the vulnerabilities in healthcare organizations like HCS. By focusing on DICOM security, cloud misconfigurations, and social engineering awareness, HCS can better protect patient data, uphold trust, and ensure uninterrupted care. Implementing a robust security posture — encryption, MFA, network segmentation, and regular security audits — will help HCS stay ahead of rapidly evolving threats.</p><p>I hope this breakdown of Hope Care Services’ threat profile and attack tree demonstrates how crucial proactive cybersecurity measures are for healthcare. If you have any questions or would like to share your experiences in securing healthcare environments, feel free to comment below or reach out directly.</p><h3>References</h3><ul><li>Amazon Web Services. (2022). <em>Guidelines for Implementing AWS WAF.</em> <a href="https://docs.aws.amazon.com/whitepapers/latest/guidelines-for-implementing-aws-waf/guidelines-for-implementing-aws-waf.html">Link</a></li><li>Burke, G. and Saxena, N. (2021). Cyber risk prediction and analysis in medical emergency equipment for situational awareness. <em>Sensors, 21(16)</em>, p.5325.</li><li>EU Agency for Cybersecurity. (2023). <em>ENISA Threat Landscape 2023.</em> <a href="https://www.enisa.europa.eu/publications/enisa-threat-landscape-2023">Link</a></li><li>Fortinet. (2023). <em>Threat Landscape Report 2023.</em></li><li>Horev, R. (2022). 8 common cloud misconfiguration types (and how to avoid them). <em>Vulcan Blog.</em></li><li>McKeon, J. (2022). Common Types of Social Engineering Phishing Attacks in Healthcare. <em>HealthITSecurity.</em></li><li>Moshe, N. (2023). <em>DICOM Demystified: Exploring the Underbelly of Medical Imaging.</em> Claroty.</li><li>SOCRadar. (2023). <em>Healthcare Industry Threat Landscape Report.</em> <a href="https://socradar.io/wp-content/uploads/2023/06/SOCRadar-Healthcare-Industry-Threat-Landscape-Report.pdf">Link</a></li></ul><p>Author’s Note: This article is based on an academic project designed to illustrate potential risks and security strategies in a hypothetical healthcare environment. All references and details align with existing cybersecurity research, highlighting best practices for healthcare data protection.</p><p>#CyberSecurity #HealthcareSecurity #ThreatModeling #CloudSecurity #DICOM #PACS #Ransomware #ThreatIntelligence #InfoSec #SecureThoughts</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=25fa684a1882" width="1" height="1" alt="">]]></content:encoded>
        </item>
    </channel>
</rss>