All of lore.kernel.org
 help / color / mirror / Atom feed
* [ULOGD PATCH] Fix IPv6 packet parsing.
@ 2008-05-23 20:34 Eric Leblond
  2008-06-02  0:04 ` Pablo Neira Ayuso
  0 siblings, 1 reply; 4+ messages in thread
From: Eric Leblond @ 2008-05-23 20:34 UTC (permalink / raw)
  To: netfilter-devel; +Cc: Eric Leblond

Source and destination addresses were put in ptr field of the target structure
instead of being put in the new type ui128. The result was an improper value
of the IPv6 source add destination addresses.

Signed-off-by: Eric Leblond <eric@inl.fr>
---
 filter/raw2packet/ulogd_raw2packet_BASE.c |    6 ++++--
 1 files changed, 4 insertions(+), 2 deletions(-)

diff --git a/filter/raw2packet/ulogd_raw2packet_BASE.c b/filter/raw2packet/ulogd_raw2packet_BASE.c
index b1f4113..a5312e4 100644
--- a/filter/raw2packet/ulogd_raw2packet_BASE.c
+++ b/filter/raw2packet/ulogd_raw2packet_BASE.c
@@ -769,9 +769,11 @@ static int _interp_ipv6hdr(struct ulogd_pluginstance *pi, u_int32_t len)
 	if (len < sizeof(struct ip6_hdr))
 		return 0;
 
-	ret[KEY_IP_SADDR].u.value.ptr = &ipv6h->ip6_src;
+	memcpy(ret[KEY_IP_SADDR].u.value.ui128, &ipv6h->ip6_src,
+	       sizeof(ipv6h->ip6_src));
 	ret[KEY_IP_SADDR].flags |= ULOGD_RETF_VALID;
-	ret[KEY_IP_DADDR].u.value.ptr = &ipv6h->ip6_dst;
+	memcpy(ret[KEY_IP_DADDR].u.value.ui128, &ipv6h->ip6_dst,
+	       sizeof(ipv6h->ip6_dst));
 	ret[KEY_IP_DADDR].flags |= ULOGD_RETF_VALID;
 	ret[KEY_IP6_PAYLOAD_LEN].u.value.ui16 = ntohs(ipv6h->ip6_plen);
 	ret[KEY_IP6_PAYLOAD_LEN].flags |= ULOGD_RETF_VALID;
-- 
1.5.4.3


^ permalink raw reply related	[flat|nested] 4+ messages in thread

* Re: [ULOGD PATCH] Fix IPv6 packet parsing.
  2008-05-23 20:34 [ULOGD PATCH] Fix IPv6 packet parsing Eric Leblond
@ 2008-06-02  0:04 ` Pablo Neira Ayuso
  2008-06-02 12:32   ` Eric Leblond
  0 siblings, 1 reply; 4+ messages in thread
From: Pablo Neira Ayuso @ 2008-06-02  0:04 UTC (permalink / raw)
  To: Eric Leblond; +Cc: netfilter-devel

Eric Leblond wrote:
> Source and destination addresses were put in ptr field of the target structure
> instead of being put in the new type ui128. The result was an improper value
> of the IPv6 source add destination addresses.

Applied. Thanks.

I'll test this a bit along this week, any help appreciated. We can
prepare the first release of 2.0.0-rc series soon. If my mind serves
well, configuration file reload is still pending.

-- 
"Los honestos son inadaptados sociales" -- Les Luthiers

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: [ULOGD PATCH] Fix IPv6 packet parsing.
  2008-06-02  0:04 ` Pablo Neira Ayuso
@ 2008-06-02 12:32   ` Eric Leblond
  2008-06-02 13:50     ` Pablo Neira Ayuso
  0 siblings, 1 reply; 4+ messages in thread
From: Eric Leblond @ 2008-06-02 12:32 UTC (permalink / raw)
  To: Pablo Neira Ayuso; +Cc: netfilter-devel

[-- Attachment #1: Type: text/plain, Size: 809 bytes --]

Hello,

On Monday, 2008 June  2 at  2:04:14 +0200, Pablo Neira Ayuso wrote:
> Eric Leblond wrote:
> > Source and destination addresses were put in ptr field of the target structure
> > instead of being put in the new type ui128. The result was an improper value
> > of the IPv6 source add destination addresses.
> 
> Applied. Thanks.
> 
> I'll test this a bit along this week, any help appreciated. We can
> prepare the first release of 2.0.0-rc series soon. If my mind serves
> well, configuration file reload is still pending.

Yes, reload is still missing.

By the way, a new libnetfilter_conntrack release will be needed before
ulogd2 rc. Latest libnetfilter_conntrack git is needed to have ulogd2
compile.

BR,
-- 
Eric Leblond
INL: http://www.inl.fr/
NuFW: http://www.nufw.org/

[-- Attachment #2: Digital signature --]
[-- Type: application/pgp-signature, Size: 189 bytes --]

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: [ULOGD PATCH] Fix IPv6 packet parsing.
  2008-06-02 12:32   ` Eric Leblond
@ 2008-06-02 13:50     ` Pablo Neira Ayuso
  0 siblings, 0 replies; 4+ messages in thread
From: Pablo Neira Ayuso @ 2008-06-02 13:50 UTC (permalink / raw)
  To: Eric Leblond, netfilter-devel

Eric Leblond wrote:
>> I'll test this a bit along this week, any help appreciated. We can
>> prepare the first release of 2.0.0-rc series soon. If my mind serves
>> well, configuration file reload is still pending.
> 
> Yes, reload is still missing.
> 
> By the way, a new libnetfilter_conntrack release will be needed before
> ulogd2 rc. Latest libnetfilter_conntrack git is needed to have ulogd2
> compile.

I think that you have missed the release that I have done two days ago
[1] ? :-)

http://marc.info/?l=netfilter-devel&m=121225147116142&w=2

-- 
"Los honestos son inadaptados sociales" -- Les Luthiers

^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2008-06-02 14:50 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2008-05-23 20:34 [ULOGD PATCH] Fix IPv6 packet parsing Eric Leblond
2008-06-02  0:04 ` Pablo Neira Ayuso
2008-06-02 12:32   ` Eric Leblond
2008-06-02 13:50     ` Pablo Neira Ayuso

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.