From 0febe449e6aa29be28adcdc7a825d44be09ef853 Mon Sep 17 00:00:00 2001 From: Victor Julien Date: Sun, 18 Apr 2010 22:14:56 +0200 Subject: [PATCH] In unified1-alert the ip addresses are in host order. --- src/alert-unified-alert.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/alert-unified-alert.c b/src/alert-unified-alert.c index 5107e8710e..6fb9888805 100644 --- a/src/alert-unified-alert.c +++ b/src/alert-unified-alert.c @@ -183,8 +183,8 @@ TmEcode AlertUnifiedAlert (ThreadVars *tv, Packet *p, void *data, PacketQueue *p hdr.pad2 = 0; hdr.ts.tv_sec = hdr.ref_ts.tv_sec = p->ts.tv_sec; hdr.ts.tv_usec = hdr.ref_ts.tv_usec = p->ts.tv_sec; - hdr.src_ip = GET_IPV4_SRC_ADDR_U32(p); - hdr.dst_ip = GET_IPV4_DST_ADDR_U32(p); + hdr.src_ip = ntohl(GET_IPV4_SRC_ADDR_U32(p)); /* addr is host order */ + hdr.dst_ip = ntohl(GET_IPV4_DST_ADDR_U32(p)); /* addr is host order */ hdr.sp = p->sp; hdr.dp = p->dp; hdr.protocol = IPV4_GET_RAW_IPPROTO(p->ip4h);