NetworkFirewall / Client / create_tls_inspection_configuration

create_tls_inspection_configuration#

NetworkFirewall.Client.create_tls_inspection_configuration(**kwargs)#

Creates an Network Firewall TLS inspection configuration. A TLS inspection configuration contains the Certificate Manager certificate references that Network Firewall uses to decrypt and re-encrypt inbound traffic.

After you create a TLS inspection configuration, you associate it with a new firewall policy.

To update the settings for a TLS inspection configuration, use UpdateTLSInspectionConfiguration.

To manage a TLS inspection configuration’s tags, use the standard Amazon Web Services resource tagging operations, ListTagsForResource, TagResource, and UntagResource.

To retrieve information about TLS inspection configurations, use ListTLSInspectionConfigurations and DescribeTLSInspectionConfiguration.

For more information about TLS inspection configurations, see Decrypting SSL/TLS traffic with TLS inspection configurations in the Network Firewall Developer Guide.

See also: AWS API Documentation

Request Syntax

response = client.create_tls_inspection_configuration(
    TLSInspectionConfigurationName='string',
    TLSInspectionConfiguration={
        'ServerCertificateConfigurations': [
            {
                'ServerCertificates': [
                    {
                        'ResourceArn': 'string'
                    },
                ],
                'Scopes': [
                    {
                        'Sources': [
                            {
                                'AddressDefinition': 'string'
                            },
                        ],
                        'Destinations': [
                            {
                                'AddressDefinition': 'string'
                            },
                        ],
                        'SourcePorts': [
                            {
                                'FromPort': 123,
                                'ToPort': 123
                            },
                        ],
                        'DestinationPorts': [
                            {
                                'FromPort': 123,
                                'ToPort': 123
                            },
                        ],
                        'Protocols': [
                            123,
                        ]
                    },
                ]
            },
        ]
    },
    Description='string',
    Tags=[
        {
            'Key': 'string',
            'Value': 'string'
        },
    ],
    EncryptionConfiguration={
        'KeyId': 'string',
        'Type': 'CUSTOMER_KMS'|'AWS_OWNED_KMS_KEY'
    }
)
Parameters:
  • TLSInspectionConfigurationName (string) –

    [REQUIRED]

    The descriptive name of the TLS inspection configuration. You can’t change the name of a TLS inspection configuration after you create it.

  • TLSInspectionConfiguration (dict) –

    [REQUIRED]

    The object that defines a TLS inspection configuration. This, along with TLSInspectionConfigurationResponse, define the TLS inspection configuration. You can retrieve all objects for a TLS inspection configuration by calling DescribeTLSInspectionConfiguration.

    Network Firewall uses a TLS inspection configuration to decrypt traffic. Network Firewall re-encrypts the traffic before sending it to its destination.

    To use a TLS inspection configuration, you add it to a new Network Firewall firewall policy, then you apply the firewall policy to a firewall. Network Firewall acts as a proxy service to decrypt and inspect inbound traffic. You can reference a TLS inspection configuration from more than one firewall policy, and you can use a firewall policy in more than one firewall. For more information about using TLS inspection configurations, see Decrypting SSL/TLS traffic with TLS inspection configurations in the Network Firewall Developer Guide.

    • ServerCertificateConfigurations (list) –

      Lists the server certificate configurations that are associated with the TLS configuration.

      • (dict) –

        Configures the associated Certificate Manager Secure Sockets Layer/Transport Layer Security (SSL/TLS) server certificates and scope settings Network Firewall uses to decrypt traffic in a TLSInspectionConfiguration. For information about working with SSL/TLS certificates for TLS inspection, see Requirements for using SSL/TLS server certficiates with TLS inspection configurations in the Network Firewall Developer Guide.

        Note

        If a server certificate that’s associated with your TLSInspectionConfiguration is revoked, deleted, or expired it can result in client-side TLS errors.

        • ServerCertificates (list) –

          The list of a server certificate configuration’s Certificate Manager SSL/TLS certificates.

          • (dict) –

            Any Certificate Manager Secure Sockets Layer/Transport Layer Security (SSL/TLS) server certificate that’s associated with a ServerCertificateConfiguration used in a TLSInspectionConfiguration. You must request or import a SSL/TLS certificate into ACM for each domain Network Firewall needs to decrypt and inspect. Network Firewall uses the SSL/TLS certificates to decrypt specified inbound SSL/TLS traffic going to your firewall. For information about working with certificates in Certificate Manager, see Request a public certificate or Importing certificates in the Certificate Manager User Guide.

            • ResourceArn (string) –

              The Amazon Resource Name (ARN) of the Certificate Manager SSL/TLS server certificate.

        • Scopes (list) –

          A list of a server certificate configuration’s scopes.

          • (dict) –

            Settings that define the Secure Sockets Layer/Transport Layer Security (SSL/TLS) traffic that Network Firewall should decrypt for inspection by the stateful rule engine.

            • Sources (list) –

              The source IP addresses and address ranges to decrypt for inspection, in CIDR notation. If not specified, this matches with any source address.

              • (dict) –

                A single IP address specification. This is used in the MatchAttributes source and destination specifications.

                • AddressDefinition (string) – [REQUIRED]

                  Specify an IP address or a block of IP addresses in Classless Inter-Domain Routing (CIDR) notation. Network Firewall supports all address ranges for IPv4 and IPv6.

                  Examples:

                  • To configure Network Firewall to inspect for the IP address 192.0.2.44, specify 192.0.2.44/32.

                  • To configure Network Firewall to inspect for IP addresses from 192.0.2.0 to 192.0.2.255, specify 192.0.2.0/24.

                  • To configure Network Firewall to inspect for the IP address 1111:0000:0000:0000:0000:0000:0000:0111, specify 1111:0000:0000:0000:0000:0000:0000:0111/128.

                  • To configure Network Firewall to inspect for IP addresses from 1111:0000:0000:0000:0000:0000:0000:0000 to 1111:0000:0000:0000:ffff:ffff:ffff:ffff, specify 1111:0000:0000:0000:0000:0000:0000:0000/64.

                  For more information about CIDR notation, see the Wikipedia entry Classless Inter-Domain Routing.

            • Destinations (list) –

              The destination IP addresses and address ranges to decrypt for inspection, in CIDR notation. If not specified, this matches with any destination address.

              • (dict) –

                A single IP address specification. This is used in the MatchAttributes source and destination specifications.

                • AddressDefinition (string) – [REQUIRED]

                  Specify an IP address or a block of IP addresses in Classless Inter-Domain Routing (CIDR) notation. Network Firewall supports all address ranges for IPv4 and IPv6.

                  Examples:

                  • To configure Network Firewall to inspect for the IP address 192.0.2.44, specify 192.0.2.44/32.

                  • To configure Network Firewall to inspect for IP addresses from 192.0.2.0 to 192.0.2.255, specify 192.0.2.0/24.

                  • To configure Network Firewall to inspect for the IP address 1111:0000:0000:0000:0000:0000:0000:0111, specify 1111:0000:0000:0000:0000:0000:0000:0111/128.

                  • To configure Network Firewall to inspect for IP addresses from 1111:0000:0000:0000:0000:0000:0000:0000 to 1111:0000:0000:0000:ffff:ffff:ffff:ffff, specify 1111:0000:0000:0000:0000:0000:0000:0000/64.

                  For more information about CIDR notation, see the Wikipedia entry Classless Inter-Domain Routing.

            • SourcePorts (list) –

              The source ports to decrypt for inspection, in Transmission Control Protocol (TCP) format. If not specified, this matches with any source port.

              You can specify individual ports, for example 1994, and you can specify port ranges, such as 1990:1994.

              • (dict) –

                A single port range specification. This is used for source and destination port ranges in the stateless rule MatchAttributes, SourcePorts, and DestinationPorts settings.

                • FromPort (integer) – [REQUIRED]

                  The lower limit of the port range. This must be less than or equal to the ToPort specification.

                • ToPort (integer) – [REQUIRED]

                  The upper limit of the port range. This must be greater than or equal to the FromPort specification.

            • DestinationPorts (list) –

              The destination ports to decrypt for inspection, in Transmission Control Protocol (TCP) format. If not specified, this matches with any destination port.

              You can specify individual ports, for example 1994, and you can specify port ranges, such as 1990:1994.

              • (dict) –

                A single port range specification. This is used for source and destination port ranges in the stateless rule MatchAttributes, SourcePorts, and DestinationPorts settings.

                • FromPort (integer) – [REQUIRED]

                  The lower limit of the port range. This must be less than or equal to the ToPort specification.

                • ToPort (integer) – [REQUIRED]

                  The upper limit of the port range. This must be greater than or equal to the FromPort specification.

            • Protocols (list) –

              The protocols to decrypt for inspection, specified using each protocol’s assigned internet protocol number (IANA). Network Firewall currently supports only TCP.

              • (integer) –

  • Description (string) – A description of the TLS inspection configuration.

  • Tags (list) –

    The key:value pairs to associate with the resource.

    • (dict) –

      A key:value pair associated with an Amazon Web Services resource. The key:value pair can be anything you define. Typically, the tag key represents a category (such as “environment”) and the tag value represents a specific value within that category (such as “test,” “development,” or “production”). You can add up to 50 tags to each Amazon Web Services resource.

      • Key (string) – [REQUIRED]

        The part of the key:value pair that defines a tag. You can use a tag key to describe a category of information, such as “customer.” Tag keys are case-sensitive.

      • Value (string) – [REQUIRED]

        The part of the key:value pair that defines a tag. You can use a tag value to describe a specific value within a category, such as “companyA” or “companyB.” Tag values are case-sensitive.

  • EncryptionConfiguration (dict) –

    A complex type that contains optional Amazon Web Services Key Management Service (KMS) encryption settings for your Network Firewall resources. Your data is encrypted by default with an Amazon Web Services owned key that Amazon Web Services owns and manages for you. You can use either the Amazon Web Services owned key, or provide your own customer managed key. To learn more about KMS encryption of your Network Firewall resources, see Encryption at rest with Amazon Web Services Key Managment Service in the Network Firewall Developer Guide.

    • KeyId (string) –

      The ID of the Amazon Web Services Key Management Service (KMS) customer managed key. You can use any of the key identifiers that KMS supports, unless you’re using a key that’s managed by another account. If you’re using a key managed by another account, then specify the key ARN. For more information, see Key ID in the Amazon Web Services KMS Developer Guide.

    • Type (string) – [REQUIRED]

      The type of Amazon Web Services KMS key to use for encryption of your Network Firewall resources.

Return type:

dict

Returns:

Response Syntax

{
    'UpdateToken': 'string',
    'TLSInspectionConfigurationResponse': {
        'TLSInspectionConfigurationArn': 'string',
        'TLSInspectionConfigurationName': 'string',
        'TLSInspectionConfigurationId': 'string',
        'TLSInspectionConfigurationStatus': 'ACTIVE'|'DELETING',
        'Description': 'string',
        'Tags': [
            {
                'Key': 'string',
                'Value': 'string'
            },
        ],
        'LastModifiedTime': datetime(2015, 1, 1),
        'NumberOfAssociations': 123,
        'EncryptionConfiguration': {
            'KeyId': 'string',
            'Type': 'CUSTOMER_KMS'|'AWS_OWNED_KMS_KEY'
        },
        'Certificates': [
            {
                'CertificateArn': 'string',
                'CertificateSerial': 'string',
                'Status': 'string',
                'StatusMessage': 'string'
            },
        ]
    }
}

Response Structure

  • (dict) –

    • UpdateToken (string) –

      A token used for optimistic locking. Network Firewall returns a token to your requests that access the TLS inspection configuration. The token marks the state of the TLS inspection configuration resource at the time of the request.

      To make changes to the TLS inspection configuration, you provide the token in your request. Network Firewall uses the token to ensure that the TLS inspection configuration hasn’t changed since you last retrieved it. If it has changed, the operation fails with an InvalidTokenException. If this happens, retrieve the TLS inspection configuration again to get a current copy of it with a current token. Reapply your changes as needed, then try the operation again using the new token.

    • TLSInspectionConfigurationResponse (dict) –

      The high-level properties of a TLS inspection configuration. This, along with the TLSInspectionConfiguration, define the TLS inspection configuration. You can retrieve all objects for a TLS inspection configuration by calling DescribeTLSInspectionConfiguration.

      • TLSInspectionConfigurationArn (string) –

        The Amazon Resource Name (ARN) of the TLS inspection configuration.

      • TLSInspectionConfigurationName (string) –

        The descriptive name of the TLS inspection configuration. You can’t change the name of a TLS inspection configuration after you create it.

      • TLSInspectionConfigurationId (string) –

        A unique identifier for the TLS inspection configuration. This ID is returned in the responses to create and list commands. You provide it to operations such as update and delete.

      • TLSInspectionConfigurationStatus (string) –

        Detailed information about the current status of a TLSInspectionConfiguration. You can retrieve this for a TLS inspection configuration by calling DescribeTLSInspectionConfiguration and providing the TLS inspection configuration name and ARN.

      • Description (string) –

        A description of the TLS inspection configuration.

      • Tags (list) –

        The key:value pairs to associate with the resource.

        • (dict) –

          A key:value pair associated with an Amazon Web Services resource. The key:value pair can be anything you define. Typically, the tag key represents a category (such as “environment”) and the tag value represents a specific value within that category (such as “test,” “development,” or “production”). You can add up to 50 tags to each Amazon Web Services resource.

          • Key (string) –

            The part of the key:value pair that defines a tag. You can use a tag key to describe a category of information, such as “customer.” Tag keys are case-sensitive.

          • Value (string) –

            The part of the key:value pair that defines a tag. You can use a tag value to describe a specific value within a category, such as “companyA” or “companyB.” Tag values are case-sensitive.

      • LastModifiedTime (datetime) –

        The last time that the TLS inspection configuration was changed.

      • NumberOfAssociations (integer) –

        The number of firewall policies that use this TLS inspection configuration.

      • EncryptionConfiguration (dict) –

        A complex type that contains the Amazon Web Services KMS encryption configuration settings for your TLS inspection configuration.

        • KeyId (string) –

          The ID of the Amazon Web Services Key Management Service (KMS) customer managed key. You can use any of the key identifiers that KMS supports, unless you’re using a key that’s managed by another account. If you’re using a key managed by another account, then specify the key ARN. For more information, see Key ID in the Amazon Web Services KMS Developer Guide.

        • Type (string) –

          The type of Amazon Web Services KMS key to use for encryption of your Network Firewall resources.

      • Certificates (list) –

        A list of the certificates associated with the TLS inspection configuration.

        • (dict) –

          Contains metadata about an Certificate Manager certificate.

          • CertificateArn (string) –

            The Amazon Resource Name (ARN) of the certificate.

          • CertificateSerial (string) –

            The serial number of the certificate.

          • Status (string) –

            The status of the certificate.

          • StatusMessage (string) –

            Contains details about the certificate status, including information about certificate errors.

Exceptions

  • NetworkFirewall.Client.exceptions.InvalidRequestException

  • NetworkFirewall.Client.exceptions.ThrottlingException

  • NetworkFirewall.Client.exceptions.InternalServerError

  • NetworkFirewall.Client.exceptions.LimitExceededException

  • NetworkFirewall.Client.exceptions.InsufficientCapacityException