Discovering and Classifying Sensitive Data Across an Organisation
This lesson explains how to discover sensitive data automatically, classify it and drive protections from the results, since controls are only as good as knowledge of where sensitive data lives.
Learning outcomes
After completing this lesson, you will be able to:
- Describe what Amazon Macie evaluates and finds.
- Describe how Macie is set up across an organisation.
- Explain how classification tags automate protection from discovery results.
- Identify the tools that discover sensitive data outside S3.
Amazon Macie
Macie inventories S3 buckets across the organisation and evaluates their security: public access, encryption, sharing with other accounts. It finds sensitive data in objects using managed data identifiers (credentials, financial data, personal information for many countries) and custom identifiers (regular expressions with keywords), with allow lists to suppress known false positives.
Macie scans in two modes. Automated sensitive data discovery continuously samples objects across all buckets, giving broad, low-cost visibility of where sensitive data is likely to be. Sensitive data discovery jobs analyse every object in selected buckets, once or on a schedule, for deep scans of known high-risk buckets and for compliance evidence. The following table summarises the modes.
| Mode | How it works | Use |
|---|---|---|
| Automated sensitive data discovery | Continuously samples objects across all buckets | Broad, low-cost visibility into where sensitive data is |
| Sensitive data discovery jobs | Analyse selected buckets fully, once or on a schedule | Deep scans of known high-risk buckets, compliance evidence |
Organization-wide setup
Designate a delegated administrator account (usually the security tooling account) to enable Macie for all members and see every finding. Macie findings go to EventBridge and Security Hub, so they can trigger automation and be prioritised with other security findings. Detailed results can be written to an S3 bucket encrypted with a KMS key for retention.
From discovery to protection
Discovery of sensitive data can trigger automated protection. A typical workflow proceeds as follows.
-
Discover
Macie finds personal data in a bucket that was classified as internal.
-
Trigger
An EventBridge rule starts a Step Functions workflow or Lambda function.
-
Reclassify
The workflow tags the bucket (for example
data-classification=confidential), and tag-based policies, SCPs or RCPs then apply stricter controls automatically. -
Protect further
It may also block public access, require SSE-KMS with a customer managed key, or open a ticket for the data owner.
Classification tags make protections scale: access policies, backup plans and logging requirements can all key off the tag rather than individual bucket names.
Beyond S3
Macie analyses only Amazon S3, so sensitive data elsewhere needs other tools. For databases, snapshots can be exported to S3 for Macie to scan, or the database's own classification and masking features can be used. Inside applications and data pipelines, Amazon Comprehend detects personal information in free text, AWS Glue sensitive data detection identifies and masks personal data during ETL jobs, and CloudWatch Logs data protection policies mask sensitive values in log events as they arrive. A complete design applies the same classification tags to findings from every source, so protections follow the data wherever it is.
After an audit, a company must identify every S3 bucket in its 150 accounts that contains credit card numbers and automatically apply a restrictive bucket policy when one is found. The solution must require minimal ongoing effort.
Macie with a delegated administrator covers all accounts; automated sensitive data discovery keeps coverage current without scheduling jobs. A Macie finding of type SensitiveData:S3Object/Financial sent to EventBridge triggers remediation. Custom Lambda scanners or GuardDuty would add effort or miss the requirement.
What is the difference between Macie's automated sensitive data discovery and discovery jobs?
Show answer
Automated discovery samples objects across all buckets continuously to estimate where sensitive data is. Discovery jobs analyse chosen buckets in full, once or on a schedule.
Exam Tips
Remember for the exam
- Macie discovers sensitive data in S3 and evaluates bucket security posture.
- Automated discovery samples continuously; discovery jobs scan selected buckets fully.
- Use a delegated administrator to run Macie across the organisation.
- Route findings through EventBridge to automate tagging and remediation.
- Macie covers S3 only; use Comprehend, Glue or CloudWatch Logs data protection elsewhere.