Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
13 changes: 13 additions & 0 deletions policy/action.go
Original file line number Diff line number Diff line change
Expand Up @@ -175,6 +175,9 @@ const (
// DeleteObjectTaggingAction - Delete Object Tags API action
DeleteObjectTaggingAction = "s3:DeleteObjectTagging"

// UpdateObjectEncryptionAction - UpdateObjectEncryption REST API action
UpdateObjectEncryptionAction = "s3:UpdateObjectEncryption"

// PutBucketEncryptionAction - PutBucketEncryption REST API action
PutBucketEncryptionAction = "s3:PutEncryptionConfiguration"

Expand Down Expand Up @@ -276,6 +279,7 @@ var SupportedActions = map[Action]struct{}{
GetObjectTaggingAction: {},
PutObjectTaggingAction: {},
DeleteObjectTaggingAction: {},
UpdateObjectEncryptionAction: {},
PutBucketEncryptionAction: {},
GetBucketEncryptionAction: {},
PutBucketVersioningAction: {},
Expand Down Expand Up @@ -311,6 +315,7 @@ var SupportedObjectActions = map[Action]struct{}{
GetObjectTaggingAction: {},
PutObjectTaggingAction: {},
DeleteObjectTaggingAction: {},
UpdateObjectEncryptionAction: {},
GetObjectVersionAction: {},
GetObjectVersionTaggingAction: {},
DeleteObjectVersionAction: {},
Expand Down Expand Up @@ -532,6 +537,14 @@ func createActionConditionKeyMap() ActionConditionKeyMap {
condition.ExistingObjectTag.ToKey(),
}, commonKeys...)...),

UpdateObjectEncryptionAction: condition.NewKeySet(
append([]condition.Key{
condition.S3XAmzServerSideEncryption.ToKey(),
condition.S3XAmzServerSideEncryptionCustomerAlgorithm.ToKey(),
condition.S3XAmzServerSideEncryptionAwsKmsKeyID.ToKey(),
condition.S3VersionID.ToKey(),
}, commonKeys...)...),

PutObjectVersionTaggingAction: condition.NewKeySet(
append([]condition.Key{
condition.S3VersionID.ToKey(),
Expand Down
Loading