Snort mailing list archives

FW: MySQL function


From: "Hutchinson, Andrew" <andrew.hutchinson () Vanderbilt Edu>
Date: Mon, 4 Aug 2003 13:12:59 -0500

MySQL has a builtin function called "inet_ntoa" that will do that.
There is also "inet_aton" to go the other way.
 
To use it, just call the function right in the statement:
 
SELECT inet_ntoa(ip_src) FROM iphdr WHERE sid='1' AND cid='234672';
 
Or whatever....
 
 
HTH,
 
Andrew
 

Andrew Hutchinson - Network Security
Vanderbilt University Medical Center
(615) 936-2856


        -----Original Message-----
        From: Bryan Miller [mailto:BMiller () sycomtech com] 
        Sent: Monday, August 04, 2003 12:51 PM
        To: snort-users () lists sourceforge net
        Subject: [Snort-users] MySQL function
        
        
        Anyone out there have a function or know of a way to convert IP
addresses from Acid (MySQL) into a string containing the IP address?  I
know PHP can do it but I need a way to call this from a shell script to
produce monthly reports.
         
        Bryan


Current thread: