From: Laurent Vivier <laurent@vivier.eu>
To: "Philippe Mathieu-Daudé" <f4bug@amsat.org>
Cc: qemu-devel@nongnu.org, "Riku Voipio" <riku.voipio@iki.fi>,
"Guido Günther" <agx@sigxcpu.org>
Subject: Re: [Qemu-devel] [PATCH v3 01/13] linux-user/syscall: Verify recvfrom(addr) is user-writable
Date: Tue, 3 Jul 2018 18:38:22 +0200 [thread overview]
Message-ID: <5b37d5a8-b622-a95f-4f43-0b30fd6e7d68@vivier.eu> (raw)
In-Reply-To: <e0ac6484-0f62-66e0-c7b8-fab9775fbc0f@amsat.org>
Le 03/07/2018 à 17:39, Philippe Mathieu-Daudé a écrit :
> On 07/03/2018 11:55 AM, Laurent Vivier wrote:
>> Le 02/07/2018 à 19:50, Philippe Mathieu-Daudé a écrit :
>>> Signed-off-by: Philippe Mathieu-Daudé <f4bug@amsat.org>
>>> Tested-By: Guido Günther <agx@sigxcpu.org>
>>> Reviewed-by: Laurent Vivier <laurent@vivier.eu>
>>> ---
>>> linux-user/syscall.c | 5 +++++
>>> 1 file changed, 5 insertions(+)
>>>
>>> diff --git a/linux-user/syscall.c b/linux-user/syscall.c
>>> index 2117fb13b4..ad40682cee 100644
>>> --- a/linux-user/syscall.c
>>> +++ b/linux-user/syscall.c
>>> @@ -4154,6 +4154,11 @@ static abi_long do_recvfrom(int fd, abi_ulong msg, size_t len, int flags,
>>> ret = -TARGET_EINVAL;
>>> goto fail;
>>> }
>>> + if (!access_ok(VERIFY_WRITE, target_addr, addrlen)) {
>>> + ret = -TARGET_EFAULT;
>>> + goto fail;
>>> + }
>>> +
>>> addr = alloca(addrlen);
>>> ret = get_errno(safe_recvfrom(fd, host_msg, len, flags,
>>> addr, &addrlen));
>>>
>>
>> This patch breaks the test recvfrom01 of the Linux Test Project.
>
> OK :(
>
> I just sent v4, can you simply drop this patch?
> I'll now look at it after 3.0.
Not enough time to add more patches to my pull request, sorry.
I'll queue them in my branch for the next release.
Thanks,
Laurent
next prev parent reply other threads:[~2018-07-03 16:38 UTC|newest]
Thread overview: 25+ messages / expand[flat|nested] mbox.gz Atom feed top
2018-07-02 17:50 [Qemu-devel] [PATCH v3 00/13] linux-user: strace improvements Philippe Mathieu-Daudé
2018-07-02 17:50 ` [Qemu-devel] [PATCH v3 01/13] linux-user/syscall: Verify recvfrom(addr) is user-writable Philippe Mathieu-Daudé
2018-07-03 14:55 ` Laurent Vivier
2018-07-03 15:39 ` Philippe Mathieu-Daudé
2018-07-03 16:38 ` Laurent Vivier [this message]
2018-07-03 21:05 ` Philippe Mathieu-Daudé
2018-07-02 17:50 ` [Qemu-devel] [PATCH v3 02/13] linux-user/strace: Improve capget()/capset() output Philippe Mathieu-Daudé
2018-07-02 17:50 ` [Qemu-devel] [PATCH v3 05/13] linux-user/strace: Improve settimeofday() Philippe Mathieu-Daudé
2018-07-02 18:20 ` Laurent Vivier
2018-07-02 17:50 ` [Qemu-devel] [PATCH v3 06/13] linux-user/strace: Dump AF_NETLINK sockaddr content Philippe Mathieu-Daudé
2018-07-02 19:05 ` Laurent Vivier
2018-07-02 17:50 ` [Qemu-devel] [PATCH v3 07/13] linux-user/strace: Improve recvmsg() output Philippe Mathieu-Daudé
2018-07-02 17:50 ` [Qemu-devel] [PATCH v3 10/13] linux-user/strace: Let print_sockaddr() have a 'last' argument Philippe Mathieu-Daudé
2018-07-02 18:40 ` Laurent Vivier
2018-07-02 17:50 ` [Qemu-devel] [PATCH v3 11/13] linux-user/strace: Add print_sockaddr_ptr() to handle plain/pointer addrlen Philippe Mathieu-Daudé
2018-07-02 18:52 ` Laurent Vivier
2018-07-02 17:50 ` [Qemu-devel] [PATCH v3 12/13] linux-user/strace: Improve getsockname() output Philippe Mathieu-Daudé
2018-07-02 18:46 ` Laurent Vivier
2018-07-02 17:50 ` [Qemu-devel] [PATCH v3 13/13] linux-user/strace: Improve recvfrom() output Philippe Mathieu-Daudé
2018-07-02 18:44 ` Laurent Vivier
[not found] ` <20180702175030.18621-4-f4bug@amsat.org>
2018-07-02 18:18 ` [Qemu-devel] [PATCH v3 03/13] linux-user/strace: Display invalid pointer in print_timeval() Laurent Vivier
2018-07-02 18:26 ` Philippe Mathieu-Daudé
[not found] ` <20180702175030.18621-5-f4bug@amsat.org>
2018-07-02 18:19 ` [Qemu-devel] [PATCH v3 04/13] linux-user/strace: Add print_timezone() Laurent Vivier
[not found] ` <20180702175030.18621-9-f4bug@amsat.org>
2018-07-02 18:30 ` [Qemu-devel] [PATCH v3 08/13] linux-user/strace: Improve bind() output Laurent Vivier
[not found] ` <20180702175030.18621-10-f4bug@amsat.org>
2018-07-02 18:36 ` [Qemu-devel] [PATCH v3 09/13] linux-user/strace: improve sendto() output Laurent Vivier
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=5b37d5a8-b622-a95f-4f43-0b30fd6e7d68@vivier.eu \
--to=laurent@vivier.eu \
--cc=agx@sigxcpu.org \
--cc=f4bug@amsat.org \
--cc=qemu-devel@nongnu.org \
--cc=riku.voipio@iki.fi \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).