Skip to content

Commit

Permalink
Generate docs
Browse files Browse the repository at this point in the history
  • Loading branch information
zeek-bot committed Jun 5, 2024
1 parent a369cee commit 39de6cb
Show file tree
Hide file tree
Showing 4 changed files with 69 additions and 54 deletions.
2 changes: 1 addition & 1 deletion scripts/base/bif/event.bif.zeek.rst
Original file line number Diff line number Diff line change
Expand Up @@ -826,7 +826,7 @@ Events
.. zeek:see:: new_packet tcp_packet ipv6_ext_headers
.. zeek:id:: net_done
:source-code: base/init-bare.zeek 5925 5927
:source-code: base/init-bare.zeek 5945 5947

:Type: :zeek:type:`event` (t: :zeek:type:`time`)

Expand Down
47 changes: 24 additions & 23 deletions scripts/base/bif/reporter.bif.zeek.rst
Original file line number Diff line number Diff line change
Expand Up @@ -20,10 +20,10 @@ Summary
~~~~~~~
Functions
#########
========================================================================== ========================================================================
========================================================================== =========================================================================
:zeek:id:`Reporter::conn_weird`: :zeek:type:`function` Generates a "conn" weird.
:zeek:id:`Reporter::error`: :zeek:type:`function` Generates a non-fatal error indicative of a definite problem that should
be addressed.
:zeek:id:`Reporter::error`: :zeek:type:`function` Generates a usually non-fatal error indicative of a definite problem that
should be addressed.
:zeek:id:`Reporter::fatal`: :zeek:type:`function` Generates a fatal error on stderr and terminates program execution.
:zeek:id:`Reporter::fatal_error_with_core`: :zeek:type:`function` Generates a fatal error on stderr and terminates program execution
after dumping a core file
Expand All @@ -42,15 +42,15 @@ Functions
:zeek:id:`Reporter::set_weird_sampling_threshold`: :zeek:type:`function` Sets the current weird sampling threshold
:zeek:id:`Reporter::set_weird_sampling_whitelist`: :zeek:type:`function` Sets the weird sampling whitelist
:zeek:id:`Reporter::warning`: :zeek:type:`function` Generates a message that warns of a potential problem.
========================================================================== ========================================================================
========================================================================== =========================================================================


Detailed Interface
~~~~~~~~~~~~~~~~~~
Functions
#########
.. zeek:id:: Reporter::conn_weird
:source-code: base/bif/reporter.bif.zeek 95 95
:source-code: base/bif/reporter.bif.zeek 96 96

:Type: :zeek:type:`function` (name: :zeek:type:`string`, c: :zeek:type:`connection`, addl: :zeek:type:`string` :zeek:attr:`&default` = ``""`` :zeek:attr:`&optional`, source: :zeek:type:`string` :zeek:attr:`&default` = ``""`` :zeek:attr:`&optional`) : :zeek:type:`bool`

Expand All @@ -69,12 +69,13 @@ Functions
:returns: Always true.

.. zeek:id:: Reporter::error
:source-code: base/bif/reporter.bif.zeek 46 46
:source-code: base/bif/reporter.bif.zeek 47 47

:Type: :zeek:type:`function` (msg: :zeek:type:`string`) : :zeek:type:`bool`

Generates a non-fatal error indicative of a definite problem that should
be addressed. Program execution does not terminate.
Generates a usually non-fatal error indicative of a definite problem that
should be addressed. Program execution does not terminate unless the error
is reported during initialization (e.g., :zeek:see:`zeek_init`).


:param msg: The error message to report.
Expand All @@ -85,7 +86,7 @@ Functions
.. zeek:see:: reporter_error
.. zeek:id:: Reporter::fatal
:source-code: base/bif/reporter.bif.zeek 54 54
:source-code: base/bif/reporter.bif.zeek 55 55

:Type: :zeek:type:`function` (msg: :zeek:type:`string`) : :zeek:type:`bool`

Expand All @@ -98,7 +99,7 @@ Functions
:returns: Always true.

.. zeek:id:: Reporter::fatal_error_with_core
:source-code: base/bif/reporter.bif.zeek 63 63
:source-code: base/bif/reporter.bif.zeek 64 64

:Type: :zeek:type:`function` (msg: :zeek:type:`string`) : :zeek:type:`bool`

Expand All @@ -112,7 +113,7 @@ Functions
:returns: Always true.

.. zeek:id:: Reporter::file_weird
:source-code: base/bif/reporter.bif.zeek 107 107
:source-code: base/bif/reporter.bif.zeek 108 108

:Type: :zeek:type:`function` (name: :zeek:type:`string`, f: :zeek:type:`fa_file`, addl: :zeek:type:`string` :zeek:attr:`&default` = ``""`` :zeek:attr:`&optional`, source: :zeek:type:`string` :zeek:attr:`&default` = ``""`` :zeek:attr:`&optional`) : :zeek:type:`bool`

Expand All @@ -131,7 +132,7 @@ Functions
:returns: true if the file was still valid, else false.

.. zeek:id:: Reporter::flow_weird
:source-code: base/bif/reporter.bif.zeek 83 83
:source-code: base/bif/reporter.bif.zeek 84 84

:Type: :zeek:type:`function` (name: :zeek:type:`string`, orig: :zeek:type:`addr`, resp: :zeek:type:`addr`, addl: :zeek:type:`string` :zeek:attr:`&default` = ``""`` :zeek:attr:`&optional`, source: :zeek:type:`string` :zeek:attr:`&default` = ``""`` :zeek:attr:`&optional`) : :zeek:type:`bool`

Expand All @@ -150,7 +151,7 @@ Functions
:returns: Always true.

.. zeek:id:: Reporter::get_weird_sampling_duration
:source-code: base/bif/reporter.bif.zeek 170 170
:source-code: base/bif/reporter.bif.zeek 171 171

:Type: :zeek:type:`function` () : :zeek:type:`interval`

Expand All @@ -160,7 +161,7 @@ Functions
:returns: weird sampling duration.

.. zeek:id:: Reporter::get_weird_sampling_global_list
:source-code: base/bif/reporter.bif.zeek 127 127
:source-code: base/bif/reporter.bif.zeek 128 128

:Type: :zeek:type:`function` () : :zeek:type:`string_set`

Expand All @@ -170,7 +171,7 @@ Functions
:returns: Current weird sampling global list

.. zeek:id:: Reporter::get_weird_sampling_rate
:source-code: base/bif/reporter.bif.zeek 156 156
:source-code: base/bif/reporter.bif.zeek 157 157

:Type: :zeek:type:`function` () : :zeek:type:`count`

Expand All @@ -180,7 +181,7 @@ Functions
:returns: weird sampling rate.

.. zeek:id:: Reporter::get_weird_sampling_threshold
:source-code: base/bif/reporter.bif.zeek 141 141
:source-code: base/bif/reporter.bif.zeek 142 142

:Type: :zeek:type:`function` () : :zeek:type:`count`

Expand All @@ -190,7 +191,7 @@ Functions
:returns: current weird sampling threshold.

.. zeek:id:: Reporter::get_weird_sampling_whitelist
:source-code: base/bif/reporter.bif.zeek 113 113
:source-code: base/bif/reporter.bif.zeek 114 114

:Type: :zeek:type:`function` () : :zeek:type:`string_set`

Expand All @@ -215,7 +216,7 @@ Functions
.. zeek:see:: reporter_info
.. zeek:id:: Reporter::net_weird
:source-code: base/bif/reporter.bif.zeek 71 71
:source-code: base/bif/reporter.bif.zeek 72 72

:Type: :zeek:type:`function` (name: :zeek:type:`string`, addl: :zeek:type:`string` :zeek:attr:`&default` = ``""`` :zeek:attr:`&optional`, source: :zeek:type:`string` :zeek:attr:`&default` = ``""`` :zeek:attr:`&optional`) : :zeek:type:`bool`

Expand All @@ -228,7 +229,7 @@ Functions
:returns: Always true.

.. zeek:id:: Reporter::set_weird_sampling_duration
:source-code: base/bif/reporter.bif.zeek 179 179
:source-code: base/bif/reporter.bif.zeek 180 180

:Type: :zeek:type:`function` (weird_sampling_duration: :zeek:type:`interval`) : :zeek:type:`bool`

Expand All @@ -242,7 +243,7 @@ Functions
:returns: always returns True

.. zeek:id:: Reporter::set_weird_sampling_global_list
:source-code: base/bif/reporter.bif.zeek 135 135
:source-code: base/bif/reporter.bif.zeek 136 136

:Type: :zeek:type:`function` (weird_sampling_global_list: :zeek:type:`string_set`) : :zeek:type:`bool`

Expand All @@ -255,7 +256,7 @@ Functions
:returns: Always true.

.. zeek:id:: Reporter::set_weird_sampling_rate
:source-code: base/bif/reporter.bif.zeek 164 164
:source-code: base/bif/reporter.bif.zeek 165 165

:Type: :zeek:type:`function` (weird_sampling_rate: :zeek:type:`count`) : :zeek:type:`bool`

Expand All @@ -268,7 +269,7 @@ Functions
:returns: Always returns true.

.. zeek:id:: Reporter::set_weird_sampling_threshold
:source-code: base/bif/reporter.bif.zeek 149 149
:source-code: base/bif/reporter.bif.zeek 150 150

:Type: :zeek:type:`function` (weird_sampling_threshold: :zeek:type:`count`) : :zeek:type:`bool`

Expand All @@ -281,7 +282,7 @@ Functions
:returns: Always returns true;

.. zeek:id:: Reporter::set_weird_sampling_whitelist
:source-code: base/bif/reporter.bif.zeek 121 121
:source-code: base/bif/reporter.bif.zeek 122 122

:Type: :zeek:type:`function` (weird_sampling_whitelist: :zeek:type:`string_set`) : :zeek:type:`bool`

Expand Down
56 changes: 38 additions & 18 deletions scripts/base/init-bare.zeek.rst
Original file line number Diff line number Diff line change
Expand Up @@ -1425,7 +1425,7 @@ Redefinable Options
.. zeek:id:: bits_per_uid
:source-code: base/init-bare.zeek 5878 5878
:source-code: base/init-bare.zeek 5898 5898

:Type: :zeek:type:`count`
:Attributes: :zeek:attr:`&redef`
Expand Down Expand Up @@ -1466,7 +1466,7 @@ Redefinable Options
be reported via :zeek:see:`content_gap`.

.. zeek:id:: digest_salt
:source-code: base/init-bare.zeek 5886 5886
:source-code: base/init-bare.zeek 5906 5906

:Type: :zeek:type:`string`
:Attributes: :zeek:attr:`&redef`
Expand Down Expand Up @@ -1644,7 +1644,7 @@ Redefinable Options
means "forever", which resists evasion, but can lead to state accrual.

.. zeek:id:: global_hash_seed
:source-code: base/init-bare.zeek 5873 5873
:source-code: base/init-bare.zeek 5893 5893

:Type: :zeek:type:`string`
:Attributes: :zeek:attr:`&redef`
Expand Down Expand Up @@ -1701,7 +1701,7 @@ Redefinable Options
.. zeek:see:: conn_stats
.. zeek:id:: io_poll_interval_default
:source-code: base/init-bare.zeek 5903 5903
:source-code: base/init-bare.zeek 5923 5923

:Type: :zeek:type:`count`
:Attributes: :zeek:attr:`&redef`
Expand All @@ -1720,7 +1720,7 @@ Redefinable Options
.. zeek:see:: io_poll_interval_live
.. zeek:id:: io_poll_interval_live
:source-code: base/init-bare.zeek 5918 5918
:source-code: base/init-bare.zeek 5938 5938

:Type: :zeek:type:`count`
:Attributes: :zeek:attr:`&redef`
Expand Down Expand Up @@ -1960,7 +1960,7 @@ Redefinable Options
was observed.

.. zeek:id:: max_find_all_string_length
:source-code: base/init-bare.zeek 5890 5890
:source-code: base/init-bare.zeek 5910 5910

:Type: :zeek:type:`int`
:Attributes: :zeek:attr:`&redef`
Expand Down Expand Up @@ -2190,7 +2190,7 @@ Redefinable Options
Time to wait before timing out an RPC request.

.. zeek:id:: running_under_test
:source-code: base/init-bare.zeek 5922 5922
:source-code: base/init-bare.zeek 5942 5942

:Type: :zeek:type:`bool`
:Attributes: :zeek:attr:`&redef`
Expand Down Expand Up @@ -3361,7 +3361,7 @@ State Variables
.. zeek:see:: dns_skip_all_auth dns_skip_addl
.. zeek:id:: done_with_network
:source-code: base/init-bare.zeek 5924 5924
:source-code: base/init-bare.zeek 5944 5944

:Type: :zeek:type:`bool`
:Default: ``F``
Expand Down Expand Up @@ -7711,15 +7711,23 @@ Types
The full list of TCP Option fields parsed from a TCP header.

.. zeek:type:: Telemetry::HistogramMetric
:source-code: base/init-bare.zeek 5846 5862
:source-code: base/init-bare.zeek 5858 5882

:Type: :zeek:type:`record`

opts: :zeek:type:`Telemetry::MetricOpts`
A :zeek:see:`Telemetry::MetricOpts` record describing this histogram.

labels: :zeek:type:`vector` of :zeek:type:`string`
The label values associated with this histogram, if any.
label_names: :zeek:type:`vector` of :zeek:type:`string` :zeek:attr:`&default` = ``[]`` :zeek:attr:`&optional`
The label names (also called dimensions) of the metric. When
instantiating or working with concrete metrics, corresponding
label values have to be provided. Examples of a label might
be the protocol a general observation applies to, the
directionality in a traffic flow, or protocol-specific
context like a particular message type.

label_values: :zeek:type:`vector` of :zeek:type:`string` :zeek:attr:`&optional`
The label values associated with this metric, if any.

values: :zeek:type:`vector` of :zeek:type:`double`
Individual counters for each of the buckets as
Expand All @@ -7734,20 +7742,28 @@ Types
Histograms returned by the :zeek:see:`Telemetry::collect_histogram_metrics` function.

.. zeek:type:: Telemetry::HistogramMetricVector
:source-code: base/init-bare.zeek 5865 5865
:source-code: base/init-bare.zeek 5885 5885

:Type: :zeek:type:`vector` of :zeek:type:`Telemetry::HistogramMetric`


.. zeek:type:: Telemetry::Metric
:source-code: base/init-bare.zeek 5831 5843
:source-code: base/init-bare.zeek 5835 5855

:Type: :zeek:type:`record`

opts: :zeek:type:`Telemetry::MetricOpts`
A :zeek:see:`Telemetry::MetricOpts` record describing this metric.

labels: :zeek:type:`vector` of :zeek:type:`string`
label_names: :zeek:type:`vector` of :zeek:type:`string` :zeek:attr:`&default` = ``[]`` :zeek:attr:`&optional`
The label names (also called dimensions) of the metric. When
instantiating or working with concrete metrics, corresponding
label values have to be provided. Examples of a label might
be the protocol a general observation applies to, the
directionality in a traffic flow, or protocol-specific
context like a particular message type.

label_values: :zeek:type:`vector` of :zeek:type:`string` :zeek:attr:`&optional`
The label values associated with this metric, if any.

value: :zeek:type:`double` :zeek:attr:`&optional`
Expand All @@ -7759,7 +7775,7 @@ Types
Metrics returned by the :zeek:see:`Telemetry::collect_metrics` function.

.. zeek:type:: Telemetry::MetricOpts
:source-code: base/init-bare.zeek 5784 5828
:source-code: base/init-bare.zeek 5784 5832

:Type: :zeek:type:`record`

Expand All @@ -7783,13 +7799,17 @@ Types
help_text: :zeek:type:`string` :zeek:attr:`&optional`
Documentation for this metric.

labels: :zeek:type:`vector` of :zeek:type:`string` :zeek:attr:`&default` = ``[]`` :zeek:attr:`&optional`
label_names: :zeek:type:`vector` of :zeek:type:`string` :zeek:attr:`&default` = ``[]`` :zeek:attr:`&optional`
The label names (also called dimensions) of the metric. When
instantiating or working with concrete metrics, corresponding
label values have to be provided. Examples of a label might
be the protocol a general observation applies to, the
directionality in a traffic flow, or protocol-specific
context like a particular message type.
context like a particular message type. This field is only
used in the construction of new metrics and will not be
filled in when returned from
:zeek:see:`Telemetry::collect_metrics` or
:zeek:see:`Telemetry::collect_histogram_metrics`,

is_total: :zeek:type:`bool` :zeek:attr:`&optional`
Whether the metric represents something that is accumulating.
Expand Down Expand Up @@ -7822,7 +7842,7 @@ Types
.. zeek:type:: Telemetry::MetricVector
:source-code: base/init-bare.zeek 5864 5864
:source-code: base/init-bare.zeek 5884 5884

:Type: :zeek:type:`vector` of :zeek:type:`Telemetry::Metric`

Expand Down
Loading

0 comments on commit 39de6cb

Please sign in to comment.