Snort mailing list archives

Misc patches


From: "Mayers, Philip J" <p.mayers () ic ac uk>
Date: Tue, 7 Aug 2001 18:31:51 +0100

One to make the machine-readable session stats a bit more consistent:

diff -uNr snort-1.8.1-beta5/spp_stream4.c
snort-1.8.1-beta5-local/spp_stream4.c
--- snort-1.8.1-beta5/spp_stream4.c     Mon Jul 23 14:30:10 2001
+++ snort-1.8.1-beta5-local/spp_stream4.c       Tue Aug  7 18:27:50 2001
@@ -2205,12 +2205,12 @@

         et = localtime((time_t *) &ssn->last_session_time);
         s = (ssn->last_session_time + thiszone) % 86400;
-        fprintf(session_log, " End Time: %02d/%02d/%02d-%02d:%02d:%02d",
+        fprintf(session_log, " End: %02d/%02d/%02d-%02d:%02d:%02d",
                 et->tm_mon+1, et->tm_mday, et->tm_year - 100, s/3600,
                 (s%3600)/60, s%60);

         foo.s_addr = ssn->server.ip;
-        fprintf(session_log, "[Server IP: %s  ", inet_ntoa(foo));
+        fprintf(session_log, " [Server IP: %s  ", inet_ntoa(foo));
         fprintf(session_log, "port: %d  pkts: %u  bytes: %u]",
                 ssn->server.port, ssn->server.pkts_sent,
                 ssn->server.bytes_sent);


A fix for the unified output plugin (data is a stack-allocated variable):

diff -uNr snort-1.8.1-beta5/spo_unified.c
snort-1.8.1-beta5-local/spo_unified.c
--- snort-1.8.1-beta5/spo_unified.c     Fri Jun 29 03:38:54 2001
+++ snort-1.8.1-beta5-local/spo_unified.c       Tue Aug  7 18:22:47 2001
@@ -446,7 +446,7 @@

     /* free up initialized memory */
     free(data->log_filename);
-    free(data);
+    /* free(data); */
 }


@@ -478,7 +478,7 @@

     fclose(data->log);
     free(data->log_filename);
-    free(data);
+    /* free(data); */
 }


@@ -514,7 +514,7 @@

     /* free up initialized memory */
     free(data->alert_filename);
-    free(data);
+    /* free(data); */
 }


@@ -546,6 +546,6 @@

     fclose(data->alert);
     free(data->alert_filename);
-    free(data);
+    /* free(data); */
 }


Regards, 
Phil 

+----------------------------------+ 
| Phil Mayers, Network Support     | 
| Centre for Computing Services    | 
| Imperial College                 | 
+----------------------------------+ 

_______________________________________________
Snort-users mailing list
Snort-users () lists sourceforge net
Go to this URL to change user options or unsubscribe:
http://lists.sourceforge.net/lists/listinfo/snort-users
Snort-users list archive:
http://www.geocrawler.com/redir-sf.php3?list=snort-users


Current thread: