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] [day] [month] [year] [list]
Message-Id: <20070402174033.ec74aa5b.akpm@linux-foundation.org>
Date:	Mon, 2 Apr 2007 17:40:33 -0700
From:	Andrew Morton <akpm@...ux-foundation.org>
To:	"kalash nainwal" <kalash.nainwal@...il.com>
Cc:	linux-kernel@...r.kernel.org
Subject: Re: [PATCH] (re)register_binfmt returns with -EBUSY

On Mon, 2 Apr 2007 18:24:15 +0530
"kalash nainwal" <kalash.nainwal@...il.com> wrote:

> When a binary format is unregistered and re-registered,
> register_binfmt fails with -EBUSY. The reason is that
> unregister_binfmt does not set fmt->next to NULL, and seeing
> (fmt->next != NULL), register_binfmt fails with -EBUSY.
> 
> One can find his way around by explicitly setting fmt->next to NULL
> after unregistering, but that is kind of unclean (one should better be
> using only the interfaces, and not the interal members, isn't it?)
> 
> Attached one-liner can fix it (for 2.6.20).

Yes, that'll fix it.

But I wonder why register_binfmt() even checks that the to-be-registered
linux_binfmt has a non-null fmt->next?  Presumably that's there to catch
erroneous re-registration of an already-registered format.

All very odd.  It looks like that code should be converted to list_heads
anyway...
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ