# S3OriginAccessControlProps

Properties for creating a S3 Origin Access Control resource.

Extends: S3OriginAccessControlProps
Extends: OriginAccessControlBaseProps
Used as props by: S3OriginAccessControl

- Source: [`aws-cloudfront/lib/origin-access-control.ts`](https://github.com/aws/aws-cdk/blob/v2.275.0/packages/aws-cdk-lib/aws-cloudfront/lib/origin-access-control.ts#L75)
- Type last changed: v2.156.0 · 6 Sep 2024

## Example

```ts
const myBucket = new s3.Bucket(this, 'myBucket');
const oac = new cloudfront.S3OriginAccessControl(this, 'MyOAC', {
  signing: cloudfront.Signing.SIGV4_NO_OVERRIDE
});
const s3Origin = origins.S3BucketOrigin.withOriginAccessControl(myBucket, {
    originAccessControl: oac
  }
)
new cloudfront.Distribution(this, 'myDist', {
  defaultBehavior: {
    origin: s3Origin
  },
});
```

## Properties

- `description`: string — A description of the origin access control.

  **Default:** no description

- `originAccessControlName`: string — A name to identify the origin access control, with a maximum length of 64 characters.

  **Default:** a generated name

- `signing`: [Signing](/cdk/api/v2/docs/aws-cdk-lib.aws_cloudfront.Signing.html) = SIGV4_ALWAYS — Specifies which requests CloudFront signs and the signing protocol.
