diff options
author | Jörg Frings-Fürst <debian@jff-webhosting.net> | 2024-11-14 15:08:48 +0100 |
---|---|---|
committer | Jörg Frings-Fürst <debian@jff-webhosting.net> | 2024-11-14 15:08:48 +0100 |
commit | a0ef7483cccfcab42e635d72c9a537cf6a778893 (patch) | |
tree | 5f4b98f575ad0d150b6ac73765a22b6fab679bdb /debian/patches/0800-fix-buffer-overrun.patch | |
parent | 686fa8c1c7328b9e20df2cdbb97b5d7cd30d70ba (diff) | |
parent | 8ebf7ba18b07deaae1ddd83f9943acd3413e8eb2 (diff) |
mergedebian/1.8.19-7.1
Diffstat (limited to 'debian/patches/0800-fix-buffer-overrun.patch')
-rw-r--r-- | debian/patches/0800-fix-buffer-overrun.patch | 35 |
1 files changed, 35 insertions, 0 deletions
diff --git a/debian/patches/0800-fix-buffer-overrun.patch b/debian/patches/0800-fix-buffer-overrun.patch new file mode 100644 index 0000000..295e08a --- /dev/null +++ b/debian/patches/0800-fix-buffer-overrun.patch @@ -0,0 +1,35 @@ +From b4bc5c335159b1c272e06dba98e2916e3ecc0462 Mon Sep 17 00:00:00 2001 +From: Howitzer105mm <howitzer105mm@noreply.codeberg.org> +Date: Tue, 26 Mar 2024 11:28:16 +0000 +Subject: [PATCH] open: Eliminate buffer overrun (#24) + +clangd reports a buffer overrun issue in `open` interface. + +The sprintf() used to fill ipmi_devfs2 requires 17 bytes to store the +null terminated string. The character buffer is only 16 bytes in +length. + +Signed-off-by: Johnathan Mantey <johnathanx.mantey@intel.com> +Reviewed-on: https://codeberg.org/IPMITool/ipmitool/pulls/24 +Reviewed-by: Alexander Amelkin <alexander@amelkin.msk.ru> +Co-authored-by: Howitzer105mm <howitzer105mm@noreply.codeberg.org> +Co-committed-by: Howitzer105mm <howitzer105mm@noreply.codeberg.org> +Forwarded: not-needed +Applied-Upstream: https://codeberg.org/IPMITool/ipmitool/commit/b4bc5c335159b1c272e06dba98e2916e3ecc0462 +--- + src/plugins/open/open.c | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +diff --git a/src/plugins/open/open.c b/src/plugins/open/open.c +index 39c8ea2..88cb6c3 100644 +--- a/src/plugins/open/open.c ++++ b/src/plugins/open/open.c +@@ -94,7 +94,7 @@ ipmi_openipmi_open(struct ipmi_intf *intf) + { + char ipmi_dev[16]; + char ipmi_devfs[16]; +- char ipmi_devfs2[16]; ++ char ipmi_devfs2[17]; + int devnum = 0; + + devnum = intf->devnum; |