Upgrading an EOL cloud node image¶
These instructions describe the steps to upgrade the end‑of‑life cloud node image (version 3.6 and lower) deployed on AWS or GCP up to 5.0.
Wallarm nodes 3.6 and lower are not supported
You are recommended to upgrade the Wallarm nodes 3.6 and lower since these versions are not supported, they are end-of-life.
Node configuration and traffic filtration have been significantly simplified in the Wallarm node of the latest versions. Before upgrading the modules, please carefully review the list of changes and general recommendations. Please note that some settings of the latest node are incompatible with the nodes 3.6 and lower.
Requirements¶
-
Access to the account with the Administrator role in Wallarm Console in the US Cloud or EU Cloud
-
Access to
https://us1.api.wallarm.com
if working with US Wallarm Cloud or tohttps://api.wallarm.com
if working with EU Wallarm Cloud. Please ensure the access is not blocked by a firewall -
Access to the IP addresses below for downloading updates to attack detection rules and API specifications, as well as retrieving precise IPs for your allowlisted, denylisted, or graylisted countries, regions, or data centers
Step 1: Inform Wallarm technical support that you are upgrading filtering node modules (only if upgrading node 2.18 or lower)¶
If upgrading the node 2.18 or lower, please inform Wallarm technical support that you are upgrading filtering node modules up to the latest version and ask to enable new IP list logic for your Wallarm account. When new IP list logic is enabled, please ensure the section IP lists of Wallarm Console is available.
Step 2: Disable the Active threat verification module (only if upgrading node 2.16 or lower)¶
If upgrading Wallarm node 2.16 or lower, please disable the Active threat verification module in Wallarm Console → Vulnerabilities → Configure.
The module operation can cause false positives during the upgrade process. Disabling the module minimizes this risk.
Step 3: Update API port¶
Starting with version 4.0, the filtering node uploads data to the Cloud using the us1.api.wallarm.com:443
(US Cloud) and api.wallarm.com:443
(EU Cloud) API endpoints instead of us1.api.wallarm.com:444
and api.wallarm.com:444
.
If you upgrade the node from the version 3.x or lower and your server with the deployed node has a limited access to the external resources and the access is granted to each resource separately, then after upgrade the synchronization between the filtering node and the Cloud will stop.
To restore the synchronization, in your configuration, change port 444
to 443
for API endpoint for each resource.
Step 4: Review recent architectural updates¶
The latest update has introduced architectural changes that may impact users, especially those changing default configuration files of the node. Please familiarize yourself with these changes to ensure proper configuration and usage of the new image.
Step 5: Launch a new instance with the filtering node 5.0¶
Copy the settings for processing and proxying requests from the following configuration files of the previous Wallarm node version to the files of the filtering node 5.0:
-
Open the Wallarm filtering node image on the cloud platform marketplace and proceed to the image launch:
-
At the launch step, set the following settings:
- Select the image version
5.0.x
- For AWS, select the created security group in the field Security Group Settings
- For AWS, select the name of the created key pair in the field Key Pair Settings
- Select the image version
-
Confirm the instance launch.
-
For GCP, configure the instance following these instructions.
Step 6: Adjust Wallarm node filtration mode settings to changes released in the latest versions (only if upgrading node 2.18 or lower)¶
-
Ensure that the expected behavior of settings listed below corresponds to the changed logic of the
off
andmonitoring
filtration modes: -
If the expected behavior does not correspond to the changed filtration mode logic, please adjust the filtration mode settings to released changes using the instructions.
Step 7: Connect the filtering node to Wallarm Cloud¶
-
Connect to the filtering node instance via SSH. More detailed instructions for connecting to the instances are available in the cloud platform documentation:
-
Create a new Wallarm node and connect it to the Wallarm Cloud using the generated token as described in the instructions for the cloud platform:
Step 8: Copy the filtering node settings from the previous version to the new version¶
-
Copy the settings for processing and proxying requests from the following configuration files of the previous Wallarm node version to the files of the filtering node 5.0:
/etc/nginx/nginx.conf
and other files with NGINX settings-
/etc/nginx/conf.d/wallarm-status.conf
with the filtering node monitoring service settingsMake sure the copied file contents correspond to the recommended safe configuration.
-
/etc/environment
with environment variables - any other custom configuration files for request processing and proxying, taking into account the recent architectural changes
-
Rename the following NGINX directives if they are explicitly specified in configuration files:
wallarm_instance
→wallarm_application
wallarm_local_trainingset_path
→wallarm_custom_ruleset_path
wallarm_global_trainingset_path
→wallarm_protondb_path
wallarm_ts_request_memory_limit
→wallarm_general_ruleset_memory_limit
We only changed the names of the directives, their logic remains the same. Directives with former names will be deprecated soon, so you are recommended to rename them before.
-
If the extended logging format is configured, please check if the
wallarm_request_time
variable is explicitly specified in the configuration.If so, please rename it to
wallarm_request_cpu_time
.We only changed the variable name, its logic remains the same. The old name is temporarily supported as well, but still it is recommended to rename the variable.
-
If upgrading node 2.18 or lower, migrate allowlist and denylist configuration from previous Wallarm node version to 5.0.
-
If the page
&/usr/share/nginx/html/wallarm_blocked.html
is returned to blocked requests, copy and customize its new version.In the new node version, the Wallarm sample blocking page has been changed. The logo and support email on the page are now empty by default.
Detailed information about working with NGINX configuration files is available in the official NGINX documentation.
The list of filtering node directives is available here.
Step 8: Transfer the overlimit_res
attack detection configuration from directives to the rule¶
Starting from the version 3.6, you can fine-tune the overlimit_res
attack detection using the rule in Wallarm Console.
Earlier, the wallarm_process_time_limit
and wallarm_process_time_limit_block
NGINX directives have been used. The listed directives are considered to be deprecated with the new rule release and will be deleted in future releases.
If the overlimit_res
attack detection settings are customized via the listed directives, it is recommended to transfer them to the rule as follows:
-
Open Wallarm Console → Rules and proceed to the Limit request processing time rule setup.
-
Configure the rule as done via the NGINX directives:
- The rule condition should match the NGINX configuration block with the
wallarm_process_time_limit
andwallarm_process_time_limit_block
directives specified. -
The time limit for the node to process a single request (milliseconds): the value of
wallarm_process_time_limit
.Risk of running out of system memory
The high time limit and/or continuation of request processing after the limit is exceeded can trigger memory exhaustion or out-of-time request processing.
-
The node will either block or pass the
overlimit_res
attack depending on the node filtration mode:- In the monitoring mode, the node forwards the original request to the application address. The application has the risk to be exploited by the attacks included in both processed and unprocessed request parts.
- In the safe blocking mode, the node blocks the request if it is originated from the graylisted IP address. Otherwise, the node forwards the original request to the application address. The application has the risk to be exploited by the attacks included in both processed and unprocessed request parts.
- In the block mode, the node blocks the request.
- The rule condition should match the NGINX configuration block with the
-
Delete the
wallarm_process_time_limit
andwallarm_process_time_limit_block
NGINX directives from the NGINX configuration file.If the
overlimit_res
attack detection is fine-tuned using both the directives and the rule, the node will process requests as the rule sets.
Step 9: Restart NGINX¶
Restart NGINX to apply the settings:
Step 10: Test Wallarm node operation¶
-
Send the request with test Path Traversal attack to a protected resource address:
-
Open Wallarm Console → Attacks section in the US Cloud or EU Cloud and make sure the attack is displayed in the list.
Step 11: Create the virtual machine image based on the filtering node 5.0 in AWS or GCP¶
To create the virtual machine image based on the filtering node 5.0, please follow the instructions for AWS or GCP.
Step 12: Delete the previous Wallarm node instance¶
If the new version of the filtering node is successfully configured and tested, remove the instance and virtual machine image with the previous version of the filtering node using the AWS or GCP management console.
Step 13: Re-enable the Active threat verification module (only if upgrading node 2.16 or lower)¶
Learn the recommendation on the Active threat verification module setup and re-enable it if required.
After a while, ensure the module operation does not cause false positives. If discovering false positives, please contact the Wallarm technical support.