User Activity

  • Posted a comment on ticket #124 on bogofilter -- Fast Bayesian Spam Filter

    Actually, the code doesn't update the begin of the buffer and buff.read is just a position between buffer begin and buff.size. Hopefully the last iteration: --- a/src/lexer.c +++ b/src/lexer.c @@ -260,6 +260,7 @@ static int get_decoded_line(buff_t *buff) byte *buf = buff->t.u.text; if (memcmp(buf + count - 2, CRLF, 2) == 0) { count --; + --buff->t.leng; *(buf + count - 1) = (byte) '\n'; } } @@ -334,7 +335,7 @@ int yyinput(byte *buf, size_t used, size_t size) while ((cnt = get_decoded_line(&buff))...

  • Created ticket #126 on bogofilter -- Fast Bayesian Spam Filter

    Fix out-of-bounds read in spanword

  • Created ticket #125 on bogofilter -- Fast Bayesian Spam Filter

    Fix memory-leak in db_open()

  • Posted a comment on ticket #124 on bogofilter -- Fast Bayesian Spam Filter

    The above breaks the t.passthrough-hb test case (cf. make check) because there is one adjustment in get_decoded_line() missing. This improved patch fixes make check again and the original issue: --- a/src/lexer.c +++ b/src/lexer.c @@ -260,6 +260,7 @@ static int get_decoded_line(buff_t *buff) byte *buf = buff->t.u.text; if (memcmp(buf + count - 2, CRLF, 2) == 0) { count --; + --buff->t.leng; *(buf + count - 1) = (byte) '\n'; } } @@ -334,7 +335,7 @@ int yyinput(byte *buf, size_t used, size_t size)...

  • Posted a comment on ticket #124 on bogofilter -- Fast Bayesian Spam Filter

    Actually, the change isn't sufficient in all cases: --- a/src/lexer.c +++ b/src/lexer.c @@ -334,7 +334,7 @@ int yyinput(byte *buf, size_t used, size_t size) while ((cnt = get_decoded_line(&buff)) != 0) { if (cnt > 0) - count += cnt; + count = cnt; /* Note: some malformed messages can cause xfgetsl() to report ** "Invalid buffer size, exiting." and then abort. This I've attached another minimized example that invokes an out-of-bounds memmove() with that patch. This should cover both cases: --- a/src/lexer.c...

  • Created ticket #124 on bogofilter -- Fast Bayesian Spam Filter

    Fix heap-buffer-overlow after decoding long tokens

  • Posted a comment on ticket #34 on bogofilter -- Fast Bayesian Spam Filter

    I would implement it like this: compile the different backends as shared objects depending on the configuration load the default/specified backend with dlopen Then declare the backend API functions as weak in the executables such that they can be directly called - i.e. after the dlopen. This also allows for linking the binaries without the definitions of those functions being available. A more conservative appraoch (for platforms without weak symbols): have some global struct with function pointers...

  • Posted a comment on ticket #121 on bogofilter -- Fast Bayesian Spam Filter

    See also bug #123 for a follow-up patch that eliminates the memcpy.

View All

Personal Data

Username:
g_sauthoff
Joined:
2002-06-03 12:28:51

Projects

This is a list of open source software projects that Georg Sauthoff is associated with:

Personal Tools