AWS Fundamentals Logo
AWS Fundamentals
L2 Construct

PublicKey

A Public Key Configuration.

Import

import { PublicKey } from 'aws-cdk-lib/aws-cloudfront';

Or use the module namespace:

import * as cloudfront from 'aws-cdk-lib/aws-cloudfront';
// cloudfront.PublicKey

Properties

Configuration passed to the constructor as PublicKeyProps.

encodedKeyRequired
string

The public key that you can use with signed URLs and signed cookies, or with field-level encryption. The `encodedKey` parameter must include `-----BEGIN PUBLIC KEY-----` and `-----END PUBLIC KEY-----` lines.

commentOptional
string

A comment to describe the public key.

Default: - no comment

publicKeyNameOptional
string

A name to identify the public key.

Default: - generated from the `id`

Get the Amazon CloudFront Cheat Sheet

Everything you need to know about Amazon CloudFront on one page. HD quality, print-friendly.

Download Free Infographic