Benjamin Bannier
f5a76c1aed
Reformat Zeek in Spicy style
...
This largely copies over Spicy's `.clang-format` configuration file. The
one place where we deviate is header include order since Zeek depends on
headers being included in a certain order.
2023-10-30 09:40:55 +01:00
Tim Wojtulewicz
2739275b88
Merge remote-tracking branch 'jsoref/spelling-src'
...
* jsoref/spelling-src:
Spelling src
2022-11-11 12:49:15 -07:00
Josh Soref
cd201aa24e
Spelling src
...
These are non-functional changes.
* accounting
* activation
* actual
* added
* addresult
* aggregable
* aligned
* alternatively
* ambiguous
* analysis
* analyzer
* anticlimactic
* apparently
* application
* appropriate
* arithmetic
* assignment
* assigns
* associated
* authentication
* authoritative
* barrier
* boundary
* broccoli
* buffering
* caching
* called
* canonicalized
* capturing
* certificates
* ciphersuite
* columns
* communication
* comparison
* comparisons
* compilation
* component
* concatenating
* concatenation
* connection
* convenience
* correctly
* corresponding
* could
* counting
* data
* declared
* decryption
* defining
* dependent
* deprecated
* detached
* dictionary
* directional
* directly
* directory
* discarding
* disconnecting
* distinguishes
* documentation
* elsewhere
* emitted
* empty
* endianness
* endpoint
* enumerator
* essentially
* evaluated
* everything
* exactly
* execute
* explicit
* expressions
* facilitates
* fiddling
* filesystem
* flag
* flagged
* for
* fragments
* guarantee
* guaranteed
* happen
* happening
* hemisphere
* identifier
* identifies
* identify
* implementation
* implemented
* implementing
* including
* inconsistency
* indeterminate
* indices
* individual
* information
* initial
* initialization
* initialize
* initialized
* initializes
* instantiate
* instantiated
* instantiates
* interface
* internal
* interpreted
* interpreter
* into
* it
* iterators
* length
* likely
* log
* longer
* mainly
* mark
* maximum
* message
* minimum
* module
* must
* name
* namespace
* necessary
* nonexistent
* not
* notifications
* notifier
* number
* objects
* occurred
* operations
* original
* otherwise
* output
* overridden
* override
* overriding
* overwriting
* ownership
* parameters
* particular
* payload
* persistent
* potential
* precision
* preexisting
* preservation
* preserved
* primarily
* probably
* procedure
* proceed
* process
* processed
* processes
* processing
* propagate
* propagated
* prototype
* provides
* publishing
* purposes
* queue
* reached
* reason
* reassem
* reassemble
* reassembler
* recommend
* record
* reduction
* reference
* regularly
* representation
* request
* reserved
* retrieve
* returning
* separate
* should
* shouldn't
* significant
* signing
* simplified
* simultaneously
* single
* somebody
* sources
* specific
* specification
* specified
* specifies
* specify
* statement
* subdirectories
* succeeded
* successful
* successfully
* supplied
* synchronization
* tag
* temporarily
* terminating
* that
* the
* transmitted
* true
* truncated
* try
* understand
* unescaped
* unforwarding
* unknown
* unknowndata
* unspecified
* update
* usually
* which
* wildcard
Signed-off-by: Josh Soref <2119212+jsoref@users.noreply.github.com>
2022-11-09 12:08:15 -05:00
Arne Welzel
fa956efa79
file_analysis/Analyzer: Limit maximum number of violations
...
Just the same as for protocol analyzers, prevent from violation event overload.
2022-11-08 16:44:39 -07:00
Arne Welzel
d5cd023dff
file_analysis: Implement AnalyzerViolation() for file_analysis/Analyzer
...
Add a test parsing a malformed PE file showing that analyzer_violation_info
is raised with the fa_file object set.
It could be interesting to pass through an optional connection if one
exists, but access is provided through f$conns, too.
2022-09-27 17:49:58 +02:00
Tim Wojtulewicz
8b544d648d
Remove uses of deprecated Tag types
2021-11-23 19:36:49 -07:00
Tim Wojtulewicz
b2f171ec69
Reformat the world
2021-09-16 15:35:39 -07:00
Tim Wojtulewicz
4ad08172d0
Remove obsolete ZEEK_FORWARD_DECLARE_NAMESPACED macros
2021-02-24 14:35:44 -07:00
Tim Wojtulewicz
0618be792f
Remove all of the random single-file deprecations
...
These are the changes that don't require a ton of changes to other files outside
of the original removal.
2021-01-27 10:52:40 -07:00
Tim Wojtulewicz
96d9115360
GH-1079: Use full paths starting with zeek/ when including files
2020-11-12 12:15:26 -07:00
Tim Wojtulewicz
fe0c22c789
Base: Clean up explicit uses of namespaces in places where they're not necessary.
...
This commit covers all of the common and base classes.
2020-08-24 12:07:00 -07:00
Tim Wojtulewicz
4b61d60e80
Fix indentation of namespaced aliases
2020-08-20 16:11:46 -07:00
Tim Wojtulewicz
14408235b8
Move file_analysis code to zeek namespaces
2020-08-20 15:55:17 -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
9364e6a5b7
Move IntrusivePtr and utility methods to the zeek namespace
2020-06-30 20:19:12 -07:00
Jon Siwek
57a6069cd1
Deprecate file analyzer construction methods taking raw RecordVal*
...
Replaced with versions that instead take IntrusivePtr
2020-05-22 16:13:15 -07:00
Jon Siwek
ecb7c7c27e
Deprecate file_analysis::Analyzer::Args(), replace with GetArgs()
2020-05-22 12:34:40 -07:00
Max Kellermann
0cf5799ca6
file_analysis: include cleanup
2020-02-13 10:12:03 +01:00
Max Kellermann
653b3f43e0
file_analysis/Analyzer: eliminate duplicate constructor
2020-02-13 10:12:03 +01:00
Keith J. Jones
67499979c8
Fixed typo.
2019-10-25 10:33:20 -04:00
Dominik Charousset
c1f3fe7829
Switch from header guards to pragma once
2019-09-17 14:10:30 +02:00
Tim Wojtulewicz
54752ef9a1
Deprecate the internal int/uint types in favor of the cstdint types they were based on
2019-08-12 13:50:07 -07:00
Robin Sommer
fead5f5d5e
Fix delay in disabling file analyzers.
...
When a file analyzer signaled being done with data delivery, the
analyzer would only be scheduled for removal at that poing, meaning it
could still receive more data until that action actually took effect.
Now we make sure to not send any more data to an analyzer.
2017-01-28 13:24:13 -08:00
Jon Siwek
cbbe7b52dc
Review/fix/change file reassembly functionality.
...
- Re-arrange how some fa_file fields (e.g. source, connection info, mime
type) get updated/set for consistency.
- Add more robust mechanisms for flushing the reassembly buffer.
The goal being to report all gaps and deliveries to file analyzers
regardless of the state of the reassembly buffer at the time it has to
be flushed.
2014-12-16 14:05:15 -06:00
Jon Siwek
69b1ba653d
Minor adjustments to plugin code/docs.
...
Mostly whitespace/typos.
Moved some Plugin methods out from public access.
2014-07-30 16:48:23 -05:00
Robin Sommer
d34f23c8d4
A set of file analysis extensions.
...
- Enable manager to associate analyzers with a MIME type. With that,
one can now say enable all analyzers for, e.g., "image/gif". This is
exposed to script-land as
Files::add_analyzers_for_mime_type(f: fa_file, mtype: string)
For MIME types identified via libmagic, this happens automatically
(via the file_new() handler in files/main.bro).
- Extend the analyzer API to better match that of protocol analyzers:
- Adding unique analyzer IDs so that we can refer to instances
from script-land.
- Adding subtypes to Components so that a single analyzer
implementation can support different types of analyzers
internally.
- Add an analyzer method SetTag() that allows to set the tag after
construction.
- Adding Init() and Done() methods for consistency with what other
classes offer.
- Add debug logging to the file_analysis stream.
TODO: test cases missing for the new script-land functionality.
2013-11-26 11:20:14 -08:00
Jon Siwek
5fa9c5865b
Factor out the need for a tag field in Files::AnalyzerArgs record.
...
This cleans up internals of how analyzer instances get identified by the
tag plus any args given to it and doesn't change script code a user
would write.
2013-07-31 09:48:19 -05:00
Seth Hall
58d133e764
Merge remote-tracking branch 'origin/master' into topic/seth/faf-updates
...
Conflicts:
scripts/base/frameworks/files/main.bro
scripts/base/init-bare.bro
scripts/base/protocols/ftp/file-analysis.bro
scripts/base/protocols/http/file-analysis.bro
scripts/base/protocols/irc/file-analysis.bro
scripts/base/protocols/smtp/file-analysis.bro
src/const.bif
src/event.bif
src/file_analysis/Analyzer.h
src/file_analysis/file_analysis.bif
2013-07-05 02:13:27 -04:00
Seth Hall
df2841458d
Large overhaul in name and appearance for file analysis.
2013-07-05 02:00:14 -04:00
Robin Sommer
d8b05af7e5
Merge remote-tracking branch 'origin/topic/jsiwek/faf-cleanup'
...
Closes #1002 .
* origin/topic/jsiwek/faf-cleanup:
Move file analyzers to new plugin infrastructure.
Add a general file analysis overview/how-to document.
Improve file analysis doxygen comments.
Improve tracking of HTTP file extraction (addresses #988 ).
Fix HTTP multipart body file analysis.
Remove logging of analyzers field of FileAnalysis::Info.
Remove extraction counter in default file extraction scripts.
Remove FileAnalysis::postpone_timeout.
Make default get_file_handle handlers &priority=5.
Add input interface to forward data for file analysis.
File analysis framework interface simplifications.
2013-07-03 16:27:16 -07:00
Jon Siwek
7c7b6214a6
Move file analyzers to new plugin infrastructure.
2013-06-10 15:50:18 -05:00
Jon Siwek
f82167d067
Improve file analysis doxygen comments.
2013-05-23 10:22:49 -05:00
Robin Sommer
7610aa31b6
Various smalle tweaks in preparation for merging.
2013-05-13 16:47:00 -07:00
Jon Siwek
b8c98b8bf7
FileAnalysis: change terminology s/action/analyzer
2013-04-11 14:53:54 -05:00