RHEL Engineering is moving the tracking of its product development work on RHEL 6 through RHEL 9 to Red Hat Jira (issues.redhat.com). If you're a Red Hat customer, please continue to file support cases via the Red Hat customer portal. If you're not, please head to the "RHEL project" in Red Hat Jira and file new tickets here. Individual Bugzilla bugs in the statuses "NEW", "ASSIGNED", and "POST" are being migrated throughout September 2023. Bugs of Red Hat partners with an assigned Engineering Partner Manager (EPM) are migrated in late September as per pre-agreed dates. Bugs against components "kernel", "kernel-rt", and "kpatch" are only migrated if still in "NEW" or "ASSIGNED". If you cannot log in to RH Jira, please consult article #7032570. That failing, please send an e-mail to the RH Jira admins at rh-issues@redhat.com to troubleshoot your issue as a user management inquiry. The email creates a ServiceNow ticket with Red Hat. Individual Bugzilla bugs that are migrated will be moved to status "CLOSED", resolution "MIGRATED", and set with "MigratedToJIRA" in "Keywords". The link to the successor Jira issue will be found under "Links", have a little "two-footprint" icon next to it, and direct you to the "RHEL project" in Red Hat Jira (issue links are of type "https://issues.redhat.com/browse/RHEL-XXXX", where "X" is a digit). This same link will be available in a blue banner at the top of the page informing you that that bug has been migrated.
Bug 1978586 - Test case failure: /CoreOS/httpd/mod_headers/requestheader_edit
Summary: Test case failure: /CoreOS/httpd/mod_headers/requestheader_edit
Keywords:
Status: CLOSED CURRENTRELEASE
Alias: None
Product: Red Hat Enterprise Linux 9
Classification: Red Hat
Component: httpd
Version: 9.0
Hardware: Unspecified
OS: Linux
unspecified
unspecified
Target Milestone: beta
: ---
Assignee: Luboš Uhliarik
QA Contact: rhel-cs-infra-services-qe
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2021-07-02 08:55 UTC by Branislav Náter
Modified: 2021-07-12 14:00 UTC (History)
3 users (show)

Fixed In Version:
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
Environment:
Last Closed: 2021-07-08 13:07:24 UTC
Type: Bug
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)

Description Branislav Náter 2021-07-02 08:55:34 UTC
I'm getting failure when running /CoreOS/httpd/mod_headers/requestheader_edit.
Test was working on Alpha RHEL-9.0.0-20210330.7-Alpha with httpd-2.4.46-9.el9 and php-7.4.15-2.el9 (and rhel-8).
Let me know what other info should I provide.

Version-Release number of selected component (if applicable):
httpd-2.4.48-5.el9
php-8.0.6-6.el9

Steps to Reproduce: 
1. run /CoreOS/httpd/mod_headers/requestheader_edit


Actual results: 
HTTP/1.1 500 Internal Server Error
Date: Fri, 02 Jul 2021 08:13:11 GMT
Server: Apache/2.4.48 (Red Hat Enterprise Linux)
X-Powered-By: PHP/8.0.6
Connection: close
Transfer-Encoding: chunked
Content-Type: text/html; charset=UTF-8

e
<html>
<body>

0

Expected results:
HTTP/1.1 200 OK
Date: Thu, 01 Jul 2021 13:29:40 GMT
Server: Apache/2.4.46 (Red Hat Enterprise Linux)
X-Powered-By: PHP/7.4.15
Transfer-Encoding: chunked
Content-Type: text/html; charset=UTF-8

26
<html>
<body>
SOMEhost</body>
</html>

0

Comment 5 Remi Collet 2021-07-08 12:15:48 UTC
As discussed on IRC

13:32:09 - bnater : so in /var/log/php-fpm/www-error.log we have error:
13:32:22 - bnater : [08-Jul-2021 10:38:16 UTC] PHP Fatal error:  Uncaught Error: Undefined constant "Host" in /var/www/html/test.php:5

So:


diff --git a/mod_headers/requestheader_edit/runtest.sh b/mod_headers/requestheader_edit/runtest.sh
index a66d1bd8..6e14e97b 100755
--- a/mod_headers/requestheader_edit/runtest.sh
+++ b/mod_headers/requestheader_edit/runtest.sh
@@ -45,12 +45,12 @@ rlJournalStart
     rlPhaseEnd
 
     rlPhaseStartTest "Testing"
-        cat > $httpROOTDIR/test.php << EOF
+        cat > $httpROOTDIR/test.php << 'EOF'
 <html>
 <body>
 <?php 
-\$headers = getallheaders(); 
-echo(\$headers[Host]);
+$headers = getallheaders();
+echo($headers['Host']);
 ?>
 </body>
 </html>


Note You need to log in before you can comment on or make changes to this bug.