Updated on 2023-08-11 GMT+08:00

WAF.service

Element Description

WAF examines and protects website service traffic from multiple dimensions. Together with deep learning, WAF intelligently identifies malicious requests and prevents unknown threats. It also avoids common attacks such as SQL injection and cross-site scripting so that these attacks will not affect availability or security, or consume too much resources, reducing the risk of data tampering and theft.

Element Properties

Table 1 Property Description

Property

Required

Descripiton

wafBandwidthPackage

No

Bandwidth external package of WAF service.

Type: WAF.Bandwidth

Default: {u'resourceType': u'hws.resource.type.waf.bandwidth', u'resourceSize': 0}

versionType

Yes

The version of WAF service.

Type: string

Value Description: WAF service offers 5 versions, including "devcloud","basic","professional","enterprise" and "ultimate".

Default: professional

Value Constraint: The value can only be "devcloud", "basic", "professional", "enterprise", "ultimate"

wafServicePackage

Yes

Fundamental package of WAF service.

Type: WAF.Service

Default: {u'resourceType': u'hws.resource.type.waf'}

wafDomainPackage

No

Domain external package of WAF service.

Type: WAF.Domain

Default: {u'resourceType': u'hws.resource.type.waf.domain', u'resourceSize': 0}

Relationships Between Elements

None.

Return Value

Property

Type

Description

refID

string

WAF service ID

Blueprint Example

tosca_definitions_version: huaweicloud_tosca_version_1_0
description: Web Application Firewall
inputs:
  version:
    description: The version of WAF service
    constraints:
      valid_values: ["devcloud", "basic", "professional", "enterprise", "ultimate"]
  domain-pack-num:
    type: integer
    description: The number of the domain external packages
  bandwidth-pack-num:
    type: integer
    description: The number of the bandwidth external packages
node_templates:
  waf-app:
    type: HuaweiCloud.WAF.service
    properties:
      wafServicePackage:
        cloudServiceType: hws.service.type.waf
        resourceType: hws.resource.type.waf
        resourceSpecCode: waf
        isMainResource: 1
      wafDomainPackage:
        cloudServiceType: hws.service.type.waf
        resourceType: hws.resource.type.waf.domain
        resourceSpecCode: waf.expack.domain
        resourceSize: 
          get_input: domain-pack-num
        isMainResource: 0
      wafBandwidthPackage:
        cloudServiceType: hws.service.type.waf
        resourceType: hws.resource.type.waf.bandwidth
        resourceSpecCode: waf.expack.bandwidth
        resourceSize: 
          get_input: bandwidth-pack-num
        isMainResource: 0
      versionType: 
        get_input: version
outputs:  
  waf-deployment:
    description: The container app name in cce
    value: { get_attribute: [ waf-app, Deployment, name ] }