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: <m163ixk9t2.fsf@fess.ebiederm.org>
Date:	Wed, 25 Feb 2009 22:10:33 -0800
From:	ebiederm@...ssion.com (Eric W. Biederman)
To:	Herbert Xu <herbert@...dor.apana.org.au>
Cc:	Patrick McHardy <kaber@...sh.net>,
	Linux Netdev List <netdev@...r.kernel.org>
Subject: Re: IPv4/IPv6 sysctl unregistration deadlock

Herbert Xu <herbert@...dor.apana.org.au> writes:

> On Wed, Feb 25, 2009 at 08:18:47AM +0100, Patrick McHardy wrote:
>>
>> Unfortunately its more complicated than I thought because of
>> device renames, where the sysctl pointer is reused after
>> unregistration and the rename/unregistration/re-registration
>> should be atomic. Deferring unregistration means we can't perform
>> the new registration immediately unless we allow multiple
>> registrations for a single device to be active simulaneously,
>> which introduces a whole new set of problems.
>
> Good point.
>
>> Simply ignoring the request during unregistration doesn't seem
>> so bad after all, the main problem is that it intoduces a different
>> race on renames where a write to the "forwarding" file returns
>> success, but the change doesn't take effect. We could return
>> -ENOENT, but that seems a bit strange after open() returned success.
>> Maybe -EBUSY, although I would prefer to make this transparent
>> to userspace.
>
> I'd like to avoid that for the rename case just because shell
> scripts know how to deal with echo foo > /nonexist/file but not
> necessarily a failed echo on write/close.
>
>> I think I'm stuck. Will rethink it after some coffee :)
>
> Yes we need more coffee :)

How does adding a rename operation to sysctl sound?

I am a little concerned that if we have this issue with sysctl
we also have it with proc and sysfs as well.

Although I admit I don't understand it yet.

Eric


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