Commit graph

10798 commits

Author SHA1 Message Date
Tim Wojtulewicz
e6871ed3e9 GH-1040: Add zero-indexed version of str_split 2020-07-06 17:05:40 -07:00
Jon Siwek
76a38caf34 Fix WhileStmt to call Stmt(Tag) ctor
Also removed Stmt() default ctor to help ensure derived classes
initialize the Stmt tag (and other members).
2020-07-06 12:22:23 -07:00
Ron Wellman
e7146c2a6b Implement EDNS Client Subnet Option 2020-07-06 15:09:03 -04:00
Tim Wojtulewicz
560ee0c05e GH-1041: Move compress_path to a bif that uses normalize_path 2020-07-06 11:43:44 -07:00
Jon Siwek
e891c310fb Update submodule(s)
[nomail]
2020-07-06 10:31:24 -07:00
Robin Sommer
3d3d5e7eb4 Merge remote-tracking branch 'origin/topic/jsiwek/add-backtrace-bif'
(Added a Doxygen comment.)

* origin/topic/jsiwek/add-backtrace-bif:
  Add backtrace() and print_backtrace()
2020-07-06 14:56:28 +00:00
Jon Siwek
8d4df512d0 Update submodule(s)
[nomail]
2020-07-04 00:04:19 -07:00
Jon Siwek
9770acd029 Update submodule(s)
[nomail]
2020-07-03 14:42:11 -07:00
Jon Siwek
61b52b54ba Fix --enable-mobile-ipv6 build 2020-07-03 14:30:13 -07:00
Jon Siwek
3a59948238 Fix namespace of GetCurrentLocation() to zeek::detail 2020-07-03 14:18:02 -07:00
Jon Siwek
a1c19840ce Add backtrace() and print_backtrace() 2020-07-03 14:09:31 -07:00
Jon Siwek
76e67ff239 Merge remote-tracking branch 'origin/topic/timw/266-namespaces-part2'
* origin/topic/timw/266-namespaces-part2:
  Rename BroString files to ZeekString
  Update NEWS entry with note about class renames
  Rename BroObj to Obj
  Rename BroString to zeek::String
  Move Func up to zeek namespace, rename BroFunc to ScriptFunc
  Mark global val_mgr as deprecated and fix uses of it to use namespaced version
  Minor cleanup items from PR review
  Update binpac and bifcl submodules with review changes
  Move Location to zeek::detail and BroObj to zeek
  Move BroString to zeek namespace
  Move Dictionary/PDict, List/PList, and Queue/PQueue to zeek namespace
  Remove typedef that should have been removed in 3.1
  Move Func and associated classes into zeek::detail namespace
  Move Frame and Scope to zeek::detail namespace
  Move all Val classes to the zeek namespaces
  Use type aliases for IntrusivePtr definitions
  Move deprecation macro to zeek-config.h.in to avoid having to over-include util.h
  Move IntrusivePtr and utility methods to the zeek namespace
2020-07-02 19:25:13 -07:00
Tim Wojtulewicz
45d2c96643 Rename BroString files to ZeekString 2020-07-02 17:24:22 -07:00
Tim Wojtulewicz
fbab72866c Update NEWS entry with note about class renames 2020-07-02 16:15:01 -07:00
Tim Wojtulewicz
02cef05f93 Rename BroObj to Obj 2020-07-02 16:15:01 -07:00
Tim Wojtulewicz
736a3f53d4 Rename BroString to zeek::String 2020-07-02 16:15:01 -07:00
Tim Wojtulewicz
a2bc42dd93 Move Func up to zeek namespace, rename BroFunc to ScriptFunc 2020-07-02 16:15:01 -07:00
Tim Wojtulewicz
86fdf0eaa9 Mark global val_mgr as deprecated and fix uses of it to use namespaced version 2020-07-02 16:15:00 -07:00
Tim Wojtulewicz
d1814ea1ff Merge remote-tracking branch 'origin/topic/jsiwek/gh-786-fix-incomplete-casts'
* origin/topic/jsiwek/gh-786-fix-incomplete-casts:
  GH-786: fix Val::As methods casting incomplete types
  GH-786: fix Stmt::As methods casting incomplete types
  GH-786: fix Expr::As methods casting incomplete types
2020-07-02 15:57:40 -07:00
Jon Siwek
902173a358 GH-786: fix Val::As methods casting incomplete types 2020-07-02 14:55:04 -07:00
Jon Siwek
5cba12444a GH-786: fix Stmt::As methods casting incomplete types 2020-07-02 14:28:28 -07:00
Jon Siwek
c8b6badd54 GH-786: fix Expr::As methods casting incomplete types 2020-07-02 14:23:20 -07:00
Tim Wojtulewicz
3098dd6fbb Minor cleanup items from PR review 2020-07-02 12:55:21 -07:00
Jon Siwek
0ec2ff20c6 Merge remote-tracking branch 'origin/topic/timw/786-typecasting'
* origin/topic/timw/786-typecasting:
  GH-786: Move Type::As methods to cc file so they have type info for casting safely
2020-07-02 11:38:35 -07:00
Tim Wojtulewicz
3d9d3972f1 Update binpac and bifcl submodules with review changes 2020-07-02 11:07:48 -07:00
Johanna Amann
f6251e62a0 BrokerStore<->Zeek tables: allow setting storage location & tests
With this, the basic functionality of &backend seems to be working.

It is not yet integrated with zeekctl, one has to manually specify the
storage location for the sqlite files somewhere when using sqlite.

Usage for memory stores:

global table_to_share: table[string] of count &backend=Broker::MEMORY;

Usage for sqlite stores:

redef Broker::auto_store_db_directory = "[path]";
global table_to_share: table[string] of count &backend=Broker::SQLITE;

In both cases, the cluster should automatically sync to changes done by
any node. When using sqlite, data should also be saved to disk and
re-loaded on startup.
2020-07-01 17:10:43 -07:00
Johanna Amann
a220b02722 BrokerStore<->Zeek tables: &backend works for in-memory stores.
Currently this requires using this with a normal cluster - or sending
messages by yourself.

It, in principle, should also work with SQLITE - but that is a bit
nonsensical without being able to change the storage location.
2020-07-01 16:38:10 -07:00
Jon Siwek
734af6b6d1 Fix a deprecation warning compiling with GCC 2020-07-01 09:58:18 -07:00
Tim Wojtulewicz
ae7a4f7735 GH-786: Move Type::As methods to cc file so they have type info for casting safely 2020-07-01 09:27:55 -07:00
Tim Wojtulewicz
40ecede4ea Move Location to zeek::detail and BroObj to zeek 2020-06-30 21:12:26 -07:00
Tim Wojtulewicz
58c6e10b62 Move BroString to zeek namespace 2020-06-30 21:12:26 -07:00
Tim Wojtulewicz
464efbe66a Move Dictionary/PDict, List/PList, and Queue/PQueue to zeek namespace 2020-06-30 21:12:26 -07:00
Tim Wojtulewicz
4a1e17f4e0 Remove typedef that should have been removed in 3.1 2020-06-30 20:51:58 -07:00
Tim Wojtulewicz
d6f1ea16ac Move Func and associated classes into zeek::detail namespace 2020-06-30 20:51:58 -07:00
Tim Wojtulewicz
937a462e70 Move Frame and Scope to zeek::detail namespace 2020-06-30 20:51:53 -07:00
Tim Wojtulewicz
64332ca22c Move all Val classes to the zeek namespaces 2020-06-30 20:48:09 -07:00
Tim Wojtulewicz
ec9eff0bd5 Use type aliases for IntrusivePtr definitions 2020-06-30 20:37:30 -07:00
Tim Wojtulewicz
f6a251cdac Move deprecation macro to zeek-config.h.in to avoid having to over-include util.h 2020-06-30 20:19:14 -07:00
Tim Wojtulewicz
9364e6a5b7 Move IntrusivePtr and utility methods to the zeek namespace 2020-06-30 20:19:12 -07:00
Jon Siwek
4668378d91 Merge remote-tracking branch 'origin/topic/timw/1032-namespaced-enums'
Merge adjustments:
- Added back in deprecation tag for base_type_no_ref()
- Added back the deprecated plugin::hook_name() function

* origin/topic/timw/1032-namespaced-enums:
  Deprecate plugin::HookType and plugin::component::Type in a different way
  Deprecate init_class and IDScope in another way.
  Deprecate TypeTag and friends in a different way
  Deprecate attr_tag in a different way, rename to AttrTag
2020-06-30 16:55:36 -07:00
Johanna Amann
318a72c303 BrokerStore<->Zeek table - introdude &backend attribute
The &backend attribute allows for a much more convenient way of
interacting with brokerstores. One does not need to create a broker
store anymore - instead all of this is done internally.

The current state of this partially works. This should work fine for
persistence - but clones are currently not yet correctly attached.
2020-06-30 16:33:52 -07:00
Jon Siwek
35fa042fd6 Merge remote-tracking branch 'origin/topic/timw/1034-IndexTypes'
Minor tweaks during merge:
- Remove/default superfluous ~Attributes()
- Added in resize() calls to accompany reserve() of associated vectors

* origin/topic/timw/1034-IndexTypes:
  Revert Attributes::Attrs back to return an attr_list and mark it deprecated
  GH-1034: Revert TypeList::Types() back to return a type_list* and mark it deprecated
2020-06-30 15:56:49 -07:00
Tim Wojtulewicz
b1b1ec5171 Deprecate plugin::HookType and plugin::component::Type in a different way 2020-06-30 13:38:39 -07:00
Tim Wojtulewicz
7ee8e11a8f Deprecate init_class and IDScope in another way.
This also renamed init_class to InitClass for consistency.
2020-06-30 13:06:34 -07:00
Tim Wojtulewicz
361ad8f2f7 Deprecate TypeTag and friends in a different way 2020-06-30 12:48:07 -07:00
Tim Wojtulewicz
a280bfa0b1 Deprecate attr_tag in a different way, rename to AttrTag 2020-06-30 12:47:54 -07:00
Jon Siwek
e85dce7907 Update submodule(s)
[nomail]
2020-06-30 11:32:15 -07:00
Jon Siwek
9f437b19a9 Update submodule(s)
[nomail]
2020-06-30 11:06:21 -07:00
Tim Wojtulewicz
5b8aaf6497 Revert Attributes::Attrs back to return an attr_list and mark it deprecated 2020-06-30 10:39:03 -07:00
Tim Wojtulewicz
e1338cc379 GH-1034: Revert TypeList::Types() back to return a type_list* and mark it deprecated 2020-06-29 17:50:09 -07:00