Skip to content
v2.278.0

CfnLoggingConfigurationProps Struct ​

Properties for defining a CfnLoggingConfiguration.

Example ​

ts
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
import { aws_networkfirewall as networkfirewall } from 'aws-cdk-lib';
const cfnLoggingConfigurationProps: networkfirewall.CfnLoggingConfigurationProps = {
  firewallArn: 'firewallArn',
  loggingConfiguration: {
    logDestinationConfigs: [{
      logDestination: {
        logDestinationKey: 'logDestination',
      },
      logDestinationType: 'logDestinationType',
      logType: 'logType',
    }],
  },

  // the properties below are optional
  enableMonitoringDashboard: false,
  firewallName: 'firewallName',
};
python
# The code below shows an example of how to instantiate this type.
# The values are placeholders you should change.
from aws_cdk import aws_networkfirewall as networkfirewall

cfn_logging_configuration_props = networkfirewall.CfnLoggingConfigurationProps(
    firewall_arn="firewallArn",
    logging_configuration=networkfirewall.CfnLoggingConfiguration.LoggingConfigurationProperty(
        log_destination_configs=[networkfirewall.CfnLoggingConfiguration.LogDestinationConfigProperty(
            log_destination={
                "log_destination_key": "logDestination"
            },
            log_destination_type="logDestinationType",
            log_type="logType"
        )]
    ),

    # the properties below are optional
    enable_monitoring_dashboard=False,
    firewall_name="firewallName"
)
java
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
import software.amazon.awscdk.services.networkfirewall.*;

CfnLoggingConfigurationProps cfnLoggingConfigurationProps = CfnLoggingConfigurationProps.builder()
        .firewallArn("firewallArn")
        .loggingConfiguration(LoggingConfigurationProperty.builder()
                .logDestinationConfigs(List.of(LogDestinationConfigProperty.builder()
                        .logDestination(Map.of(
                                "logDestinationKey", "logDestination"))
                        .logDestinationType("logDestinationType")
                        .logType("logType")
                        .build()))
                .build())

        // the properties below are optional
        .enableMonitoringDashboard(false)
        .firewallName("firewallName")
        .build();
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.AWS.NetworkFirewall;

var cfnLoggingConfigurationProps = new CfnLoggingConfigurationProps {
    FirewallArn = "firewallArn",
    LoggingConfiguration = new LoggingConfigurationProperty {
        LogDestinationConfigs = new [] { new LogDestinationConfigProperty {
            LogDestination = new Dictionary<string, string> {
                { "logDestinationKey", "logDestination" }
            },
            LogDestinationType = "logDestinationType",
            LogType = "logType"
        } }
    },

    // the properties below are optional
    EnableMonitoringDashboard = false,
    FirewallName = "firewallName"
};
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 "github.com/aws/aws-cdk-go/awscdk"

cfnLoggingConfigurationProps := &CfnLoggingConfigurationProps{
	FirewallArn: jsii.String("firewallArn"),
	LoggingConfiguration: &LoggingConfigurationProperty{
		LogDestinationConfigs: []interface{}{
			&LogDestinationConfigProperty{
				LogDestination: map[string]*string{
					"logDestinationKey": jsii.String("logDestination"),
				},
				LogDestinationType: jsii.String("logDestinationType"),
				LogType: jsii.String("logType"),
			},
		},
	},

	// the properties below are optional
	EnableMonitoringDashboard: jsii.Boolean(false),
	FirewallName: jsii.String("firewallName"),
}

Properties ​

enableMonitoringDashboardoptionalboolean | IResolvableenable_monitoring_dashboardoptionaltyping.Union[bool, IResolvable]enableMonitoringDashboardoptionalBooleanEnableMonitoringDashboardoptionalboolEnableMonitoringDashboardoptionalinterface{} #
firewallArnstring | IFirewallReffirewall_arntyping.Union[str, IFirewallRef]firewallArnStringFirewallArnstringFirewallArninterface{} required #
The Amazon Resource Name (ARN) of the firewallthat the logging configuration is associated with.

You can't change the firewall specification after you create the logging configuration.

firewallNameoptionalstringfirewall_nameoptionalstrfirewallNameoptionalStringFirewallNameoptionalstringFirewallNameoptional*string #
The name of the firewall that the logging configuration is associated with.

You can't change the firewall specification after you create the logging configuration.

loggingConfigurationIResolvable | CfnLoggingConfiguration.LoggingConfigurationPropertylogging_configurationtyping.Union[IResolvable, LoggingConfigurationProperty]loggingConfigurationIResolvableLoggingConfigurationIResolvableLoggingConfigurationinterface{} required #
Defines how AWS Network Firewall performs logging for a firewall.