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, 25 Sep 2009 19:35:23 +0100
From:	"Dr. David Alan Gilbert" <linux@...blig.org>
To:	Valdis.Kletnieks@...edu
Cc:	Miklos Szeredi <miklos@...redi.hu>,
	Andreas Gruenbacher <agruen@...e.de>,
	linux-fsdevel@...r.kernel.org, linux-kernel@...r.kernel.org
Subject: Re: [PATCH] vfs: new O_NODE open flag

* Valdis.Kletnieks@...edu (Valdis.Kletnieks@...edu) wrote:
> On Fri, 25 Sep 2009 13:37:47 BST, "Dr. David Alan Gilbert" said:
> 
> > Given an fd opened in this way is it possible to reopen it normally and
> > be guarenteed to get the same object?
> 
> It's not possible even without this flag. Consider:
> 
>         fd1 = open("/tmp/foo",flags);
>         rc = rename("/tmp/foo","/tmp/bar");
>         fd2 = open("/tmp/foo",flags);
> 
> Or were you asking if *absent that sort of tomfoolery* if it would work?

I know it's not possible without this flag, my interest is whether
it would be possible WITH this flag to promote an fd opened with the
O_NODE to a normal fd, guaranteeing that it's still operating on the
same object.  The case I'm (vaguely) thinking of is open with O_NODE,
fstat it, come to the conslusion it's not a device and then proceed
to open it and read from it.

Dave


-- 
 -----Open up your eyes, open up your mind, open up your code -------   
/ Dr. David Alan Gilbert    | Running GNU/Linux on Alpha,68K| Happy  \ 
\ gro.gilbert @ treblig.org | MIPS,x86,ARM,SPARC,PPC & HPPA | In Hex /
 \ _________________________|_____ http://www.treblig.org   |_______/
--
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