Bug 1409685 - a typo for 404 handler in the default server section
Summary: a typo for 404 handler in the default server section
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Fedora EPEL
Classification: Fedora
Component: nginx
Version: epel7
Hardware: All
OS: Linux
unspecified
low
Target Milestone: ---
Assignee: Felix Kaechele
QA Contact: Fedora Extras Quality Assurance
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2017-01-03 01:47 UTC by (GalaxyMaster)
Modified: 2020-10-01 00:30 UTC (History)
7 users (show)

Fixed In Version: nginx-1.16.1-2.el7
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
Environment:
Last Closed: 2020-10-01 00:30:56 UTC
Type: Bug
Embargoed:


Attachments (Terms of Use)

Description (GalaxyMaster) 2017-01-03 01:47:51 UTC
Description of problem:

There is a minor typo in the default server definition in /etc/nginx/nginx.conf

How reproducible:

# rpm -q nginx
nginx-1.10.2-1.el7.x86_64
# fgrep -A2 404.html /etc/nginx/nginx.conf
        error_page 404 /404.html;
            location = /40x.html {
        }
--
#        error_page 404 /404.html;
#            location = /40x.html {
#        }
# ls -1 /usr/share/nginx/html/*.html
/usr/share/nginx/html/404.html
/usr/share/nginx/html/50x.html
/usr/share/nginx/html/index.html
#

The intent of the "location = /40x.html" block was to inhibit any additional processing when a user hits a 404 error, however it seems that the line was copy-n-pasted from the 50x handler, was not properly updated, and become a no-op block in this configuration.

I think that the "location = /40x.html" lines should be fixed to be "location = /404.html" to achieve the desired effect.

P.S. The indentation in /etc/nginx/nginx.conf looks weird, e.g. these location definitions for error pages look weirdly indented.
P.P.S. Also the content of the error pages refers to Fedora while the package can be installed on RHEL and CentOS -- I'd suggest replace "Fedora" in the error page content with "EPEL" or something similar.

Comment 1 Fedora Update System 2020-09-16 00:53:11 UTC
FEDORA-EPEL-2020-0f3f88c479 has been submitted as an update to Fedora EPEL 7. https://bodhi.fedoraproject.org/updates/FEDORA-EPEL-2020-0f3f88c479

Comment 2 Fedora Update System 2020-09-16 14:40:04 UTC
FEDORA-EPEL-2020-0f3f88c479 has been pushed to the Fedora EPEL 7 testing repository.

You can provide feedback for this update here: https://bodhi.fedoraproject.org/updates/FEDORA-EPEL-2020-0f3f88c479

See also https://fedoraproject.org/wiki/QA:Updates_Testing for more information on how to test updates.

Comment 3 Fedora Update System 2020-10-01 00:30:56 UTC
FEDORA-EPEL-2020-0f3f88c479 has been pushed to the Fedora EPEL 7 stable repository.
If problem still persists, please make note of it in this bug report.


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