Re: [Qemu-devel] [PATCH v2 5/5] 9p: forbid empty extension string

2016-08-30 Thread Greg Kurz
On Mon, 29 Aug 2016 14:35:07 -0500 Eric Blake wrote: > On 08/28/2016 12:34 PM, Greg Kurz wrote: > > >> > >> For the sake of simplicity, I'd rather have the target names to follow the > >> same rules as other file names, and return ENOENT directly (the link you > >> provide states it is a valid o

Re: [Qemu-devel] [PATCH v2 5/5] 9p: forbid empty extension string

2016-08-29 Thread Eric Blake
On 08/28/2016 12:34 PM, Greg Kurz wrote: >> >> For the sake of simplicity, I'd rather have the target names to follow the >> same rules as other file names, and return ENOENT directly (the link you >> provide states it is a valid option). >> >> Peter, >> >> Since you suggested to do explicit error

Re: [Qemu-devel] [PATCH v2 5/5] 9p: forbid empty extension string

2016-08-28 Thread Peter Maydell
On 28 August 2016 at 13:21, Greg Kurz wrote: > Peter, > > Since you suggested to do explicit error checking on empty file names, do > you have an opinion on the case of symlinks with an empty target ? I have no strong opinion here. I was just aiming for the general principles of consistency and p

Re: [Qemu-devel] [PATCH v2 5/5] 9p: forbid empty extension string

2016-08-28 Thread Greg Kurz
On Sun, 28 Aug 2016 19:21:25 +0200 Greg Kurz wrote: > On Fri, 26 Aug 2016 14:00:37 -0500 > Eric Blake wrote: > > > On 08/26/2016 10:07 AM, Greg Kurz wrote: > > > A buggy guest using the 9p2000.u protocol can issue a create request and > > > pass an empty string as the extension argument. This

Re: [Qemu-devel] [PATCH v2 5/5] 9p: forbid empty extension string

2016-08-28 Thread Greg Kurz
On Fri, 26 Aug 2016 14:00:37 -0500 Eric Blake wrote: > On 08/26/2016 10:07 AM, Greg Kurz wrote: > > A buggy guest using the 9p2000.u protocol can issue a create request and > > pass an empty string as the extension argument. This causes QEMU to crash > > in the case of a hard link or a special fi

Re: [Qemu-devel] [PATCH v2 5/5] 9p: forbid empty extension string

2016-08-26 Thread Michael S. Tsirkin
On Fri, Aug 26, 2016 at 02:00:37PM -0500, Eric Blake wrote: > On 08/26/2016 10:07 AM, Greg Kurz wrote: > > A buggy guest using the 9p2000.u protocol can issue a create request and > > pass an empty string as the extension argument. This causes QEMU to crash > > in the case of a hard link or a speci

Re: [Qemu-devel] [PATCH v2 5/5] 9p: forbid empty extension string

2016-08-26 Thread Eric Blake
On 08/26/2016 10:07 AM, Greg Kurz wrote: > A buggy guest using the 9p2000.u protocol can issue a create request and > pass an empty string as the extension argument. This causes QEMU to crash > in the case of a hard link or a special file, and leads to undefined > behavior, depending on the backend

[Qemu-devel] [PATCH v2 5/5] 9p: forbid empty extension string

2016-08-26 Thread Greg Kurz
A buggy guest using the 9p2000.u protocol can issue a create request and pass an empty string as the extension argument. This causes QEMU to crash in the case of a hard link or a special file, and leads to undefined behavior, depending on the backend, in the case of a symbolic link. This patch cau