nufw-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Nufw-devel] nuauth not updating end_timestamp connectly in mysql u


From: Eric Leblond
Subject: Re: [Nufw-devel] nuauth not updating end_timestamp connectly in mysql ulog table.
Date: Thu, 25 Feb 2010 23:49:34 +0100

Hello,

Le vendredi 26 février 2010 à 10:50 +1300, Glen Ogilvie a écrit :
> Hi,
> 
> I've been looking at nuauth and noticed that it does not seem to be updating 
> the end_timestamp when using connection tracking.
> 
> The queries I see in the database when connections close are:
> 
> UPDATE ulog SET end_timestamp=FROM_UNIXTIME(0), state=3, packets_in=14, 
> packets_out=16, bytes_in=2508, bytes_out=14158 WHERE (ip_saddr=176160858 AND 
> ip_daddr=3232290298 AND tcp_sport='38463' AND tcp_dport='8080' AND (state='2' 
> OR state='1'))                                                                
>        
> 
> This is happening with: nufw-nuauth-2.2.21
> 
> I think they query that is being built is on line: 784 of 
> src/nuauth/modules/log_mysql/mysql.c
> 
> It looks like element->timestamp must be 0 for some reason, or cannot be 
> converted to "%lu"

Nice catch, it looks like timestamp is not set. I really don't
understand why I did not hear about this before.

Could you try the following patch ? Tests I have made here seems to show
that it fixes the bug.

BR,


-- 
Eric Leblond <address@hidden>
NuFW, Now User Filtering Works : http://www.nufw.org

Attachment: 0001-nuauth-set-connection-timestamp-in-nuauth.patch
Description: Text Data

Attachment: signature.asc
Description: Ceci est une partie de message numériquement signée


reply via email to

[Prev in Thread] Current Thread [Next in Thread]