Giter Club home page Giter Club logo

Comments (3)

binf avatar binf commented on August 20, 2024

On Fri, Jun 21, 2013 at 8:44 AM, Boris [email protected] wrote:

Hello.
I encountered that base64_STATIC() (and also base64()) functions not correctly creating BASE64 digest.

When string is long additional '\n' inserted into output by:

if(cols == 72)
{
*output = '\n'; output++;
cols = 0;
}

condition.

For example when I use syslog_full output plugin at my /var/messages I see:

Jun 21 14:39:06 localhost | [SNORTIDS[LOG]: [test-sn01] ] || 2013-06-21 14:38:59.792+004 0 [1:1999999999:1] Snort Alert [1:1999999999:1] || [Unknown Classification] || 6 192.168.155.99 192.168.155.72 4 20 16 61 46288 2 0 52701 0 || 57929 22 3382172796 3250754374 8 0 24 365 5378 0 || 75 CAAnr4YhCAAnnKmBCABFEAA9tNBAAEAGzd3AqJtjwKibSOJJABbJl9x8wcKTRoAYAW0VAgAA#012AQEICgAeauAANwl0dGVzdDEyMw0K || #12 |

Under which OS do you log locally to syslog?

Seem's like your syslog server would be doing that.

Do you use rsyslog?

if you you might want to look into this:
http://www.rsyslog.com/doc/rsconf1_escapecontrolcharactersonreceive.html

-elz

from barnyard2.

dzruyk avatar dzruyk commented on August 20, 2024

Thx a lot for reply. EscapeControlCharactersOnReceive works perfect.

Additional question about syslog_full format.

I use output log_syslog_full with operation_mode complete directive
And at end of every alert (after encoded payload) I see something like this ( I use default delimiters and separators):

PAYLOAD || \n | \0

where \n - newline symbol
and \0 end of string symbol.

This is format mistake?

If yes I assume that its because inside OpSyslog_Log we use OpSyslog_Concat(syslogContext) to append last newline character and when operation mode is "complete" it will be wrapped around
syslogContext->delim.

from barnyard2.

binf avatar binf commented on August 20, 2024

On Fri, Jul 5, 2013 at 6:21 AM, Boris [email protected] wrote:

Thx a lot for reply. EscapeControlCharactersOnReceive works perfect.

Additional question about syslog_full format.

I use output log_syslog_full with operation_mode complete directive
And at end of every alert (after encoded payload) I see something like this ( I use default delimiters and separators):

PAYLOAD || \n | \0

where \n - newline symbol
and \0 end of string symbol.

This is format mistake?

If yes I assume that its because inside OpSyslog_Log we use OpSyslog_Concat(syslogContext) to append last newline character and when operation mode is "complete" it will be wrapped around
syslogContext->delim.

Yes the delimiter is appended by OpSyslog_Concat.
but you could allways ignore it in a regex by using something like ||
($1) || \n |

Where $1 would be your actual syslog pattern message for complete mode.

-elz

from barnyard2.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.