mirror of
https://github.com/zeek/zeek.git
synced 2025-10-02 14:48:21 +00:00
Update script language reference documentation
This commit is contained in:
parent
260b25f20a
commit
d0e304de46
3 changed files with 32 additions and 10 deletions
|
@ -173,14 +173,20 @@ Here is a more detailed explanation of each attribute:
|
|||
|
||||
Rotates a file after a specified interval.
|
||||
|
||||
Note: This attribute is deprecated and will be removed in a future release.
|
||||
|
||||
.. bro:attr:: &rotate_size
|
||||
|
||||
Rotates a file after it has reached a given size in bytes.
|
||||
|
||||
Note: This attribute is deprecated and will be removed in a future release.
|
||||
|
||||
.. bro:attr:: &encrypt
|
||||
|
||||
Encrypts files right before writing them to disk.
|
||||
|
||||
Note: This attribute is deprecated and will be removed in a future release.
|
||||
|
||||
.. bro:attr:: &raw_output
|
||||
|
||||
Opens a file in raw mode, i.e., non-ASCII characters are not
|
||||
|
@ -229,5 +235,4 @@ Here is a more detailed explanation of each attribute:
|
|||
|
||||
The associated identifier is marked as deprecated and will be
|
||||
removed in a future version of Bro. Look in the NEWS file for more
|
||||
explanation and/or instructions to migrate code that uses deprecated
|
||||
functionality.
|
||||
instructions to migrate code that uses deprecated functionality.
|
||||
|
|
|
@ -58,6 +58,23 @@ executed. Directives are evaluated before script execution begins.
|
|||
for that script are ignored).
|
||||
|
||||
|
||||
.. bro:keyword:: @load-plugin
|
||||
|
||||
Activate a dynamic plugin with the specified plugin name. The specified
|
||||
plugin must be located in Bro's plugin search path. Example::
|
||||
|
||||
@load-plugin Demo::Rot13
|
||||
|
||||
By default, Bro will automatically activate all dynamic plugins found
|
||||
in the plugin search path (the search path can be changed by setting
|
||||
the environment variable BRO_PLUGIN_PATH to a colon-separated list of
|
||||
directories). However, in bare mode ("bro -b"), dynamic plugins can be
|
||||
activated only by using "@load-plugin", or by specifying the full
|
||||
plugin name on the Bro command-line (e.g., "bro Demo::Rot13"), or by
|
||||
setting the environment variable BRO_PLUGIN_ACTIVATE to a
|
||||
comma-separated list of plugin names.
|
||||
|
||||
|
||||
.. bro:keyword:: @load-sigs
|
||||
|
||||
This works similarly to "@load", except that in this case the filename
|
||||
|
|
|
@ -258,8 +258,8 @@ Here are the statements that the Bro scripting language supports.
|
|||
|
||||
.. bro:keyword:: break
|
||||
|
||||
The "break" statement is used to break out of a :bro:keyword:`switch` or
|
||||
:bro:keyword:`for` statement.
|
||||
The "break" statement is used to break out of a :bro:keyword:`switch`,
|
||||
:bro:keyword:`for`, or :bro:keyword:`while` statement.
|
||||
|
||||
|
||||
.. bro:keyword:: delete
|
||||
|
@ -379,10 +379,10 @@ Here are the statements that the Bro scripting language supports.
|
|||
|
||||
.. bro:keyword:: next
|
||||
|
||||
The "next" statement can only appear within a :bro:keyword:`for` loop.
|
||||
It causes execution to skip to the next iteration.
|
||||
The "next" statement can only appear within a :bro:keyword:`for` or
|
||||
:bro:keyword:`while` loop. It causes execution to skip to the next
|
||||
iteration.
|
||||
|
||||
For an example, see the :bro:keyword:`for` statement.
|
||||
|
||||
.. bro:keyword:: print
|
||||
|
||||
|
@ -571,7 +571,7 @@ Here are the statements that the Bro scripting language supports.
|
|||
|
||||
.. bro:keyword:: while
|
||||
|
||||
A "while" loop iterates over a body statement as long a given
|
||||
A "while" loop iterates over a body statement as long as a given
|
||||
condition remains true.
|
||||
|
||||
A :bro:keyword:`break` statement can be used at any time to immediately
|
||||
|
@ -609,8 +609,8 @@ Here are the statements that the Bro scripting language supports.
|
|||
(outside of the braces) of a compound statement.
|
||||
|
||||
A compound statement is required in order to execute more than one
|
||||
statement in the body of a :bro:keyword:`for`, :bro:keyword:`if`, or
|
||||
:bro:keyword:`when` statement.
|
||||
statement in the body of a :bro:keyword:`for`, :bro:keyword:`while`,
|
||||
:bro:keyword:`if`, or :bro:keyword:`when` statement.
|
||||
|
||||
Example::
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue