lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date:	Tue, 27 Mar 2007 18:33:29 -0300
From:	"Arnaldo Carvalho de Melo" <acme@...stprotocols.net>
To:	"Patrick McHardy" <kaber@...sh.net>
Cc:	"David Miller" <davem@...emloft.net>, netdev@...r.kernel.org
Subject: Re: [PATCH 2/2] [SK_BUFF]: Introduce skb_copy_from_linear_data{_offset}

On 3/27/07, Patrick McHardy <kaber@...sh.net> wrote:
> Arnaldo Carvalho de Melo wrote:
> > On 3/27/07, David Miller <davem@...emloft.net> wrote:
> >
> >> From: Arnaldo Carvalho de Melo <acme@...stprotocols.net>
> >> Date: Tue, 27 Mar 2007 16:41:48 -0300
> >>
> >> > +static inline void skb_move_linear_data(const struct sk_buff *skb,
> >> > +                                     const int from_offset,
> >> > +                                     const int to_offset,
> >> > +                                     const unsigned int len)
> >> > +{
> >> > +     memcpy(skb->data + to_offset, skb->data + from_offset, len);
> >> > +}
> >> > +
> >>
> >> What do you intend to use this for?  There are no users in
> >> your patch, and I'd be fearful of overlapping cases (which
> >> ought to be common for anything using this) which therefore
> >> would require use of memmove() instead of memcpy().
> >>
> >> How about we just leave out interfaces until we have a use
> >> case?
> >
> >
> > I don't want to intend anything with this, was just a brain fart, a
> > failed attempt to convince me that this was needed, I apologise for
> > letting this sleep thru, will remove and resubmit, ok?
>
>
> nf_nat_helper.c:mangle_content() could make use of this, but it
> would need memmove. Something to do this with non-linear packets
> would be even cooler :)

Damn, that was so fast man! For the qeth case that motivated me to try
the leftover it was like: memcpy is the fastest way, memmove would be
more costly but more general, when in doubt I just droppped the users
without removing the infrastructure, nah, lets leave this for another
day, for now I'll just drop the non-used -new infrastrucure and
resubmit.

- Arnaldo
-
To unsubscribe from this list: send the line "unsubscribe netdev" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Powered by blists - more mailing lists