WordPress.org

Make WordPress Core

Opened 9 months ago

Closed 6 months ago

#49596 closed defect (bug) (invalid)

Improvements to PasswordHash Class

Reported by: bhubbard Owned by:
Milestone: Priority: normal
Severity: normal Version:
Component: General Keywords:
Focuses: Cc:

Description

Lots of PHP Coding Standards fixes for PasswordHash class.

Change History (5)

This ticket was mentioned in PR #185 on WordPress/wordpress-develop by bhubbard.


9 months ago

Lots of small improvements to improve PHP Coding Standards for class-phpass.php

Trac ticket: https://core.trac.wordpress.org/ticket/49596

#2 @ocean90
9 months ago

  • Milestone Awaiting Review deleted
  • Resolution set to invalid
  • Status changed from new to closed

Hello @bhubbard, thanks for the ticket.

PasswordHash is an external library and doesn't need to follow WordPress coding standards. It’s also excluded in our PHP Code Sniffer config, see phpcs.xml.dist.

#3 @bhubbard
9 months ago

  • Resolution invalid deleted
  • Status changed from closed to reopened

Hi @ocean90,

Any chance we can revisit that idea? It is one file, I checked the original library project, which has been updated to 0.5 with not many changes, also the library file had already been modified from the original project on line 83 to remove the use of getmypid().

#4 @ocean90
9 months ago

  • Keywords close added

The existing changes were done for compatibility/security reasons and are self-contained to still be able to merge upstream changes like done in #16072.

I'm not seeing any benefit in applying a WordPress specific coding standard to an external library or even changing it to use WordPress specific functions which may change the desired output. See also https://make.wordpress.org/core/handbook/contribute/code-refactoring/.

#5 @ocean90
6 months ago

  • Keywords close removed
  • Resolution set to invalid
  • Status changed from reopened to closed

Reclosing per above comment.

Note: See TracTickets for help on using tickets.