Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

False positive: publicly-accessible SNS Topics #1580

Open
rdegraaf opened this issue Oct 14, 2023 · 1 comment
Open

False positive: publicly-accessible SNS Topics #1580

rdegraaf opened this issue Oct 14, 2023 · 1 comment
Labels
bug Something isn't working potential Unconfirmed issue

Comments

@rdegraaf
Copy link

ScoutSuite reported a number of SNS Topics in my account as being publicly accessible. Upon investigation, they are not. They had resource policies containing the following statements:

{
  "Sid": "__default_statement_ID",
  "Effect": "Allow",
  "Principal": {
    "AWS": "*"
  },
  "Action": [
    "SNS:GetTopicAttributes",
    <elided>
  ],
  "Resource": "<redacted>",
  "Condition": {
    "StringEquals": {
      "AWS:SourceOwner": "<redacted>"
    }
  }
},
{
  "Sid": "AWSSNSPolicy",
  "Effect": "Allow",
  "Principal": {
    "AWS": "*"
  },
  "Action": "sns:Publish",
  "Resource": "<redacted>",
  "Condition": {
    "StringEquals": {
      "aws:PrincipalOrgID": "<redacted>"
    }
  }
}

Since other Topics access policies also used the condition key "AWS:SourceOwner" (spelled with upper-case "AWS") without being flagged, this is probably not the problem. The problem is most like the "aws:PrincipalOrgID" condition key.

If this is indeed a correct analysis of the problem, it likely applies to other findings as well.

To Reproduce

I have not tried to create a reproduction case for this flaw. Let me know if you're having difficulty and I will try to help. However, I will most likely no longer have access to the account where I encountered this flaw.

@rdegraaf rdegraaf added bug Something isn't working potential Unconfirmed issue labels Oct 14, 2023
@x64-latacora
Copy link

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working potential Unconfirmed issue
Projects
None yet
Development

No branches or pull requests

2 participants