Configuring On-Access Scanning in ClamAV



This guide is for users interested in leveraging and understanding ClamAV’s On-Access Scanning feature. It will walk through how to set up and use the On-Access Scanner and step through some common issues and their solutions.


On-Access is only available on Linux systems. On Linux, On-Access requires a kernel version >= 3.8. This is because it leverages a kernel api called fanotify to block processes from attempting to access malicious files. This prevention occurs in kernel-space, and thus offers stronger protection than a purely user-space solution.

For Versions >= 0.102.0

It also requires Curl version >= 7.45 to ensure support for all curl options used by clamonacc. Users on Linux operating systems that package older versions of libcurl have a number of options:

  1. Wait for your package maintainer to provide a newer version of libcurl.
  2. Install a newer version of libcurl from source.
  3. Disable installation of clamonacc and On-Access Scanning capabilities with the ./configure flag --disable-clamonacc.

General Use

To use ClamAV’s On-Access Scanner, operation will vary depending on version.

For Versions >= 0.102.0

You will need to run the clamd and clamonacc applications side by side. First, you will need to configure and run clamd. For instructions on how to do that, see the clamd configuration guide. One important thing to note while configuring clamd.conf is that–like clamdscan–the clamonacc application will connect to clamd using the clamd.conf settings for either LocalSocket or TCPAddr/TCPSocket. Another important thing to note, is that when using a clamd.conf that specifies a LocalSocket, then clamd will need to be run under a user with the right permissions to scan the files you plan on including in your watch-path.

Next, you will need to configure clamonacc. For a very simple configuration, follow these steps:

1. Open `clamd.conf` for editing
2. Specify the path(s) you would like to recursively watch by setting the `OnAccessIncludePath` option
3. Set `OnAccessPrevention` to `yes`
4. Check what username `clamd` is running under
5. Set `OnAccessExcludeUname` to `clamd`'s uname
6. Save your work and close `clamd.conf`

For slightly more nuanced configurations, which may be adapted to your use case better, please check out the recipe guide below.

Then, run clamonacc with elevated permissions:

sudo clamonacc

If all went well, the On-Access scanner will fork to the background, and will now be actively protecting the path(s) specified with OnAccessIncludePath. You can test this by dropping an eicar file into the specified path, and attempting to read/access it (e.g. cat eicar.txt). This will result in an “Operation not permitted” message, triggered by fanotify blocking the access attempt at the kernel level.

Finally, you will have to restart both clamd and clamonacc. If default clamonacc performance is not to your liking, and your system has the resources available, we reccomend increasing the values for the following clamd.conf configuration options to increase performance:

  • MaxQueue
  • MaxThreads
  • OnAccessMaxThreads

For Versions <= 0.101.x

You will only need to run the clamd application in older versions. First, we reccomend you configure clamd for your environment. For instructions on how to do that, see the clamd configuration guide.

Next, you will need to configure On Access Scanning using the clamd.conf file. For a very simple configuration follow these steps:

1. Open `clamd.conf` for editing
2. Set the `ScanOnAccess` option to `yes`
3. Specify the path(s) you would like to recursively watch by setting the `OnAccessIncludePath` option
4. Set `OnAccessPrevention` to `yes`
6. Save your work and close `clamd.conf`

For slightly more nuanced configurations, which may be adapted to your use case better, please check out the recipe guide below.

Then, run clamd with elevated permissions:

sudo clamd

If all went well, the On-Access scanner will fork to the background, and will now be actively protecting the path(s) specified with OnAccessIncludePath. You can test this by dropping an eicar file into the specified path, and attempting to read/access it (e.g. cat eicar.txt). This will result in an “Operation not permitted” message, triggered by fanotify blocking the access attempt at the kernel level.


Some OS distributors have disabled fanotify, despite kernel support. You can check for fanotify support on your kernel by running the command:

cat /boot/config-<kernel_version> | grep FANOTIFY

You should see the following:


If you see this…


… then ClamAV’s On-Access Scanner will still function, scanning and alerting on files normally in real time. However, it will be unable to block access attempts on malicious files. We call this notify-only mode.

ClamAV’s On-Access Scanning system uses a scheme called Dynamic Directory Determination (DDD for short) which is a shorthand way of saying that it tracks the layout of every directory specified with OnAccessIncludePath dynamically, and recursively.

In real time. It does this by leveraging inotify which by default has a limited number of watch-points available for use by a process at any given time. Given the complexity of some directory hierarchies, ClamAV may warn you that it has exhausted its supply of inotify watch-points (8192 by default). To increase the number of inotify watch-points available for use by ClamAV (to 524288), run the following command:

echo 524288 | sudo tee -a /proc/sys/fs/inotify/max_user_watches

The OnAccessIncludePath option will not accept / as a valid path. This is because fanotify works by blocking a process’ access to a file until a access_ok or access_denied determination has been made by the original fanotify calling process. Thus, by placing fanotify watch-points on the entire filesystem, key system files may have their access blocked to key processes at the kernel level, which will result in a system lockup.

This restriction was made to prevent users from “shooting themselves in the foot.” However, clever users will find it’s possible to circumvent this restriction by using multiple OnAccessIncludePath options to recursively protect most of the filesystem anyways, or better still, simply the paths they truly care about.

The OnAccessMountPath option uses a different fanotify api configuration which makes it incompatible with OnAccessIncludePath and the DDD System. Therefore, inotify watch-point limitations will not be a concern when using this option. Unfortunately, this also means that the following options cannot be used in conjunction with OnAccessMountPath:

  • OnAccessExtraScanning – is built around catching inotify events.
  • OnAccessExcludePath – is built upon the DDD System.
  • OnAccessPrevention – would lock up the system if / was selected for OnAccessMountPath. If you need OnAccessPrevention, you should use OnAccessIncludePath instead of OnAccessMountPath.

Configuration and Recipes

More nuanced behavior can be coerced from ClamAV’s On-Access Scanner via careful modification to clamd.conf. Each option related to On-Access Scanning is easily identified by looking for the OnAccess prefix pre-pended to each option. The default clamd.conf file contains descriptions of each option, along with any documented limitations or safety features.

Below are examples of common use cases, recipes for the correct minimal configuration, and the expected behavioral result.

Use Case 0x0

  • User needs to watch the entire file system, but blocking malicious access attempts isn’t a concern
    ScanOnAccess yes ## versions <= 0.101.x
    OnAccessMountPath /
    OnAccessExcludeRootUID yes
    OnAccessExcludeUname clamav ## versions >= 0.102

This configuration will put the On-Access Scanner into notify-only mode. It will also ensure only non-root, non-clam, user processes will trigger scans against the filesystem.

Use Case 0x1

  • System Administrator needs to watch the home directory of multiple Users, but not all users. Blocking access attempts is un-needed.
    ScanOnAccess yes ## versions <= 0.101.x
    OnAccessIncludePath /home
    OnAccessExcludePath /home/user2
    OnAccessExcludePath /home/user4
    OnAccessExcludeUname clamav ## versions >= 0.102

With this configuration, the On-Access Scanner will watch the entirety of the /home directory recursively in notify-only mode. However, it will recursively exclude the /home/user2 and /home/user4 directories.

Use Case 0x2

  • The user needs to protect a single directory non-recursively and ensure all access attempts on malicious files are blocked.
    ScanOnAccess yes ## versions <= 0.101.x
    OnAccessIncludePath /home/user/Downloads
    OnAccessExcludeUname clamav ## versions >= 0.102
    OnAccessPrevention yes
    OnAccessDisableDDD yes

The configuration above will result in non-recursive real-time protection of the /home/user/Downloads directory by ClamAV’s On-Access Scanner. Any access attempts that ClamAV detects on malicious files within the top level of the directory hierarchy will be blocked by fanotify at the kernel level.

Command Line Options for Versions >= 0.102

Beyond clamd.conf configuration, you can change the behavior of the On-Access scanner by passing in a number of command line options. A list of all options can be retrieved with --help, but below is a list and explanation of some of options you might find most useful.

  • --log=FILE (-l FILE) – passing this option is important if you want a record of scan results, otherwise clamonacc will operate silently.
  • --verbose (-v) – primarily for debugging as this will increase the amount of noise in your log by quite a lot, but useful for troubleshooting potential connection problems
  • --foreground (-F) – forces clamonacc to not for the background, which is useful for debugging potential issues with during startup or runtime
  • --include-list=FILE (-e FILE) – allows users to pass a list of directories for clamonacc to watch, each directory must be a full path and separated by a newline
  • --exclude-list=FILE (-e FILE) – same as include-list option, but for excluding at startup
  • --remove – after an infected verdict, an attempt will be made to remove the infected file
  • --move=DIRECTORY – just like the remove option, but infected file will be moved to the specified quarantine location instead
  • --copy=DIRECTORY – just like the move, except infected file is also left in place




Configuring Linux for Many Watch Folders

Last Updated: 2021-03-01

To run many (>100) push Watch Folders on Linux computers, adjust three system settings and then reload the sysctl.conf file to activate them.


  1. Increase the maximum number of watches allowed by the system.

    Retrieve the current value by running the following command:

    $ cat /proc/sys/fs/inotify/max_user_watches


    To permanently increase the number of available watches (to a value that is greater than the number of files to watch, such as 524288), add the configuration to /etc/sysctl.conf:

    $ sudo echo "fs.inotify.max_user_watches=524288" >> /etc/sysctl.conf


  2. Increase the maximum number of inotify instances, which correspond to the number of allowed Watch Services instances.

    Retrieve the current value by running the following command:

    $ cat /proc/sys/fs/inotify/max_user_instances


    On many systems, the default value is 128, meaning only 128 watches can be created. To permanently increase the number available (to a value that is greater than the number of desired Watch Folder instances, such as 1024), add the configuration to /etc/sysctl.conf:

    $ sudo echo "fs.inotify.max_user_instances=1024" >> /etc/sysctl.conf


  3. Increase the open file limit.

    Retrieve the current value by running the following command:

    $ cat /proc/sys/fs/file-max


    To permanently increase the open file limit (to a value that is greater than the number of desired watches, such as 2097152), add the configuration to /etc/sysctl.conf:

    $ sudo echo "fs.file-max=2097152" >> /etc/sysctl.conf


  4. Reload systemd settings to activate the new settings.

    To reload systemd settings, either reboot the machine or run the following command:

    $ sudo sysctl -p /etc/sysctl.conf

How To Configure Suricata as an Intrusion Prevention System (IPS) on Ubuntu 20.04



In this tutorial you will learn how to configure Suricata’s built-in Intrusion Prevention System (IPS) mode on Ubuntu 20.04. By default Suricata is configured to run as an Intrusion Detection System (IDS), which only generates alerts and logs suspicious traffic. When you enable IPS mode, Suricata can actively drop suspicious network traffic in addition to generating alerts for further analysis.

Before enabling IPS mode, it is important to check which signatures you have enabled, and their default actions. An incorrectly configured signature, or a signature that is overly broad may result in dropping legitimate traffic to your network, or even block you from accessing your servers over SSH and other management protocols.

In the first part of this tutorial you will check the signatures that you have installed and enabled. You will also learn how to include your own signatures. Once you know which signatures you would like to use in IPS mode, you’ll convert their default action to drop or reject traffic. With your signatures in place, you’ll learn how to send network traffic through Suricata using the netfilter NFQUEUE iptables target, and then generate some invalid network traffic to ensure that Suricata drops it as expected.


If you have been following this tutorial series then you should already have Suricata running on an Ubuntu 20.04 server.

If you still need to install Suricata then you can follow How To Install Suricata on Ubuntu 20.04

You should also have the ET Open Ruleset downloaded using the suricata-update command, and included in your Suricata signatures.

The jq command line JSON processing tool. If you do not have it installed from a previous tutorial, you can do so using the apt command:

sudo apt update
sudo apt install jq

You may also have custom signatures that you would like to use from the previous Understanding Suricata Signatures tutorial.

Step 1 — Including Custom Signatures

The previous tutorials in this series explored how to install and configure Suricata, as well as how to understand signatures. If you would like to create and include your own rules then you need to edit Suricata’s /etc/suricata/suricata.yaml file to include a custom path to your signatures.

First, let’s find your server’s public IPs so that you can use them in your custom signatures. To find your IPs you can use the ip command:

ip -brief address show

You should receive output like the following:

lo UNKNOWN ::1/128
eth0 UP 2001:DB8::1/32 fe80::94ad:d4ff:fef9:cee0/64
eth1 UP fe80::44a2:ebff:fe91:5187/64

Your public IP address(es) will be similar to the highlighted and 2001:DB8::1/32 IPs in the output.

Now let’s create the following custom signature to scan for SSH traffic to non-SSH ports and include it in a file called /var/lib/suricata/rules/local.rules. Open the file with nano or your preferred editor:

sudo nano /var/lib/suricata/rules/local.rules

Copy and paste the following signature:

Invalid SSH Traffic Signature

alert ssh any any -> !22 (msg:"SSH TRAFFIC on non-SSH port"; flow:to_client, not_established; classtype: misc-attack; target: dest_ip; sid:1000000;)
alert ssh any any -> 2001:DB8::1/32 !22 (msg:"SSH TRAFFIC on non-SSH port"; flow:to_client, not_established; classtype: misc-attack; target: dest_ip; sid:1000001;)

Substitute your server’s public IP address in place of the and 2001:DB8::1/32 addresses in the rule. If you are not using IPv6 then you can skip adding that signature in this and the following rules.

You can continue adding custom signatures to this local.rules file depending on your network and applications. For example, if you wanted to alert about HTTP traffic to non-standard ports, you could use the following signatures:

HTTP traffic on non-standard port signature

alert http any any -> !80 (msg:"HTTP REQUEST on non-HTTP port"; flow:to_client, not_established; classtype:misc-activity; sid:1000002;)
alert http any any -> 2001:DB8::1/32 !80 (msg:"HTTP REQUEST on non-HTTP port"; flow:to_client, not_established; classtype:misc-activity; sid:1000003;)

To add a signature that checks for TLS traffic to ports other than the default 443 for web servers, add the following:

TLS traffic on non-standard port signature

alert tls any any -> !443 (msg:"TLS TRAFFIC on non-TLS HTTP port"; flow:to_client, not_established; classtype:misc-activity; sid:1000004;)
alert tls any any -> 2001:DB8::1/32 !443 (msg:"TLS TRAFFIC on non-TLS HTTP port"; flow:to_client, not_established; classtype:misc-activity; sid:1000005;)

When you are done adding signatures, save and close the file. If you are using nano, you can do so with CTRL+X, then Y and ENTER to confirm. If you are using vi, press ESC and then 😡 then ENTER to save and exit.

Now that you have some custom signatures defined, edit Suricata’s /etc/suricata/suricata.yaml configuration file using nano or your preferred editor to include them:

sudo nano /etc/suricata/suricata.yaml

Find the rule-files: portion of the configuration. If you are using nano use CTRL+_ and then enter the line number 1879. If you are using vi enter 1879gg to go to the line. The exact location in your file may be different, but you should be in the correct general region of the file.

Edit the section and add the following highlighted – local.rules line:


. . .
- suricata.rules
- local.rules
. . .

Save and exit the file. Be sure to validate Suricata’s configuration after adding your rules. To do so run the following command:

sudo suricata -T -c /etc/suricata/suricata.yaml -v

The test can take some time depending on how many rules you have loaded in the default suricata.rules file. If you find the test takes too long, you can comment out the – suricata.rules line in the configuration by adding a # to the beginning of the line and then run your configuration test again. Be sure to remove the # comment if you plan to use the suricata.rules signature in your final running configuration.

Once you are satisfied with the signatures that you have created or included using the suricata-update tool, you can proceed to the next step, where you’ll switch the default action for your signatures from alert or log to actively dropping traffic.

Step 2 — Configuring Signature Actions

Now that you have your custom signatures tested and working with Suricata, you can change the action to drop or reject. When Suricata is operating in IPS mode, these actions will actively block invalid traffic for any matching signature.

These two actions are described in the previous tutorial in this series, Understanding Suricata Signatures. The choice of which action to use is up to you. A drop action will immediately discard a packet and any subsequent packets that belong to the network flow. A reject action will send both the client and server a reset packet if the traffic is TCP-based, and an ICMP error packet for any other protocol.

Let’s use the custom rules from the previous section and convert them to use the drop action, since the traffic that they match is likely to be a network scan, or some other invalid connection.

Open your /var/lib/suricata/rules/local.rules file using nano or your preferred editor and change the alert action at the beginning of each line in the file to drop:

sudo nano /var/lib/suricata/rules/local.rules


drop ssh any any -> !22 (msg:"SSH TRAFFIC on non-SSH port"; classtype: misc-attack; target: dest_ip; sid:1000000;)
drop ssh any any -> 2001:DB8::1/32 !22 (msg:"SSH TRAFFIC on non-SSH port"; classtype: misc-attack; target: dest_ip; sid:1000001;)
. . .

Repeat the step above for any signatures in /var/lib/suricata/rules/suricata.rules that you would like to convert to drop or reject mode.

Note: If you ran suricata-update in the prerequisite tutorial, you may have more than 30,000 signatures included in your suricata.rules file.

If you convert every signature to drop or reject you risk blocking legitimate access to your network or servers. Instead, leave the rules in suricata.rules for the time being, and add your custom signatures to local.rules. Suricata will continue to generate alerts for suspicious traffic that is described by the signatures in suricata.rules while it is running in IPS mode.

After you have a few days or weeks of alerts collected, you can analyze them and choose the relevant signatures to convert to drop or reject based on their sid.

Once you have all the signatures configured with the action that you would like them to take, the next step is to reconfigure and then restart Suricata in IPS mode.

Step 3 — Enabling nfqueue Mode

Suricata runs in IDS mode by default, which means it will not actively block network traffic. To switch to IPS mode, you’ll need to edit Suricata’s /etc/default/suricata configuration file.

Open the file in nano or your preferred editor:

sudo nano /etc/default/suricata

Find the LISTENMODE=af-packet line and comment it out by adding a # to the beginning of the line. Then add a new line LISTENMODE=nfqueue line that tells Suricata to run in IPS mode.

Your file should have the following highlighted lines in it when you are done editing:


. . .
# LISTENMODE=af-packet
. . .

Save and close the file. Now you can restart Suricata using systemctl:

sudo systemctl restart suricata.service

Check Suricata’s status using systemctl:

sudo systemctl status suricata.service

You should receive output like the following:


● suricata.service - LSB: Next Generation IDS/IPS
Loaded: loaded (/etc/init.d/suricata; generated)
Active: active (running) since Wed 2021-12-01 15:54:28 UTC; 2s ago
Docs: man:systemd-sysv-generator(8)
Process: 1452 ExecStart=/etc/init.d/suricata start (code=exited, status=0/SUCCESS)
Tasks: 12 (limit: 9513)
Memory: 63.6M
CGroup: /system.slice/suricata.service
└─1472 /usr/bin/suricata -c /etc/suricata/suricata.yaml --pidfile /var/run/ -q 0 -D -vvv

Dec 01 15:54:28 suricata systemd[1]: Starting LSB: Next Generation IDS/IPS...
Dec 01 15:54:28 suricata suricata[1452]: Starting suricata in IPS (nfqueue) mode... done.
Dec 01 15:54:28 suricata systemd[1]: Started LSB: Next Generation IDS/IPS.

Note the highlighted active (running) line that indicates Suricata restarted successfully. Also note the Starting suricata in IPS (nfqueue) mode… done. line, which confirms Suricata is now running in IPS mode.

With this change you are now ready to send traffic to Suricata using the UFW firewall in the next step.

Step 4 — Configuring UFW To Send Traffic to Suricata

Now that you have configured Suricata to process traffic in IPS mode, the next step is to direct incoming packets to Suricata. If you followed the prerequisite tutorials for this series and are using an Ubuntu 20.04 system, you should have the Uncomplicated Firewall (UFW) installed and enabled.

To add the required rules for Suricata to UFW, you will need to edit the firewall files in the /etc/ufw/before.rules (IPv4 rules) and /etc/ufw/before6.rules (IPv6) directly.

Open the first file for IPv4 rules using nano or your preferred editor:

sudo nano /etc/ufw/before.rules

Near the beginning of the file, insert the following highlighted lines:



. . .
# Don't delete these required lines, otherwise there will be errors
:ufw-before-input - [0:0]
:ufw-before-output - [0:0]
:ufw-before-forward - [0:0]
:ufw-not-local - [0:0]
# End required lines

## Start Suricata NFQUEUE rules
## End Suricata NFQUEUE rules

# allow all on loopback
-A ufw-before-input -i lo -j ACCEPT
-A ufw-before-output -o lo -j ACCEPT
. . .

Save and exit the file when you are done editing it. Now add the same highlighted lines to the same section in the /etc/ufw/before6.rules file:

sudo nano /etc/ufw/before.rules

Ensure that both files have the same contents. Save and exit the file when you are done editing it.

The first two INPUT and OUTPUT rules are used to bypass Suricata so that you can connect to your server using SSH, even when Suricata is not running. Without these rules, an incorrect or overly broad signature could block your SSH access. Additionally, if Suricata is stopped, all traffic will be sent to the NFQUEUE target and then dropped since Suricata is not running.

The next FORWARD rule ensures that if your server is acting as a gateway for other systems, all that traffic will also go to Suricata for processing.

The final two INPUT and OUTPUT rules send all remaining traffic that is not SSH traffic to Suricata for processing.

Restart UFW to load the new rules:

sudo systemctl restart ufw.service

Note: If you are using another firewall you will need to modify these rules to match the format your firewall expects.

If you are using iptables, then you can insert these rules directly using the iptables and ip6tables commands. However, you will need to ensure that the rules are persistent across reboots with a tool like iptables-persistent.

If you are using firewalld, then the following rules will direct traffic to Suricata:

firewall-cmd --permanent --direct --add-rule ipv4 filter INPUT 0 -p tcp --dport 22 -j NFQUEUE --queue-bypass
firewall-cmd --permanent --direct --add-rule ipv4 filter INPUT 1 -j NFQUEUE
firewall-cmd --permanent --direct --add-rule ipv6 filter INPUT 0 -p tcp --dport 22 -j NFQUEUE --queue-bypass
firewall-cmd --permanent --direct --add-rule ipv6 filter INPUT 1 -j NFQUEUE

firewall-cmd --permanent --direct --add-rule ipv4 filter FORWARD 0 -j NFQUEUE
firewall-cmd --permanent --direct --add-rule ipv6 filter FORWARD 0 -j NFQUEUE

firewall-cmd --permanent --direct --add-rule ipv4 filter OUTPUT 0 -p tcp --sport 22 -j NFQUEUE --queue-bypass
firewall-cmd --permanent --direct --add-rule ipv4 filter OUTPUT 1 -j NFQUEUE
firewall-cmd --permanent --direct --add-rule ipv6 filter OUTPUT 0 -p tcp --sport 22 -j NFQUEUE --queue-bypass
firewall-cmd --permanent --direct --add-rule ipv6 filter OUTPUT 1 -j NFQUEUE

At this point in the tutorial you have Suricata configured to run in IPS mode, and your network traffic is being sent to Suricata by default. You will be able to restart your server at any time and your Suricata and firewall rules will be persistent.

The last step in this tutorial is to verify Suricata is dropping traffic correctly.

Step 5 — Testing Invalid Traffic

Now that you have Suricata and your firewall configured to process network traffic, you can test whether Suricata will drop packets that match your custom and other included signatures.

Recall signature sid:2100498 from the previous tutorial, which is modified in this example to drop matching packets:


drop ip any any -> any any (msg:"GPL ATTACK_RESPONSE id check returned root"; content:"uid=0|28|root|29|"; classtype:bad-unknown; sid:2100498; rev:7; metadata:created_at 2010_09_23, updated_at 2010_09_23;)

Find and edit the rule in your /var/lib/suricata/rules/suricata.rules file to use the drop action if you have the signature included there. Otherwise, add the rule to your /var/lib/suricata/rules/local.rules file.

Send Suricata the SIGUSR2 signal to get it to reload its signatures:

sudo kill -usr2 $(pidof suricata)

Now test the rule using curl:

curl --max-time 5

You should receive an error stating that the request timed out, which indicates Suricata blocked the HTTP response:

curl: (28) Operation timed out after 5000 milliseconds with 0 out of 39 bytes received

You can confirm that Suricata dropped the HTTP response using jq to examine the eve.log file:

jq 'select(.alert .signature_id==2100498)' /var/log/suricata/eve.json

You should receive output like the following:

. . .
"community_id": "1:tw19kjR2LeWacglA094gRfEEuDU=",
"alert": {
"action": "blocked",
"gid": 1,
"signature_id": 2100498,
"rev": 7,
"signature": "GPL ATTACK_RESPONSE id check returned root",
"category": "Potentially Bad Traffic",
"severity": 2,
"metadata": {
"created_at": [
"updated_at": [
"http": {
"hostname": "",
"url": "/uid/index.html",
"http_user_agent": "curl/7.68.0",
"http_content_type": "text/html",
"http_method": "GET",
"protocol": "HTTP/1.1",
"status": 200,
"length": 39
. . .

The highlighted “action”: “blocked” line confirms that the signature matched, and Suricata dropped or rejected the test HTTP request.


In this tutorial you configured Suricata to block suspicious network traffic using its built-in IPS mode. You also added custom signatures to examine and block SSH, HTTP, and TLS traffic on non-standard ports. To tie everything together, you also added firewall rules to direct traffic through Suricata for processing.

Now that you have Suricata installed and configured in IPS mode, and can write your own signatures that either alert on or drop suspicious traffic, you can continue monitoring your servers and networks, and refining your signatures.

Once you are satisfied with your Suricata signatures and configuration, you can continue with the last tutorial in this series, which will guide you through sending logs from Suricata to a Security and Information Event Management (SIEM) system built using the Elastic Stack.

Customer Guidance for WannaCrypt attacks

Microsoft solution available to protect additional products

Today many of our customers around the world and the critical systems they depend on were victims of malicious “WannaCrypt” software. Seeing businesses and individuals affected by cyberattacks, such as the ones reported today, was painful. Microsoft worked throughout the day to ensure we understood the attack and were taking all possible actions to protect our customers. This blog spells out the steps every individual and business should take to stay protected. Additionally, we are taking the highly unusual step of providing a security update for all customers to protect Windows platforms that are in custom support only, including Windows XP, Windows 8, and Windows Server 2003. Customers running Windows 10 were not targeted by the attack today.

Details are below.

  • In March, we released a security update which addresses the vulnerability that these attacks are exploiting. Those who have Windows Update enabled are protected against attacks on this vulnerability. For those organizations who have not yet applied the security update, we suggest you immediately deploy Microsoft Security Bulletin MS17-010.
  • For customers using Windows Defender, we released an update earlier today which detects this threat as Ransom:Win32/WannaCrypt. As an additional “defense-in-depth” measure, keep up-to-date anti-malware software installed on your machines. Customers running anti-malware software from any number of security companies can confirm with their provider, that they are protected.
  • This attack type may evolve over time, so any additional defense-in-depth strategies will provide additional protections. (For example, to further protect against SMBv1 attacks, customers should consider blocking legacy protocols on their networks).

We also know that some of our customers are running versions of Windows that no longer receive mainstream support. That means those customers will not have received the above mentioned Security Update released in March. Given the potential impact to customers and their businesses, we made the decision to make the Security Update for platforms in custom support only, Windows XP, Windows 8, and Windows Server 2003, broadly available for download (see links below).

Customers who are running supported versions of the operating system (Windows Vista, Windows Server 2008, Windows 7, Windows Server 2008 R2, Windows 8.1, Windows Server 2012, Windows 10, Windows Server 2012 R2, Windows Server 2016) will have received the security update MS17-010 in March. If customers have automatic updates enabled or have installed the update, they are protected. For other customers, we encourage them to install the update as soon as possible.

This decision was made based on an assessment of this situation, with the principle of protecting our customer ecosystem overall, firmly in mind.

Some of the observed attacks use common phishing tactics including malicious attachments. Customers should use vigilance when opening documents from untrusted or unknown sources. For Office 365 customers we are continually monitoring and updating to protect against these kinds of threats including Ransom:Win32/WannaCrypt. More information on the malware itself is available from the Microsoft Malware Protection Center on the Windows Security blog. For those new to the Microsoft Malware Protection Center, this is a technical discussion focused on providing the IT Security Professional with information to help further protect systems.

We are working with customers to provide additional assistance as this situation evolves, and will update this blog with details as appropriate.

Update 5/22/2017: Today, we released an update to the Microsoft Malicious Software Removal Tool (MSRT) to detect and remove WannaCrypt malware. For customers that run Windows Update, the tool will detect and remove WannaCrypt and other prevalent malware infections. Customers can also manually download and run the tool by following the guidance here. The MSRT tool runs on all supported Windows machines where automatic updates are enabled, including those that aren’t running other Microsoft security products.

Phillip Misner, Principal Security Group Manager  Microsoft Security Response Center

Further resources:

General information on ransomware

Protecting your PC from ransomware

MS17-010 security update

How to verify that MS17-010 is installed

Download English language security updates: Windows Server 2003 SP2 x64Windows Server 2003 SP2 x86, Windows XP SP2 x64Windows XP SP3 x86Windows XP Embedded SP3 x86Windows 8 x86, Windows 8 x64

Download localized language security updates: Windows Server 2003 SP2 x64Windows Server 2003 SP2 x86Windows XP SP2 x64Windows XP SP3 x86Windows XP Embedded SP3 x86Windows 8 x86Windows 8 x64

How to enable and disable SMB in Windows and Windows Server & GPO deployment

Guidance for Azure customers

Applying MS17-010 using Microsoft Intune

ConfigMgr SQL queries for reporting on KBs related to MS17-010

Guidance for Operations Management Suite customers

LiveUpdate 更新受阻的解决方案

一、选取可用 IP 地址。
使用 PING 测试下列三组 IP,各选出一个可连通且延迟最低的 IP.







二、添加至 HOSTS 文件。
将上一步选取的三个 IP 地址添加至 HOSTS 文件。方法不再赘述。

  1. # Symantec LiveUpdate IP Address


三、刷新本地 DNS 缓存。

  1. ipconfig /flushDNS



  • 重定向 Norton 更新域名后,Norton 可能会报 SecurityRisk.URLRedir



SEP 14

Symantec Endpoint Protection官方下载


12.1.6 MP6


12.1.6 MP9


wget --header="Cookie: veritas_main"




wget --header="Cookie: veritas_main"



wget --header="Cookie: veritas_main"


International English 英文
Traditional Chinese 繁体中文
Simplified Chinese 简体中文
Spanish 西班牙





14.3 RU1

Symantec Endpoint Protection 14.3 RU1 for Windows 64-bit (115 MB)

Symantec Endpoint Protection 14.3 RU1 for Windows 32-bit (105 MB)

Symantec Endpoint Protection 14.3 RU1 for MacOS (124 MB)

Symantec Endpoint Protection 14.3 RU1 – All Clients (344 MB)

Symantec Endpoint Protection 14.3 RU1 – Full Installation (1.9 GB)


14.3 RU2

Symantec Endpoint Protection 14.3 RU2 for Windows 64-bit

Symantec Endpoint Protection 14.3 RU2 for MacOS

Symantec Endpoint Protection 14.3 RU2 – All Clients

Symantec Endpoint Protection 14.3 RU2 – Full Installation

No More Ransom! 協助你一同對抗勒索病毒





趨勢科技針對勒索軟體推出的免費復原工具 Trend Micro Ransomware File Decryptor,能有效對付某些類型勒索病毒,在不用支付贖金的情況下來強制重新復原救回檔案,這個工具目前支援包括 TeslaCrypt、CryptXXX、SNSLocker 等等在內共十多種勒索軟體類型。除此之外,本文要來介紹一個「No More Ransom」網站,一個勒索病毒主題入口網站,以專門對付勒索病毒為主,網站來頭不小,由 Intel Security、Interpol、荷蘭警方和卡巴斯基安全實驗室聯手打造!主要是協助使用者對抗危害,提供各種解密破解工具,讓使用者在不支付勒索贖金的情況下恢復重要文件檔案。


與其說 No More Ransom 是一個提供解密工具的網站,倒不如說他是一個教育使用者如何避免遇到勒索病毒危害的教育網站,內容簡單扼要一目了然,例如:備份資料、只打開認識且信任的聯絡人郵件附件、安裝防毒軟體、讓電腦軟體更新保持最新狀態,這些雖是老生常談,謹記在心準沒錯。

此外,No More Ransom 還提供線上勒索病毒檢測平台,使用者只要上傳自己被加密後的檔案,它就能從該組織擁有的 16 萬組解密金鑰中找出能夠解鎖的方式,還會讓你免費下載合適的復原工具,接下來我就簡單介紹一下 No More Ransom 這個網站的使用方法吧!




開啟 No More Ransom! 網站後,首頁會直接詢問是否要協助你解鎖、復原你的檔案或文件,而不用支付給駭客贖金?點選 YES 後會進入檢測平台,如果點選 No 則會有一系列的防護安全資訊供使用者參考學習,不過目前僅有英文版。



No More Ransom! 的 Crypto Sherief 加密檔案自我檢測平台相當厲害,可能是目前網路唯一提供這項服務的網站!簡單來說,使用者只要點選左側兩個按鈕將被加密的任一兩個檔案選取、上傳,右側則是填入你在支付贖金頁面看到的 Email、網址,這部分需要確認無誤,以避免找不到可以解密的金鑰或工具,你也可以直接上傳勒索病毒留下來的訊息(.txt 或 .html 格式)。

最後,點選下方按鈕,No More Ransom! 就會找出可能可以解蜜、復原檔案的金鑰讓你免費下載,或者可能可以還原的免費工具。



在網站的 Decryption Tools 解密工具頁面,提供一系列可協助處理、還原或救援被勒索病毒加密後檔案的工具(CoinVault、RannohDecryptor、RakhniDecryptor、ShadeDecryptor),都有各自對應可以處理的勒索病毒副檔名格式。



目前勒索軟體(勒索病毒)的數量相當多,而且不斷變種,有更多型態出現,現階段破解工具還無法涵蓋所有的勒索病毒,不過 No More Ransom! 網站提醒:盡量不支付贖金給這些病毒駭客,一來你會讓這些人認為有利可圖,進而找出更多方法來入侵其他使用者電腦;二來支付贖金獲取的解密金鑰也可能無法使用!讓你掉入被詐騙的陷阱當中。若你真的不幸中了勒索病毒,請記得先到 No More Ransom 網站找找解決辦法。

Tool for decrypting files affected by Trojan-Ransom.Win32.Rannoh infection

Tool for decrypting files affected by Trojan-Ransom.Win32.Rannoh infection

Back to “Virus-fighting utilities”

2016 May 24 ID: 8547

If the system is infected by a malicious program of the family Trojan-Ransom.Win32.Rannoh, Trojan-Ransom.Win32.AutoIt, Trojan-Ransom.Win32.Fury, Trojan-Ransom.Win32.CrybolaTrojan-Ransom.Win32.Cryakl or Trojan-Ransom.Win32.CryptXXX, all files on the computer will be encrypted in the following way:

  • In case of a Trojan-Ransom.Win32.Rannoh infection, file names and extensions will be changed according to the template locked-<original_name>.<four_random_letters>.
  • In case of a Trojan-Ransom.Win32.Cryakl infection, the tag {CRYPTENDBLACKDC} is added to the end of file names.
  • In case of a Trojan-Ransom.Win32.AutoIt infection, extensions will be changed according to the template<original_name>@<mail server>_.<random_set_of_characters>.
    Example: [email protected]_.RZWDTDIC.
  • In case of a Trojan-Ransom.Win32.CryptXXX infection, extensions will be changed according to the template<original_name>.crypt.

RannohDecryptor tool is designed to decrypt files dectypted by Trojan-Ransom.Win32.Rannoh, Trojan-Ransom.Win32.AutoIt,Trojan-Ransom.Win32.Fury, Trojan-Ransom.Win32.Crybola, Trojan-Ransom.Win32.Cryakl or Trojan-Ransom.Win32.CryptXXX versions 1 and 2 (files encrypted by Trojan-Ransom.Win32.CryptXXX version 3 are detected, but not decrypted).



To disinfect the system:

  1. Download The following pages contain information on how to download the file.
  2. Run RannohDecryptor.exe on the infected computer.
  3. In the main window, click Start scan.


  1. Indicate path to one encrypted file and one not encrypted file.
    If the file is encrypted by Trojan-Ransom.Win32.CryptXXX, indicate the largest files. Only the files of this size or smaller ones will be decrypted.
  2. Wait until the files are found and decrypted.
  3. Reboot the computer, if needed.
  4. To delete copies of encrypted files named like locked-<original_name>.<four_random_letters> after a successful decryption, use the option Delete encrypted files after decryption.
Please note. If the file was encrypted by Trojan-Ransom.Win32.Cryakl, the tool will save the files with the extension.decryptedKLR.original_extension. If you select the option Delete encrypted files after decryption, the decrypted file will be saved under the original name.
  1. By default, the tool log is saved on system disk (the one with the operating system installed).Log file name is: UtilityName.Version_Date_Time_log.txt

    For example, C:\RannohDecryptor.

If the system is encrypted by Trojan-Ransom.Win32.CryptXXX, the tool scans a limited number of files. If you have selected a file encrypted by CryptXXX v2, the encryption key restoration can take a rather long time. In this case the tool views the following message:



Command line options

-l <file_name> – create a log file with given name.

-y – close the window after decryption.

Symantec Endpoint Protection 12.1

这个可以理解为SCS的升级新一代版本,试用后感觉响应速度和PF占用都有了很大进步,使用symantec SAV或者SCS的朋友可以考虑更新到这个版本了。
Symantec Endpoint Protection V12.1简体中文版
英文名称:Symantec_Endpoint_Protection 12.1


[安装测试] 在WindowsXP SP2 SP3中文版Windows 7 中文版安装测试通过,因我没有该系统


Symantec Endpoint Protection将Symantec AntiVirus与高级威胁防御功能相结合,可以为笔记本、台式机和服务器提供无与伦比的恶意软件防护能力。 它在一个代{过}{滤}理和管理控制台中无缝集成了基本安全技术,从而不仅提高了防护能力,而且还有助于降低总拥有成本。

* 无缝集成一些基本技术,如防病毒、反间谍软件、防火墙、入侵防御和设备控制。
* 只需要一个代{过}{滤}理,通过一个管理控制台即可进行管理。
* 由端点安全领域的市场领导者提供无可匹敌的端点防护。
* 无需对每个端点额外部署软件即可立即进行 NAC 升级。

* 阻截恶意软件,如病毒、蠕虫、特洛伊木马、间谍软件、恶意软件、bot、零日威胁和 rootkit。
* 防止安全违规事件的发生,从而降低管理开销。
* 降低保障端点安全的总拥有成本。


为所有 Symantec Endpoint Protection 技术和 Symantec Network Access Control 提供一个代{过}{滤}理。 为管理所有 Symantec Endpoint Protection 技术和 Symantec Network Access Control 提供一个集成的界面。 允许对所有技术采用一种通信方法和一个内容交付系统。
* 提供了出色的操作效能,如单个软件更新、单个策略更新等。
* 提供了统一的集中报告。
* 提供了统一的授权许可和维护。
* 添加 Symantec Network Access Control 实施功能时不需要对客户端进行更改。
* 降低保障端点安全的总拥有成本。
* 降低了管理工作量。

基于行为的防护,可以防御零日威胁和前所未见的威胁。 与其它启发式技术不同,主动威胁扫描可以对未知应用程序的行为好坏进行分类,从而提供了更精确的恶意软件检测。
* 无需设置基于规则的配置即可准确检测恶意软件。
* 有助于降低误报数量。

高级 Rootkit 检测和删除功能
通过集成 VxMS(Veritas 映射服务,Veritas 的一种技术)提供了出色的 rootkit 检测和删除功能,从而可以访问操作系统底层,进行全面分析和修复。
* 检测并删除最难以处理的 rootkit。
* 无需对受感染的计算机重新制作映像,因此节省了时间和金钱,同时防止工作效率下降。

允许管理员控制用户和其它应用程序访问特定进程、文件和文件夹。 它提供了应用程序分析、进程控制、文集和注册表访问控制,以及模块和 DLL 控制。 它使管理员能够限制某些被视为可疑或高风险类型的活动。
* 防止恶意软件传播或破坏端点。
* 锁定端点,防止数据泄漏。

控制可以连接到计算机的外设以及这些外设的使用方式。 它可以锁定一个端点,阻止其与拇指驱动器、CD 刻录机、打印机和其它 USB 设备相连。
* 防止敏感的机密信息从端点被提取或窃取(数据泄漏)。
* 防止端点被通过外设传播的病毒感染。

Symantec Endpoint Protection 客户端(32 位)
* Windows 2000 SP3+、Windows XP、Windows Server 2003、Windows Vista (x86)
* Pentium III 300 MHz(Windows Vista 需要 1GHz)
* 256 MB 内存
* 180 MB 磁盘(安装期间额外需要 440 MB)

Symantec Endpoint Protection 客户端(64 位)
* Windows XP Professional (x64) SP1+、Windows Server 2003 (x64)、Windows Vista (x64)
* 1 GHz,采用以下处理器之一:具有 Intel EM64T 支持的 Intel Xeon、具有 EM64T 支持的 Intel Pentium IV、AMD 64 位 Opteron、AMD 64 位 Athlon(注意:不支持 Itanium)
* 256 MB 内存
* 180 MB 磁盘(安装期间额外需要 440 MB)

Symantec AntiVirus for Linux 客户端
支持的 Linux 分发:Red Hat Enterprise Linux、SuSE Linux Enterprise(服务器/台式机)、Novell Open Enterprise Server、VMWare ESX
Symantec Endpoint Protection Manager
* Windows XP Professional SP2;Windows Server 2003 Standard/Enterprise
* Microsoft Internet Information Services(Web 服务器)
* Microsoft SQL Server 2000 SP3 或 SQL Server 2005(可选)
* 2GB 内存
* 1GB 可用磁盘空间

Symantec Endpoint Protection 控制台
* Windows XP Professional;Windows Server 2003 Standard 或 Enterprise;Windows 2000 Professional/Server/Advanced Server
* Sun Java Runtime Environment (JRE) 1.5
* Microsoft Internet Explorer 6.0 SP2
* 512 MB 内存

Symantec? Endpoint Protection combines Symantec AntiVirus? with advanced threat prevention in a single agent delivering unmatched defense against malware for laptops, desktops and servers.

– Seamlessly integrates essential technologies such as antivirus, antispyware, firewall, intrusion prevention, device control
– Requires only a single agent and managed by a single management console
– Unmatched endpoint protection from a proven, market leading endpoint security vendor
– Each endpoint comes “SNAC-ready” (Symantec Network Access Control)(Optional purchase), enabling instant upgrade without additional software deployment on the endpoints

– Stops malware and such as viruses, worms, trojans, spyware, adware and rootkits
– Helps prevent security outbreaks
– Lowers TCO for endpoint security
– Reduces administrative effort


官方下载地址 注:简体中文版











也可使用Internet Download Manager等下载工具下载,貌似不需要打开以上三个网站,有兴趣的朋友可以试试。

RU4的官方卸载工具CleanWipe 12.1.4013.4013分享在百度网盘:




大小: 295213288 字节
MD5: 4CCC3D13EA37089CB7627E54F27E9DC2
SHA1: 24649DC19C57D26E499EA7A08FE8965B6D030599

大小: 306378272 字节
MD5: E95221CD9600DF58DA5DC266C4ECECF8
SHA1: F41D3DDE10D2A31700ADC8AAC15BD23747F196BC

大小: 295110912 字节
MD5: 3BBDD0F4627B7DAD8BA77B08FC801261
SHA1: 442CC4AA56B20D00071205727C982BE411BEE349

大小: 306268384 字节
MD5: F8C6440B3314164FEC79E45656B7DCF0
SHA1: A434004FE8B9CB21F3B4845E93F8DC0FB8D71B3D

大小: 1526418040 字节
MD5: DAF202F77A97301F8FC277C5AAA48E98
SHA1: 154AD7BBC1EE04FD54DDF707800AF5975BF6910D

大小: 1478648552 字节
MD5: D3EBF5290600F84B3F8C3CE279625DCC
SHA1: C6D3522F226DD0112182700D28BA634C10F41D9C

大小: 1868570360 字节
MD5: 4688734CE2BB1D5659C092F17E7F2699
SHA1: 4D2B7E50A0A70591982C39949EC6D87FA576D533

大小: 225922488 字节
MD5: C42C892E6FA3790421BA28654F0022D3
SHA1: 0397661DEEDF88B03CD98EA6C5CAA4A415BFE8BE

大小: 1820454240 字节
MD5: 814981BCA81BFD1AEC0684AA7BB2693F
SHA1: 0B380B57659B31E84C052E4AAA7817FF976BBB6A

大小: 221691368 字节
SHA1: 1B4FA87BF3CAC5B2CA5EF3C1949105985A05F2D9