Benchmarks
Plugin footprint Passed 16 tests
Installer Passed 1 test
🔺 Critical test (weight: 50) | The install procedure must perform silently
This plugin's installer ran successfully
Server metrics [RAM: ▲0.04MB] [CPU: ▼142.55ms] Passed 4 tests
This is a short check of server-side resources used by Upload Scanner
No issues were detected with server-side resource usage
Page | Memory (MB) | CPU Time (ms) |
---|---|---|
Home / | 2.88 ▲0.04 | 43.05 ▲9.47 |
Dashboard /wp-admin | 3.11 ▲0.05 | 43.05 ▼4.60 |
Posts /wp-admin/edit.php | 3.16 ▲0.05 | 41.41 ▼2.11 |
Add New Post /wp-admin/post-new.php | 5.46 ▲0.03 | 89.41 ▼565.26 |
Media Library /wp-admin/upload.php | 3.05 ▲0.05 | 32.33 ▲1.77 |
Upload Scanner /wp-admin/options-general.php?page=upload-scanner-plugin | 3.06 | 29.63 |
Server storage [IO: ▲0.28MB] [DB: ▲0.00MB] Passed 3 tests
How much does this plugin use your filesystem and database?
The plugin installed successfully
Filesystem: 19 new files
Database: no new tables, 5 new options
New WordPress options |
---|
upload-scanner_command |
upload-scanner_onfail_email |
upload-scanner_version |
upload-scanner_quarantine_folder |
upload-scanner_onfail_log_file |
Browser metrics Passed 4 tests
A check of browser resources used by Upload Scanner
Normal browser usage
Page | Nodes | Memory (MB) | Script (ms) | Layout (ms) |
---|---|---|---|---|
Home / | 3,694 ▲100 | 16.28 ▲0.73 | 9.61 ▲0.99 | 49.12 ▲4.99 |
Dashboard /wp-admin | 2,975 ▲44 | 6.10 ▼0.03 | 138.87 ▲1.70 | 106.99 ▼15.64 |
Posts /wp-admin/edit.php | 2,744 ▲8 | 2.71 ▼0.13 | 64.07 ▲0.34 | 96.13 ▼3.91 |
Add New Post /wp-admin/post-new.php | 1,679 ▲9 | 18.87 ▼0.29 | 383.40 ▲10.59 | 113.42 ▲4.95 |
Media Library /wp-admin/upload.php | 1,812 ▲2 | 5.03 ▲0.03 | 140.71 ▲0.28 | 120.57 ▲2.62 |
Upload Scanner /wp-admin/options-general.php?page=upload-scanner-plugin | 1,306 | 2.18 | 59.34 | 89.91 |
Uninstaller [IO: ▲0.00MB] [DB: ▲0.00MB] Passed 4 tests
🔸 Tests weight: 35 | Checking the uninstaller removed all traces of the plugin
The plugin uninstalled completely, with no zombie files or tables
Smoke tests 75% from 4 tests
Server-side errors Passed 1 test
🔹 Test weight: 20 | A shallow check that no server-side errors were triggered
Good news, no errors were detected
SRP 50% from 2 tests
🔹 Tests weight: 20 | The single-responsibility principle: PHP files have to remain inert when accessed directly, throwing no errors and performing no actions
Almost there! Just fix the following items
- 1× PHP files trigger errors when accessed directly with GET requests:
- > PHP Fatal error
Uncaught Error: Call to undefined function load_plugin_textdomain() in wp-content/plugins/upload-scanner/upload-scanner.php:13
- > PHP Fatal error
User-side errors Passed 1 test
🔹 Test weight: 20 | Just a short smoke test targeting errors on the browser (console and network errors and warnings)
Everything seems fine on the user side
Optimizations
Plugin configuration 97% from 29 tests
readme.txt 94% from 16 tests
Don't ignore readme.txt as it is the file that instructs WordPress.org on how to present your plugin to the world
These attributes need your attention:
- Screenshots: These screenshots do not have images: #1 (Options screen.), #2 (Log viewer.), #3 (Sample e-mail report.)
upload-scanner/upload-scanner.php Passed 13 tests
The entry point to "Upload Scanner" version 1.2 is a PHP file that has certain tags in its header comment area
62 characters long description:
Scan all uploaded files with Clam AV or any arbitrary command.
Code Analysis Passed 3 tests
File types Passed 1 test
🔸 Test weight: 35 | Executable files are not allowed as they can serve as attack vectors
Good job! No executable or dangerous file extensions detected486 lines of code in 12 files:
Language | Files | Blank lines | Comment lines | Lines of code |
---|---|---|---|---|
PHP | 12 | 90 | 187 | 486 |
PHP code Passed 2 tests
Cyclomatic complexity and code structure are the fingerprint of this plugin
Although this was not an exhaustive test, there were no cyclomatic complexity issues detected
Cyclomatic complexity | |
---|---|
Average complexity per logical line of code | 0.30 |
Average class complexity | 10.17 |
▷ Minimum class complexity | 1.00 |
▷ Maximum class complexity | 44.00 |
Average method complexity | 3.62 |
▷ Minimum method complexity | 1.00 |
▷ Maximum method complexity | 20.00 |
Code structure | ||
---|---|---|
Namespaces | 0 | |
Interfaces | 0 | |
Traits | 0 | |
Classes | 6 | |
▷ Abstract classes | 1 | 16.67% |
▷ Concrete classes | 5 | 83.33% |
▷ Final classes | 0 | 0.00% |
Methods | 21 | |
▷ Static methods | 0 | 0.00% |
▷ Public methods | 21 | 100.00% |
▷ Protected methods | 0 | 0.00% |
▷ Private methods | 0 | 0.00% |
Functions | 0 | |
▷ Named functions | 0 | 0.00% |
▷ Anonymous functions | 0 | 0.00% |
Constants | 1 | |
▷ Global constants | 1 | 100.00% |
▷ Class constants | 0 | 0.00% |
▷ Public constants | 0 | 0.00% |
Plugin size Passed 2 tests
Image compression Passed 2 tests
PNG files should be compressed to save space and minimize bandwidth usage
3 PNG files occupy 0.25MB with 0.16MB in potential savings
Potential savings
Compression of 3 random PNG files using pngquant | |||
---|---|---|---|
File | Size - original | Size - compressed | Savings |
screenshot-3.png | 62.19KB | 21.13KB | ▼ 66.03% |
screenshot-1.png | 115.55KB | 41.12KB | ▼ 64.41% |
screenshot-2.png | 73.24KB | 23.21KB | ▼ 68.31% |