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:	Fri, 4 Dec 2009 12:52:33 -0800
From:	Andrew Morton <akpm@...ux-foundation.org>
To:	Vlad Yasevich <vladislav.yasevich@...com>
Cc:	David Miller <davem@...emloft.net>,
	Linux SCTP Dev Mailing list <linux-sctp@...r.kernel.org>,
	netdev <netdev@...r.kernel.org>,
	Andrei Pelinescu-Onciul <andrei@...el.org>
Subject: Re: pull request: SCTP updates for net-next

On Fri, 04 Dec 2009 11:23:14 -0500
Vlad Yasevich <vladislav.yasevich@...com> wrote:

> > 
> > Overall, it would be way simpler and saner to clamp this value to some
> > explicit time period, IMO.
> > 
> > <pulls number out of thin air>
> > 
> > --- a/net/sctp/socket.c~a
> > +++ a/net/sctp/socket.c
> > @@ -2086,9 +2086,8 @@ static int sctp_setsockopt_autoclose(str
> >  		return -EINVAL;
> >  	if (copy_from_user(&sp->autoclose, optval, optlen))
> >  		return -EFAULT;
> > -	/* make sure it won't exceed MAX_SCHEDULE_TIMEOUT */
> > -	if (sp->autoclose > (MAX_SCHEDULE_TIMEOUT / HZ) )
> > -		sp->autoclose = MAX_SCHEDULE_TIMEOUT / HZ ;
> > +	/* make sure it won't exceed one hour */
> > +	sp->autoclose = min_t(u32, sp->autoclose, 60 * 60);
> >  
> 
> But that may not be long enough.  The spec doesn't impose limits
> and it's really up to the application to decide how long it wants
> to keep idle connections open.  Thus any limits shorter the maximum
> supported by kernel are really artificial and may not be sufficient.

Could make ->autoclose a u64?  That fixes any 32bit-vs-64bit
inconsistencies and allows for an effectively infinite period.

--
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

Powered by Openwall GNU/*/Linux Powered by OpenVZ