// *** WARNING: this file was generated by the Pulumi Terraform Bridge (tfgen) Tool. ***
// *** Do not edit by hand unless you're certain you know what you are doing! ***

using System;
using System.Collections.Generic;
using System.Collections.Immutable;
using System.Threading.Tasks;
using Pulumi.Serialization;
using Pulumi;

namespace Pulumiverse.Fortios
{
    /// <summary>
    /// Configure Web proxy global settings.
    /// 
    /// ## Example Usage
    /// 
    /// ```csharp
    /// using System.Collections.Generic;
    /// using System.Linq;
    /// using Pulumi;
    /// using Fortios = Pulumiverse.Fortios;
    /// 
    /// return await Deployment.RunAsync(() =&gt; 
    /// {
    ///     var trname = new Fortios.WebproxyGlobal("trname", new()
    ///     {
    ///         FastPolicyMatch = "enable",
    ///         ForwardProxyAuth = "disable",
    ///         ForwardServerAffinityTimeout = 30,
    ///         LearnClientIp = "disable",
    ///         MaxMessageLength = 32,
    ///         MaxRequestLength = 4,
    ///         MaxWafBodyCacheLength = 32,
    ///         ProxyFqdn = "default.fqdn",
    ///         SslCaCert = "Fortinet_CA_SSL",
    ///         SslCert = "Fortinet_Factory",
    ///         StrictWebCheck = "disable",
    ///         TunnelNonHttp = "enable",
    ///         UnknownHttpVersion = "best-effort",
    ///     });
    /// 
    /// });
    /// ```
    /// 
    /// ## Import
    /// 
    /// WebProxy Global can be imported using any of these accepted formats
    /// 
    /// ```sh
    ///  $ pulumi import fortios:index/webproxyGlobal:WebproxyGlobal labelname WebProxyGlobal
    /// ```
    /// 
    ///  If you do not want to import arguments of block$ export "FORTIOS_IMPORT_TABLE"="false"
    /// 
    /// ```sh
    ///  $ pulumi import fortios:index/webproxyGlobal:WebproxyGlobal labelname WebProxyGlobal
    /// ```
    /// 
    ///  $ unset "FORTIOS_IMPORT_TABLE"
    /// </summary>
    [FortiosResourceType("fortios:index/webproxyGlobal:WebproxyGlobal")]
    public partial class WebproxyGlobal : global::Pulumi.CustomResource
    {
        /// <summary>
        /// Sort sub-tables, please do not set this parameter when configuring static sub-tables. Options: [ false, true, natural, alphabetical ]. false: Default value, do not sort tables; true/natural: sort tables in natural order. For example: [ a10, a2 ] -&gt; [ a2, a10 ]; alphabetical: sort tables in alphabetical order. For example: [ a10, a2 ] -&gt; [ a10, a2 ].
        /// </summary>
        [Output("dynamicSortSubtable")]
        public Output<string?> DynamicSortSubtable { get; private set; } = null!;

        /// <summary>
        /// Enable/disable fast matching algorithm for explicit and transparent proxy policy. Valid values: `enable`, `disable`.
        /// </summary>
        [Output("fastPolicyMatch")]
        public Output<string> FastPolicyMatch { get; private set; } = null!;

        /// <summary>
        /// Enable/disable forwarding proxy authentication headers. Valid values: `enable`, `disable`.
        /// </summary>
        [Output("forwardProxyAuth")]
        public Output<string> ForwardProxyAuth { get; private set; } = null!;

        /// <summary>
        /// Period of time before the source IP's traffic is no longer assigned to the forwarding server (6 - 60 min, default = 30).
        /// </summary>
        [Output("forwardServerAffinityTimeout")]
        public Output<int> ForwardServerAffinityTimeout { get; private set; } = null!;

        /// <summary>
        /// Enable/disable LDAP user cache for explicit and transparent proxy user. Valid values: `enable`, `disable`.
        /// </summary>
        [Output("ldapUserCache")]
        public Output<string> LdapUserCache { get; private set; } = null!;

        /// <summary>
        /// Enable/disable learning the client's IP address from headers. Valid values: `enable`, `disable`.
        /// </summary>
        [Output("learnClientIp")]
        public Output<string> LearnClientIp { get; private set; } = null!;

        /// <summary>
        /// Learn client IP address from the specified headers. Valid values: `true-client-ip`, `x-real-ip`, `x-forwarded-for`.
        /// </summary>
        [Output("learnClientIpFromHeader")]
        public Output<string> LearnClientIpFromHeader { get; private set; } = null!;

        /// <summary>
        /// IPv6 Source address name (srcaddr or srcaddr6 must be set). The structure of `learn_client_ip_srcaddr6` block is documented below.
        /// </summary>
        [Output("learnClientIpSrcaddr6s")]
        public Output<ImmutableArray<Outputs.WebproxyGlobalLearnClientIpSrcaddr6>> LearnClientIpSrcaddr6s { get; private set; } = null!;

        /// <summary>
        /// Source address name (srcaddr or srcaddr6 must be set). The structure of `learn_client_ip_srcaddr` block is documented below.
        /// </summary>
        [Output("learnClientIpSrcaddrs")]
        public Output<ImmutableArray<Outputs.WebproxyGlobalLearnClientIpSrcaddr>> LearnClientIpSrcaddrs { get; private set; } = null!;

        /// <summary>
        /// Maximum length of HTTP message, not including body (16 - 256 Kbytes, default = 32).
        /// </summary>
        [Output("maxMessageLength")]
        public Output<int> MaxMessageLength { get; private set; } = null!;

        /// <summary>
        /// Maximum length of HTTP request line (2 - 64 Kbytes, default = 4).
        /// </summary>
        [Output("maxRequestLength")]
        public Output<int> MaxRequestLength { get; private set; } = null!;

        /// <summary>
        /// Maximum length of HTTP messages processed by Web Application Firewall (WAF) (10 - 1024 Kbytes, default = 32).
        /// </summary>
        [Output("maxWafBodyCacheLength")]
        public Output<int> MaxWafBodyCacheLength { get; private set; } = null!;

        /// <summary>
        /// Fully Qualified Domain Name (FQDN) that clients connect to (default = default.fqdn) to connect to the explicit web proxy.
        /// </summary>
        [Output("proxyFqdn")]
        public Output<string> ProxyFqdn { get; private set; } = null!;

        /// <summary>
        /// IPv4 source addresses to exempt proxy affinity.
        /// </summary>
        [Output("srcAffinityExemptAddr")]
        public Output<string> SrcAffinityExemptAddr { get; private set; } = null!;

        /// <summary>
        /// IPv6 source addresses to exempt proxy affinity.
        /// </summary>
        [Output("srcAffinityExemptAddr6")]
        public Output<string> SrcAffinityExemptAddr6 { get; private set; } = null!;

        /// <summary>
        /// SSL CA certificate for SSL interception.
        /// </summary>
        [Output("sslCaCert")]
        public Output<string> SslCaCert { get; private set; } = null!;

        /// <summary>
        /// SSL certificate for SSL interception.
        /// </summary>
        [Output("sslCert")]
        public Output<string> SslCert { get; private set; } = null!;

        /// <summary>
        /// Enable/disable strict web checking to block web sites that send incorrect headers that don't conform to HTTP 1.1. Valid values: `enable`, `disable`.
        /// </summary>
        [Output("strictWebCheck")]
        public Output<string> StrictWebCheck { get; private set; } = null!;

        /// <summary>
        /// Enable/disable allowing non-HTTP traffic. Allowed non-HTTP traffic is tunneled. Valid values: `enable`, `disable`.
        /// </summary>
        [Output("tunnelNonHttp")]
        public Output<string> TunnelNonHttp { get; private set; } = null!;

        /// <summary>
        /// Action to take when an unknown version of HTTP is encountered: reject, allow (tunnel), or proceed with best-effort. Valid values: `reject`, `tunnel`, `best-effort`.
        /// </summary>
        [Output("unknownHttpVersion")]
        public Output<string> UnknownHttpVersion { get; private set; } = null!;

        /// <summary>
        /// Specifies the vdom to which the resource will be applied when the FortiGate unit is running in VDOM mode. Only one vdom can be specified. If you want to inherit the vdom configuration of the provider, please do not set this parameter.
        /// </summary>
        [Output("vdomparam")]
        public Output<string?> Vdomparam { get; private set; } = null!;

        /// <summary>
        /// Name of the web proxy profile to apply when explicit proxy traffic is allowed by default and traffic is accepted that does not match an explicit proxy policy.
        /// </summary>
        [Output("webproxyProfile")]
        public Output<string> WebproxyProfile { get; private set; } = null!;


        /// <summary>
        /// Create a WebproxyGlobal resource with the given unique name, arguments, and options.
        /// </summary>
        ///
        /// <param name="name">The unique name of the resource</param>
        /// <param name="args">The arguments used to populate this resource's properties</param>
        /// <param name="options">A bag of options that control this resource's behavior</param>
        public WebproxyGlobal(string name, WebproxyGlobalArgs args, CustomResourceOptions? options = null)
            : base("fortios:index/webproxyGlobal:WebproxyGlobal", name, args ?? new WebproxyGlobalArgs(), MakeResourceOptions(options, ""))
        {
        }

        private WebproxyGlobal(string name, Input<string> id, WebproxyGlobalState? state = null, CustomResourceOptions? options = null)
            : base("fortios:index/webproxyGlobal:WebproxyGlobal", name, state, MakeResourceOptions(options, id))
        {
        }

        private static CustomResourceOptions MakeResourceOptions(CustomResourceOptions? options, Input<string>? id)
        {
            var defaultOptions = new CustomResourceOptions
            {
                Version = Utilities.Version,
                PluginDownloadURL = "github://api.github.com/pulumiverse/pulumi-fortios",
            };
            var merged = CustomResourceOptions.Merge(defaultOptions, options);
            // Override the ID if one was specified for consistency with other language SDKs.
            merged.Id = id ?? merged.Id;
            return merged;
        }
        /// <summary>
        /// Get an existing WebproxyGlobal resource's state with the given name, ID, and optional extra
        /// properties used to qualify the lookup.
        /// </summary>
        ///
        /// <param name="name">The unique name of the resulting resource.</param>
        /// <param name="id">The unique provider ID of the resource to lookup.</param>
        /// <param name="state">Any extra arguments used during the lookup.</param>
        /// <param name="options">A bag of options that control this resource's behavior</param>
        public static WebproxyGlobal Get(string name, Input<string> id, WebproxyGlobalState? state = null, CustomResourceOptions? options = null)
        {
            return new WebproxyGlobal(name, id, state, options);
        }
    }

    public sealed class WebproxyGlobalArgs : global::Pulumi.ResourceArgs
    {
        /// <summary>
        /// Sort sub-tables, please do not set this parameter when configuring static sub-tables. Options: [ false, true, natural, alphabetical ]. false: Default value, do not sort tables; true/natural: sort tables in natural order. For example: [ a10, a2 ] -&gt; [ a2, a10 ]; alphabetical: sort tables in alphabetical order. For example: [ a10, a2 ] -&gt; [ a10, a2 ].
        /// </summary>
        [Input("dynamicSortSubtable")]
        public Input<string>? DynamicSortSubtable { get; set; }

        /// <summary>
        /// Enable/disable fast matching algorithm for explicit and transparent proxy policy. Valid values: `enable`, `disable`.
        /// </summary>
        [Input("fastPolicyMatch")]
        public Input<string>? FastPolicyMatch { get; set; }

        /// <summary>
        /// Enable/disable forwarding proxy authentication headers. Valid values: `enable`, `disable`.
        /// </summary>
        [Input("forwardProxyAuth")]
        public Input<string>? ForwardProxyAuth { get; set; }

        /// <summary>
        /// Period of time before the source IP's traffic is no longer assigned to the forwarding server (6 - 60 min, default = 30).
        /// </summary>
        [Input("forwardServerAffinityTimeout")]
        public Input<int>? ForwardServerAffinityTimeout { get; set; }

        /// <summary>
        /// Enable/disable LDAP user cache for explicit and transparent proxy user. Valid values: `enable`, `disable`.
        /// </summary>
        [Input("ldapUserCache")]
        public Input<string>? LdapUserCache { get; set; }

        /// <summary>
        /// Enable/disable learning the client's IP address from headers. Valid values: `enable`, `disable`.
        /// </summary>
        [Input("learnClientIp")]
        public Input<string>? LearnClientIp { get; set; }

        /// <summary>
        /// Learn client IP address from the specified headers. Valid values: `true-client-ip`, `x-real-ip`, `x-forwarded-for`.
        /// </summary>
        [Input("learnClientIpFromHeader")]
        public Input<string>? LearnClientIpFromHeader { get; set; }

        [Input("learnClientIpSrcaddr6s")]
        private InputList<Inputs.WebproxyGlobalLearnClientIpSrcaddr6Args>? _learnClientIpSrcaddr6s;

        /// <summary>
        /// IPv6 Source address name (srcaddr or srcaddr6 must be set). The structure of `learn_client_ip_srcaddr6` block is documented below.
        /// </summary>
        public InputList<Inputs.WebproxyGlobalLearnClientIpSrcaddr6Args> LearnClientIpSrcaddr6s
        {
            get => _learnClientIpSrcaddr6s ?? (_learnClientIpSrcaddr6s = new InputList<Inputs.WebproxyGlobalLearnClientIpSrcaddr6Args>());
            set => _learnClientIpSrcaddr6s = value;
        }

        [Input("learnClientIpSrcaddrs")]
        private InputList<Inputs.WebproxyGlobalLearnClientIpSrcaddrArgs>? _learnClientIpSrcaddrs;

        /// <summary>
        /// Source address name (srcaddr or srcaddr6 must be set). The structure of `learn_client_ip_srcaddr` block is documented below.
        /// </summary>
        public InputList<Inputs.WebproxyGlobalLearnClientIpSrcaddrArgs> LearnClientIpSrcaddrs
        {
            get => _learnClientIpSrcaddrs ?? (_learnClientIpSrcaddrs = new InputList<Inputs.WebproxyGlobalLearnClientIpSrcaddrArgs>());
            set => _learnClientIpSrcaddrs = value;
        }

        /// <summary>
        /// Maximum length of HTTP message, not including body (16 - 256 Kbytes, default = 32).
        /// </summary>
        [Input("maxMessageLength")]
        public Input<int>? MaxMessageLength { get; set; }

        /// <summary>
        /// Maximum length of HTTP request line (2 - 64 Kbytes, default = 4).
        /// </summary>
        [Input("maxRequestLength")]
        public Input<int>? MaxRequestLength { get; set; }

        /// <summary>
        /// Maximum length of HTTP messages processed by Web Application Firewall (WAF) (10 - 1024 Kbytes, default = 32).
        /// </summary>
        [Input("maxWafBodyCacheLength")]
        public Input<int>? MaxWafBodyCacheLength { get; set; }

        /// <summary>
        /// Fully Qualified Domain Name (FQDN) that clients connect to (default = default.fqdn) to connect to the explicit web proxy.
        /// </summary>
        [Input("proxyFqdn", required: true)]
        public Input<string> ProxyFqdn { get; set; } = null!;

        /// <summary>
        /// IPv4 source addresses to exempt proxy affinity.
        /// </summary>
        [Input("srcAffinityExemptAddr")]
        public Input<string>? SrcAffinityExemptAddr { get; set; }

        /// <summary>
        /// IPv6 source addresses to exempt proxy affinity.
        /// </summary>
        [Input("srcAffinityExemptAddr6")]
        public Input<string>? SrcAffinityExemptAddr6 { get; set; }

        /// <summary>
        /// SSL CA certificate for SSL interception.
        /// </summary>
        [Input("sslCaCert")]
        public Input<string>? SslCaCert { get; set; }

        /// <summary>
        /// SSL certificate for SSL interception.
        /// </summary>
        [Input("sslCert")]
        public Input<string>? SslCert { get; set; }

        /// <summary>
        /// Enable/disable strict web checking to block web sites that send incorrect headers that don't conform to HTTP 1.1. Valid values: `enable`, `disable`.
        /// </summary>
        [Input("strictWebCheck")]
        public Input<string>? StrictWebCheck { get; set; }

        /// <summary>
        /// Enable/disable allowing non-HTTP traffic. Allowed non-HTTP traffic is tunneled. Valid values: `enable`, `disable`.
        /// </summary>
        [Input("tunnelNonHttp")]
        public Input<string>? TunnelNonHttp { get; set; }

        /// <summary>
        /// Action to take when an unknown version of HTTP is encountered: reject, allow (tunnel), or proceed with best-effort. Valid values: `reject`, `tunnel`, `best-effort`.
        /// </summary>
        [Input("unknownHttpVersion")]
        public Input<string>? UnknownHttpVersion { get; set; }

        /// <summary>
        /// Specifies the vdom to which the resource will be applied when the FortiGate unit is running in VDOM mode. Only one vdom can be specified. If you want to inherit the vdom configuration of the provider, please do not set this parameter.
        /// </summary>
        [Input("vdomparam")]
        public Input<string>? Vdomparam { get; set; }

        /// <summary>
        /// Name of the web proxy profile to apply when explicit proxy traffic is allowed by default and traffic is accepted that does not match an explicit proxy policy.
        /// </summary>
        [Input("webproxyProfile")]
        public Input<string>? WebproxyProfile { get; set; }

        public WebproxyGlobalArgs()
        {
        }
        public static new WebproxyGlobalArgs Empty => new WebproxyGlobalArgs();
    }

    public sealed class WebproxyGlobalState : global::Pulumi.ResourceArgs
    {
        /// <summary>
        /// Sort sub-tables, please do not set this parameter when configuring static sub-tables. Options: [ false, true, natural, alphabetical ]. false: Default value, do not sort tables; true/natural: sort tables in natural order. For example: [ a10, a2 ] -&gt; [ a2, a10 ]; alphabetical: sort tables in alphabetical order. For example: [ a10, a2 ] -&gt; [ a10, a2 ].
        /// </summary>
        [Input("dynamicSortSubtable")]
        public Input<string>? DynamicSortSubtable { get; set; }

        /// <summary>
        /// Enable/disable fast matching algorithm for explicit and transparent proxy policy. Valid values: `enable`, `disable`.
        /// </summary>
        [Input("fastPolicyMatch")]
        public Input<string>? FastPolicyMatch { get; set; }

        /// <summary>
        /// Enable/disable forwarding proxy authentication headers. Valid values: `enable`, `disable`.
        /// </summary>
        [Input("forwardProxyAuth")]
        public Input<string>? ForwardProxyAuth { get; set; }

        /// <summary>
        /// Period of time before the source IP's traffic is no longer assigned to the forwarding server (6 - 60 min, default = 30).
        /// </summary>
        [Input("forwardServerAffinityTimeout")]
        public Input<int>? ForwardServerAffinityTimeout { get; set; }

        /// <summary>
        /// Enable/disable LDAP user cache for explicit and transparent proxy user. Valid values: `enable`, `disable`.
        /// </summary>
        [Input("ldapUserCache")]
        public Input<string>? LdapUserCache { get; set; }

        /// <summary>
        /// Enable/disable learning the client's IP address from headers. Valid values: `enable`, `disable`.
        /// </summary>
        [Input("learnClientIp")]
        public Input<string>? LearnClientIp { get; set; }

        /// <summary>
        /// Learn client IP address from the specified headers. Valid values: `true-client-ip`, `x-real-ip`, `x-forwarded-for`.
        /// </summary>
        [Input("learnClientIpFromHeader")]
        public Input<string>? LearnClientIpFromHeader { get; set; }

        [Input("learnClientIpSrcaddr6s")]
        private InputList<Inputs.WebproxyGlobalLearnClientIpSrcaddr6GetArgs>? _learnClientIpSrcaddr6s;

        /// <summary>
        /// IPv6 Source address name (srcaddr or srcaddr6 must be set). The structure of `learn_client_ip_srcaddr6` block is documented below.
        /// </summary>
        public InputList<Inputs.WebproxyGlobalLearnClientIpSrcaddr6GetArgs> LearnClientIpSrcaddr6s
        {
            get => _learnClientIpSrcaddr6s ?? (_learnClientIpSrcaddr6s = new InputList<Inputs.WebproxyGlobalLearnClientIpSrcaddr6GetArgs>());
            set => _learnClientIpSrcaddr6s = value;
        }

        [Input("learnClientIpSrcaddrs")]
        private InputList<Inputs.WebproxyGlobalLearnClientIpSrcaddrGetArgs>? _learnClientIpSrcaddrs;

        /// <summary>
        /// Source address name (srcaddr or srcaddr6 must be set). The structure of `learn_client_ip_srcaddr` block is documented below.
        /// </summary>
        public InputList<Inputs.WebproxyGlobalLearnClientIpSrcaddrGetArgs> LearnClientIpSrcaddrs
        {
            get => _learnClientIpSrcaddrs ?? (_learnClientIpSrcaddrs = new InputList<Inputs.WebproxyGlobalLearnClientIpSrcaddrGetArgs>());
            set => _learnClientIpSrcaddrs = value;
        }

        /// <summary>
        /// Maximum length of HTTP message, not including body (16 - 256 Kbytes, default = 32).
        /// </summary>
        [Input("maxMessageLength")]
        public Input<int>? MaxMessageLength { get; set; }

        /// <summary>
        /// Maximum length of HTTP request line (2 - 64 Kbytes, default = 4).
        /// </summary>
        [Input("maxRequestLength")]
        public Input<int>? MaxRequestLength { get; set; }

        /// <summary>
        /// Maximum length of HTTP messages processed by Web Application Firewall (WAF) (10 - 1024 Kbytes, default = 32).
        /// </summary>
        [Input("maxWafBodyCacheLength")]
        public Input<int>? MaxWafBodyCacheLength { get; set; }

        /// <summary>
        /// Fully Qualified Domain Name (FQDN) that clients connect to (default = default.fqdn) to connect to the explicit web proxy.
        /// </summary>
        [Input("proxyFqdn")]
        public Input<string>? ProxyFqdn { get; set; }

        /// <summary>
        /// IPv4 source addresses to exempt proxy affinity.
        /// </summary>
        [Input("srcAffinityExemptAddr")]
        public Input<string>? SrcAffinityExemptAddr { get; set; }

        /// <summary>
        /// IPv6 source addresses to exempt proxy affinity.
        /// </summary>
        [Input("srcAffinityExemptAddr6")]
        public Input<string>? SrcAffinityExemptAddr6 { get; set; }

        /// <summary>
        /// SSL CA certificate for SSL interception.
        /// </summary>
        [Input("sslCaCert")]
        public Input<string>? SslCaCert { get; set; }

        /// <summary>
        /// SSL certificate for SSL interception.
        /// </summary>
        [Input("sslCert")]
        public Input<string>? SslCert { get; set; }

        /// <summary>
        /// Enable/disable strict web checking to block web sites that send incorrect headers that don't conform to HTTP 1.1. Valid values: `enable`, `disable`.
        /// </summary>
        [Input("strictWebCheck")]
        public Input<string>? StrictWebCheck { get; set; }

        /// <summary>
        /// Enable/disable allowing non-HTTP traffic. Allowed non-HTTP traffic is tunneled. Valid values: `enable`, `disable`.
        /// </summary>
        [Input("tunnelNonHttp")]
        public Input<string>? TunnelNonHttp { get; set; }

        /// <summary>
        /// Action to take when an unknown version of HTTP is encountered: reject, allow (tunnel), or proceed with best-effort. Valid values: `reject`, `tunnel`, `best-effort`.
        /// </summary>
        [Input("unknownHttpVersion")]
        public Input<string>? UnknownHttpVersion { get; set; }

        /// <summary>
        /// Specifies the vdom to which the resource will be applied when the FortiGate unit is running in VDOM mode. Only one vdom can be specified. If you want to inherit the vdom configuration of the provider, please do not set this parameter.
        /// </summary>
        [Input("vdomparam")]
        public Input<string>? Vdomparam { get; set; }

        /// <summary>
        /// Name of the web proxy profile to apply when explicit proxy traffic is allowed by default and traffic is accepted that does not match an explicit proxy policy.
        /// </summary>
        [Input("webproxyProfile")]
        public Input<string>? WebproxyProfile { get; set; }

        public WebproxyGlobalState()
        {
        }
        public static new WebproxyGlobalState Empty => new WebproxyGlobalState();
    }
}
