mirror of
https://github.com/zeek/zeek.git
synced 2025-10-07 17:18:20 +00:00
Merge branch 'master' into topic/jsiwek/autodoc-fixes
Conflicts: scripts/CMakeLists.txt scripts/base/frameworks/cluster/setup-connections.bro scripts/base/frameworks/communication/__load__.bro scripts/base/frameworks/metrics/conn-example.bro scripts/base/frameworks/metrics/http-example.bro scripts/site/local.bro
This commit is contained in:
commit
2a9ea6b8ba
96 changed files with 1809 additions and 722 deletions
|
@ -16,11 +16,13 @@ export {
|
|||
extract_file: bool &default=F;
|
||||
|
||||
## Store the file handle here for the file currently being extracted.
|
||||
extraction_file: file &optional;
|
||||
|
||||
extraction_file: file &log &optional;
|
||||
};
|
||||
|
||||
redef record State += {
|
||||
## Store a count of the number of files that have been transferred in
|
||||
## this conversation to create unique file names on disk.
|
||||
num_extracted_files: count &optional;
|
||||
num_extracted_files: count &default=0;
|
||||
};
|
||||
}
|
||||
|
||||
|
@ -34,7 +36,7 @@ event mime_segment_data(c: connection, length: count, data: string) &priority=3
|
|||
{
|
||||
if ( c$mime$extract_file && c$mime$content_len == 0 )
|
||||
{
|
||||
local suffix = fmt("%d.dat", ++c$mime$num_extracted_files);
|
||||
local suffix = fmt("%d.dat", ++c$mime_state$num_extracted_files);
|
||||
local fname = generate_extraction_filename(extraction_prefix, c, suffix);
|
||||
c$mime$extraction_file = open(fname);
|
||||
enable_raw_output(c$mime$extraction_file);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue