# EncryptedPermissionsOptions

Options for configuring permissions on encrypted resources.

Extends: [PermissionsOptions](https://docs.aws.amazon.com/cdk/api/v2/docs/aws-cdk-lib.PermissionsOptions.html)
Used as argument in: [QueueGrants.actions](https://docs.aws.amazon.com/cdk/api/v2/docs/aws-cdk-lib.aws_sqs.QueueGrants.html#actions), [TopicGrants.actions](https://docs.aws.amazon.com/cdk/api/v2/docs/aws-cdk-lib.aws_sns.TopicGrants.html#actions)

- Source: [`core/lib/grants.ts`](https://github.com/aws/aws-cdk/blob/v2.278.0/packages/aws-cdk-lib/core/lib/grants.ts#L16)
- Type last changed: v2.244.0 · 19 Mar 2026

## Example

TypeScript:

```ts
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
import * as cdk from 'aws-cdk-lib';
const encryptedPermissionsOptions: cdk.EncryptedPermissionsOptions = {
  keyActions: ['keyActions'],
  resourceArns: ['resourceArns'],
};
```

Python:

```python
# The code below shows an example of how to instantiate this type.
# The values are placeholders you should change.
import aws_cdk as cdk

encrypted_permissions_options = cdk.EncryptedPermissionsOptions(
    key_actions=["keyActions"],
    resource_arns=["resourceArns"]
)
```

Java:

```java
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
import software.amazon.awscdk.*;

EncryptedPermissionsOptions encryptedPermissionsOptions = EncryptedPermissionsOptions.builder()
        .keyActions(List.of("keyActions"))
        .resourceArns(List.of("resourceArns"))
        .build();
```

C# / .NET:

```csharp
// Install: dotnet add package Amazon.CDK.Lib
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
using Amazon.CDK;

var encryptedPermissionsOptions = new EncryptedPermissionsOptions {
    KeyActions = new [] { "keyActions" },
    ResourceArns = new [] { "resourceArns" }
};
```

Golang:

```go
// Install: go get github.com/aws/aws-cdk-go/awscdk/v2
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
import cdk "github.com/aws/aws-cdk-go/awscdk"

encryptedPermissionsOptions := &EncryptedPermissionsOptions{
	KeyActions: []*string{
		jsii.String("keyActions"),
	},
	ResourceArns: []*string{
		jsii.String("resourceArns"),
	},
}
```

## Properties

- `keyActions`: string[] — The KMS key actions to grant permissions for.

  **Default:** No permission is added to the KMS key, even if it exists

- `resourceArns`: string[] — The ARNs of the resources to grant permissions on.

  **Default:** The ARN of the resource associated with the grant is used.
