Commit graph

1565 commits

Author SHA1 Message Date
Robin Sommer
4bc18bd3f2 External tests no longer include the full content of mismatching files
in the diagnostics output.
2011-09-15 15:17:31 -07:00
Robin Sommer
53f93e7073 Removing load of script that doesn't exist anymore. 2011-09-15 15:06:21 -07:00
Robin Sommer
ad313a8412 Updating test baselines for recent HTTP output changes. 2011-09-15 15:04:14 -07:00
Robin Sommer
5beeca44a9 Updating CHANGES. 2011-09-15 14:59:11 -07:00
Jon Siwek
8697615b81 Memory leak fixes.
Both related to Val lists constructed as arguments to events that were
not freed because the event function was never called (e.g. no handlers).

Addresses #574
2011-09-15 16:08:48 -05:00
Seth Hall
8006f26db2 Merge remote-tracking branch 'origin/master' into topic/seth/notice-suppression 2011-09-15 00:27:57 -04:00
Seth Hall
d656e2a8c4 Fixing a major memory utilization issue with the x509_verify bif.
- The check for the root_certs variable was recreating the certificate
  store over and over again which would eventually consume lots of memory
  in the x509_stores internal (c++) variable.  The index check uses the
  Val pointer value for comparison now.
2011-09-14 22:51:52 -04:00
Seth Hall
c8e6255666 More options for the header-names.bro script. 2011-09-14 22:44:17 -04:00
Seth Hall
f32b567c85 New script for logging header names and values.
- Closes #519.
2011-09-13 22:33:26 -04:00
Seth Hall
af6c7c8b1a HTTP body size measurement added to http log.
- The value of the content-length headers has now been removed
  but it could be added back locally at an installation by a user.

- Added fields to indicate if some parsing interruption happened
  during the body transfer.

- Closes #581
2011-09-13 21:34:29 -04:00
Seth Hall
0a7685bf29 Not sure what happened here, but the broctl remote was on an old branch. 2011-09-13 10:41:25 -04:00
Seth Hall
fa375d3164 Removing a small "TODO" now that a bug has been fixed. 2011-09-13 09:10:19 -04:00
Seth Hall
ee1884ca93 Another change to possibly fix the SSL memory consumption problem.
- If a protocol violation happens, Bro now logs what it has seen
  up until the protocol violation and deletes the c$ssl record
  so that a long lived connection with a protocol violation does
  continue to hold the memory.
2011-09-13 09:09:55 -04:00
Jon Siwek
dd49f7d477 Add configure options for ruby/bindings integration. 2011-09-12 15:38:23 -05:00
Seth Hall
c87704cc25 Small usability and correctness updates.
- Removed an notice definition from the base SSL scripts.

- Moved a logging stream ID into the export section for known-services
  and bumped priority for creating the stream.

- Adding configuration knobs for the SQL injection attack detection
  script and renaming the HTTP::SQL_Injection_Attack notice to
  HTTP::SQL_Injection_Attack_Against

- Bumped priority when creating Known::CERTS_LOG.
2011-09-12 16:14:28 -04:00
Seth Hall
eda8632d62 Small updates for a warning from the cluster framework. 2011-09-12 15:50:04 -04:00
Robin Sommer
23643eb4da Updating submodule(s). 2011-09-12 12:16:14 -07:00
Robin Sommer
6ffde1abc2 Updating baselines and testing helper script. 2011-09-12 12:12:47 -07:00
Seth Hall
e0af4f6e8d Small, mostly cosmetic updates and fixing a test.
- The test needed to append the second notice the event queue so that
  the notice would be suppressed correctly.

- Setting $suppress_for manually in apply_policy since it doesn't pick
  up the &default when directly creating the record inside the NOTICE call.
2011-09-12 15:08:25 -04:00
Jon Siwek
a267c30fcd Fix crash on exit (addresses #607).
MutableVal's destructor now checks if the global scope still exists
before trying to remove an identifier from it.
2011-09-12 13:16:48 -05:00
Robin Sommer
83783c5ca7 Bugfix for log writer.
It didn't escape binary stuff in some situations.

Closes #585.
2011-09-11 21:33:09 -07:00
Seth Hall
2d85ab9818 Duplicate notice suppression.
- Duplicate notices are discovered with the new Notice::Info
  field $identifier.  It's a string that is left up to the
  notice implementor to define which would indicate a
  fundamentally duplicate notice.  The field is optional and
  if it's not included it's not possible for notice
  suppression to take place.

- Duplicate notices are suppressed by default for the interval
  defined by the Notice::default_suppression_interval variable
  (1 hour by default).

- A new notice action was defined ACTION_NO_SUPPRESS to prevent
  suppression for a specific notice instance.  A convenience set
  named not_suppressed_types was also created to not suppress
  entire notice types.

- A new field was added to the PolicyItem type to modify the length
  of time a notice should be suppressed if the predicate matches.
  The field is named $suppress_for.  This name makes the code more
  readable like this: $suppress_for = 1day

- New events were created to give visibility into the notice
  framework's suppression activity.
  - event Notice::begin_suppression(n: Notice::Info)
  - event Notice::suppressed(n: Notice::Info)
  - event Notice::end_suppression(n: Notice::Info)

- The suppression.bro script doesn't have a baseline because
  it is causing a segfault in Bro.  This one test is the
  reason that this is being integrated into a branch instead
  of master.
2011-09-11 08:44:48 -04:00
Jon Siwek
7ff2a3e115 Fix filter path_func to allow record argument as a subset of stream's columns.
This required adding the ability for RecordVal::CoerceTo functions to
optionally allow orphaning fields.  The default is to not allow it, but
now before writing to a log, the value of the stream's columns is coerced
down, if necessary, before passing it on to the filter's path_func.

Addresses #600.
2011-09-09 14:57:22 -05:00
Robin Sommer
5e1ec1c50e Fix for proxy usage. 2011-09-09 11:56:44 -07:00
Robin Sommer
cb2cb117d0 Excluding log fields of name mime_type for comparision.
This is because libmagic can return different results depending on
installation.

Note, this still doesn't fix all problems: smtp-entities sets md5
depending on the mime-type returned by libmagic ...
2011-09-09 11:41:03 -07:00
Jon Siwek
bf5b5218a9 Remove malloc.c (closes #557). 2011-09-09 13:30:43 -05:00
Jon Siwek
eb3c5ee1a4 Fix indexing for record types with optional fields
Addresses #378
2011-09-09 13:06:45 -05:00
Robin Sommer
3a3f58d5df Bugfix for trace updater. 2011-09-08 19:21:52 -07:00
Robin Sommer
7a989c476d Test infrastructure fixes.
- A new helper script to btest-diff a bunch of files simulatiously.

- Fixes to btest.cfg.

- A few further script updates.
2011-09-08 18:50:51 -07:00
Robin Sommer
07dd8eb952 Merge branch 'master' of ssh://git.bro-ids.org/bro 2011-09-08 15:04:38 -07:00
Robin Sommer
fc152d8038 Fixing metrics API call. 2011-09-08 14:50:35 -07:00
Jon Siwek
fe38c22d2b Remove Log::rotation_control (addresses #572).
Log rotation is now controlled directly through Filter records.

Also addressed a TODO in the default_path_func regarding the
LogMgr::AddFilter function generating internal filter path
suggestions/fallbacks.  Now, if the user doesn't explicitly set a filter
path, the filter's path will be the result of the first call to
default_path_func (happens during the first write to the log).  And in
that case the path suggestion argument to the path_func is an empty
string.
2011-09-08 15:00:31 -05:00
Robin Sommer
bd4a629bef Changes to the testing/external infrastructure.
The traces for external test-suites are no longer kept inside the
repositories themselves but downloaded separately via curl. This is
because git is pretty bad at dealing with large files.

See the README for more information.
2011-09-08 12:36:35 -07:00
Jon Siwek
d8c716ae17 Merge branch 'master' into topic/jsiwek/filter-rotation 2011-09-08 13:01:00 -05:00
Robin Sommer
856e207359 Updating submodule(s). 2011-09-08 09:08:34 -07:00
Robin Sommer
db8ab89c3a Merge remote branch 'origin/topic/jsiwek/misc-doc-fixes'
* origin/topic/jsiwek/misc-doc-fixes:
  More tweaks to generated script docs.
  Various changes to documentation framework.

Closes #598.
2011-09-08 09:07:20 -07:00
Seth Hall
3bf98548f7 The script level pf_ring support isn't working so removing it. 2011-09-08 02:28:04 -04:00
Seth Hall
cdbf0fda38 Updating broctl submodule for the new pf_ring support. 2011-09-08 02:21:43 -04:00
Seth Hall
fc75f7cc83 Merge branch 'master' of ssh://git.bro-ids.org/bro 2011-09-08 01:52:36 -04:00
Seth Hall
4931aa815f Delete SSL certificates from memory after ssl_established event.
- This is an attempt at fixing the memory issues brought about by
  the introduction of the new SSL analyzer.  My initial testing
  shows a hefty memory saving.
2011-09-08 01:52:25 -04:00
Robin Sommer
87cceadd48 Merge branch 'master' of ssh://git.bro-ids.org/bro 2011-09-07 16:18:15 -07:00
Robin Sommer
c2501cec51 Merge remote branch 'origin/topic/gilbert/rand-pool'
* origin/topic/gilbert/rand-pool:
  Updating tests.
  Updated uid pools to use integer values instead of strings.
  Updating tests.
  Test no longer relevant.  Need a way to generate and test collisions.
  A few minor tweaks to make code less braindead.  Fixed-length piece of pool name now only used to hash when determinism is not required; otherwise, whole pool name is used.  Note that collisions between pool name hashes will lead to sensitivity to initialization order within the UID generator.
  Testing long (>32 character) pool names.
  Simple test to verify various pools are not affecting each other.
  Some working code.  Adds UID pools classified by string.  Just compiles and runs; need to go back through and make sure this code is actually doing what I want it to do.

Note, I've removed the collision detection. Seems unlikely to occur
and even if, it's not really that bad.
2011-09-07 16:17:59 -07:00
Seth Hall
e07e4ca117 Cleaned up some small SSL mistakes. 2011-09-07 15:11:01 -04:00
Robin Sommer
f868af101c Potential fix for #588. 2011-09-07 11:08:33 -07:00
Jon Siwek
d2bf33ee19 Merge branch 'master' into topic/jsiwek/filter-rotation 2011-09-07 12:30:47 -05:00
Jon Siwek
95ed192088 More tweaks to generated script docs.
- The "private interface" section is still tracked, but no longer rendered.
  We can judge the usefulness of it later and add back if there's demand.

- Documentation of event handlers was being treated the same as event
  declarations.  Now handlers are tracked separately, but not currently
  rendered in the generated doc output since usefulness is questionable.
2011-09-07 11:33:08 -05:00
Jon Siwek
80e154ba3c Various changes to documentation framework.
- Reorganize top-level 'doc' Makefile target so submodules can easily
  add their own doc-generating routines to it.  e.g. the Bro project
  makes a placeholder 'doc' target, then adds 'restdoc', 'sphinxdoc';
  later Broccoli can add it's own target as a dependency for generating
  API docs.

- Fixed generated docs for BIFs not being organized under a base/
  subdirectory like the original source files.

- Fixed documentation style for function parameters not applying to
  functions declared as record fields.

- Misc. script documentation tweaks to address warnings given by Sphinx.
2011-09-07 10:02:15 -05:00
Seth Hall
eda2245e9e Merge remote-tracking branch 'origin/topic/seth/pf_ring_support'
* origin/topic/seth/pf_ring_support:
  Added pf_ring load balancing support to the scripting layer.
2011-09-06 15:20:22 -04:00
Gilbert Clark gc355804@ohio.edu
cff47dd98f Updating tests. 2011-09-05 12:12:09 -07:00
Gilbert Clark gc355804@ohio.edu
3953b851e5 Merge branch 'master' into topic/gilbert/rand-pool
Conflicts:
	testing/btest/Baseline/istate.events-ssl/receiver.http.log
	testing/btest/Baseline/istate.events-ssl/sender.http.log
	testing/btest/Baseline/istate.events/receiver.http.log
	testing/btest/Baseline/istate.events/sender.http.log
	testing/btest/Baseline/scripts.base.protocols.smtp.basic/smtp.log
2011-09-05 11:40:34 -07:00