validate

package
v1.46.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Nov 10, 2020 License: MPL-2.0 Imports: 11 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var UUIDRegExp = regexp.MustCompile("^[a-fA-F0-9]{8}-[a-fA-F0-9]{4}-4[a-fA-F0-9]{3}-[8|9|aA|bB][a-fA-F0-9]{3}-[a-fA-F0-9]{12}$")

uuid regex helper

View Source
var ValidateWebApplicationFirewallPolicyRuleGroupName = validation.StringInSlice([]string{
	"crs_20_protocol_violations",
	"crs_21_protocol_anomalies",
	"crs_23_request_limits",
	"crs_30_http_policy",
	"crs_35_bad_robots",
	"crs_40_generic_attacks",
	"crs_41_sql_injection_attacks",
	"crs_41_xss_attacks",
	"crs_42_tight_security",
	"crs_45_trojans",
	"General",
	"REQUEST-911-METHOD-ENFORCEMENT",
	"REQUEST-913-SCANNER-DETECTION",
	"REQUEST-920-PROTOCOL-ENFORCEMENT",
	"REQUEST-921-PROTOCOL-ATTACK",
	"REQUEST-930-APPLICATION-ATTACK-LFI",
	"REQUEST-931-APPLICATION-ATTACK-RFI",
	"REQUEST-932-APPLICATION-ATTACK-RCE",
	"REQUEST-933-APPLICATION-ATTACK-PHP",
	"REQUEST-941-APPLICATION-ATTACK-XSS",
	"REQUEST-942-APPLICATION-ATTACK-SQLI",
	"REQUEST-943-APPLICATION-ATTACK-SESSION-FIXATION",
}, false)
View Source
var ValidateWebApplicationFirewallPolicyRuleSetType = validation.StringInSlice([]string{
	"OWASP",
	"Microsoft_BotManagerRuleSet",
}, false)
View Source
var ValidateWebApplicationFirewallPolicyRuleSetVersion = validation.StringInSlice([]string{
	"0.1",
	"1.0",
	"2.2.9",
	"3.0",
	"3.1",
}, false)

Functions

func ApiManagementApiName

func ApiManagementApiName(v interface{}, k string) (ws []string, es []error)

func ApiManagementApiPath

func ApiManagementApiPath(v interface{}, k string) (ws []string, es []error)

func ApiManagementBackendName

func ApiManagementBackendName(v interface{}, k string) (warnings []string, errors []error)

func ApiManagementChildName

func ApiManagementChildName(v interface{}, k string) (warnings []string, errors []error)

func ApiManagementServiceName

func ApiManagementServiceName(v interface{}, k string) (warnings []string, errors []error)

func ApiManagementServicePublisherEmail

func ApiManagementServicePublisherEmail(v interface{}, k string) (warnings []string, errors []error)

func ApiManagementServicePublisherName

func ApiManagementServicePublisherName(v interface{}, k string) (warnings []string, errors []error)

func ApiManagementUserName

func ApiManagementUserName(v interface{}, k string) (warnings []string, errors []error)

func AzureTimeZoneString

func AzureTimeZoneString() schema.SchemaValidateFunc

func BotMSTeamsCallingWebHook

func BotMSTeamsCallingWebHook() schema.SchemaValidateFunc

func CIDR

func CIDR(i interface{}, k string) (warnings []string, errors []error)

CIDR is a SchemaValidateFunc which tests if the provided value is a valid IPv4 CIDR

func CognitiveServicesAccountName

func CognitiveServicesAccountName() schema.SchemaValidateFunc

func CosmosAccountName

func CosmosAccountName(v interface{}, k string) (warnings []string, errors []error)

func CosmosEntityName

func CosmosEntityName(v interface{}, k string) (warnings []string, errors []error)

func CosmosMaxThroughput

func CosmosMaxThroughput(i interface{}, k string) (warnings []string, errors []error)

func CosmosThroughput

func CosmosThroughput(v interface{}, k string) (warnings []string, errors []error)

func DataFactoryName

func DataFactoryName() schema.SchemaValidateFunc

func DataFactoryPipelineAndTriggerName

func DataFactoryPipelineAndTriggerName() schema.SchemaValidateFunc

func DevSpaceName

func DevSpaceName() schema.SchemaValidateFunc

func DevTestLabName

func DevTestLabName() schema.SchemaValidateFunc

func DevTestVirtualMachineName

func DevTestVirtualMachineName(maxLength int) schema.SchemaValidateFunc

func DevTestVirtualNetworkUsagePermissionType

func DevTestVirtualNetworkUsagePermissionType() schema.SchemaValidateFunc

func EndpointDeliveryRuleName

func EndpointDeliveryRuleName() schema.SchemaValidateFunc

func FloatInSlice

func FloatInSlice(valid []float64) schema.SchemaValidateFunc

FloatInSlice returns a SchemaValidateFunc which tests if the provided value is of type float64 and matches the value of an element in the valid slice

func GoogleClientID

func GoogleClientID(v interface{}, k string) (warnings []string, errors []error)

func HDInsightClusterVersion

func HDInsightClusterVersion(i interface{}, k string) (warnings []string, errors []error)

func HDInsightName

func HDInsightName(v interface{}, k string) (warnings []string, errors []error)

func IPv4Address

func IPv4Address(i interface{}, k string) (warnings []string, errors []error)

func IPv4AddressOrEmpty

func IPv4AddressOrEmpty(i interface{}, k string) (warnings []string, errors []error)

func ISO8601DateTime

func ISO8601DateTime(i interface{}, k string) (warnings []string, errors []error)

func ISO8601Duration

func ISO8601Duration(i interface{}, k string) (warnings []string, errors []error)

func ISO8601DurationBetween

func ISO8601DurationBetween(min string, max string) func(i interface{}, k string) (warnings []string, errors []error)

func KubernetesAdminUserName

func KubernetesAdminUserName(i interface{}, k string) (warnings []string, errors []error)

func KubernetesAgentPoolName

func KubernetesAgentPoolName(i interface{}, k string) (warnings []string, errors []error)

func KubernetesDNSPrefix

func KubernetesDNSPrefix(i interface{}, k string) (warnings []string, errors []error)

func LowerCasedString

func LowerCasedString(i interface{}, k string) ([]string, []error)

LowerCasedString validates that the string is lower-cased

func PortNumber

func PortNumber(i interface{}, k string) (warnings []string, errors []error)

func PortNumberOrZero

func PortNumberOrZero(i interface{}, k string) (warnings []string, errors []error)

func PublicIpDomainNameLabel

func PublicIpDomainNameLabel(v interface{}, k string) (warnings []string, errors []error)

func RFC3339DateInFutureBy

func RFC3339DateInFutureBy(d time.Duration) schema.SchemaValidateFunc

RFC3339 date is duration d or greater into the future

func RegExHelper

func RegExHelper(i interface{}, k, r string) (match bool, errors []error)

func RuleActionCacheExpirationDuration

func RuleActionCacheExpirationDuration() schema.SchemaValidateFunc

func RuleActionUrlRedirectFragment

func RuleActionUrlRedirectFragment() schema.SchemaValidateFunc

func RuleActionUrlRedirectPath

func RuleActionUrlRedirectPath() schema.SchemaValidateFunc

func RuleActionUrlRedirectQueryString

func RuleActionUrlRedirectQueryString() schema.SchemaValidateFunc

func RuleActionUrlRewriteDestination

func RuleActionUrlRewriteDestination() schema.SchemaValidateFunc

func RuleActionUrlRewriteSourcePattern

func RuleActionUrlRewriteSourcePattern() schema.SchemaValidateFunc

func ServiceBusMaxSizeInMegabytes

func ServiceBusMaxSizeInMegabytes() schema.SchemaValidateFunc

func SharedAccessSignatureIP

func SharedAccessSignatureIP(v interface{}, k string) (warnings []string, errors []error)

func SharedImageGalleryName

func SharedImageGalleryName(v interface{}, k string) (warnings []string, errors []error)

func SharedImageName

func SharedImageName(v interface{}, k string) (warnings []string, errors []error)

func SharedImageVersionName

func SharedImageVersionName(v interface{}, k string) (warnings []string, errors []error)

func StorageContainerName

func StorageContainerName(v interface{}, k string) (warnings []string, errors []error)

func StorageShareDirectoryName

func StorageShareDirectoryName(v interface{}, k string) (warnings []string, errors []error)

func StreamAnalyticsJobStreamingUnits

func StreamAnalyticsJobStreamingUnits(i interface{}, k string) (w []string, es []error)

func VirtualMachineTimeZone

func VirtualMachineTimeZone() schema.SchemaValidateFunc

VirtualMachineTimeZone returns a case-sensitive validation function for the Time Zones for a Virtual Machine

func VirtualMachineTimeZoneCaseInsensitive

func VirtualMachineTimeZoneCaseInsensitive() schema.SchemaValidateFunc

VirtualMachineTimeZone returns a case-insensitive validation function for the Time Zones for a Virtual Machine

func VirtualNetworkRuleName

func VirtualNetworkRuleName(v interface{}, k string) (warnings []string, errors []error)

Types

This section is empty.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL