Benchmarks
Plugin footprint 65% from 16 tests
Installer Passed 1 test
🔺 Critical test (weight: 50) | Checking the installer triggered no errors
This plugin's installer ran successfully
Server metrics [RAM: ▲1.43MB] [CPU: ▲9.40ms] Passed 4 tests
An overview of server-side resources used by Security Force
Normal server usage
Page | Memory (MB) | CPU Time (ms) |
---|---|---|
Home / | 4.34 ▲0.88 | 42.68 ▲1.17 |
Dashboard /wp-admin | 4.92 ▲1.57 | 74.30 ▲9.12 |
Posts /wp-admin/edit.php | 4.99 ▲1.64 | 70.53 ▲19.20 |
Add New Post /wp-admin/post-new.php | 7.61 ▲1.72 | 108.31 ▲11.35 |
Media Library /wp-admin/upload.php | 4.86 ▲1.63 | 55.79 ▲15.97 |
Pro Options /wp-admin/admin.php?page=securityforce_secure_network | 4.78 | 59.82 |
Security Settings /wp-admin/admin.php?page=security_force | 4.81 | 53.70 |
Widgets /wp-admin/admin.php?page=security_force_dashboard | 4.81 | 56.67 |
Setup Wizard /wp-admin/admin.php?page=securityforce_setup_wizard | 4.79 | 52.44 |
Server storage [IO: ▲2.64MB] [DB: ▲0.01MB] Passed 3 tests
Analyzing filesystem and database footprints of this plugin
There were no storage issued detected upon installing this plugin
Filesystem: 471 new files
Database: 2 new tables, 8 new options
New tables |
---|
wp_securityforce_ab_attacks |
wp_securityforce_blocked_ips |
New WordPress options |
---|
theysaidso_admin_options |
securityforce_firewall_phpidsinstalled |
db_upgraded |
widget_theysaidso_widget |
can_compress_scripts |
widget_recent-posts |
security_force |
widget_recent-comments |
Browser metrics Passed 4 tests
This is an overview of browser requirements for Security Force
Minimal impact on browser resources
Page | Nodes | Memory (MB) | Script (ms) | Layout (ms) |
---|---|---|---|---|
Home / | 2,802 ▲55 | 14.67 ▲0.29 | 1.41 ▼0.19 | 39.99 ▼2.51 |
Dashboard /wp-admin | 2,221 ▲47 | 5.52 ▲0.00 | 94.29 ▼6.38 | 75.11 ▲28.08 |
Posts /wp-admin/edit.php | 2,129 ▲29 | 1.96 ▼0.06 | 39.61 ▼1.42 | 36.47 ▲3.37 |
Add New Post /wp-admin/post-new.php | 1,701 ▲175 | 22.10 ▼1.11 | 591.74 ▼118.50 | 59.59 ▲1.30 |
Media Library /wp-admin/upload.php | 1,429 ▲29 | 4.11 ▼0.18 | 98.53 ▼16.68 | 74.43 ▲25.82 |
Pro Options /wp-admin/admin.php?page=securityforce_secure_network | 873 | 2.00 | 27.27 | 27.99 |
Security Settings /wp-admin/admin.php?page=security_force | 2,197 | 2.92 | 112.08 | 60.77 |
Widgets /wp-admin/admin.php?page=security_force_dashboard | 1,173 | 3.24 | 135.98 | 35.72 |
Setup Wizard /wp-admin/admin.php?page=securityforce_setup_wizard | 935 | 1.65 | 28.30 | 33.32 |
Uninstaller [IO: ▲0.00MB] [DB: ▲0.01MB] 50% from 4 tests
🔸 Tests weight: 35 | The uninstall procedure must remove all plugin files and extra database tables
Please fix the following items
- This plugin does not fully uninstall, leaving 2 tables in the database
- wp_securityforce_ab_attacks
- wp_securityforce_blocked_ips
- Zombie WordPress options detected upon uninstall: 8 options
- db_upgraded
- can_compress_scripts
- security_force
- widget_recent-comments
- widget_theysaidso_widget
- securityforce_firewall_phpidsinstalled
- widget_recent-posts
- theysaidso_admin_options
Smoke tests 50% from 4 tests
Server-side errors Passed 1 test
🔹 Test weight: 20 | Just a short smoke test targeting errors on the server (in the Apache logs)
The smoke test was a success, however most plugin functionality was not tested
SRP 0% from 2 tests
🔹 Tests weight: 20 | A shallow check of the single-responsibility principle; PHP files should perform no action - including output of placeholder text - and trigger no errors when accessed directly
Please fix the following
- 1× PHP files output text when accessed directly:
- > /wp-content/plugins/security-force/firewall/libraries/IDS/Config/Config.ini.php
- 35× GET requests to PHP files trigger server-side errors or Error 500 responses (only 10 are shown):
- > PHP Fatal error
Uncaught Error: Class 'HTMLPurifier_Printer' not found in wp-content/plugins/security-force/firewall/libraries/IDS/vendors/htmlpurifier/standalone/HTMLPurifier/Printer/ConfigForm.php:6
- > PHP Fatal error
Uncaught Error: Call to undefined function plugins_url() in wp-content/plugins/security-force/securityforce.php:21
- > PHP Fatal error
require_once(): Failed opening required 'IDS/Log/Interface.php' (include_path='.:/usr/share/php') in wp-content/plugins/security-force/firewall/libraries/IDS/Log/Database.php on line 35
- > PHP Warning
require_once(IDS/Log/Interface.php): failed to open stream: No such file or directory in wp-content/plugins/security-force/firewall/libraries/IDS/Log/File.php on line 34
- > PHP Fatal error
require_once(): Failed opening required 'IDS/Caching/Interface.php' (include_path='.:/usr/share/php') in wp-content/plugins/security-force/firewall/libraries/IDS/Caching/Apc.php on line 33
- > PHP Fatal error
Uncaught Error: Call to undefined function is_multisite() in wp-content/plugins/security-force/lib/auto_config.php:4
- > PHP Fatal error
Uncaught Error: Using $this when not in object context in wp-content/plugins/security-force/lib/auto_config/woo-commerce.php:2
- > PHP Fatal error
Uncaught Error: Class 'HTMLPurifier_Filter' not found in wp-content/plugins/security-force/firewall/libraries/IDS/vendors/htmlpurifier/standalone/HTMLPurifier/Filter/YouTube.php:3
- > PHP Fatal error
require_once(): Failed opening required 'IDS/Caching/Interface.php' (include_path='.:/usr/share/php') in wp-content/plugins/security-force/firewall/libraries/IDS/Caching/Memcached.php on line 34
- > PHP Fatal error
Uncaught Error: Class 'Jetpack' not found in wp-content/plugins/security-force/lib/auto_config/jetpack.php:3
- > PHP Fatal error
User-side errors Passed 1 test
🔹 Test weight: 20 | This is a shallow check for browser errors
No browser errors were detected
Optimizations
Plugin configuration 86% 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
1 plugin tags: security
security-force/securityforce.php 69% from 13 tests
"Security Force" version 1.0.1's primary PHP file adds more information about the plugin and serves as the entry point for WordPress
You should first fix the following items:
- Text Domain: The text domain name should consist of only dashes and lowercase characters
- Git Repository: Please do not include Git repositories in your plugin
- Domain Path: The domain path points to an invalid folder, "/lang" does not exist
- Main file name: Name the main plugin file the same as the plugin slug ("security-force.php" instead of "securityforce.php")
Code Analysis 97% from 3 tests
File types Passed 1 test
🔸 Test weight: 35 | There should be no dangerous file extensions present in any WordPress plugin
Success! There were no dangerous files found in this plugin42,362 lines of code in 82 files:
Language | Files | Blank lines | Comment lines | Lines of code |
---|---|---|---|---|
PHP | 71 | 7,732 | 14,734 | 30,873 |
JavaScript | 5 | 2,199 | 2,154 | 10,539 |
XML | 1 | 0 | 0 | 827 |
CSS | 2 | 3 | 1 | 73 |
SVG | 1 | 0 | 1 | 48 |
INI | 1 | 1 | 1 | 1 |
JSON | 1 | 0 | 0 | 1 |
PHP code 50% from 2 tests
A short review of cyclomatic complexity and code structure
Please tend to the following items
- Please reduce cyclomatic complexity of methods to less than 100 (currently 232)
Cyclomatic complexity | |
---|---|
Average complexity per logical line of code | 0.48 |
Average class complexity | 17.81 |
▷ Minimum class complexity | 1.00 |
▷ Maximum class complexity | 889.00 |
Average method complexity | 5.25 |
▷ Minimum method complexity | 1.00 |
▷ Maximum method complexity | 232.00 |
Code structure | ||
---|---|---|
Namespaces | 0 | |
Interfaces | 2 | |
Traits | 0 | |
Classes | 264 | |
▷ Abstract classes | 16 | 6.06% |
▷ Concrete classes | 248 | 93.94% |
▷ Final classes | 0 | 0.00% |
Methods | 1,074 | |
▷ Static methods | 108 | 10.06% |
▷ Public methods | 859 | 79.98% |
▷ Protected methods | 105 | 9.78% |
▷ Private methods | 110 | 10.24% |
Functions | 19 | |
▷ Named functions | 8 | 42.11% |
▷ Anonymous functions | 11 | 57.89% |
Constants | 91 | |
▷ Global constants | 20 | 21.98% |
▷ Class constants | 71 | 78.02% |
▷ Public constants | 71 | 100.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
10 PNG files occupy 0.03MB with 0.01MB in potential savings
Potential savings
Compression of 5 random PNG files using pngquant | |||
---|---|---|---|
File | Size - original | Size - compressed | Savings |
img/hedge3.48.png | 3.46KB | 1.99KB | ▼ 42.57% |
img/delete.png | 2.17KB | 1.62KB | ▼ 25.35% |
img/hedge3.64.png | 4.77KB | 2.23KB | ▼ 53.28% |
img/add.png | 0.51KB | 0.27KB | ▼ 47.82% |
img/securityforce32.png | 2.75KB | 1.56KB | ▼ 43.36% |