-
Notifications
You must be signed in to change notification settings - Fork 583
[Rule Tuning][New Rule][Deprecation] AWS EC2 EBS Snapshot Activity Rules #4763
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
Conversation
1. Rule Tuning - to prevent duplicate alerts for AWS EC2 EBS Snapshot Shared of Made Public, the execution interval has been adjusted from 5m interval with 4m lookback to 5m interval with 1m lookback. 2. New Rule - to capture when access is removed from an EBS Snapshot. While this may be intentional behavior it could indicate malicious attempts to inhibit system recovery efforts post-compromise, or to maintain exclusive access to critical backups by removing permissions for all users except their own controlled account. 3. Deprecate - AWS EC2 Snapshot Activity is too broad a rule and the behavior of the other 2 rules resulting in duplicate alerts and non-specific context for which permission change type is happening (`add` vs `remove`).
Rule: New - GuidelinesThese guidelines serve as a reminder set of considerations when proposing a new rule. Documentation and Context
Rule Metadata Checks
New BBR Rules
Testing and Validation
|
1 similar comment
Rule: New - GuidelinesThese guidelines serve as a reminder set of considerations when proposing a new rule. Documentation and Context
Rule Metadata Checks
New BBR Rules
Testing and Validation
|
rules/integrations/aws/impact_ec2_ebs_snapshot_access_removed.toml
Outdated
Show resolved
Hide resolved
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Great work @imays11 !
Do we have a red-team or in-the-wild abuse reference we can add to these by chance or is this hypothetical?
@terrancedejesus Mainly hypothetical, there are examples of snapshots being deleted and I considered this for rule dev but think that would be too noisy a rule. |
Pull Request
Issue link(s):
Resolves #3906
Tracked https://github.com/elastic/ia-trade-team/issues/616
Summary - What I changed
AWS EC2 EBS Snapshot Shared of Made Public
, the execution interval has been adjusted from5m interval with 4m lookback
to5m interval with 1m
lookback.Screenshot - No duplicate Alerts
Screenshot of new rule showing `remove` activity type
AWS EC2 Snapshot Activity
is too broad in scope and encompasses the behavior of the other 2 rules resulting in duplicate alerts and non-specific context for which permission change type is happening (add
vsremove
).Screenshot showing duplicate alerts for same activity
How To Test
I have these rules enabled in our shared stack and a Python script available upon request that will trigger the rules. For manual testing with the AWS CLI use the steps below:
Step 1: Setup
Create a Volume
us-east-1a
,1
, andgp2
with your desired availability zone, size, and volume type, respectively.VolumeId
from the response.Wait for the Volume to be Available
Create a Snapshot
SnapshotId
from the response.Wait for the Snapshot to Complete
Step 2: Exfiltration
Share Snapshot Publicly
Share Snapshot with a Specific AWS Account (Optional)
Step 3: Covering Tracks
Cleanup
Delete the Snapshot
Delete the Volume
Notes:
<VolumeId>
,<SnapshotId>
and<account-id>
with the actual IDs obtained from the previous commands and our shared AWS account Id.