Website Profiles
The learned structure of an application is called a profile of the website. Website profiles are made up of profiles for URLs and profiles for parameters of those URLs. A URL profile lists allowed fields like HTTP methods, names and types of each parameter, query strings, length based restrictions, etc. A Parameter profile defines the allowed format for each parameter using either a negative or positive security model and includes length restrictions.
Website Profiles allow you to create specific rules to fine tune the security settings of a Service. They do not modify the default security policy settings, but fine tune security settings specific to a Service. For more information, see Configuring Website Profiles.
The following diagram shows the location of enforcement of Website Profiles in the Request/Response evaluation flow:
For more information on the complete evaluation flow for requests and responses, refer to Evaluation Policy and Flow.
To Update a Website Profile
URL: /v1/virtual_services/{virtual_service_id} | |||
Method: PUT | |||
Description: Updates the values of given parameters in the given website profile. | |||
Parameter Name | Data Type | Mandatory | Description |
|---|---|---|---|
Input Parameters: |
|
|
|
use_profile | String | Optional | Specifies whether or not to validate the incoming requests against the URL profiles and parameter profiles. The values include:
|
strict_profile_check | String | Optional | Specifies whether or not to enforce strict profile checks for the requests coming for the specified service. The values include:
|
mode | Enumeration | Optional | Specifies the mode of the website profile for the specified service. The enumerated values include:
|
allowed_domains | Alphanumeric | Optional | Specify the domain or IP address of the Service whose requests/responses should be validated against the URL and parameter profiles. |
exclude_url_patterns | Alphanumeric | Optional | Specify the URL patterns to be excluded in the URL profile validations. |
include_url_patterns | Alphanumeric | Optional | Specify the URL patterns to be included in the URL profile validations in spite of being listed in the exclude_url_patterns parameter. |
Example: Updating a Website Profile
Request:
curl http://10.11.26.132:8000/restapi/v1/virtual_services/service_4 -u 'eyJldCI6IjI2NTk5MzYzMDUiLCJwYXNzd29yZCI6IjBjMjZlNjRiNTFhYTUxMWE0YzhhN2ZkNzQy\nMTllZTg5IiwidXNlciI6ImFkbWluIn0=\n:' -X PUT -H Content-Type:application/json -d '{"website_profiles":{"use_profile":"yes","strict_profile_check":"no","mode":"passive","allowed_domains":["*","www.abc.com","99.99.1.119"],"exclude_url_patterns":["*.jpg","*.txt"],"include_url_patterns":["*.jpeg"]}}'
Response:
{"id":"service_4","token":"eyJldCI6IjI2NTk5MzYzMDUiLCJwYXNzd29yZCI6IjBjMjZlNjRiNTFhYTUxMWE0YzhhN2ZkNzQy\nMTllZTg5IiwidXNlciI6ImFkbWluIn0=\n"}
To Create a URL Profile
URL: /v1/virtual_services/{virtual_service_id}/url_profiles | |||
Method: POST |