Hide Forgot
Quoting the upstream bug: “ If the specified needle crosses a page-boundary, the s390-z15 ifunc variant of strstr truncates the needle which results in invalid results. Example: needle = "Hello" <page-boundary> "World" really used needle = "Hello" haystack = "abc HelloBug def" result = "HelloBug def" This only happens if the needle before page-boundary contains 9 or less characters. The s390-z15 ifunc variant of strstr was introduces in glibc 2.30. ” This was introduced into Red Hat Enterprise Linux 8.1 via bug 1659438.
We will need QA assistance for testing the change on z15 hardware. Cc:ing IBM.
(In reply to Florian Weimer from comment #1) > We will need QA assistance for testing the change on z15 hardware. Cc:ing > IBM. . ... yes, IBM will do fix verification ... setting OtherQA ...
------- Comment From STLI.com 2019-11-27 06:49 EDT------- Please backport the glibc-commit "S390: Fix handling of needles crossing a page in strstr z15 ifunc-variant. [BZ #25226]" to RHEL 8.1 (AND RHEL 8.2) as it is already released there: -upstream-glibc/master: https://sourceware.org/git/?p=glibc.git;a=commit;h=bfdb731438206b0f70fe7afa890681155c30b419 -upstream-bugzilla: "Bug 25226 - strstr: Invalid result if needle crosses page on s390-z15 ifunc variant." (https://sourceware.org/bugzilla/show_bug.cgi?id=25226) Yes, I can test an updated rpm on z15 hardware.
------- Comment From STLI.com 2019-12-17 06:37 EDT------- I've installed RHEL 8.2is2 with glibc 2.28-99.el8 package and verified that the patch is applied. Thanks.
Set as verified based on https://bugzilla.redhat.com/show_bug.cgi?id=1777241#c8 and after sanity check
Upstream commit: commit bfdb731438206b0f70fe7afa890681155c30b419 Author: Stefan Liebler <stli.com> Date: Wed Nov 27 12:35:40 2019 +0100 S390: Fix handling of needles crossing a page in strstr z15 ifunc-variant. [BZ #25226] If the specified needle crosses a page-boundary, the s390-z15 ifunc variant of strstr truncates the needle which results in invalid results. This is fixed by loading the needle beyond the page boundary to v18 instead of v16. The bug is sometimes observable in test-strstr.c in check1 and check2 as the haystack and needle is stored on stack. Thus the needle can be on a page boundary. check2 is now extended to test haystack / needles located on stack, at end of page and on two pages. This bug was introduced with commit 6f47401bd5fc71209219779a0426170a9a7395b0 ("S390: Add arch13 strstr ifunc variant.") and is already released in glibc 2.30.
Since the problem described in this bug report should be resolved in a recent advisory, it has been closed with a resolution of ERRATA. For information on the advisory, and where to find the updated files, follow the link below. If the solution does not work for you, open a new bug report. https://access.redhat.com/errata/RHSA-2020:1828