Data lineage authorization and data access
Lineage shows how data moves between jobs and datasets in your account, and it can include sensitive metadata such as query text and job roles. AWS Glue Data Catalog Lineage uses IAM to control who can view and send lineage. This topic describes what lineage can reveal and how to limit access to it.
Access to lineage
You control access to lineage only through IAM. To view lineage, a principal needs the glue:GetLineageNode IAM permission. This permission is not limited to specific tables. A principal with this permission can view any lineage node in the AWS account, with all of its details, including column lineage. If your Data Catalog is encrypted with a customer managed AWS KMS key, the key policy also limits who can view lineage. For details, see Encrypted catalogs.
With the glue:GetLineageNode permission, a principal can read all lineage in the AWS account, including the lineage graph in the AWS Glue console. IAM policies that allow glue:Get* or glue:* also allow glue:GetLineageNode. Give this permission only to principals that should see all lineage in the account.
Because lineage isn't filtered by catalog permissions, a principal with glue:GetLineageNode can see lineage for tables that they can't discover in the catalog or query.
What lineage can reveal
Lineage nodes can include:
-
Table, column, and job names.
-
Amazon S3 locations.
-
Query text, which can include literal values from
WHEREclauses. -
The roles and users that ran jobs.
Lineage doesn't include the data in your tables.
Recommendations
-
Grant
glue:GetLineageNodeonly to principals that should see lineage for the whole account, such as data platform administrators and governance teams. -
Use separate AWS accounts to isolate lineage between business units. Each account has its own lineage graph.
-
To control who can send lineage, grant or deny
glue:PostLineageEvent. -
Use service control policies to set these rules across your organization.
Access to the lineage system table
The lineage system table is a table in Amazon S3 Tables. Access to it is controlled by Lake Formation and IAM, like other tables. Granting SELECT on the table gives access to every lineage event in the account.
Data access by lineage capture
Lineage capture doesn't change what data a job can access. AWS services send lineage with the same role that runs the job. Jobs with fine-grained access control send lineage only to AWS Glue Data Catalog.
Encrypted catalogs
If your Data Catalog is encrypted with a customer managed AWS KMS key (SSE-KMS), a principal needs kms:Decrypt on that key in addition to glue:GetLineageNode. Without it, the request fails with AccessDeniedException. If the catalog uses SSE-KMS-WITH-SERVICE-ROLE, AWS Glue reads lineage with the catalog's encryption service role, and the principal needs only glue:GetLineageNode.