Getting information about a WAF profile
-
In the management console
, select the folder containing the WAF profile. -
Navigate
to Smart Web Security. -
In the left-hand panel, select WAF profiles.
-
Select the profile in question.
-
The Overview page will show the profile details:
- Basic profile parameters.
- Security profiles the WAF profile is attached to.
- Rule sets included in the profile, number of active rules in each set, anomaly and paranoia level for the OWASP set.
With Terraform
Terraform is distributed under the Business Source License
For more information about the provider resources, see the guides on the Terraform
If you do not have Terraform yet, install it and configure the Yandex Cloud provider.
To manage infrastructure using Terraform under a service account or user accounts (a Yandex account, a federated account, or a local user), authenticate using the appropriate method.
To get info about the Yandex Smart Web Security WAF profile you created with Terraform:
-
Add the
dataandoutputsections to the Terraform configuration file:data "yandex_sws_waf_profile" "default" { name = "<WAF_profile_name>" } output "profile-created" { value = data.yandex_sws_waf_profile.default.created_at }Where:
-
data "yandex_sws_waf_profile": Description of the WAF profile as a data source:name: WAF profile name.
-
output "profile-created": Output variable that contains information about the WAF profile creation timestamp:value: Value returned by the data source.
You can replace
created_atwith any other attribute to get the information you need. For more on the properties of theyandex_sws_waf_profiledata source, see this provider guide. -
-
Create the resources:
-
In the terminal, navigate to the configuration file directory.
-
Make sure the configuration is correct using this command:
terraform validateIf the configuration is valid, you will get this message:
Success! The configuration is valid. -
Run this command:
terraform planYou will see a list of resources and their properties. No changes will be made at this step. Terraform will show any errors in the configuration.
-
Apply the configuration changes:
terraform apply -
Type
yesand press Enter to confirm the changes.
Terraform will create all required resources and display their output variables. To check the results, run this command:
terraform outputResult:
profile-created = "2024-12-13T17:45:34Z" -
To get information about a Yandex Smart Web Security WAF profile, use the get REST API method for the WafProfile resource or the WafProfile/Get gRPC API call.