Patch Detail
get:
Show a patch.
patch:
Update a patch.
put:
Update a patch.
GET /api/patches/47419/?format=api
http://patches.dpdk.org/api/patches/47419/?format=api", "web_url": "http://patches.dpdk.org/project/dpdk/patch/20181025104911.137496-1-dariusz.stojaczyk@intel.com/", "project": { "id": 1, "url": "http://patches.dpdk.org/api/projects/1/?format=api", "name": "DPDK", "link_name": "dpdk", "list_id": "dev.dpdk.org", "list_email": "dev@dpdk.org", "web_url": "http://core.dpdk.org", "scm_url": "git://dpdk.org/dpdk", "webscm_url": "http://git.dpdk.org/dpdk", "list_archive_url": "https://inbox.dpdk.org/dev", "list_archive_url_format": "https://inbox.dpdk.org/dev/{}", "commit_url_format": "" }, "msgid": "<20181025104911.137496-1-dariusz.stojaczyk@intel.com>", "list_archive_url": "https://inbox.dpdk.org/dev/20181025104911.137496-1-dariusz.stojaczyk@intel.com", "date": "2018-10-25T10:49:10", "name": "vfio: fix read-after-free on getting container fd", "commit_ref": null, "pull_url": null, "state": "accepted", "archived": true, "hash": "fd6de0278b2bb4488cbc39bd63ddcaf1ec15c6ad", "submitter": { "id": 1123, "url": "http://patches.dpdk.org/api/people/1123/?format=api", "name": "Stojaczyk, Dariusz", "email": "dariusz.stojaczyk@intel.com" }, "delegate": { "id": 1, "url": "http://patches.dpdk.org/api/users/1/?format=api", "username": "tmonjalo", "first_name": "Thomas", "last_name": "Monjalon", "email": "thomas@monjalon.net" }, "mbox": "http://patches.dpdk.org/project/dpdk/patch/20181025104911.137496-1-dariusz.stojaczyk@intel.com/mbox/", "series": [ { "id": 2094, "url": "http://patches.dpdk.org/api/series/2094/?format=api", "web_url": "http://patches.dpdk.org/project/dpdk/list/?series=2094", "date": "2018-10-25T10:49:10", "name": "vfio: fix read-after-free on getting container fd", "version": 1, "mbox": "http://patches.dpdk.org/series/2094/mbox/" } ], "comments": "http://patches.dpdk.org/api/patches/47419/comments/", "check": "success", "checks": "http://patches.dpdk.org/api/patches/47419/checks/", "tags": {}, "related": [], "headers": { "Return-Path": "<dev-bounces@dpdk.org>", "X-Original-To": "patchwork@dpdk.org", "Delivered-To": "patchwork@dpdk.org", "Received": [ "from [92.243.14.124] (localhost [127.0.0.1])\n\tby dpdk.org (Postfix) with ESMTP id 927A84F91;\n\tThu, 25 Oct 2018 12:50:13 +0200 (CEST)", "from mga18.intel.com (mga18.intel.com [134.134.136.126])\n\tby dpdk.org (Postfix) with ESMTP id 4C90D4C99;\n\tThu, 25 Oct 2018 12:50:12 +0200 (CEST)", "from orsmga002.jf.intel.com ([10.7.209.21])\n\tby orsmga106.jf.intel.com with ESMTP/TLS/DHE-RSA-AES256-GCM-SHA384;\n\t25 Oct 2018 03:50:11 -0700", "from violet.igk.intel.com ([10.102.54.177])\n\tby orsmga002.jf.intel.com with ESMTP; 25 Oct 2018 03:50:10 -0700" ], "X-Amp-Result": "SKIPPED(no attachment in message)", "X-Amp-File-Uploaded": "False", "X-ExtLoop1": "1", "X-IronPort-AV": "E=Sophos;i=\"5.54,424,1534834800\"; d=\"scan'208\";a=\"103183462\"", "From": "Darek Stojaczyk <dariusz.stojaczyk@intel.com>", "To": "dev@dpdk.org", "Cc": "Darek Stojaczyk <dariusz.stojaczyk@intel.com>, jianfeng.tan@intel.com,\n\tanatoly.burakov@intel.com, stable@dpdk.org", "Date": "Thu, 25 Oct 2018 12:49:10 +0200", "Message-Id": "<20181025104911.137496-1-dariusz.stojaczyk@intel.com>", "X-Mailer": "git-send-email 2.17.1", "Subject": "[dpdk-dev] [PATCH] vfio: fix read-after-free on getting container fd", "X-BeenThere": "dev@dpdk.org", "X-Mailman-Version": "2.1.15", "Precedence": "list", "List-Id": "DPDK patches and discussions <dev.dpdk.org>", "List-Unsubscribe": "<https://mails.dpdk.org/options/dev>,\n\t<mailto:dev-request@dpdk.org?subject=unsubscribe>", "List-Archive": "<http://mails.dpdk.org/archives/dev/>", "List-Post": "<mailto:dev@dpdk.org>", "List-Help": "<mailto:dev-request@dpdk.org?subject=help>", "List-Subscribe": "<https://mails.dpdk.org/listinfo/dev>,\n\t<mailto:dev-request@dpdk.org?subject=subscribe>", "Errors-To": "dev-bounces@dpdk.org", "Sender": "\"dev\" <dev-bounces@dpdk.org>" }, "content": "We were reading some memory just after freeing it.\n\nFixes: 83a73c5fef66 (\"vfio: use generic multi-process channel\")\nCc: jianfeng.tan@intel.com\nCc: anatoly.burakov@intel.com\nCc: stable@dpdk.org\n\nSigned-off-by: Darek Stojaczyk <dariusz.stojaczyk@intel.com>\n---\n lib/librte_eal/linuxapp/eal/eal_vfio.c | 3 ++-\n 1 file changed, 2 insertions(+), 1 deletion(-)", "diff": "diff --git a/lib/librte_eal/linuxapp/eal/eal_vfio.c b/lib/librte_eal/linuxapp/eal/eal_vfio.c\nindex d7268e4ce..fc3c7b870 100644\n--- a/lib/librte_eal/linuxapp/eal/eal_vfio.c\n+++ b/lib/librte_eal/linuxapp/eal/eal_vfio.c\n@@ -1034,8 +1034,9 @@ rte_vfio_get_container_fd(void)\n \t\tmp_rep = &mp_reply.msgs[0];\n \t\tp = (struct vfio_mp_param *)mp_rep->param;\n \t\tif (p->result == SOCKET_OK && mp_rep->num_fds == 1) {\n+\t\t\tvfio_container_fd = mp_rep->fds[0];\n \t\t\tfree(mp_reply.msgs);\n-\t\t\treturn mp_rep->fds[0];\n+\t\t\treturn vfio_container_fd;\n \t\t}\n \t\tfree(mp_reply.msgs);\n \t}\n", "prefixes": [] }{ "id": 47419, "url": "