Make WordPress Core

Opened 8 years ago

Last modified 2 months ago

#41638 new defect (bug)

Must-Use Plugin File Still Available With a dot at the beginning of a filename (aka supposedly hidden)

Reported by: ronalfy's profile ronalfy Owned by:
Milestone: Awaiting Review Priority: normal
Severity: normal Version: 4.8.1
Component: Plugins Keywords: has-patch needs-testing needs-refresh dev-feedback
Focuses: administration Cc:

Description

If you place a dot in front of a must-use plugin file, I believe it shouldn't be included as part of your Must-Use arsenal and the code shouldn't be available as well.

Perhaps I'm doing it the wrong way, but when I place a dot in front of something (e.g., folder, file), I expect that file to no longer be available.

Attachments (3)

Screen Shot 2017-08-14 at 5.34.33 PM.png (66.2 KB) - added by ronalfy 8 years ago.
Must-Use Showing Dot File Name Available
41638.diff (509 bytes) - added by azouamauriac 4 years ago.
a fix
41638.2.diff (535 bytes) - added by callumbw95 2 months ago.
Refreshed the original patch

Download all attachments as: .zip

Change History (6)

@ronalfy
8 years ago

Must-Use Showing Dot File Name Available

@azouamauriac
4 years ago

a fix

#1 @azouamauriac
4 years ago

  • Keywords has-patch needs-testing needs-refresh dev-feedback added

hello thank you for you ticket, I have submit a fix, would you like to test it?

thank you.

#2 @azouamauriac
4 years ago

  • Focuses ui removed

hello @SergeyBiryukov could you please take a look over here? if you accepte the ticket, I think it should move forward to 6.0 milestone. thanks

#3 @callumbw95
2 months ago

Hi All,
I have just taken a look at this, and can confirm that this issue still exists, and will upload a refreshed patch shortly. For visibility I have attached a bug report too, to hopefully increase visibility on this ticket.

Bug Report

Description

When a single php plugin file is hidden using the linux method by inserting a leading dot into the filename, WordPress will still include this file as a plugin.

Environment

  • WordPress: 6.9-alpha-60093-src
  • PHP: 8.4.7
  • Server: nginx/1.27.5
  • Database: mysqli (Server: 8.0.40 / Client: mysqlnd 8.4.7)
  • Browser: Chrome 137.0.0.0
  • OS: macOS
  • Theme: Twenty Seventeen 3.9
  • MU Plugins: None activated
  • Plugins:
    • Test Reports 1.2.0

Steps to Reproduce

  1. Insert a single php plugin into the mu-plugins directory.
  2. Rename the plugin so that it has a leading dot (.) into the file name.
  3. 🐞 Bug occurs.

Expected Results

  1. ✅ Plugin should not appear in the mu-plugins list.

Actual Results

  1. ❌ Plugin still appears, and in the case the meta is not included in the file the plugin name will show with the leading dot.

@callumbw95
2 months ago

Refreshed the original patch

Note: See TracTickets for help on using tickets.