com.pulumi.aws.waf.kotlin.SqlInjectionMatchSetArgs.kt Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of pulumi-aws-kotlin Show documentation
Show all versions of pulumi-aws-kotlin Show documentation
Build cloud applications and infrastructure by combining the safety and reliability of infrastructure as code with the power of the Kotlin programming language.
@file:Suppress("NAME_SHADOWING", "DEPRECATION")
package com.pulumi.aws.waf.kotlin
import com.pulumi.aws.waf.SqlInjectionMatchSetArgs.builder
import com.pulumi.aws.waf.kotlin.inputs.SqlInjectionMatchSetSqlInjectionMatchTupleArgs
import com.pulumi.aws.waf.kotlin.inputs.SqlInjectionMatchSetSqlInjectionMatchTupleArgsBuilder
import com.pulumi.core.Output
import com.pulumi.core.Output.of
import com.pulumi.kotlin.ConvertibleToJava
import com.pulumi.kotlin.PulumiTagMarker
import com.pulumi.kotlin.applySuspend
import kotlin.String
import kotlin.Suppress
import kotlin.Unit
import kotlin.collections.List
import kotlin.jvm.JvmName
/**
* Provides a WAF SQL Injection Match Set Resource
* ## Example Usage
*
* ```typescript
* import * as pulumi from "@pulumi/pulumi";
* import * as aws from "@pulumi/aws";
* const sqlInjectionMatchSet = new aws.waf.SqlInjectionMatchSet("sql_injection_match_set", {
* name: "tf-sql_injection_match_set",
* sqlInjectionMatchTuples: [{
* textTransformation: "URL_DECODE",
* fieldToMatch: {
* type: "QUERY_STRING",
* },
* }],
* });
* ```
* ```python
* import pulumi
* import pulumi_aws as aws
* sql_injection_match_set = aws.waf.SqlInjectionMatchSet("sql_injection_match_set",
* name="tf-sql_injection_match_set",
* sql_injection_match_tuples=[{
* "text_transformation": "URL_DECODE",
* "field_to_match": {
* "type": "QUERY_STRING",
* },
* }])
* ```
* ```csharp
* using System.Collections.Generic;
* using System.Linq;
* using Pulumi;
* using Aws = Pulumi.Aws;
* return await Deployment.RunAsync(() =>
* {
* var sqlInjectionMatchSet = new Aws.Waf.SqlInjectionMatchSet("sql_injection_match_set", new()
* {
* Name = "tf-sql_injection_match_set",
* SqlInjectionMatchTuples = new[]
* {
* new Aws.Waf.Inputs.SqlInjectionMatchSetSqlInjectionMatchTupleArgs
* {
* TextTransformation = "URL_DECODE",
* FieldToMatch = new Aws.Waf.Inputs.SqlInjectionMatchSetSqlInjectionMatchTupleFieldToMatchArgs
* {
* Type = "QUERY_STRING",
* },
* },
* },
* });
* });
* ```
* ```go
* package main
* import (
* "github.com/pulumi/pulumi-aws/sdk/v6/go/aws/waf"
* "github.com/pulumi/pulumi/sdk/v3/go/pulumi"
* )
* func main() {
* pulumi.Run(func(ctx *pulumi.Context) error {
* _, err := waf.NewSqlInjectionMatchSet(ctx, "sql_injection_match_set", &waf.SqlInjectionMatchSetArgs{
* Name: pulumi.String("tf-sql_injection_match_set"),
* SqlInjectionMatchTuples: waf.SqlInjectionMatchSetSqlInjectionMatchTupleArray{
* &waf.SqlInjectionMatchSetSqlInjectionMatchTupleArgs{
* TextTransformation: pulumi.String("URL_DECODE"),
* FieldToMatch: &waf.SqlInjectionMatchSetSqlInjectionMatchTupleFieldToMatchArgs{
* Type: pulumi.String("QUERY_STRING"),
* },
* },
* },
* })
* if err != nil {
* return err
* }
* return nil
* })
* }
* ```
* ```java
* package generated_program;
* import com.pulumi.Context;
* import com.pulumi.Pulumi;
* import com.pulumi.core.Output;
* import com.pulumi.aws.waf.SqlInjectionMatchSet;
* import com.pulumi.aws.waf.SqlInjectionMatchSetArgs;
* import com.pulumi.aws.waf.inputs.SqlInjectionMatchSetSqlInjectionMatchTupleArgs;
* import com.pulumi.aws.waf.inputs.SqlInjectionMatchSetSqlInjectionMatchTupleFieldToMatchArgs;
* import java.util.List;
* import java.util.ArrayList;
* import java.util.Map;
* import java.io.File;
* import java.nio.file.Files;
* import java.nio.file.Paths;
* public class App {
* public static void main(String[] args) {
* Pulumi.run(App::stack);
* }
* public static void stack(Context ctx) {
* var sqlInjectionMatchSet = new SqlInjectionMatchSet("sqlInjectionMatchSet", SqlInjectionMatchSetArgs.builder()
* .name("tf-sql_injection_match_set")
* .sqlInjectionMatchTuples(SqlInjectionMatchSetSqlInjectionMatchTupleArgs.builder()
* .textTransformation("URL_DECODE")
* .fieldToMatch(SqlInjectionMatchSetSqlInjectionMatchTupleFieldToMatchArgs.builder()
* .type("QUERY_STRING")
* .build())
* .build())
* .build());
* }
* }
* ```
* ```yaml
* resources:
* sqlInjectionMatchSet:
* type: aws:waf:SqlInjectionMatchSet
* name: sql_injection_match_set
* properties:
* name: tf-sql_injection_match_set
* sqlInjectionMatchTuples:
* - textTransformation: URL_DECODE
* fieldToMatch:
* type: QUERY_STRING
* ```
*
* ## Import
* Using `pulumi import`, import AWS WAF SQL Injection Match Set using their ID. For example:
* ```sh
* $ pulumi import aws:waf/sqlInjectionMatchSet:SqlInjectionMatchSet example a1b2c3d4-d5f6-7777-8888-9999aaaabbbbcccc
* ```
* @property name The name or description of the SQL Injection Match Set.
* @property sqlInjectionMatchTuples The parts of web requests that you want AWS WAF to inspect for malicious SQL code and, if you want AWS WAF to inspect a header, the name of the header.
*/
public data class SqlInjectionMatchSetArgs(
public val name: Output? = null,
public val sqlInjectionMatchTuples: Output>? =
null,
) : ConvertibleToJava {
override fun toJava(): com.pulumi.aws.waf.SqlInjectionMatchSetArgs =
com.pulumi.aws.waf.SqlInjectionMatchSetArgs.builder()
.name(name?.applyValue({ args0 -> args0 }))
.sqlInjectionMatchTuples(
sqlInjectionMatchTuples?.applyValue({ args0 ->
args0.map({ args0 ->
args0.let({ args0 -> args0.toJava() })
})
}),
).build()
}
/**
* Builder for [SqlInjectionMatchSetArgs].
*/
@PulumiTagMarker
public class SqlInjectionMatchSetArgsBuilder internal constructor() {
private var name: Output? = null
private var sqlInjectionMatchTuples: Output>? =
null
/**
* @param value The name or description of the SQL Injection Match Set.
*/
@JvmName("lhsphipjqpcorjgi")
public suspend fun name(`value`: Output) {
this.name = value
}
/**
* @param value The parts of web requests that you want AWS WAF to inspect for malicious SQL code and, if you want AWS WAF to inspect a header, the name of the header.
*/
@JvmName("yhseijqcvktuahmk")
public suspend fun sqlInjectionMatchTuples(`value`: Output>) {
this.sqlInjectionMatchTuples = value
}
@JvmName("mnnupsvolbsnakck")
public suspend fun sqlInjectionMatchTuples(vararg values: Output) {
this.sqlInjectionMatchTuples = Output.all(values.asList())
}
/**
* @param values The parts of web requests that you want AWS WAF to inspect for malicious SQL code and, if you want AWS WAF to inspect a header, the name of the header.
*/
@JvmName("lsxjvpxypkwmrpni")
public suspend fun sqlInjectionMatchTuples(values: List
© 2015 - 2024 Weber Informatics LLC | Privacy Policy