Bug 2017143 - [autoindex fancy]Directory named `core` gets icon for `core` file.
Summary: [autoindex fancy]Directory named `core` gets icon for `core` file.
Keywords:
Status: CLOSED RAWHIDE
Alias: None
Product: Fedora
Classification: Fedora
Component: httpd
Version: 36
Hardware: All
OS: All
unspecified
low
Target Milestone: ---
Assignee: Luboš Uhliarik
QA Contact: Fedora Extras Quality Assurance
URL:
Whiteboard:
: 2077039 (view as bug list)
Depends On:
Blocks: 1196553
TreeView+ depends on / blocked
 
Reported: 2021-10-25 18:30 UTC by Pat Riehecky
Modified: 2022-04-22 14:47 UTC (History)
8 users (show)

Fixed In Version:
Clone Of:
: 2017144 (view as bug list)
Environment:
Last Closed: 2022-04-22 11:25:28 UTC
Type: Bug
Embargoed:


Attachments (Terms of Use)

Description Pat Riehecky 2021-10-25 18:30:58 UTC
Description of problem:
When using the default configuration for `mod_autoindex` the default icon for a directory named `core` is bomb.gif.  Can the default config restrict bomb.gif to only files named `core` and let the `core` directory default to folder.gif?

Version-Release number of selected component (if applicable):
httpd-2.4.48-1.fc33

How reproducible:
100%

Steps to Reproduce:
1. Install httpd
2. Enable autoindex with Fancy Icons
3. mkdir /var/www/html/core
4. touch /var/www/html/core/examplefile
5. look at the auto generated index for /var/www/html/

Actual results:

The directory `core` gets `bomb.gif` for the icon, which is misleading.

Expected results:

Directories recieve `folder.gif` as their icon by default.

Additional info:

Comment 1 Ben Cotton 2022-02-08 21:36:30 UTC
This bug appears to have been reported against 'rawhide' during the Fedora 36 development cycle.
Changing version to 36.

Comment 2 Luboš Uhliarik 2022-04-22 11:25:28 UTC
Hi Pat,

I changed the behavior how httpd treats core files. Previously, httpd was marking core files based on its filename. Because httpd can not distinguish between files and directories in AddIcon directive it was marking directories called "core" with the bomb icon as well.

Now mod_autoindex will check MIME type of the file and if the file is recognized as coredump, it will mark that file with the bomb icon.

Let me know if this works for you correctly and feel free to reopen this bug if not.

Comment 3 Joe Orton 2022-04-22 14:47:48 UTC
*** Bug 2077039 has been marked as a duplicate of this bug. ***


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