diff --git a/0001-usbmisc-initialize-string-buffer-before-reading-from.patch b/0001-usbmisc-initialize-string-buffer-before-reading-from.patch deleted file mode 100644 index ef8ffc6..0000000 --- a/0001-usbmisc-initialize-string-buffer-before-reading-from.patch +++ /dev/null @@ -1,37 +0,0 @@ -From e3a98cd4870e46cefbfaa1c6f3142c70351aba02 Mon Sep 17 00:00:00 2001 -From: Greg Kroah-Hartman -Date: Thu, 22 Oct 2020 12:01:44 +0200 -Subject: [PATCH 11/15] usbmisc: initialize string buffer before reading from - device. - -Cliff Biffle points out that some devices lie about the length of their -string, so we end up with stack data in the string buffer, which is then -displayed by userspace. Fix this up by initializing the data to 0 first -before reading from the device. - -Reported-by: Cliff L. Biffle -Signed-off-by: Greg Kroah-Hartman ---- - usbmisc.c | 6 ++++++ - 1 file changed, 6 insertions(+) - -diff --git a/usbmisc.c b/usbmisc.c -index 9a329f2..ba0591f 100644 ---- a/usbmisc.c -+++ b/usbmisc.c -@@ -210,6 +210,12 @@ char *get_dev_string(libusb_device_handle *dev, uint8_t id) - langid = get_any_langid(dev); - if (!langid) return strdup("(error)"); - -+ /* -+ * Some devices lie about their string size, so initialize -+ * the buffer with all 0 to account for that. -+ */ -+ memset(unicode_buf, 0x00, sizeof(unicode_buf)); -+ - ret = libusb_get_string_descriptor(dev, id, langid, - (unsigned char *) unicode_buf, - sizeof unicode_buf); --- -1.8.3.1 - diff --git a/usbutils-012.tar.xz b/usbutils-012.tar.xz deleted file mode 100644 index 1178f91..0000000 Binary files a/usbutils-012.tar.xz and /dev/null differ diff --git a/usbutils-014.tar.xz b/usbutils-014.tar.xz new file mode 100644 index 0000000..c747842 Binary files /dev/null and b/usbutils-014.tar.xz differ diff --git a/usbutils.spec b/usbutils.spec index 78581da..2304e0b 100644 --- a/usbutils.spec +++ b/usbutils.spec @@ -1,6 +1,6 @@ Name: usbutils -Version: 012 -Release: 5 +Version: 014 +Release: 1 Summary: Linux utilities for USB device License: GPLv2+ URL: http://www.linux-usb.org/ @@ -9,7 +9,6 @@ Source0: https://www.kernel.org/pub/linux/utils/usb/usbutils/%{name}-%{version}. Source1: GPL-2.0.txt Source2: GPL-3.0.txt -Patch1: 0001-usbmisc-initialize-string-buffer-before-reading-from.patch BuildRequires: libusbx-devel systemd-devel gcc autoconf automake libtool Requires: hwdata @@ -46,6 +45,9 @@ install -D -m 644 %{SOURCE2} %{buildroot}%{_defaultlicensedir}/%{name}/GPL-3.0.t %{_mandir}/*/* %changelog +* Tue Nov 23 2021 yanglongkang - 014-1 +- update package to 014 + * Tue Sep 28 2021 Wenchao Hao - 012-5 - Nothing but to sync master and LTS branch