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]
Message-ID: <1464796900.5939.161.camel@edumazet-glaptop3.roam.corp.google.com>
Date:	Wed, 01 Jun 2016 09:01:40 -0700
From:	Eric Dumazet <eric.dumazet@...il.com>
To:	Stephen Hemminger <stephen@...workplumber.org>
Cc:	netdev <netdev@...r.kernel.org>
Subject: Re: [PATCH iproute2] fq_codel: add per queue memory limit

On Wed, 2016-06-01 at 08:53 -0700, Stephen Hemminger wrote:
> On Wed, 01 Jun 2016 07:23:31 -0700
> Eric Dumazet <eric.dumazet@...il.com> wrote:
> > +		} else if (strcmp(*argv, "memory_limit") == 0) {
> > +			NEXT_ARG();
> > +			if (get_size(&memory, *argv)) {
> > +				fprintf(stderr, "Illegal \"memory_limit\"\n");
> > +				return -1;
> > +			}
> 
> Do you really want to allow memory limit of 0?
> 

Why not ? If there is a kernel bug we need to fix it anyway ?

What would be the enforced 'minimum' ?

> 
> > +	if (tb[TCA_FQ_CODEL_MEMORY_LIMIT] &&
> > +	    RTA_PAYLOAD(tb[TCA_FQ_CODEL_MEMORY_LIMIT]) >= sizeof(__u32)) {
> > +		memory_limit = rta_getattr_u32(tb[TCA_FQ_CODEL_MEMORY_LIMIT]);
> > +
> > +		fprintf(f, "memory_limit %s ", sprint_size(memory_limit, b1));
> > +	}
> 
> Why the size check? other parameters don't do it?

Existing code style in tc/q_fq_codel.c

I really think all TLV consumers should never trust producers, even if
it is the kernel ;)


Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ