mirror of
https://github.com/zeek/zeek.git
synced 2025-10-02 14:48:21 +00:00
Merge remote-tracking branch 'origin/topic/awelzel/revert-to-tpe'
* origin/topic/awelzel/revert-to-tpe: scripts: Use tpe instead of type_, again
This commit is contained in:
commit
eb6b4a0c46
9 changed files with 32 additions and 18 deletions
|
@ -85,6 +85,7 @@ ot2 = "ot2"
|
||||||
uses_seh = "uses_seh"
|
uses_seh = "uses_seh"
|
||||||
ect0 = "ect0"
|
ect0 = "ect0"
|
||||||
ect1 = "ect1"
|
ect1 = "ect1"
|
||||||
|
tpe = "tpe"
|
||||||
|
|
||||||
[default.extend-words]
|
[default.extend-words]
|
||||||
caf = "caf"
|
caf = "caf"
|
||||||
|
|
13
CHANGES
13
CHANGES
|
@ -1,3 +1,16 @@
|
||||||
|
8.0.0-dev.594 | 2025-07-03 20:43:51 +0200
|
||||||
|
|
||||||
|
* scripts: Use tpe instead of type_, again (Arne Welzel, Corelight)
|
||||||
|
|
||||||
|
The .rst generation doesn't escape the trailing `_` and the docs build
|
||||||
|
gets upset due to using `type` as a reference target then.
|
||||||
|
|
||||||
|
For the better or worse, revert to using tpe. Though I acknowledge this
|
||||||
|
means we need to be careful with trailing underscores because our docs
|
||||||
|
build is so fragile.
|
||||||
|
|
||||||
|
Partly reverts b9eabbabbab912c8f45c49013865a88c1256f342.
|
||||||
|
|
||||||
8.0.0-dev.592 | 2025-07-03 18:41:29 +0200
|
8.0.0-dev.592 | 2025-07-03 18:41:29 +0200
|
||||||
|
|
||||||
* NEWS: Adapt for conn_id$ctx introduction (Arne Welzel, Corelight)
|
* NEWS: Adapt for conn_id$ctx introduction (Arne Welzel, Corelight)
|
||||||
|
|
2
VERSION
2
VERSION
|
@ -1 +1 @@
|
||||||
8.0.0-dev.592
|
8.0.0-dev.594
|
||||||
|
|
|
@ -30,7 +30,7 @@ type EventFields: record {
|
||||||
option_val: string;
|
option_val: string;
|
||||||
};
|
};
|
||||||
|
|
||||||
event config_line(description: Input::EventDescription, type_: Input::Event, p: EventFields)
|
event config_line(description: Input::EventDescription, tpe: Input::Event, p: EventFields)
|
||||||
{
|
{
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -27,11 +27,11 @@ export {
|
||||||
##
|
##
|
||||||
## desc: The :zeek:type:`Input::EventDescription` record which generated the event.
|
## desc: The :zeek:type:`Input::EventDescription` record which generated the event.
|
||||||
##
|
##
|
||||||
## type_: The type of input event.
|
## tpe: The type of input event.
|
||||||
##
|
##
|
||||||
## item: The intel item being read (of type :zeek:type:`Intel::Item`).
|
## item: The intel item being read (of type :zeek:type:`Intel::Item`).
|
||||||
##
|
##
|
||||||
global read_entry: event(desc: Input::EventDescription, type_: Input::Event, item: Intel::Item);
|
global read_entry: event(desc: Input::EventDescription, tpe: Input::Event, item: Intel::Item);
|
||||||
|
|
||||||
## This event is raised each time the input framework detects an error
|
## This event is raised each time the input framework detects an error
|
||||||
## while reading the intel file. It can be used to implement further checks
|
## while reading the intel file. It can be used to implement further checks
|
||||||
|
@ -46,7 +46,7 @@ export {
|
||||||
global read_error: event(desc: Input::EventDescription, message: string, level: Reporter::Level);
|
global read_error: event(desc: Input::EventDescription, message: string, level: Reporter::Level);
|
||||||
}
|
}
|
||||||
|
|
||||||
event Intel::read_entry(desc: Input::EventDescription, type_: Input::Event, item: Intel::Item)
|
event Intel::read_entry(desc: Input::EventDescription, tpe: Input::Event, item: Intel::Item)
|
||||||
{
|
{
|
||||||
Intel::insert(item);
|
Intel::insert(item);
|
||||||
}
|
}
|
||||||
|
|
|
@ -76,16 +76,16 @@ event OpenFlow::cluster_flow_clear(name: string)
|
||||||
}
|
}
|
||||||
@endif
|
@endif
|
||||||
|
|
||||||
function register_controller(type_: OpenFlow::Plugin, name: string, controller: Controller)
|
function register_controller(tpe: OpenFlow::Plugin, name: string, controller: Controller)
|
||||||
{
|
{
|
||||||
controller$state$_name = cat(type_, name);
|
controller$state$_name = cat(tpe, name);
|
||||||
controller$state$_plugin = type_;
|
controller$state$_plugin = tpe;
|
||||||
|
|
||||||
# we only run the init functions on the manager.
|
# we only run the init functions on the manager.
|
||||||
if ( Cluster::local_node_type() != Cluster::MANAGER )
|
if ( Cluster::local_node_type() != Cluster::MANAGER )
|
||||||
return;
|
return;
|
||||||
|
|
||||||
register_controller_impl(type_, name, controller);
|
register_controller_impl(tpe, name, controller);
|
||||||
}
|
}
|
||||||
|
|
||||||
function unregister_controller(controller: Controller)
|
function unregister_controller(controller: Controller)
|
||||||
|
|
|
@ -113,12 +113,12 @@ export {
|
||||||
## Function to register a controller instance. This function
|
## Function to register a controller instance. This function
|
||||||
## is called automatically by the plugin _new functions.
|
## is called automatically by the plugin _new functions.
|
||||||
##
|
##
|
||||||
## type_: Type of this plugin.
|
## tpe: Type of this plugin.
|
||||||
##
|
##
|
||||||
## name: Unique name of this controller instance.
|
## name: Unique name of this controller instance.
|
||||||
##
|
##
|
||||||
## controller: The controller to register.
|
## controller: The controller to register.
|
||||||
global register_controller: function(type_: OpenFlow::Plugin, name: string, controller: Controller);
|
global register_controller: function(tpe: OpenFlow::Plugin, name: string, controller: Controller);
|
||||||
|
|
||||||
## Function to unregister a controller instance. This function
|
## Function to unregister a controller instance. This function
|
||||||
## should be called when a specific controller should no longer
|
## should be called when a specific controller should no longer
|
||||||
|
@ -253,7 +253,7 @@ function controller_init_done(controller: Controller)
|
||||||
|
|
||||||
# Functions that are called from cluster.zeek and non-cluster.zeek
|
# Functions that are called from cluster.zeek and non-cluster.zeek
|
||||||
|
|
||||||
function register_controller_impl(type_: OpenFlow::Plugin, name: string, controller: Controller)
|
function register_controller_impl(tpe: OpenFlow::Plugin, name: string, controller: Controller)
|
||||||
{
|
{
|
||||||
if ( controller$state$_name in name_to_controller )
|
if ( controller$state$_name in name_to_controller )
|
||||||
{
|
{
|
||||||
|
|
|
@ -25,12 +25,12 @@ function flow_clear(controller: Controller): bool
|
||||||
return F;
|
return F;
|
||||||
}
|
}
|
||||||
|
|
||||||
function register_controller(type_: OpenFlow::Plugin, name: string, controller: Controller)
|
function register_controller(tpe: OpenFlow::Plugin, name: string, controller: Controller)
|
||||||
{
|
{
|
||||||
controller$state$_name = cat(type_, name);
|
controller$state$_name = cat(tpe, name);
|
||||||
controller$state$_plugin = type_;
|
controller$state$_plugin = tpe;
|
||||||
|
|
||||||
register_controller_impl(type_, name, controller);
|
register_controller_impl(tpe, name, controller);
|
||||||
}
|
}
|
||||||
|
|
||||||
function unregister_controller(controller: Controller)
|
function unregister_controller(controller: Controller)
|
||||||
|
|
|
@ -58,7 +58,7 @@ type FileLine: record {
|
||||||
s: string;
|
s: string;
|
||||||
};
|
};
|
||||||
|
|
||||||
event Exec::line(description: Input::EventDescription, type_: Input::Event, s: string, is_stderr: bool)
|
event Exec::line(description: Input::EventDescription, tpe: Input::Event, s: string, is_stderr: bool)
|
||||||
{
|
{
|
||||||
local result = results[description$name];
|
local result = results[description$name];
|
||||||
if ( is_stderr )
|
if ( is_stderr )
|
||||||
|
@ -77,7 +77,7 @@ event Exec::line(description: Input::EventDescription, type_: Input::Event, s: s
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
event Exec::file_line(description: Input::EventDescription, type_: Input::Event, s: string)
|
event Exec::file_line(description: Input::EventDescription, tpe: Input::Event, s: string)
|
||||||
{
|
{
|
||||||
local parts = split_string1(description$name, /_/);
|
local parts = split_string1(description$name, /_/);
|
||||||
local name = parts[0];
|
local name = parts[0];
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue