CloudFront / Client / create_field_level_encryption_config
create_field_level_encryption_config#
- CloudFront.Client.create_field_level_encryption_config(**kwargs)#
Create a new field-level encryption configuration.
See also: AWS API Documentation
Request Syntax
response = client.create_field_level_encryption_config( FieldLevelEncryptionConfig={ 'CallerReference': 'string', 'Comment': 'string', 'QueryArgProfileConfig': { 'ForwardWhenQueryArgProfileIsUnknown': True|False, 'QueryArgProfiles': { 'Quantity': 123, 'Items': [ { 'QueryArg': 'string', 'ProfileId': 'string' }, ] } }, 'ContentTypeProfileConfig': { 'ForwardWhenContentTypeIsUnknown': True|False, 'ContentTypeProfiles': { 'Quantity': 123, 'Items': [ { 'Format': 'URLEncoded', 'ProfileId': 'string', 'ContentType': 'string' }, ] } } } )
- Parameters:
FieldLevelEncryptionConfig (dict) –
[REQUIRED]
The request to create a new field-level encryption configuration.
CallerReference (string) – [REQUIRED]
A unique number that ensures the request can’t be replayed.
Comment (string) –
An optional comment about the configuration. The comment cannot be longer than 128 characters.
QueryArgProfileConfig (dict) –
A complex data type that specifies when to forward content if a profile isn’t found and the profile that can be provided as a query argument in a request.
ForwardWhenQueryArgProfileIsUnknown (boolean) – [REQUIRED]
Flag to set if you want a request to be forwarded to the origin even if the profile specified by the field-level encryption query argument, fle-profile, is unknown.
QueryArgProfiles (dict) –
Profiles specified for query argument-profile mapping for field-level encryption.
Quantity (integer) – [REQUIRED]
Number of profiles for query argument-profile mapping for field-level encryption.
Items (list) –
Number of items for query argument-profile mapping for field-level encryption.
(dict) –
Query argument-profile mapping for field-level encryption.
QueryArg (string) – [REQUIRED]
Query argument for field-level encryption query argument-profile mapping.
ProfileId (string) – [REQUIRED]
ID of profile to use for field-level encryption query argument-profile mapping
ContentTypeProfileConfig (dict) –
A complex data type that specifies when to forward content if a content type isn’t recognized and profiles to use as by default in a request if a query argument doesn’t specify a profile to use.
ForwardWhenContentTypeIsUnknown (boolean) – [REQUIRED]
The setting in a field-level encryption content type-profile mapping that specifies what to do when an unknown content type is provided for the profile. If true, content is forwarded without being encrypted when the content type is unknown. If false (the default), an error is returned when the content type is unknown.
ContentTypeProfiles (dict) –
The configuration for a field-level encryption content type-profile.
Quantity (integer) – [REQUIRED]
The number of field-level encryption content type-profile mappings.
Items (list) –
Items in a field-level encryption content type-profile mapping.
(dict) –
A field-level encryption content type profile.
Format (string) – [REQUIRED]
The format for a field-level encryption content type-profile mapping.
ProfileId (string) –
The profile ID for a field-level encryption content type-profile mapping.
ContentType (string) – [REQUIRED]
The content type for a field-level encryption content type-profile mapping.
- Return type:
dict
- Returns:
Response Syntax
{ 'FieldLevelEncryption': { 'Id': 'string', 'LastModifiedTime': datetime(2015, 1, 1), 'FieldLevelEncryptionConfig': { 'CallerReference': 'string', 'Comment': 'string', 'QueryArgProfileConfig': { 'ForwardWhenQueryArgProfileIsUnknown': True|False, 'QueryArgProfiles': { 'Quantity': 123, 'Items': [ { 'QueryArg': 'string', 'ProfileId': 'string' }, ] } }, 'ContentTypeProfileConfig': { 'ForwardWhenContentTypeIsUnknown': True|False, 'ContentTypeProfiles': { 'Quantity': 123, 'Items': [ { 'Format': 'URLEncoded', 'ProfileId': 'string', 'ContentType': 'string' }, ] } } } }, 'Location': 'string', 'ETag': 'string' }
Response Structure
(dict) –
FieldLevelEncryption (dict) –
Returned when you create a new field-level encryption configuration.
Id (string) –
The configuration ID for a field-level encryption configuration which includes a set of profiles that specify certain selected data fields to be encrypted by specific public keys.
LastModifiedTime (datetime) –
The last time the field-level encryption configuration was changed.
FieldLevelEncryptionConfig (dict) –
A complex data type that includes the profile configurations specified for field-level encryption.
CallerReference (string) –
A unique number that ensures the request can’t be replayed.
Comment (string) –
An optional comment about the configuration. The comment cannot be longer than 128 characters.
QueryArgProfileConfig (dict) –
A complex data type that specifies when to forward content if a profile isn’t found and the profile that can be provided as a query argument in a request.
ForwardWhenQueryArgProfileIsUnknown (boolean) –
Flag to set if you want a request to be forwarded to the origin even if the profile specified by the field-level encryption query argument, fle-profile, is unknown.
QueryArgProfiles (dict) –
Profiles specified for query argument-profile mapping for field-level encryption.
Quantity (integer) –
Number of profiles for query argument-profile mapping for field-level encryption.
Items (list) –
Number of items for query argument-profile mapping for field-level encryption.
(dict) –
Query argument-profile mapping for field-level encryption.
QueryArg (string) –
Query argument for field-level encryption query argument-profile mapping.
ProfileId (string) –
ID of profile to use for field-level encryption query argument-profile mapping
ContentTypeProfileConfig (dict) –
A complex data type that specifies when to forward content if a content type isn’t recognized and profiles to use as by default in a request if a query argument doesn’t specify a profile to use.
ForwardWhenContentTypeIsUnknown (boolean) –
The setting in a field-level encryption content type-profile mapping that specifies what to do when an unknown content type is provided for the profile. If true, content is forwarded without being encrypted when the content type is unknown. If false (the default), an error is returned when the content type is unknown.
ContentTypeProfiles (dict) –
The configuration for a field-level encryption content type-profile.
Quantity (integer) –
The number of field-level encryption content type-profile mappings.
Items (list) –
Items in a field-level encryption content type-profile mapping.
(dict) –
A field-level encryption content type profile.
Format (string) –
The format for a field-level encryption content type-profile mapping.
ProfileId (string) –
The profile ID for a field-level encryption content type-profile mapping.
ContentType (string) –
The content type for a field-level encryption content type-profile mapping.
Location (string) –
The fully qualified URI of the new configuration resource just created.
ETag (string) –
The current version of the field level encryption configuration. For example:
E2QWRUHAPOMQZL
.
Exceptions
CloudFront.Client.exceptions.QueryArgProfileEmpty
CloudFront.Client.exceptions.TooManyFieldLevelEncryptionQueryArgProfiles
CloudFront.Client.exceptions.TooManyFieldLevelEncryptionContentTypeProfiles
CloudFront.Client.exceptions.FieldLevelEncryptionConfigAlreadyExists
CloudFront.Client.exceptions.InconsistentQuantities
CloudFront.Client.exceptions.TooManyFieldLevelEncryptionConfigs
CloudFront.Client.exceptions.NoSuchFieldLevelEncryptionProfile
CloudFront.Client.exceptions.InvalidArgument