| 1 |
.. _User Manual: https://docs.zeek.org/projects/broker |
| 2 |
|
| 3 |
================================ |
| 4 |
Broker: Zeek's Messaging Library |
| 5 |
================================ |
| 6 |
|
| 7 |
The Broker library implements Zeek's high-level communication patterns: |
| 8 |
|
| 9 |
- remote logging |
| 10 |
- remote events |
| 11 |
- distributed data stores |
| 12 |
|
| 13 |
Remote logging and events all follow a pub/sub communication model |
| 14 |
between Broker endpoints that are directly peered with each other. An |
| 15 |
endpoint also has the option of subscribing to its own messages. |
| 16 |
Subscriptions are matched prefix-wise and endpoints have the capability |
| 17 |
of fine-tuning the subscription topic strings they wish to advertise to |
| 18 |
peers as well as the messages they wish to send to them. |
| 19 |
|
| 20 |
The distributed data store functionality allows a master data store |
| 21 |
associated with one Broker endpoint to be cloned at peer endpoints which |
| 22 |
may then perform lightweight, local queries against the clone, which |
| 23 |
automatically stays synchronized with the master store. Clones |
| 24 |
cannot modify their content directly, instead they send modifications |
| 25 |
to the centralized master store which applies them and then broadcasts |
| 26 |
them to all clones. |
| 27 |
|
| 28 |
Applications which integrate the Broker library may communicate with |
| 29 |
each other using the above-mentioned patterns which are common to Zeek. |
| 30 |
|
| 31 |
See the `User Manual`_ for more information. For offline reading, it's |
| 32 |
also available in the ``doc/`` directory of the source tree. |
| 33 |
|
| 34 |
See the NEWS file for the most important release notes and the CHANGES |
| 35 |
file for the complete history of changes. |
| 36 |
|
| 37 |
Dependencies |
| 38 |
------------ |
| 39 |
|
| 40 |
Compiling Broker requires the following libraries/tools to already be |
| 41 |
installed: |
| 42 |
|
| 43 |
* C++ compiler with C++17 support (GCC 7+, Clang 4+, MSVC 19.14+) |
| 44 |
* OpenSSL headers/libraries (http://www.openssl.org) |
| 45 |
* CMake 3.0 or greater (https://cmake.org) |
| 46 |
|
| 47 |
The optional Python bindings also require Python 2.7 or greater |
| 48 |
along with Python development packages. For Python 2.7, you'll |
| 49 |
also need the ``ipaddress`` backport from Python 3. |
| 50 |
|
| 51 |
By default, Broker will use an integrated version of the C++ Actor |
| 52 |
Framework (CAF; https://actor-framework.org), though there's still the |
| 53 |
option to specify an exernal CAF version via the ``--with-caf=`` |
| 54 |
configure script option. |
| 55 |
|
| 56 |
Compiling/Installing |
| 57 |
-------------------- |
| 58 |
|
| 59 |
On UNIX, we provide a ``configure`` script to automate the CMake setup. To |
| 60 |
compile and install into ``/usr/local``:: |
| 61 |
|
| 62 |
./configure |
| 63 |
make |
| 64 |
make install |
| 65 |
|
| 66 |
See ``./configure --help`` for more advanced configuration options. |
| 67 |
|
| 68 |
On Windows, we support MSVC natively. We do not support builds via MinGW or |
| 69 |
Cygwin. For Windows builds, please use CMake directly and use the CMake |
| 70 |
generator for your Visual Studio version. Afterwards, you can either open the |
| 71 |
project file with Visual Studio to build Broker, or you can build directly from |
| 72 |
the command line using CMake:: |
| 73 |
|
| 74 |
cmake --build <build-dir> --target install --config release |
| 75 |
|
| 76 |
Please note that Broker currently only supports *static* builds on MSVC. |