89% password-hash

Code Review | PHP Native Password Hash

WordPress plugin PHP Native Password Hash scored89%from 54 tests.

About plugin

  • Plugin page: password-hash
  • Plugin version: 3.0
  • PHP compatiblity: 7.0+
  • PHP version: 7.4.16
  • WordPress compatibility: 5.2-6.3
  • WordPress version: 6.3.1
  • First release: Jan 4, 2017
  • Latest release: Jul 23, 2023
  • Number of updates: 56
  • Update frequency: every 42.7 days
  • Top authors: ayeshrajans (100%)

Code review

54 tests

User reviews

5 reviews

Install metrics

2,000+ active /14,532 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | All plugins must install correctly, without throwing any errors, warnings, or notices
Installer ran successfully

Server metrics [RAM: ▼0.01MB] [CPU: ▼9.09ms] Passed 4 tests

Server-side resources used by PHP Native Password Hash
This plugin does not affect your website's performance
PageMemory (MB)CPU Time (ms)
Home /3.47 ▲0.0034.97 ▼3.29
Dashboard /wp-admin3.31 ▼0.0342.01 ▼14.78
Posts /wp-admin/edit.php3.37 ▲0.0042.29 ▼5.31
Add New Post /wp-admin/post-new.php5.90 ▲0.0180.59 ▼12.98
Media Library /wp-admin/upload.php3.24 ▲0.0036.00 ▼2.15

Server storage [IO: ▲0.02MB] [DB: ▲0.00MB] Passed 3 tests

A short overview of filesystem and database impact
This plugin installed successfully
Filesystem: 5 new files
Database: no new tables, 6 new options
New WordPress options
can_compress_scripts
db_upgraded
theysaidso_admin_options
widget_theysaidso_widget
widget_recent-posts
widget_recent-comments

Browser metrics Passed 4 tests

PHP Native Password Hash: an overview of browser usage
Normal browser usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,814 ▲6814.17 ▼0.182.05 ▲0.2740.02 ▼0.82
Dashboard /wp-admin2,192 ▲155.55 ▼0.0583.00 ▼4.6736.07 ▼1.81
Posts /wp-admin/edit.php2,100 ▼01.99 ▼0.0132.99 ▼4.5033.85 ▼1.11
Add New Post /wp-admin/post-new.php1,526 ▼223.07 ▲0.16651.67 ▲7.8851.22 ▼11.20
Media Library /wp-admin/upload.php1,400 ▼04.20 ▼0.1092.89 ▼21.7542.34 ▼6.64

Uninstaller [IO: ▲0.00MB] [DB: ▲0.00MB] 75% from 4 tests

🔸 Tests weight: 35 | It is important to correctly uninstall your plugin, without leaving any traces
It is recommended to fix the following
  • This plugin did not uninstall successfully, leaving 6 options in the database
    • widget_recent-comments
    • widget_theysaidso_widget
    • theysaidso_admin_options
    • db_upgraded
    • can_compress_scripts
    • widget_recent-posts

Smoke tests Passed 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | This is a short smoke test looking for server-side errors
Even though no errors were found, this is by no means an exhaustive test

SRP Passed 2 tests

🔹 Tests weight: 20 | SRP (Single-Responsibility Principle) - PHP files must act as libraries and never output text or perform any action when accessed directly in a browser
Everything seems fine, however this is by no means an exhaustive test

User-side errors Passed 1 test

🔹 Test weight: 20 | This is a smoke test targeting browser errors/issues
There were no browser issues found

Optimizations

Plugin configuration 93% from 29 tests

readme.txt Passed 16 tests

It's important to format your readme.txt file correctly as it is parsed for the public listing of your plugin
10 plugin tags: argon2i, argon2id, password hashing, password, password_hash...

password-hash/wp-php-password-hash.php 85% from 13 tests

"PHP Native Password Hash" version 3.0's main PHP file describes plugin functionality and also serves as the entry point to any WordPress functionality
It is important to fix the following:
  • Main file name: Please rename the main PHP file in this plugin to the plugin slug ("password-hash.php" instead of "wp-php-password-hash.php")
  • Description: Please don't use more than 140 characters for the plugin description (currently 261 characters long)

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | Executable files are considered dangerous and should not be included with any WordPress plugin
There were no executable files found in this plugin155 lines of code in 4 files:
LanguageFilesBlank linesComment linesLines of code
PHP33152125
JSON10030

PHP code Passed 2 tests

A short review of cyclomatic complexity and code structure
This plugin has no cyclomatic complexity issues
Cyclomatic complexity
Average complexity per logical line of code0.32
Average class complexity11.00
▷ Minimum class complexity11.00
▷ Maximum class complexity11.00
Average method complexity2.11
▷ Minimum method complexity1.00
▷ Maximum method complexity4.00
Code structure
Namespaces1
Interfaces0
Traits0
Classes1
▷ Abstract classes00.00%
▷ Concrete classes1100.00%
▷ Final classes1100.00%
Methods10
▷ Static methods110.00%
▷ Public methods550.00%
▷ Protected methods00.00%
▷ Private methods550.00%
Functions5
▷ Named functions480.00%
▷ Anonymous functions120.00%
Constants6
▷ Global constants00.00%
▷ Class constants6100.00%
▷ Public constants6100.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

It is recommended to compress PNG files in your plugin to minimize bandwidth usage
There are no PNG files in this plugin