Skip to content

Commit

Permalink
ossec: resolve journalist notification racing with reboots
Browse files Browse the repository at this point in the history
The app server is rebooted every 24h and will send a notification at
boot time. The ossec server is also rebooted and will immediately send
the email to the journalist, regardless of when the previous mail was
sent (mail frequency is not a feature of ossec-maild). Always running
the localfile command at boot time is an undocumented OSSEC behavior
ossec/ossec-hids#1415 in 2.8.2 as well as
2.9.3.

This guarantees exactly one mail will be sent daily.

Setting the 25 hours frequency element is a safeguard:

* against the following race a) command runs because the 24h period
  expires, b) the server reboots shortly after because it reboots
  every 24h, c) command runs again after the server is rebooted,
  causing two notifications to be sent in a row

* in case the server does not reboot for some reason, the notification
  will still be sent every 25h

Fixes: freedomofpress/securedrop#3367
  • Loading branch information
Loic Dachary committed May 9, 2018
1 parent adc9cd9 commit 16716d5
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions docs/install.rst
Original file line number Diff line number Diff line change
Expand Up @@ -75,6 +75,9 @@ worth checking the *Journalist Interface*. For this you will need:
the GPG private key, it is not possible to specify multiple
GPG keys.

.. note:: The journalist notification is sent after the daily reboot
of the *Application Server*.

You will have to copy the following required files to
``install_files/ansible-base``:

Expand Down

0 comments on commit 16716d5

Please sign in to comment.