AWS codecommit documentation change
Summary
Replaced pull request output example with IAM policy allowing GetRepository access
Security assessment
The change adds an example IAM policy granting codecommit:GetRepository permission, which documents how to configure access control. This is a security feature but does not address a specific security vulnerability.
Diff
diff --git a/codecommit/latest/userguide/how-to-close-pull-request.md b/codecommit/latest/userguide/how-to-close-pull-request.md index 2c92faa46..35ff6436f 100644 --- a//codecommit/latest/userguide/how-to-close-pull-request.md +++ b//codecommit/latest/userguide/how-to-close-pull-request.md @@ -67,0 +68,6 @@ If successful, this command produces output similar to the following: +JSON + + +**** + + @@ -69,20 +75,2 @@ If successful, this command produces output similar to the following: - "pullRequest": { - "approvalRules": [ - { - "approvalRuleContent": "{\"Version\": \"2018-11-08\",\"Statements\": [{\"Type\": \"Approvers\",\"NumberOfApprovalsNeeded\": 2,\"ApprovalPoolMembers\": [\"arn:aws:sts::123456789012:assumed-role/CodeCommitReview/*\"]}]}", - "approvalRuleId": "dd8b17fe-EXAMPLE", - "approvalRuleName": "2-approvers-needed-for-this-change", - "creationDate": 1571356106.936, - "lastModifiedDate": 571356106.936, - "lastModifiedUser": "arn:aws:iam::123456789012:user/Mary_Major", - "ruleContentSha256": "4711b576EXAMPLE" - } - ], - "authorArn": "arn:aws:iam::123456789012:user/Li_Juan", - "clientRequestToken": "", - "creationDate": 1508530823.165, - "description": "Updated the pull request to remove unused global variable.", - "lastActivityDate": 1508372423.12, - "pullRequestId": "47", - "pullRequestStatus": "CLOSED", - "pullRequestTargets": [ + "Version": "2012-10-17", + "Statement": [ @@ -90,11 +78,5 @@ If successful, this command produces output similar to the following: - "destinationCommit": "9f31c968EXAMPLE", - "destinationReference": "refs/heads/main", - "mergeMetadata": { - "isMerged": false, - }, - "repositoryName": "MyDemoRepo", - "sourceCommit": "99132ab0EXAMPLE", - "sourceReference": "refs/heads/variables-branch" - } - ], - "title": "Consolidation of global variables" + "Effect": "Allow", + "Action": "codecommit:GetRepository", + "Resource": [ + "arn:aws:codecommit:us-east-2:111122223333:MySharedDemoRepo" + ] @@ -101,0 +84 @@ If successful, this command produces output similar to the following: + ]