Traffic Enforcement Configuration
Once the application is up and running, it’s time to configure it for enabling traffic mitigation. This means we need to create virtual scrubbers (objects containing protection policies based on target), each virtual scrubber inspects the traffic matching one, or more, destination subnets. Each virtual scrubber, identified by a target ID, has its own traffic enforcement profiles that can be configured/changed/inspected at runtime using the API.
This sections provides some basic knowledge for configuring the engine using the REST API. Please refer to the API documentation for the full API specifications.
Note that although this section covers the configuration using the REST API, a few command line tools (see Appendix A) are also available to ease the configuration, including:
- nscrub-cli, implementing a console with autocompletion with all the functionalities implemented by the REST API.
- nscrub-add, a wizard tool for creating new victims with a basic configuration (further customisations are usually needed using nscrub-cli or the API).
- nscrub-export, a tool for dumping the current configuration for a specific victim.
Default settings for configuring nscrub:
| HTTP port | 8880 |
|---|---|
| HTTPs port | 4443 |
| Socket binding | localhost |
INFO
nScrub listens on localhost by default, please configure a different address (-G option) to use the REST API from a remote machine.
There are no default credentials: a password must be explicitly configured for the admin user before the REST API/CLI will accept authentication. See Setting the REST API Password below.
User Management
Setting the REST API Password
Passwords are stored in Redis as salted SHA-256 hashes under the key nscrub.user.<username>.password, in the format sha256:<salt>:<hash>, where <salt> is a random 16-byte hex string and <hash> is the SHA-256 digest of <salt> concatenated with the password.
To set the password for the admin user, run the command below, replacing newpassword with the desired password (the same command can be used for any other username by replacing admin in the Redis key):
SALT=$(openssl rand -hex 16); redis-cli SET nscrub.user.admin.password "sha256:${SALT}:$(printf '%s%s' "$SALT" 'newpassword' | openssl dgst -sha256 -r | awk '{print $1}')"If Redis listens on a non-default host/port, supply the connection details with -h host and -p port (or -n db-id for a non-default database).
Changing the Password
Once the initial admin password is set, credentials can also be managed (while nScrub is running) using the REST API or the CLI.
Using nscrub-cli:
nscrub-cli> usermod <username> <group> <new_password>Example to change the admin password:
nscrub-cli> usermod admin administrator newpasswordUsing the REST API directly:
curl -u admin:<password> "https://localhost:4443/users?action=update&username=admin&group=administrator&password=newpassword"Adding and Removing Users
Using nscrub-cli:
nscrub-cli> useradd <username> <group> <password> # add a new user
nscrub-cli> userdel <username> # remove a user
nscrub-cli> users # list all usersUsing the REST API:
curl -u admin:<password> "https://localhost:4443/users?action=add&username=john&group=administrator&password=secret"
curl -u admin:<password> "https://localhost:4443/users?action=del&username=john"
curl -u admin:<password> "https://localhost:4443/users?action=list"Password Reset (Emergency)
If you lost the admin password, set a new one directly in Redis using the same command shown in Setting the REST API Password above (no restart is required). Passwords hashed by older nScrub versions (a plain unsalted MD5 hash) are still accepted for backward compatibility, and are automatically upgraded to the salted SHA-256 format the next time that user logs in successfully.
Traffic Enforcement Logic
Understanding how nScrub processes and enforces traffic policies is essential for proper configuration. This section explains the core traffic enforcement mechanism and how profiles interact to provide DDoS protection while allowing legitimate traffic.
Profile-Based Traffic Inspection
Each virtual scrubber (victim) has four profiles that define traffic enforcement policies:
- DEFAULT profile: Applied to traffic from IP addresses not in any list (unknown sources)
- WHITE profile: Applied to whitelisted IP addresses (verified legitimate sources)
- BLACK profile: Applied to blacklisted IP addresses (known attackers)
- GRAY profile: Applied to IP addresses requiring special handling
WAN to LAN Traffic Flow (Inbound Traffic Inspection)
Traffic arriving from the WAN interface destined to protected subnets (targets/victims) is first checked against the global attackers list based on the source IP address. If there is no specific match there (or the target ignores the global list), it is checked against the target attackers list, always based on the source IP address, and the matching per-target profile:
Unknown Sources (DEFAULT profile):
- Traffic from sources not in any list (WHITE, BLACK, or GRAY) is evaluated by the DEFAULT profile
- Typically configured with a "drop by default" policy since traffic should only pass after verification
- The DEFAULT profile contains validation checks (SYN checks, DNS checks, rate limits, etc.)
- When a packet passes all checks and is verified as legitimate, the source IP is automatically added to the WHITE list
- Subsequent packets from that source will then be processed by the WHITE profile
Whitelisted Sources (WHITE profile):
Traffic from sources in the WHITE list is processed by the WHITE profile
Should be configured with an "accept all" policy to allow legitimate traffic to flow freely
Sources are added to WHITE list either:
- Automatically after successful verification by DEFAULT profile checks
- Manually via API/CLI
- From LAN to WAN traffic (see below)
Blacklisted Sources (BLACK profile):
Traffic from sources in the BLACK list is processed by the BLACK profile
Typically configured to drop all traffic
Sources are added to BLACK list either:
- Manually via API/CLI
- Automatically by auto-blacklist features when sources fail validation or exceed rate limits
Gray-listed Sources (GRAY profile):
- Traffic from sources in the GRAY list requires special policies
- Useful for applying custom rules to specific IP addresses or subnets
- Typically configured with default "drop" and specific allow rules for certain traffic types
LAN to WAN Traffic Flow (Outbound Traffic)
Traffic from the LAN (protected network) to WAN is handled differently:
- All LAN to WAN traffic is always passed without inspection
- When a packet is sent from the LAN, the destination IP is automatically whitelisted
- This ensures return traffic (where the whitelisted destination becomes the source on WAN) is accepted through the WHITE profile
- This mechanism allows legitimate bidirectional communication initiated from the protected network
Important: If return traffic is not working as expected, this typically indicates a misconfiguration that requires debugging (e.g., incorrect WHITE profile policy, routing issues, or asymmetric routing problems).
Traffic Verification and Promotion Example
Here's a typical flow for a new TCP connection:
External client (1.2.3.4) sends SYN packet to victim (10.0.0.1)
Source 1.2.3.4 is not in any list → DEFAULT profile applies
DEFAULT profile has SYN check enabled (e.g., RFC compliance check)
If SYN packet passes validation:
- Packet is forwarded to victim
- Source 1.2.3.4 is added to WHITE list
Subsequent packets from 1.2.3.4 → WHITE profile applies
WHITE profile has "accept all" → packets flow freely
If idle timeout expires (with autopurging enabled), 1.2.3.4 may be removed from WHITE list
Configuration Best Practices
For proper traffic enforcement:
WHITE profile: Set "accept all" policy
consolecurl -u admin:admin "https://localhost:4443/profile/all/accept?target_id=VICTIM&profile=white&action=enable"BLACK profile: Set "drop all" policy
consolecurl -u admin:admin "https://localhost:4443/profile/all/drop?target_id=VICTIM&profile=black&action=enable"DEFAULT profile: Configure with validation checks and "drop by default"
consolecurl -u admin:admin "https://localhost:4443/profile/default?target_id=VICTIM&profile=default&action=update&value=drop" curl -u admin:admin "https://localhost:4443/profile/tcp/syn/check_method?target_id=VICTIM&profile=default&action=update&value=rfc"Dynamic list management: Enable autopurging to automatically remove idle whitelisted IPs
consolecurl -u admin:admin "https://localhost:4443/attackers/dynamic/autopurging?target_id=VICTIM&action=enable" curl -u admin:admin "https://localhost:4443/attackers/dynamic/expiration?target_id=VICTIM&action=update&value=3600"
Please check the Step-By-Step Guide for a full (basic) configuration example.
Victims definition
Victims can be dynamically added, removed and configured at runtime. This section shows some examples of the most common runtime settings, focusing on the REST API. The below sections describe all the available API calls to configure the engine using both the CLI and the REST API.
Read active victims:
curl -u <user>:<password> "https://<host>:<port>/targets?action=list"or do the same using the command line tool:
nscrub-cli
localhost:8880> list targetsAdd a new victim:
curl -u <user>:<password> "https://<host>:<port>/targets?action=add&target_id=<victim name>&subnet=<subnet (CIDR notation)>"Each victim is bound to four profiles: default, black, white, and gray. These profiles define how traffic is processed based on the source IP address. For a detailed explanation of how profiles work and the traffic enforcement logic, see the "Traffic Enforcement Logic" section above.
INFO
This section provides only a few examples of victim configuration, for the full settings please refer to the API documentation.
It is a common practice to set the "drop all" policy to the black profile:
curl -u <user>:<password> "https://<host>:<port>/profile/all/drop?target_id=<victim name>&profile=black&action=enable"It is also a common practice to set the "accept all" policy to the white profile:
curl -u <user>:<password> "https://<host>:<port>/profile/all/accept?target_id=<victim name>&profile=white&action=enable"The gray profile is usually used for applying special policies to "special" IPs. For instance it is a common practice to set the "default" policy to "drop" and then specify more specific policies to let specific traffic types through.
curl -u <user>:<password> "https://<host>:<port>/profile/default?target_id=<victim name>&profile=gray&action=update&value=drop"The default profile is where the real traffic enforcement policies go, for checking unknown traffic. For instance it is also a common practice to set the default policy to drop:
curl -u <user>:<password> "https://<host>:<port>/profile/default?target_id=<victim name>&profile=default&action=update&value=drop"Accept ICMP:
curl -u <user>:<password> "https://<host>:<port>/profile/icmp/accept?target_id=<victim name>&profile=default&action=enable"Drop UDP:
curl -u <user>:<password> "https://<host>:<port>/profile/udp/drop?target_id=<victim name>&profile=default&action=enable"Accept UDP port 53 (DNS):
curl -u <user>:<password> "https://<host>:<port>/profile/udp/src/53/accept?target_id=<victim name>&profile=default&action=enable"Check TCP traffic:
curl -u <user>:<password> "https://<host>:<port>/profile/tcp/syn/check_method?target_id=<victim name>&profile=default&action=update&value=rfc"It is also possible to set a rate limiter (in this example per source) to set a threshold to the traffic rate.
curl -u <user>:<password> "https://<host>:<port>/profile/rate?target_id=<victim name>&profile={black, white, gray, default}[&action=update&value=<pkts/s>]"Many more policies are available, please refer to the full API documentation.
Please note all the settings can also be read, omitting the action (and value) parameter.
In order to temporarily disable traffic checks, it is possible to put the system in bypass state, both globally:
curl -u <user>:<password> "https://<host>:<port>/bypass?[action={enable, disable}]"or per victim:
curl -u <user>:<password> "https://<host>:<port>/profile/bypass?target_id=<victim name>&profile=default[&action={enable, disable}]"Global Settings
Application version, configuration and status
CLI
> statusREST
curl -u <user>:<password> https://<host>:<port>/statusExample:
curl -u admin:admin https://localhost:4443/Stats
CLI
> statsREST
curl -u <user>:<password> https://<host>:<port>/statsExample:
curl -u admin:admin https://localhost:4443/statsConfigure system name
CLI
> hostname [NAME]REST
curl -u <user>:<password> https://<host>:<port>/hostname?[action=update\&value=<NAME>]Example:
curl -u admin:admin https://localhost:4443/hostnameConfigure system description
CLI
> desc [DESCRIPTION]REST
curl -u <user>:<password> https://<host>:<port>/desc?[action=update\&value=<DESCRIPTION>]Example:
curl -u admin:admin https://localhost:4443/descConfigure global bypass
Hardware bypass is used when available. Note: this is a full bypass, does not handle routing (when enabled).
CLI
> bypass [enable|disable]REST
curl -u <user>:<password> https://<host>:<port>/bypass?[action={enable, disable}]Example:
curl -u admin:admin https://localhost:4443/bypasscurl -u admin:admin https://localhost:4443/bypass?action=enablecurl -u admin:admin https://localhost:4443/bypass?action=disableRead the neighbor table
Read the ARP Table. Note that nScrub automatically learns neighbors reading the system arp table, thus you can manage neighbors using the standard arp commands. Example of manually adding an entry: $ arp -i eth1 -s 192.168.1.85 00:b1:ac:50:17:00 Example of manually deleting an entry: $ arp -d 192.168.1.85
CLI
> neighREST
curl -u <user>:<password> https://<host>:<port>/neigh?action=listExample:
curl -u admin:admin https://localhost:4443/neigh?action=listSet WAN/LAN IP
Set the IP address for the WAN or LAN interfaces (changes are applied on nscrub restart)
CLI
> ip
> ip WAN|LAN set IPREST
curl -u <user>:<password> https://<host>:<port>/ip?action=update&interface={WAN, LAN}&value=<IP>Example:
curl -u admin:admin https://localhost:4443/ipcurl -u admin:admin https://localhost:4443/ip?action=update\&interface=WAN\&value=10.10.10.1Read the routing table
Routing mode only.
CLI
> routeREST
curl -u <user>:<password> https://<host>:<port>/route?action=listExample:
curl -u admin:admin https://localhost:4443/route?action=listUpdate the routing table
Routing mode only.
CLI
> route add SUBNET gw IP
> route del SUBNETREST
curl -u <user>:<password> https://<host>:<port>/route?[action={add, del}\&destination=<CIDR>[\&gw=<IP>]]Example:
curl -u admin:admin https://localhost:4443/routecurl -u admin:admin https://localhost:4443/route?action=add\&destination=default\&gw=192.168.1.1curl -u admin:admin https://localhost:4443/route?action=add\&destination=10.10.10.0/24\&gw=10.10.10.1curl -u admin:admin https://localhost:4443/route?action=del\&destination=10.10.10.0/24Configure VLAN reforging
This is used to map ingress VLAN to egress VLAN. Note: to remove a mapping set Src-ID = Dest-ID
CLI
> vlan id SRC-VLAN-ID reforge [DST-VLAN-ID]REST
curl -u <user>:<password> https://<host>:<port>/vlan/id/<Src-ID>/reforge?[action=update\&value=<Dest-ID>]Example:
curl -u admin:admin https://localhost:4443/vlan/id/2/reforgecurl -u admin:admin https://localhost:4443/vlan/id/2/reforge?action=update\&value=3Read the VLAN reforging list
CLI
> vlanREST
curl -u <user>:<password> https://<host>:<port>/vlan/id?action=listExample:
curl -u admin:admin https://localhost:4443/vlan/id?action=listConfigure traffic mirroring
Define how traffic is sent to the auxiliary queues.
CLI
> mirror ID
> mirror ID type [forwarded|discarded|injected|all]
> mirror ID sampling [RATE]REST
curl -u <user>:<password> https://<host>:<port>/mirror/<queue set id>/type[?action=update\&value={forwarded, discarded, injected, all}]curl -u <user>:<password> https://<host>:<port>/mirror/<queue set id>/sampling[?action=update\&value=<sampling rate (0 for no traffic)>]Example:
curl -u admin:admin https://localhost:4443/mirror/0/type?action=update\&value=allcurl -u admin:admin https://localhost:4443/mirror/0/sampling?action=update\&value=1Configure the runtime debug level
CLI
> debug [LEVEL]REST
curl -u <user>:<password> https://<host>:<port>/debug[?action=update\&value=<level>]Example:
curl -u admin:admin https://localhost:4443/debugcurl -u admin:admin https://localhost:4443/debug?action=update\&value=2Configure peer (MAC) policy
This is usually not needed unless you want to blacklist a peer.
CLI
> peer
> peer add MAC policy pass|drop
> peer del MACREST
curl -u <user>:<password> https://<host>:<port>/peers?action={add,del,list}[\&address=<mac>[\&value={pass, drop}]]Example:
curl -u admin:admin https://localhost:4443/peers?action=listcurl -u admin:admin https://localhost:4443/peers?action=add\&address=00:11:22:33:44:55\&policy=dropcurl -u admin:admin https://localhost:4443/peers?action=del\&address=00:11:22:33:44:55Global Attackers Lists
In addition to per-target WHITE/BLACK/GRAY lists, nScrub supports global attackers lists, shared by all targets, so a blacklist (or whitelist) does not need to be loaded once per target.
- The global list is checked before the per-target profile lookup described below: if the relevant IP (source for WAN to LAN traffic) has an entry in the global list, that profile is used immediately and the per-target list is not consulted.
- If there is no global match, traffic falls through to the normal per-target profile lookup described in the rest of this section.
- Any target can opt out and only use its own lists, ignoring the global list entirely, see "Ignore the global attackers list for a target" in the Global Attackers Management section.
- The global list only supports statically managed entries (added/loaded via CLI/REST). There is no global equivalent of the per-target automatically-populated dynamic list, since dynamic detection is based on a single target traffic.
See the Global Attackers Management section for how to manage the global list via CLI/REST.
Targets Management
Read targets list
CLI
> list targetsREST
curl -u <user>:<password> https://<host>:<port>/targets?action=listExample:
curl -u admin:admin https://localhost:4443/targets?action=listAdd/del subnets from targets
If the target does not exists, it creates a new target.
CLI
> add target ID SUBNET
> del target ID SUBNETREST
curl -u <user>:<password> https://<host>:<port>/targets?action={add, del}\&target_id=<target id>\&subnet=<CIDR>Example:
curl -u admin:admin https://localhost:4443/targets?action=add\&target_id=SCRBR1\&subnet=10.10.11.1/32curl -u admin:admin https://localhost:4443/targets?action=del\&target_id=SCRBR1\&subnet=10.10.11.1/32Delete a target by name
Delete a target and its configuration. Use * for all targets.
CLI
> purge target ID|*REST
curl -u <user>:<password> https://<host>:<port>/targets?action=target_del\&target_id={<target id>,*}Example:
curl -u admin:admin https://localhost:4443/targets?action=target_del\&target_id=SCRBR1Set a description for the target
CLI
> target ID desc [DESCRIPTION]REST
curl -u <user>:<password> https://<host>:<port>/targets/desc?target_id=<target id>[\&action=update\&value=<DESCRIPTION>]Example:
curl -u admin:admin https://localhost:4443/targets/desc?target_id=SCRBR1Configure VLAN reforging for traffic towards the target
This can be used as an alternative to the global mapping /vlan/id/{Src-ID}/reforge Note: to disable reforging set Dest-ID = 0
CLI
> target ID vlan reforge [DST-VLAN-ID]REST
curl -u <user>:<password> https://<host>:<port>/targets/vlan/reforge?target_id=<target id>[\&action=update\&value=<Dest-ID>]Example:
curl -u admin:admin https://localhost:4443/targets/vlan/reforge?target_id=SCRBR1curl -u admin:admin https://localhost:4443/targets/vlan/reforge?target_id=SCRBR1\&action=update\&value=16Configure target type
Target types (Web server, Game server, DNS server, ISP clients, etc) are used to give hints to the engine and optimise the protection algorithms.
CLI
> target ID type [web|dns|game|isp]REST
curl -u <user>:<password> https://<host>:<port>/targets/type?target_id=<target id>[\&action=update\&value={web,dns,game,isp}]Example:
curl -u admin:admin https://localhost:4443/targets/type?target_id=SCRBR1curl -u admin:admin https://localhost:4443/targets/type?target_id=SCRBR1\&action=update\&value=webRead target stats
Read (inbound traffic only) stats for a target. Note: this accepts regexp (e.g. 'webserver_[0-9]*') as target id.
CLI
> target ID statsREST
curl -u <user>:<password> https://<host>:<port>/targets/stats?target_id=<target id>Example:
curl -u admin:admin https://localhost:4443/targets/stats?target_id=SCRBR1Attackers Management
Read attackers
Read the attackers for a specific target, specifying the list name, and filtering by profile Note:
- profile=* means all the attackers, profile=white/black/gray to select IPs matching a profile
- list=* means all the lists
- up to 100 items are returned by default, or limit if provided. The offset parameter can be used to handle pagination.
CLI
> target ID attackers show LISTNAME|* white|gray|black|*REST
curl -u <user>:<password> https://<host>:<port>/attackers?target_id=<target id>\&action=list\&profile={black, white, gray, *}\&list={<list name>, *}[\&offset=<offset>][\&limit=<max items>]Example:
curl -u admin:admin https://localhost:4443/attackers?target_id=SCRBR1\&action=list\&profile=*\&list=Testcurl -u admin:admin https://localhost:4443/attackers?target_id=SCRBR1\&action=list\&profile=*\&list=*\&offset=0\&limit=500Add/Delete attackers
Add/del items from an attacker list (optionally you can specify a lifetime for adding attackers to the dynamic list, in this case attackers are not persistent on application restart)
CLI
> target ID attackers add LISTNAME SUBNET white|gray|black [SEC]
> target ID attackers del LISTNAME SUBNETREST
curl -u <user>:<password> https://<host>:<port>/attackers?target_id=<target id>\&action={add, del}\&list=<list name>\&subnet=<CIDR>[\&profile={black, white, gray}][\&lifetime=<seconds>]Example:
curl -u admin:admin https://localhost:4443/attackers?target_id=SCRBR1\&action=add\&list=Test\&subnet=10.10.11.1/32\&profile=blackcurl -u admin:admin https://localhost:4443/attackers?target_id=SCRBR1\&action=del\&list=Test\&subnet=10.10.11.1/32Delete an attacker list
CLI
>REST
curl -u <user>:<password> https://<host>:<port>/attackers?target_id=<target id>\&action=list_del\&list=<list name>Example:
curl -u admin:admin https://localhost:4443/attackers?target_id=SCRBR1\&action=list_del\&list=TestPurge all attackers
This also deletes all lists.
CLI
> target ID attackers purge allREST
curl -u <user>:<password> https://<host>:<port>/attackers?target_id=<target id>\&action=purgeExample:
curl -u admin:admin https://localhost:4443/attackers?target_id=SCRBR1\&action=purgeList all attackers list
List all attackers lists for a target (this also returns the number of entries in each list)
CLI
> target ID attackers showlistsREST
curl -u <user>:<password> https://<host>:<port>/attackers?target_id=<target id>\&action=list_lsExample:
curl -u admin:admin https://localhost:4443/attackers?target_id=SCRBR1\&action=list_lsSearch attackers
Search for an attacker in a specific list (by name), all lists (using '*'), all configured lists (using 'static') or all dynamically whitelisted/blacklisted IPs (using 'dynamic'). Returns the list names where the subnet is defined.
CLI
> target ID attackers search LISTNAME|dynamic|* white|gray|black|* SUBNETREST
curl -u <user>:<password> https://<host>:<port>/attackers?target_id=<target id>\&action=search\&list={<list name>, dynamic, static, *}\&profile={black, white, gray, *}\&subnet=<CIDR>Example:
curl -u admin:admin https://localhost:4443/attackers?target_id=SCRBR1\&action=search\&list=*\&profile=*\&subnet=10.10.11.1/32curl -u admin:admin https://localhost:4443/attackers?target_id=SCRBR1\&action=search\&list=dynamic\&profile=*\&subnet=10.10.11.1/32Read dynamic list
This will also include subnets in static lists.
CLI
> target ID attackers show dynamic white|gray|black|*REST
curl -u <user>:<password> https://<host>:<port>/attackers?target_id=<target id>\&action=list\&profile={black, white, gray}\&list=dynamicExample:
curl -u admin:admin https://localhost:4443/attackers?target_id=SCRBR1\&action=list\&profile=white\&list=dynamicPurge dynamic list
CLI
> target ID attackers purge dynamicREST
curl -u <user>:<password> https://<host>:<port>/attackers/dynamic?target_id=<target id>\&action=purgeExample:
curl -u admin:admin https://localhost:4443/attackers/dynamic?target_id=SCRBR1\&action=purgeConfigure dynamic list autopurging
(auto remove dynamically whitelisted IPs on idle timeout)
CLI
> target ID attackers dynamic autopurging [enable|disable]REST
curl -u <user>:<password> https://<host>:<port>/attackers/dynamic/autopurging?target_id=<target id>[\&action={enable, disable}]Example:
curl -u admin:admin https://localhost:4443/attackers/dynamic/autopurging?target_id=SCRBR1curl -u admin:admin https://localhost:4443/attackers/dynamic/autopurging?target_id=SCRBR1\&action=enableConfigure dynamic list expiration for autopurging
CLI
This is the idle timeout for IPs which are automatically whitelisted or blacklisted by the engine.
> target ID attackers dynamic expiration [SEC]REST
curl -u <user>:<password> https://<host>:<port>/attackers/dynamic/expiration?target_id=<target id>[\&action=update\&value=<sec>]Example:
curl -u admin:admin https://localhost:4443/attackers/dynamic/expiration?target_id=SCRBR1curl -u admin:admin https://localhost:4443/attackers/dynamic/expiration?target_id=SCRBR1\&action=update\&value=3600Batch add/delete attackers
Add/del multiple items in a single call from an attacker list (JSON array via POST) Note: add-fast action updates the datapath faster (less impact on traffic), however it flushed all dynamically-added IPs and does not handle duplicate items across lists
CLI
> target ID attackers load LISTNAME FILEPATH white|gray|black [SEC]REST
Example:
curl -u admin:admin -X POST https://localhost:4443/attackers?target_id=SCRBR1\&action={add, add-fast}\&list=Test\&profile=black -d '["1.1.1.1/32","2.2.2.2/32"]'curl -u admin:admin -X POST https://localhost:4443/attackers?target_id=SCRBR1\&action=del\&list=Test -d '["1.1.1.1/32","2.2.2.2/32"]'Global Attackers Management
The global attackers list (see "Global Attackers List" above) is managed the same way as a per-target list, except calls omit target_id and use the /attackers/global endpoint (CLI: attackers global ..., a top-level command, as opposed to target ID attackers ...). Updates are applied immediately to the live datapath, same as per-target lists. Note: the dynamic, search, autopurging and expiration actions are not available for the global list.
Read global attackers
Read the global attackers, specifying the list name, and filtering by profile. Note:
- profile=* means all the attackers, profile=white/black/gray to select IPs matching a profile
- list=* means all the lists
- up to 100 items are returned by default, or limit if provided. The offset parameter can be used to handle pagination.
CLI
> attackers global show LISTNAME|* white|gray|black|*REST
curl -u <user>:<password> https://<host>:<port>/attackers/global?action=list\&profile={black, white, gray, *}\&list={<list name>, *}[\&offset=<offset>][\&limit=<max items>]Example:
curl -u admin:admin https://localhost:4443/attackers/global?action=list\&profile=*\&list=TestAdd/Delete global attackers
Add/del items from a global attacker list.
CLI
> attackers global add LISTNAME SUBNET white|gray|black [SEC]
> attackers global del LISTNAME SUBNETREST
curl -u <user>:<password> https://<host>:<port>/attackers/global?action={add, del}\&list=<list name>\&subnet=<CIDR>[\&profile={black, white, gray}][\&lifetime=<seconds>]Example:
curl -u admin:admin https://localhost:4443/attackers/global?action=add\&list=Test\&subnet=10.10.11.1/32\&profile=blackcurl -u admin:admin https://localhost:4443/attackers/global?action=del\&list=Test\&subnet=10.10.11.1/32Delete a global attacker list
CLI
> attackers global purge LISTNAMEREST
curl -u <user>:<password> https://<host>:<port>/attackers/global?action=list_del\&list=<list name>Example:
curl -u admin:admin https://localhost:4443/attackers/global?action=list_del\&list=TestPurge all global attackers
This also deletes all global lists.
CLI
> attackers global purge allREST
curl -u <user>:<password> https://<host>:<port>/attackers/global?action=purgeExample:
curl -u admin:admin https://localhost:4443/attackers/global?action=purgeList all global attackers lists
List all global attackers lists (this also returns the number of entries in each list).
CLI
> attackers global showlistsREST
curl -u <user>:<password> https://<host>:<port>/attackers/global?action=list_lsExample:
curl -u admin:admin https://localhost:4443/attackers/global?action=list_lsBatch add/delete global attackers
Add/del multiple items in a single call from a global attacker list (JSON array via POST). Note: add-fast action updates the datapath faster (less impact on traffic), however it flushes all dynamically-added IPs and does not handle duplicate items across lists
CLI
> attackers global load LISTNAME FILEPATH white|gray|black [SEC]REST
Example:
curl -u admin:admin -X POST https://localhost:4443/attackers/global?action={add, add-fast}\&list=Test\&profile=black -d '["1.1.1.1/32","2.2.2.2/32"]'curl -u admin:admin -X POST https://localhost:4443/attackers/global?action=del\&list=Test -d '["1.1.1.1/32","2.2.2.2/32"]'Ignore the global attackers list for a target
Per-target opt-out: when enabled, this target's traffic is matched only against its own per-target attackers list, ignoring the global attackers list entirely.
CLI
> target ID attackers ignoreglobal [enable|disable]REST
curl -u <user>:<password> https://<host>:<port>/attackers/global/ignore?target_id=<target id>[\&action={enable, disable}]Example:
curl -u admin:admin https://localhost:4443/attackers/global/ignore?target_id=SCRBR1curl -u admin:admin https://localhost:4443/attackers/global/ignore?target_id=SCRBR1\&action=enableTargets Profiles Configuration
Configure bypass
This can be set on the 'default' profile only and overwrites all more specific profiles.
CLI
> target ID profile white|gray|black|default bypass [enable|disable]REST
curl -u <user>:<password> https://<host>:<port>/profile/bypass?target_id=<target id>\&profile=default[\&action={enable, disable}]Example:
curl -u admin:admin https://localhost:4443/profile/bypass?target_id=SCRBR1\&profile=defaultcurl -u admin:admin https://localhost:4443/profile/bypass?target_id=SCRBR1\&profile=default\&action=disableConfigure default action
CLI
> target ID profile white|gray|black|default default [drop|pass]REST
curl -u <user>:<password> https://<host>:<port>/profile/default?target_id=<target id>\&profile={black, white, gray, default}[\&action=update\&value={pass, drop}]Example:
curl -u admin:admin https://localhost:4443/profile/default?target_id=SCRBR1\&profile=defaultcurl -u admin:admin https://localhost:4443/profile/default?target_id=SCRBR1\&profile=default\&action=update\&value=dropRate limiting per source/dest
Configure per-source (attacker) per-dest (victim) rate limiting (pkts/s)
CLI
> target ID profile white|gray|black|default rate src [PPS]
> target ID profile white|gray|black|default rate dst [PPS]REST
curl -u <user>:<password> https://<host>:<port>/profile/rate/{src, dst}?target_id=<target id>\&profile={black, white, gray, default}[\&action=update\&value=<pkts/s>]Example:
curl -u admin:admin https://localhost:4443/profile/rate/src?target_id=SCRBR1\&profile=defaultcurl -u admin:admin https://localhost:4443/profile/rate/src?target_id=SCRBR1\&profile=default\&action=update\&value=100Configure all traffic drop/accept
CLI
> target ID profile white|gray|black|default all drop [enable|disable]
> target ID profile white|gray|black|default all accept [enable|disable]REST
curl -u <user>:<password> https://<host>:<port>/profile/all/{accept, drop}?target_id=<target id>\&profile={black, white, gray, default}[\&action={enable, disable}]Example:
curl -u admin:admin https://localhost:4443/profile/all/drop?target_id=SCRBR1\&profile=blackcurl -u admin:admin https://localhost:4443/profile/all/drop?target_id=SCRBR1\&profile=black\&action=enableRead UDP/TCP/ICMP policies
Read a summary of the configured policies for each protocol.
CLI
> target ID profile white|gray|black|default [ip|udp|tcp|icmp|dns]REST
curl -u <user>:<password> https://<host>:<port>/profile/{udp, tcp, icmp}?target_id=<target id>\&profile={black, white, gray, default}Example:
curl -u admin:admin https://localhost:4443/profile/udp?target_id=SCRBR1\&profile=defaultConfigure UDP/TCP/ICMP drop/accept
This applies to all ports/types.
CLI
> target ID profile white|gray|black|default [udp|tcp|icmp]
> target ID profile white|gray|black|default [udp|tcp|icmp] drop [enable|disable]
> target ID profile white|gray|black|default [udp|tcp|icmp] accept [enable|disable]REST
curl -u <user>:<password> https://<host>:<port>/profile/{udp, tcp, icmp}/{accept, drop}?target_id=<target id>\&profile={black, white, gray, default}[\&action={enable, disable}]Example:
curl -u admin:admin https://localhost:4443/profile/udp/drop?target_id=SCRBR1\&profile=default\&action=enableConfigure GRE Signaling drop/accept
This works when decapsulation is enabled only.
CLI
> target ID profile white|gray|black|default gre
> target ID profile white|gray|black|default gre drop [enable|disable]
> target ID profile white|gray|black|default gre accept [enable|disable]REST
curl -u <user>:<password> https://<host>:<port>/profile/gre/{accept, drop}?target_id=<target id>\&profile={black, white, gray, default}[\&action={enable, disable}]Example:
curl -u admin:admin https://localhost:4443/profile/gre/accept?target_id=SCRBR1\&profile=default\&action=enableConfigure SYN check engage mode
Enable to force always on, disable to disable tcp check in any condition, threshold to enable tcp check on traffic threshold, auto to enable tcp check when an attack is automatically detected or thredhold is exceeded.
CLI
> target ID profile white|gray|black|default tcp syn check [disable|threshold|auto|enable]REST
curl -u <user>:<password> https://<host>:<port>/profile/tcp/syn/check?target_id=<target id>\&profile={black, white, gray, default}[\&action=update\&value={disable, threshold, auto, enable}]Example:
curl -u admin:admin https://localhost:4443/profile/tcp/syn/check?target_id=SCRBR1\&profile=defaultcurl -u admin:admin https://localhost:4443/profile/tcp/syn/check?target_id=SCRBR1\&profile=default\&action=update\&value=autoConfigure TCP traffic threshold
Set the maximum expected TCP traffic rate to feed the detection algorithm (Mbit/s).
CLI
> target ID profile white|gray|black|default tcp threshold [MBITPS]REST
curl -u <user>:<password> https://<host>:<port>/profile/tcp/threshold?target_id=<target id>\&profile={black, white, gray, default}[\&action=update\&value=<Mbit/s>]Example:
curl -u admin:admin https://localhost:4443/profile/tcp/threshold?target_id=SCRBR1\&profile=default\&action=update\&value=1000Configure SYN check method
Select the method used to validate TCP connections from sources that are not whitelisted:
- rfc: the first SYN of a source is dropped, a legitimate client retransmits it according to the TCP specification and is whitelisted. This delays the first connection of each source by the client SYN retransmission timeout (usually 1 second).
- proxy: nScrub answers the SYN with a SYN-ACK carrying a SYN cookie, and opens the connection to the server only after the client has completed the 3-way handshake; the traffic of the connection is then translated by nScrub. No delay is added. In asymmetric mode (wan to lan traffic only) this works as a SYN cookie check.
- disable: no SYN check (default).
SSL traffic (TCP port 443) is checked with the rfc method when the SYN check method is either rfc or proxy, unless a different method is configured with the SSL SYN check method setting below.
CLI
> target ID profile white|gray|black|default tcp syn check_method [rfc|proxy|disable]REST
curl -u <user>:<password> https://<host>:<port>/profile/tcp/syn/check_method?target_id=<target id>\&profile={black, white, gray, default}[\&action=update\&value={rfc, proxy, disable}]Example:
curl -u admin:admin https://localhost:4443/profile/tcp/syn/check_method?target_id=SCRBR1\&profile=defaultcurl -u admin:admin https://localhost:4443/profile/tcp/syn/check_method?target_id=SCRBR1\&profile=default\&action=update\&value=rfcConfigure SSL SYN check method
By default SSL traffic (TCP port 443) is checked with the rfc method when the SYN check method is either rfc or proxy, as methods based on connection reset can be an issue with some SSL clients. This setting overrides the method used for port 443:
- rfc: always use the rfc method on port 443 (same as the default behaviour).
- proxy: use the SYN proxy on port 443 too, avoiding the delay on the first connection of each source.
- default: remove the override, the method is selected according to the SYN check method (reading the setting returns "default" when no override is configured).
The override applies only when the SYN check method is enabled (rfc or proxy): when the SYN check method is disable, port 443 is not checked.
CLI
> target ID profile white|gray|black|default ssl syn check_method [rfc|proxy|default]REST
curl -u <user>:<password> https://<host>:<port>/profile/ssl/syn/check_method?target_id=<target id>\&profile={black, white, gray, default}[\&action=update\&value={rfc, proxy, default}]Example:
curl -u admin:admin https://localhost:4443/profile/ssl/syn/check_method?target_id=SCRBR1\&profile=defaultcurl -u admin:admin https://localhost:4443/profile/ssl/syn/check_method?target_id=SCRBR1\&profile=default\&action=update\&value=proxyConfigure SYN RFC check method threshold
Maximum expected new TCP connections per second) to feed the mitigation algorithm (syn/s).
CLI
> target ID profile white|gray|black|default tcp syn rfc threshold [PPS]REST
curl -u <user>:<password> https://<host>:<port>/profile/tcp/syn/rfc/threshold?target_id=<target id>\&profile={black, white, gray, default}[\&action=update\&value=<pps>Example:
curl -u admin:admin https://localhost:4443/profile/tcp/syn/rfc/threshold?target_id=SCRBR1\&profile=defaultcurl -u admin:admin https://localhost:4443/profile/tcp/syn/rfc/threshold?target_id=SCRBR1\&profile=default\&action=update\&value=100Enable whitelisting of sessions only
Enable session whitelisting instead of IPs on traffic verified by the TCP check.
CLI
> target ID profile white|gray|black|default tcp syn wl_session_only [enable|disable]REST
curl -u <user>:<password> https://<host>:<port>/profile/tcp/syn/wl_session_only?target_id=<target id>\&profile={black, white, gray, default}[\&action={enable, disable}]Example:
curl -u admin:admin https://localhost:4443/profile/tcp/syn/wl_session_only?target_id=SCRBR1\&profile=default\&action=enableAuto-engage whitelisting of sessions only
Configure whitelisting of sessions only instead of IPs on traffic verified by the TCP check to automatically engage on threshold The maximum number of whitelisted IPs should be specified to trigger it. The /tcp/syn/wl_session_only option is ignored when using this.
CLI
> target ID profile white|gray|black|default tcp syn wl_threshold [NUM]REST
curl -u <user>:<password> https://<host>:<port>/profile/tcp/syn/wl_threshold?target_id=<target id>\&profile={black, white, gray, default}[\&action=update\&value=<whitelist size>]Example:
curl -u admin:admin https://localhost:4443/profile/tcp/syn/wl_threshold?target_id=SCRBR1\&profile=default\&action=update\&value=10000Configure SYN rate limiting
Limit per source or dest (pkts/s)
CLI
> target ID profile white|gray|black|default tcp syn rate src [PPS]
> target ID profile white|gray|black|default tcp syn rate dst [PPS]REST
curl -u <user>:<password> https://<host>:<port>/profile/tcp/syn/rate/{src, dst}?target_id=<target id>\&profile={black, white, gray, default}[\&action=update\&value=<pkts/s>]Example:
curl -u admin:admin https://localhost:4443/profile/tcp/syn/rate/src?target_id=SCRBR1\&profile=defaultcurl -u admin:admin https://localhost:4443/profile/tcp/syn/rate/src?target_id=SCRBR1\&profile=default\&action=update\&value=20Configure Auto-Blacklist
Blacklist sources exceeding SYN rate for some time or not passing the TCP-Check. It is recommended to also enable /attackers/autopurging.
CLI
> target ID profile white|gray|black|default tcp syn auto_blacklist [enable|disable]REST
curl -u <user>:<password> https://<host>:<port>/profile/tcp/syn/auto_blacklist?target_id=<target id>\&profile={black, white, gray, default}[\&action={enable, disable}]Example:
curl -u admin:admin https://localhost:4443/profile/tcp/syn/auto_blacklist?target_id=SCRBR1\&profile=default\&action=enableConfigure SYN-ACK rate limiting
Limit per source or dest (pkts/s)
CLI
> target ID profile white|gray|black|default tcp synack rate src [PPS]
> target ID profile white|gray|black|default tcp synack rate dst [PPS]REST
curl -u <user>:<password> https://<host>:<port>/profile/tcp/synack/rate/{src, dst}?target_id=<target id>\&profile={black, white, gray, default}[\&action=update\&value=<pkts/s>]Example:
curl -u admin:admin https://localhost:4443/profile/tcp/synack/rate/src?target_id=SCRBR1\&profile=defaultcurl -u admin:admin https://localhost:4443/profile/tcp/synack/rate/src?target_id=SCRBR1\&profile=default\&action=update\&value=20Configure SYN-ACK session whitelisting
CLI
> target ID profile white|gray|black|default tcp synack wl_session [enable|disable]REST
curl -u <user>:<password> https://<host>:<port>/profile/tcp/synack/wl_session?target_id=<target id>\&profile={black, white, gray, default}[\&action={enable, disable}]Example:
curl -u admin:admin https://localhost:4443/profile/tcp/synack/wl_session?target_id=SCRBR1\&profile=default\&action=enableConfigure SYN-ACK TCP-Amplification protection
CLI
> target ID profile white|gray|black|default tcp synack tcp_amp_protection [enable|disable]REST
curl -u <user>:<password> https://<host>:<port>/profile/tcp/synack/tcp_amp_protection?target_id=<target id>\&profile={black, white, gray, default}[\&action={enable, disable}]Example:
curl -u admin:admin https://localhost:4443/profile/tcp/synack/tcp_amp_protection?target_id=SCRBR1\&profile=default\&action=enableDrop TCP SYN with seq num 0
CLI
>REST
curl -u <user>:<password> https://<host>:<port>/profile/tcp/syn/noseqnum/drop?target_id=<target id>\&profile={black, white, gray, default}[\&action={enable, disable}]Example:
curl -u admin:admin https://localhost:4443/profile/tcp/syn/noseqnum/drop?target_id=SCRBR1\&profile=defaultcurl -u admin:admin https://localhost:4443/profile/tcp/syn/noseqnum/drop?target_id=SCRBR1\&profile=default\&action=enableDrop TCP SYN with no options
CLI
> target ID profile white|gray|black|default tcp syn nooption drop [enable|disable]REST
curl -u <user>:<password> https://<host>:<port>/profile/tcp/syn/nooption/drop?target_id=<target id>\&profile={black, white, gray, default}[\&action={enable, disable}]Example:
curl -u admin:admin https://localhost:4443/profile/tcp/syn/nooption/drop?target_id=SCRBR1\&profile=defaultcurl -u admin:admin https://localhost:4443/profile/tcp/syn/nooption/drop?target_id=SCRBR1\&profile=default\&action=enableDrop TCP SYN packets with payload
CLI
> target ID profile white|gray|black|default tcp syn payload drop [enable|disable]REST
curl -u <user>:<password> https://<host>:<port>/profile/tcp/syn/payload/drop?target_id=<target id>\&profile={black, white, gray, default}[\&action={enable, disable}]Example:
curl -u admin:admin https://localhost:4443/profile/tcp/syn/payload/drop?target_id=SCRBR1\&profile=defaultcurl -u admin:admin https://localhost:4443/profile/tcp/syn/payload/drop?target_id=SCRBR1\&profile=default\&action=enableSet drop/accept policy per UDP/TCP src/dst port
Note: in order to block UDP-based amplification attacks set source ports for dns, ntp, snmp, nb, ssdp, cg, qotd, bt, kad, qnp, sp.
CLI
> target ID profile white|gray|black|default [udp|tcp] [src|dst] PORT [drop|accept] [enable|disable]REST
curl -u <user>:<password> https://<host>:<port>/profile/{udp, tcp}/{src, dst}/{port}/{accept, drop}?target_id=<target id>\&profile={black, white, gray, default}[\&action={enable, disable}]Example:
curl -u admin:admin https://localhost:4443/profile/udp/src/53/drop?target_id=SCRBR1\&profile=defaultcurl -u admin:admin https://localhost:4443/profile/udp/src/53/drop?target_id=SCRBR1\&profile=default\&action=enableSet min/max UDP payload length
CLI
> target ID profile white|gray|black|default udp payload min_len [BYTES]
> target ID profile white|gray|black|default udp payload max_len [BYTES]REST
curl -u <user>:<password> https://<host>:<port>/profile/udp/payload/{min, max}_len?target_id=<target id>\&profile={black, white, gray, default}[\&action=update\&value=<len>]Example:
curl -u admin:admin https://localhost:4443/profile/udp/payload/min_len?target_id=SCRBR1\&profile=defaultcurl -u admin:admin https://localhost:4443/profile/udp/payload/min_len?target_id=SCRBR1\&profile=default\&action=update\&value=2Drop UDP fragments
CLI
> target ID profile white|gray|black|default udp fragment drop [enable|disable]REST
curl -u <user>:<password> https://<host>:<port>/profile/udp/fragment/drop?target_id=<target id>\&profile={black, white, gray, default}[\&action={enable, disable}]Example:
curl -u admin:admin https://localhost:4443/profile/udp/fragment/drop?target_id=SCRBR1\&profile=defaultcurl -u admin:admin https://localhost:4443/profile/udp/fragment/drop?target_id=SCRBR1\&profile=default\&action=enableSet min/max UDP fragments payload length
CLI
> target ID profile white|gray|black|default udp fragment payload min_len [BYTES]
> target ID profile white|gray|black|default udp fragment payload max_len [BYTES]REST
curl -u <user>:<password> https://<host>:<port>/profile/udp/fragment/payload/{min, max}_len?target_id=<target id>\&profile={black, white, gray, default}[\&action=update\&value=<len>]Example:
curl -u admin:admin https://localhost:4443/profile/udp/fragment/payload/min_len?target_id=SCRBR1\&profile=defaultcurl -u admin:admin https://localhost:4443/profile/udp/fragment/payload/min_len?target_id=SCRBR1\&profile=default\&action=update\&value=64Drop UDP with checksum0
CLI
> target ID profile white|gray|black|default udp checksum0 drop [enable|disable]REST
curl -u <user>:<password> https://<host>:<port>/profile/udp/checksum0/drop?target_id=<target id>\&profile={black, white, gray, default}[\&action={enable, disable}]Example:
curl -u admin:admin https://localhost:4443/profile/udp/checksum0/drop?target_id=SCRBR1\&profile=defaultcurl -u admin:admin https://localhost:4443/profile/udp/checksum0/drop?target_id=SCRBR1\&profile=default\&action=enableConfigure UDP rate limiting
Limit all UDP traffic (pkts/s) per source or destination
CLI
> target ID profile white|gray|black|default udp rate src [PPS]
> target ID profile white|gray|black|default udp rate dst [PPS]REST
curl -u <user>:<password> https://<host>:<port>/profile/udp/rate/{src, dst}?target_id=<target id>\&profile={black, white, gray, default}[\&action=update\&value=<pkts/s>]Example:
curl -u admin:admin https://localhost:4443/profile/udp/rate/src?target_id=SCRBR1\&profile=defaultcurl -u admin:admin https://localhost:4443/profile/udp/rate/src?target_id=SCRBR1\&profile=default\&action=update\&value=100Set drop policy per ICMP type
CLI
> target ID profile white|gray|black|default icmp type TYPE drop [enable|disable]
> target ID profile white|gray|black|default icmp type TYPE accept [enable|disable]REST
curl -u <user>:<password> https://<host>:<port>/profile/icmp/type/<icmp type>/{accept, drop}?target_id=<target id>\&profile={black, white, gray, default}[\&action={enable, disable}]Example:
curl -u admin:admin https://localhost:4443/profile/icmp/type/0/drop?target_id=SCRBR1\&profile=defaultcurl -u admin:admin https://localhost:4443/profile/icmp/type/0/drop?target_id=SCRBR1\&profile=default\&action=disableSet drop policy per TTL values
CLI
> target ID profile white|gray|black|default ip
> target ID profile white|gray|black|default ip ttl TTL drop [enable|disable]
> target ID profile white|gray|black|default ip ttl TTL accept [enable|disable]REST
curl -u <user>:<password> https://<host>:<port>/profile/ip/ttl/<ttl value>/{accept, drop}?target_id=<target id>\&profile={black, white, gray, default}[\&action={enable, disable}]Example:
curl -u admin:admin https://localhost:4443/profile/ip/ttl?target_id=SCRBR1\&profile=defaultcurl -u admin:admin https://localhost:4443/profile/ip/ttl/24/drop?target_id=SCRBR1\&profile=default\&action=enableConfigure DNS check method
CLI
> target ID profile white|gray|black|default dns request check_method [forcetcp|disable]REST
curl -u <user>:<password> https://<host>:<port>/profile/dns/request/check_method?target_id=<target id>\&profile={black, white, gray, default}[\&action=update\&value={forcetcp, default}]Example:
curl -u admin:admin https://localhost:4443/profile/dns?target_id=SCRBR1\&profile=defaultcurl -u admin:admin https://localhost:4443/profile/dns/request/check_method?target_id=SCRBR1\&profile=default\&action=update\&value=forcetcpConfigure DNS rate limiting
Limit DNS requests per source or transaction ID (pkts/s)
CLI
> target ID profile white|gray|black|default dns request rate src [PPS]
> target ID profile white|gray|black|default dns request rate transaction_id [PPS]REST
curl -u <user>:<password> https://<host>:<port>/profile/dns/request/rate/src?target_id=<target id>\&profile={black, white, gray, default}[\&action=update\&value=<pkts/s>]Example:
curl -u admin:admin https://localhost:4443/profile/dns/request/rate/src?target_id=SCRBR1\&profile=defaultcurl -u admin:admin https://localhost:4443/profile/dns/request/rate/src?target_id=SCRBR1\&profile=default\&action=update\&value=20Configure DNS traffic threshold
This is the maximum expected number of queries per second. This is used to feed the detection algorithm. (packets/s)
CLI
> target ID profile white|gray|black|default dns request threshold [PPS]REST
curl -u <user>:<password> https://<host>:<port>/profile/dns/request/threshold?target_id=<target id>\&profile={black, white, gray, default}[\&action=update\&value=<pps>]Example:
curl -u admin:admin https://localhost:4443/profile/dns/request/threshold?target_id=SCRBR1\&profile=default\&action=update\&value=1000Set drop policy per DNS request type
CLI
> target ID profile white|gray|black|default dns request type TYPE drop [enable|disable]REST
curl -u <user>:<password> https://<host>:<port>/profile/dns/request/type/<dns query type>/drop?target_id=<target id>\&profile={black, white, gray, default}[\&action={enable, disable}]Example:
curl -u admin:admin https://localhost:4443/profile/dns/request/type/255/drop?target_id=SCRBR1\&profile=defaultcurl -u admin:admin https://localhost:4443/profile/dns/request/type/255/drop?target_id=SCRBR1\&profile=default\&action=enableSet max DNS subdomain length
CLI
> target ID profile white|gray|black|default dns request subdomain_max_len [CHARACTERS]REST
curl -u <user>:<password> https://<host>:<port>/profile/dns/request/subdomain_max_len?target_id=<target id>\&profile={black, white, gray, default}[\&action=update\&value=<len>]Example:
curl -u admin:admin https://localhost:4443/profile/dns/request/subdomain_max_len?target_id=SCRBR1\&profile=defaultcurl -u admin:admin https://localhost:4443/profile/dns/request/subdomain_max_len?target_id=SCRBR1\&profile=default\&action=update\&value=10Hex/string pattern match
Add <hex/string, offset> pattern to match (drop). Set "" as value to delete a pattern. Note:
- 'payload+' represents beginning of L7 payload (end of L4 headers), it applies to tcp/udp packets only.
- when 'payload+' is not specified, 'offset' is considered from the beginning of the ethernet frame.
- 'string' is case sensitive
CLI
> target ID profile white|gray|black|default pattern PATTERN drop [{hex, string},[payload+]{OFFSET, any},VALUE|-]REST
curl -u <user>:<password> https://<host>:<port>/profile/pattern/<id>/drop?target_id=<target id>\&profile={black, white, gray, default}\&action=update\&value={hex, string},[payload+]{<offset>, any},<hex/string to match>Example:
curl -u admin:admin https://localhost:4443/profile/pattern/1/drop?target_id=SCRBR1\&profile=default\&action=update\&value=hex,56,0954A03AC3320Fcurl -u admin:admin https://localhost:4443/profile/pattern/2/drop?target_id=SCRBR1\&profile=default\&action=update\&value=string,payload+8,HelloRead active patterns
CLI
> target ID profile white|gray|black|default patternREST
curl -u <user>:<password> https://<host>:<port>/profile/pattern?target_id=<target id>\&profile={black, white, gray, default}Example:
curl -u admin:admin https://localhost:4443/profile/pattern?target_id=SCRBR1\&profile=defaultHTTP request field match
Add HTTP request field to match (drop). Set "" as value to delete a field. Note: 'label' is case sensitive, instead 'value' is compared ignoring the case.
CLI
> target ID profile white|gray|black|default http request field FIELD drop [LABEL,VALUE|-]REST
curl -u <user>:<password> https://<host>:<port>/profile/http/request/field/<id>/drop?target_id=<target id>\&profile={black, white, gray, default}\&action=update\&value=<label>,<value>Example:
curl -u admin:admin https://localhost:4443/profile/http/request/field/1/drop?target_id=SCRBR1\&profile=default\&action=update\&value=User-Agent,Botcurl -u admin:admin https://localhost:4443/profile/http/request/field/1/drop?target_id=SCRBR1\&profile=white\&action=update\&value=User-Agent,BotRead active HTTP request fields
CLI
> target ID profile white|gray|black|default http request fieldREST
curl -u <user>:<password> https://<host>:<port>/profile/http/request/field?target_id=<target id>\&profile={black, white, gray, default}Example:
curl -u admin:admin https://localhost:4443/profile/http/request/field?target_id=SCRBR1\&profile=defaultAdd allowed HTTP hosts
CLI
> target ID profile white|gray|black|default http request host ID pass [HOSTNAME|-]REST
curl -u <user>:<password> https://<host>:<port>/profile/http/request/host/<id>/pass?target_id=<target id>\&profile={black, white, gray, default}\&action=update\&value=<hostname>Example:
curl -u admin:admin https://localhost:4443/profile/http/request/host/1/pass?target_id=SCRBR1\&profile=default\&action=update\&value=example.comRead active HTTP hosts
CLI
> target ID profile white|gray|black|default http request hostREST
curl -u <user>:<password> https://<host>:<port>/profile/http/request/host?target_id=<target id>\&profile={black, white, gray, default}Example:
curl -u admin:admin https://localhost:4443/profile/http/request/host?target_id=SCRBR1\&profile=defaultUsers Management
Read users list
CLI
> usersREST
curl -u <user>:<password> https://<host>:<port>/users?action=listExample:
curl -u admin:admin https://localhost:4443/users?action=listAdd/del/update users
CLI
> useradd NAME GROUP PASSWORD
> usermod NAME GROUP [PASSWORD]
> userdel NAMEREST
curl -u <user>:<password> -X POST https://<host>:<port>/users?action={add, del, update}\&username=<username>\&fullname=<full name>\&group={administrator} -d '{ "password" : "<password>" }'Example:
curl -u admin:admin -X POST https://localhost:4443/users?action=add\&username=john\&fullname=John\&group=administrator -d '{ "password" : "temporarypassword" }'curl -u admin:admin https://localhost:4443/users?action=del\&username=john