Version Description
Download this release
Release Info
Developer | paultgoodchild |
Plugin | Shield Security for WordPress |
Version | 15.1.5 |
Comparing to | |
See all releases |
Code changes from version 15.1.4 to 15.1.5
- cl.json +14 -0
- config/deprecated/data.php +1 -1
- config/deprecated/ips.php +18 -167
- config/ips.json +8 -5
- icwp-wpsf.php +1 -1
- plugin-spec.php +3 -3
- plugin.json +3 -3
- readme.txt +4 -2
- src/lib/src/Controller/Controller.php +4 -3
- src/lib/src/Modules/IPs/Lib/Ops/DeleteIp.php +1 -1
- src/lib/src/Modules/License/Lib/WpHashes/ApiTokenManager.php +4 -1
- src/lib/src/Modules/Plugin/AjaxHandler.php +6 -0
- src/lib/src/ShieldNetApi/WPHashes/SolicitToken.php +2 -1
- src/lib/vendor/fernleafsystems/wordpress-services/src/Utilities/Licenses/Keyless/Lookup.php +1 -0
- templates/twig/notices/does-not-meet-requirements.twig +2 -1
cl.json
CHANGED
@@ -72,6 +72,20 @@
|
|
72 |
"type": "fixed"
|
73 |
}
|
74 |
]
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
75 |
}
|
76 |
]
|
77 |
},
|
72 |
"type": "fixed"
|
73 |
}
|
74 |
]
|
75 |
+
},
|
76 |
+
{
|
77 |
+
"version": "5",
|
78 |
+
"released_at": 1655719000,
|
79 |
+
"items": [
|
80 |
+
{
|
81 |
+
"title": "Log the IP address in the Activity Log when IP has been manually unblocked.",
|
82 |
+
"type": "improved"
|
83 |
+
},
|
84 |
+
{
|
85 |
+
"title": "Address a potential fatal error in the admin area when the minimum server requirements aren't met.",
|
86 |
+
"type": "fixed"
|
87 |
+
}
|
88 |
+
]
|
89 |
}
|
90 |
]
|
91 |
},
|
config/deprecated/data.php
CHANGED
@@ -54,7 +54,7 @@
|
|
54 |
"has_deleted_at": false,
|
55 |
"cols_custom": {
|
56 |
"req_id": {
|
57 |
-
"macro_type": "
|
58 |
"length": 10,
|
59 |
"attr": [
|
60 |
"UNIQUE"
|
54 |
"has_deleted_at": false,
|
55 |
"cols_custom": {
|
56 |
"req_id": {
|
57 |
+
"macro_type": "varchar",
|
58 |
"length": 10,
|
59 |
"attr": [
|
60 |
"UNIQUE"
|
config/deprecated/ips.php
CHANGED
@@ -16,7 +16,7 @@
|
|
16 |
"premium": false,
|
17 |
"run_if_whitelisted": true,
|
18 |
"run_if_verified_bot": true,
|
19 |
-
"run_if_wpcli":
|
20 |
"order": 100
|
21 |
},
|
22 |
"menus": {
|
@@ -71,11 +71,6 @@
|
|
71 |
"title": "AntiBot System",
|
72 |
"title_short": "AntiBot System"
|
73 |
},
|
74 |
-
{
|
75 |
-
"slug": "section_crowdsec",
|
76 |
-
"title": "CrowdSec",
|
77 |
-
"title_short": "CrowdSec"
|
78 |
-
},
|
79 |
{
|
80 |
"slug": "section_logins",
|
81 |
"title": "Capture Login Bots",
|
@@ -269,47 +264,6 @@
|
|
269 |
"summary": "Request Path Whitelist",
|
270 |
"description": "Request Path Whitelist."
|
271 |
},
|
272 |
-
{
|
273 |
-
"key": "cs_block",
|
274 |
-
"section": "section_crowdsec",
|
275 |
-
"advanced": true,
|
276 |
-
"default": "block_with_unblock",
|
277 |
-
"type": "select",
|
278 |
-
"value_options": [
|
279 |
-
{
|
280 |
-
"value_key": "disabled",
|
281 |
-
"text": "Disabled"
|
282 |
-
},
|
283 |
-
{
|
284 |
-
"value_key": "block_with_unblock",
|
285 |
-
"text": "Block Request With Ability To Auto-Unblock"
|
286 |
-
},
|
287 |
-
{
|
288 |
-
"value_key": "block",
|
289 |
-
"text": "Block Request"
|
290 |
-
}
|
291 |
-
],
|
292 |
-
"link_info": "",
|
293 |
-
"link_blog": "",
|
294 |
-
"beacon_id": 0,
|
295 |
-
"name": "CrowdSec IP Blocking",
|
296 |
-
"summary": "How To Handle Requests From IPs Found On CrowdSec Blocklist",
|
297 |
-
"description": "How should Shield block requests from IP address that are found on CrowdSec's list of malicious IP addresses."
|
298 |
-
},
|
299 |
-
{
|
300 |
-
"key": "cs_enroll_id",
|
301 |
-
"section": "section_crowdsec",
|
302 |
-
"sensitive": true,
|
303 |
-
"premium": false,
|
304 |
-
"default": "",
|
305 |
-
"type": "text",
|
306 |
-
"link_info": "",
|
307 |
-
"link_blog": "",
|
308 |
-
"beacon_id": 0,
|
309 |
-
"name": "Enroll ID",
|
310 |
-
"summary": "CrowdSec Enroll ID",
|
311 |
-
"description": "CrowdSec Enroll ID."
|
312 |
-
},
|
313 |
{
|
314 |
"key": "text_loginfailed",
|
315 |
"section": "section_user_messages",
|
@@ -616,28 +570,10 @@
|
|
616 |
"transferable": false,
|
617 |
"type": "array",
|
618 |
"default": []
|
619 |
-
},
|
620 |
-
{
|
621 |
-
"key": "crowdsec_cfg",
|
622 |
-
"section": "section_non_ui",
|
623 |
-
"transferable": false,
|
624 |
-
"type": "array",
|
625 |
-
"default": []
|
626 |
}
|
627 |
],
|
628 |
"definitions": {
|
629 |
-
"
|
630 |
-
"scenarios": {
|
631 |
-
"free": [
|
632 |
-
"crowdsecurity/http-bf-wordpress_bf",
|
633 |
-
"crowdsecurity/http-wordpress_wpconfig",
|
634 |
-
"crowdsecurity/http-wordpress_user-enum"
|
635 |
-
],
|
636 |
-
"pro": [
|
637 |
-
]
|
638 |
-
}
|
639 |
-
},
|
640 |
-
"rest_api": {
|
641 |
"publish": true,
|
642 |
"pro_only": true,
|
643 |
"route_defs": {
|
@@ -651,7 +587,7 @@
|
|
651 |
}
|
652 |
}
|
653 |
},
|
654 |
-
"allowable_ext_404s":
|
655 |
"js",
|
656 |
"css",
|
657 |
"gif",
|
@@ -663,12 +599,10 @@
|
|
663 |
"woff",
|
664 |
"woff2"
|
665 |
],
|
666 |
-
"db_handler_classes":
|
667 |
-
"botsignal":
|
668 |
-
"crowdsec_decisions": "\\FernleafSystems\\Wordpress\\Plugin\\Shield\\Modules\\IPs\\DB\\CrowdSecDecisions\\Ops\\Handler",
|
669 |
-
"crowdsec_signals": "\\FernleafSystems\\Wordpress\\Plugin\\Shield\\Modules\\IPs\\DB\\CrowdSecSignals\\Ops\\Handler"
|
670 |
},
|
671 |
-
"db_table_botsignal":
|
672 |
"autoexpire": 0,
|
673 |
"slug": "botsignal",
|
674 |
"has_updated_at": true,
|
@@ -786,60 +720,11 @@
|
|
786 |
}
|
787 |
}
|
788 |
},
|
789 |
-
"
|
790 |
-
"autoexpire": 0,
|
791 |
-
"slug": "crowdsec_decisions",
|
792 |
-
"has_updated_at": true,
|
793 |
-
"col_older_than": "updated_at",
|
794 |
-
"cols_custom": {
|
795 |
-
"ip_ref": {
|
796 |
-
"macro_type": "foreign_key_id",
|
797 |
-
"foreign_key": {
|
798 |
-
"ref_table": "icwp_wpsf_ips"
|
799 |
-
}
|
800 |
-
}
|
801 |
-
},
|
802 |
-
"cols_timestamps": {
|
803 |
-
"auto_unblock_at": {
|
804 |
-
"comment": "Visitor Requested Unblock"
|
805 |
-
},
|
806 |
-
"expires_at": {
|
807 |
-
"comment": "Record Expires At"
|
808 |
-
}
|
809 |
-
}
|
810 |
-
},
|
811 |
-
"db_table_crowdsec_signals": {
|
812 |
-
"autoexpire": 0,
|
813 |
-
"slug": "crowdsec_signals",
|
814 |
-
"has_updated_at": false,
|
815 |
-
"has_created_at": true,
|
816 |
-
"has_deleted_at": false,
|
817 |
-
"col_older_than": "created_at",
|
818 |
-
"cols_custom": {
|
819 |
-
"scenario": {
|
820 |
-
"macro_type": "varchar",
|
821 |
-
"length": 32,
|
822 |
-
"attr": []
|
823 |
-
},
|
824 |
-
"scope": {
|
825 |
-
"macro_type": "varchar",
|
826 |
-
"length": 16,
|
827 |
-
"attr": []
|
828 |
-
},
|
829 |
-
"value": {
|
830 |
-
"macro_type": "varchar",
|
831 |
-
"length": 256,
|
832 |
-
"attr": []
|
833 |
-
}
|
834 |
-
},
|
835 |
-
"cols_timestamps": {
|
836 |
-
}
|
837 |
-
},
|
838 |
-
"db_classes": {
|
839 |
"ip_lists": "\\FernleafSystems\\Wordpress\\Plugin\\Shield\\Databases\\IPs\\Handler"
|
840 |
},
|
841 |
-
"ip_lists_table_name":
|
842 |
-
"db_table_ip_lists":
|
843 |
"slug": "ip_lists",
|
844 |
"cols_custom": {
|
845 |
"ip": "varchar(60) NOT NULL DEFAULT '' COMMENT 'Human readable IP address or range'",
|
@@ -854,7 +739,7 @@
|
|
854 |
"blocked_at": "IP Blocked"
|
855 |
}
|
856 |
},
|
857 |
-
"events":
|
858 |
"custom_offense": {
|
859 |
"audit_params": [
|
860 |
"message"
|
@@ -865,10 +750,6 @@
|
|
865 |
"level": "warning",
|
866 |
"audit_countable": true
|
867 |
},
|
868 |
-
"conn_kill_crowdsec": {
|
869 |
-
"level": "warning",
|
870 |
-
"audit_countable": true
|
871 |
-
},
|
872 |
"conn_not_kill_high_rep": {
|
873 |
"level": "debug"
|
874 |
},
|
@@ -886,10 +767,13 @@
|
|
886 |
],
|
887 |
"level": "alert"
|
888 |
},
|
889 |
-
"ip_unblock":
|
890 |
-
"
|
891 |
-
|
892 |
-
|
|
|
|
|
|
|
893 |
},
|
894 |
"ip_block_auto": {
|
895 |
"audit_params": [
|
@@ -975,7 +859,7 @@
|
|
975 |
},
|
976 |
"bottrack_invalidscript": {
|
977 |
"audit_params": [
|
978 |
-
"
|
979 |
],
|
980 |
"offense": true
|
981 |
},
|
@@ -987,39 +871,6 @@
|
|
987 |
"level": "info",
|
988 |
"offense": false,
|
989 |
"stat": false
|
990 |
-
},
|
991 |
-
"crowdsec_decisions_acquired": {
|
992 |
-
"level": "info",
|
993 |
-
"audit_params": [
|
994 |
-
"count_new",
|
995 |
-
"count_deleted"
|
996 |
-
]
|
997 |
-
},
|
998 |
-
"crowdsec_signals_pushed": {
|
999 |
-
"level": "info",
|
1000 |
-
"audit_params": [
|
1001 |
-
"count"
|
1002 |
-
]
|
1003 |
-
},
|
1004 |
-
"crowdsec_mach_register": {
|
1005 |
-
"level": "info",
|
1006 |
-
"audit_params": [
|
1007 |
-
"machine_id",
|
1008 |
-
"url"
|
1009 |
-
]
|
1010 |
-
},
|
1011 |
-
"crowdsec_auth_acquire": {
|
1012 |
-
"level": "info",
|
1013 |
-
"audit_params": [
|
1014 |
-
"expiration"
|
1015 |
-
]
|
1016 |
-
},
|
1017 |
-
"crowdsec_mach_enroll": {
|
1018 |
-
"level": "info",
|
1019 |
-
"audit_params": [
|
1020 |
-
"id",
|
1021 |
-
"name"
|
1022 |
-
]
|
1023 |
}
|
1024 |
}
|
1025 |
}
|
16 |
"premium": false,
|
17 |
"run_if_whitelisted": true,
|
18 |
"run_if_verified_bot": true,
|
19 |
+
"run_if_wpcli": true,
|
20 |
"order": 100
|
21 |
},
|
22 |
"menus": {
|
71 |
"title": "AntiBot System",
|
72 |
"title_short": "AntiBot System"
|
73 |
},
|
|
|
|
|
|
|
|
|
|
|
74 |
{
|
75 |
"slug": "section_logins",
|
76 |
"title": "Capture Login Bots",
|
264 |
"summary": "Request Path Whitelist",
|
265 |
"description": "Request Path Whitelist."
|
266 |
},
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
267 |
{
|
268 |
"key": "text_loginfailed",
|
269 |
"section": "section_user_messages",
|
570 |
"transferable": false,
|
571 |
"type": "array",
|
572 |
"default": []
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
573 |
}
|
574 |
],
|
575 |
"definitions": {
|
576 |
+
"rest_api": {
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
577 |
"publish": true,
|
578 |
"pro_only": true,
|
579 |
"route_defs": {
|
587 |
}
|
588 |
}
|
589 |
},
|
590 |
+
"allowable_ext_404s": [
|
591 |
"js",
|
592 |
"css",
|
593 |
"gif",
|
599 |
"woff",
|
600 |
"woff2"
|
601 |
],
|
602 |
+
"db_handler_classes": {
|
603 |
+
"botsignal": "\\FernleafSystems\\Wordpress\\Plugin\\Shield\\Modules\\IPs\\DB\\BotSignal\\Ops\\Handler"
|
|
|
|
|
604 |
},
|
605 |
+
"db_table_botsignal": {
|
606 |
"autoexpire": 0,
|
607 |
"slug": "botsignal",
|
608 |
"has_updated_at": true,
|
720 |
}
|
721 |
}
|
722 |
},
|
723 |
+
"db_classes": {
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
724 |
"ip_lists": "\\FernleafSystems\\Wordpress\\Plugin\\Shield\\Databases\\IPs\\Handler"
|
725 |
},
|
726 |
+
"ip_lists_table_name": "ip_lists",
|
727 |
+
"db_table_ip_lists": {
|
728 |
"slug": "ip_lists",
|
729 |
"cols_custom": {
|
730 |
"ip": "varchar(60) NOT NULL DEFAULT '' COMMENT 'Human readable IP address or range'",
|
739 |
"blocked_at": "IP Blocked"
|
740 |
}
|
741 |
},
|
742 |
+
"events": {
|
743 |
"custom_offense": {
|
744 |
"audit_params": [
|
745 |
"message"
|
750 |
"level": "warning",
|
751 |
"audit_countable": true
|
752 |
},
|
|
|
|
|
|
|
|
|
753 |
"conn_not_kill_high_rep": {
|
754 |
"level": "debug"
|
755 |
},
|
767 |
],
|
768 |
"level": "alert"
|
769 |
},
|
770 |
+
"ip_unblock": {
|
771 |
+
"audit_params": [
|
772 |
+
"ip"
|
773 |
+
],
|
774 |
+
"level": "notice",
|
775 |
+
"offense": false,
|
776 |
+
"stat": false
|
777 |
},
|
778 |
"ip_block_auto": {
|
779 |
"audit_params": [
|
859 |
},
|
860 |
"bottrack_invalidscript": {
|
861 |
"audit_params": [
|
862 |
+
"script"
|
863 |
],
|
864 |
"offense": true
|
865 |
},
|
871 |
"level": "info",
|
872 |
"offense": false,
|
873 |
"stat": false
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
874 |
}
|
875 |
}
|
876 |
}
|
config/ips.json
CHANGED
@@ -16,7 +16,7 @@
|
|
16 |
"premium": false,
|
17 |
"run_if_whitelisted": true,
|
18 |
"run_if_verified_bot": true,
|
19 |
-
"run_if_wpcli":
|
20 |
"order": 100
|
21 |
},
|
22 |
"menus": {
|
@@ -767,10 +767,13 @@
|
|
767 |
],
|
768 |
"level": "alert"
|
769 |
},
|
770 |
-
"ip_unblock":
|
771 |
-
"
|
772 |
-
|
773 |
-
|
|
|
|
|
|
|
774 |
},
|
775 |
"ip_block_auto": {
|
776 |
"audit_params": [
|
16 |
"premium": false,
|
17 |
"run_if_whitelisted": true,
|
18 |
"run_if_verified_bot": true,
|
19 |
+
"run_if_wpcli": true,
|
20 |
"order": 100
|
21 |
},
|
22 |
"menus": {
|
767 |
],
|
768 |
"level": "alert"
|
769 |
},
|
770 |
+
"ip_unblock": {
|
771 |
+
"audit_params": [
|
772 |
+
"ip"
|
773 |
+
],
|
774 |
+
"level": "notice",
|
775 |
+
"offense": false,
|
776 |
+
"stat": false
|
777 |
},
|
778 |
"ip_block_auto": {
|
779 |
"audit_params": [
|
icwp-wpsf.php
CHANGED
@@ -3,7 +3,7 @@
|
|
3 |
* Plugin Name: Shield Security
|
4 |
* Plugin URI: https://shsec.io/2f
|
5 |
* Description: Powerful, Easy-To-Use #1 Rated WordPress Security System
|
6 |
-
* Version: 15.1.
|
7 |
* Text Domain: wp-simple-firewall
|
8 |
* Domain Path: /languages
|
9 |
* Author: Shield Security
|
3 |
* Plugin Name: Shield Security
|
4 |
* Plugin URI: https://shsec.io/2f
|
5 |
* Description: Powerful, Easy-To-Use #1 Rated WordPress Security System
|
6 |
+
* Version: 15.1.5
|
7 |
* Text Domain: wp-simple-firewall
|
8 |
* Domain Path: /languages
|
9 |
* Author: Shield Security
|
plugin-spec.php
CHANGED
@@ -1,8 +1,8 @@
|
|
1 |
{
|
2 |
"properties": {
|
3 |
-
"version": "15.1.
|
4 |
-
"release_timestamp":
|
5 |
-
"build": "202206.
|
6 |
"slug_parent": "icwp",
|
7 |
"slug_plugin": "wpsf",
|
8 |
"text_domain": "wp-simple-firewall",
|
1 |
{
|
2 |
"properties": {
|
3 |
+
"version": "15.1.5",
|
4 |
+
"release_timestamp": 1655719000,
|
5 |
+
"build": "202206.2001",
|
6 |
"slug_parent": "icwp",
|
7 |
"slug_plugin": "wpsf",
|
8 |
"text_domain": "wp-simple-firewall",
|
plugin.json
CHANGED
@@ -1,8 +1,8 @@
|
|
1 |
{
|
2 |
"properties": {
|
3 |
-
"version": "15.1.
|
4 |
-
"release_timestamp":
|
5 |
-
"build": "202206.
|
6 |
"slug_parent": "icwp",
|
7 |
"slug_plugin": "wpsf",
|
8 |
"text_domain": "wp-simple-firewall",
|
1 |
{
|
2 |
"properties": {
|
3 |
+
"version": "15.1.5",
|
4 |
+
"release_timestamp": 1655719000,
|
5 |
+
"build": "202206.2001",
|
6 |
"slug_parent": "icwp",
|
7 |
"slug_plugin": "wpsf",
|
8 |
"text_domain": "wp-simple-firewall",
|
readme.txt
CHANGED
@@ -8,13 +8,15 @@ Requires at least: 3.7
|
|
8 |
Requires PHP: 7.0
|
9 |
Recommended PHP: 7.4
|
10 |
Tested up to: 6.0
|
11 |
-
Stable tag: 15.1.
|
12 |
|
13 |
Bad Bots Are Your #1 Security Risk. Malware is a symptom of poor security, not the cause. Discover the advantage of powerful security over marketing.
|
14 |
|
15 |
== Description ==
|
16 |
|
17 |
-
**
|
|
|
|
|
18 |
|
19 |
**Performance is critical**. Shield Security automatically blocks bad IP addresses while optimising performance so your WordPress site never slows down because of bloated security, with large IP lookup tables .
|
20 |
|
8 |
Requires PHP: 7.0
|
9 |
Recommended PHP: 7.4
|
10 |
Tested up to: 6.0
|
11 |
+
Stable tag: 15.1.5
|
12 |
|
13 |
Bad Bots Are Your #1 Security Risk. Malware is a symptom of poor security, not the cause. Discover the advantage of powerful security over marketing.
|
14 |
|
15 |
== Description ==
|
16 |
|
17 |
+
**It's time to stop our obsession with malware**. Malware scanning is important *after* you're hacked. Get a security plugin that [prioritises security *protection* before "malware marketing"](https://shsec.io/ky).
|
18 |
+
|
19 |
+
**No-Nonsense, No-Hype. Just Good Security Protection**. Shield is the only NO-nonsense security solution that defends and protects your WordPress sites against hackers and malicious bots, of all types. With our exclusive invisble "CAPTCHA" technology you can limit login attempts, block brute force attacks and prevent 100% bot comment SPAM.
|
20 |
|
21 |
**Performance is critical**. Shield Security automatically blocks bad IP addresses while optimising performance so your WordPress site never slows down because of bloated security, with large IP lookup tables .
|
22 |
|
src/lib/src/Controller/Controller.php
CHANGED
@@ -273,7 +273,7 @@ class Controller extends DynPropertiesClass {
|
|
273 |
|
274 |
$flag = $this->paths->forFlag( 'reqs_met.flag' );
|
275 |
if ( !$FS->isFile( $flag )
|
276 |
-
|| Services::Request()->carbon()->
|
277 |
$reqsMsg = [];
|
278 |
|
279 |
$minPHP = $this->cfg->requirements[ 'php' ];
|
@@ -339,7 +339,8 @@ class Controller extends DynPropertiesClass {
|
|
339 |
'strings' => [
|
340 |
'not_met' => 'Shield Security Plugin - minimum site requirements are not met',
|
341 |
'requirements' => $this->reqs_not_met,
|
342 |
-
'summary_title' =>
|
|
|
343 |
'more_information' => 'Click here for more information on requirements'
|
344 |
],
|
345 |
'hrefs' => [
|
@@ -1170,7 +1171,7 @@ class Controller extends DynPropertiesClass {
|
|
1170 |
}
|
1171 |
|
1172 |
public function isPremiumActive() :bool {
|
1173 |
-
return $this->getModule_License()->getLicenseHandler()->hasValidWorkingLicense();
|
1174 |
}
|
1175 |
|
1176 |
public function isRelabelled() :bool {
|
273 |
|
274 |
$flag = $this->paths->forFlag( 'reqs_met.flag' );
|
275 |
if ( !$FS->isFile( $flag )
|
276 |
+
|| Services::Request()->carbon()->subHours( 1 )->timestamp > $FS->getModifiedTime( $flag ) ) {
|
277 |
$reqsMsg = [];
|
278 |
|
279 |
$minPHP = $this->cfg->requirements[ 'php' ];
|
339 |
'strings' => [
|
340 |
'not_met' => 'Shield Security Plugin - minimum site requirements are not met',
|
341 |
'requirements' => $this->reqs_not_met,
|
342 |
+
'summary_title' => "Your web hosting doesn't meet the minimum requirements for the Shield Security Plugin.",
|
343 |
+
'recommend' => "We highly recommend upgrading your web hosting components as they're probably quite out-of-date.",
|
344 |
'more_information' => 'Click here for more information on requirements'
|
345 |
],
|
346 |
'hrefs' => [
|
1171 |
}
|
1172 |
|
1173 |
public function isPremiumActive() :bool {
|
1174 |
+
return $this->modules_loaded && $this->getModule_License()->getLicenseHandler()->hasValidWorkingLicense();
|
1175 |
}
|
1176 |
|
1177 |
public function isRelabelled() :bool {
|
src/lib/src/Modules/IPs/Lib/Ops/DeleteIp.php
CHANGED
@@ -12,7 +12,7 @@ class DeleteIp {
|
|
12 |
use IPs\Components\IpAddressConsumer;
|
13 |
|
14 |
public function fromBlacklist() :bool {
|
15 |
-
$this->getCon()->fireEvent( 'ip_unblock' );
|
16 |
return (bool)$this->getDeleter()
|
17 |
->filterByBlacklist()
|
18 |
->query();
|
12 |
use IPs\Components\IpAddressConsumer;
|
13 |
|
14 |
public function fromBlacklist() :bool {
|
15 |
+
$this->getCon()->fireEvent( 'ip_unblock', [ 'audit_params' => [ 'ip' => $this->getIP() ] ] );
|
16 |
return (bool)$this->getDeleter()
|
17 |
->filterByBlacklist()
|
18 |
->query();
|
src/lib/src/Modules/License/Lib/WpHashes/ApiTokenManager.php
CHANGED
@@ -50,7 +50,10 @@ class ApiTokenManager {
|
|
50 |
if ( $this->isExpired() && $this->canRequestNewToken() ) {
|
51 |
$token = $this->loadToken();
|
52 |
try {
|
53 |
-
$token = array_merge( $token,
|
|
|
|
|
|
|
54 |
}
|
55 |
catch ( \Exception $e ) {
|
56 |
}
|
50 |
if ( $this->isExpired() && $this->canRequestNewToken() ) {
|
51 |
$token = $this->loadToken();
|
52 |
try {
|
53 |
+
$token = array_merge( $token,
|
54 |
+
array_intersect_key( $this->solicitApiToken(),
|
55 |
+
array_flip( [ 'token', 'expires_at', 'valid_license' ] ) )
|
56 |
+
);
|
57 |
}
|
58 |
catch ( \Exception $e ) {
|
59 |
}
|
src/lib/src/Modules/Plugin/AjaxHandler.php
CHANGED
@@ -48,6 +48,7 @@ class AjaxHandler extends Shield\Modules\BaseShield\AjaxHandler {
|
|
48 |
$dbMisconfigured = count( $checks[ 'dbs' ] ) !== count( array_filter( $checks[ 'dbs' ] ) );
|
49 |
|
50 |
if ( $dbMisconfigured ) {
|
|
|
51 |
/** @var Handler[] $allHandlers */
|
52 |
$allHandlers = [
|
53 |
$con->getModule_AuditTrail()->getDbH_Logs(),
|
@@ -56,6 +57,11 @@ class AjaxHandler extends Shield\Modules\BaseShield\AjaxHandler {
|
|
56 |
$con->getModule_Data()->getDbH_ReqLogs(),
|
57 |
$con->getModule_Data()->getDbH_UserMeta(),
|
58 |
$con->getModule_IPs()->getDbH_BotSignal(),
|
|
|
|
|
|
|
|
|
|
|
59 |
];
|
60 |
Services::WpDb()->doSql(
|
61 |
sprintf( 'DROP TABLE IF EXISTS `%s`', implode( '`,`', array_map(
|
48 |
$dbMisconfigured = count( $checks[ 'dbs' ] ) !== count( array_filter( $checks[ 'dbs' ] ) );
|
49 |
|
50 |
if ( $dbMisconfigured ) {
|
51 |
+
$modHG = $con->getModule_HackGuard();
|
52 |
/** @var Handler[] $allHandlers */
|
53 |
$allHandlers = [
|
54 |
$con->getModule_AuditTrail()->getDbH_Logs(),
|
57 |
$con->getModule_Data()->getDbH_ReqLogs(),
|
58 |
$con->getModule_Data()->getDbH_UserMeta(),
|
59 |
$con->getModule_IPs()->getDbH_BotSignal(),
|
60 |
+
$modHG->getDbH_Scans(),
|
61 |
+
$modHG->getDbH_ScanItems(),
|
62 |
+
$modHG->getDbH_ScanResults(),
|
63 |
+
$modHG->getDbH_ResultItems(),
|
64 |
+
$modHG->getDbH_ResultItemMeta()
|
65 |
];
|
66 |
Services::WpDb()->doSql(
|
67 |
sprintf( 'DROP TABLE IF EXISTS `%s`', implode( '`,`', array_map(
|
src/lib/src/ShieldNetApi/WPHashes/SolicitToken.php
CHANGED
@@ -11,11 +11,12 @@ class SolicitToken extends Common\BaseShieldNetApi {
|
|
11 |
|
12 |
public function send() :array {
|
13 |
$this->shield_net_params_required = false;
|
|
|
14 |
$this->params_query = [
|
15 |
'url' => Services::WpGeneral()->getHomeUrl()
|
16 |
];
|
17 |
$raw = $this->sendReq();
|
18 |
-
return ( !empty( $raw ) && is_array( $raw[ '
|
19 |
}
|
20 |
|
21 |
protected function getApiRequestUrl() :string {
|
11 |
|
12 |
public function send() :array {
|
13 |
$this->shield_net_params_required = false;
|
14 |
+
$this->api_version = '2';
|
15 |
$this->params_query = [
|
16 |
'url' => Services::WpGeneral()->getHomeUrl()
|
17 |
];
|
18 |
$raw = $this->sendReq();
|
19 |
+
return ( !empty( $raw ) && is_array( $raw ) && !empty( $raw[ 'token' ] ) ) ? $raw : [];
|
20 |
}
|
21 |
|
22 |
protected function getApiRequestUrl() :string {
|
src/lib/vendor/fernleafsystems/wordpress-services/src/Utilities/Licenses/Keyless/Lookup.php
CHANGED
@@ -46,6 +46,7 @@ class Lookup extends Base {
|
|
46 |
'url',
|
47 |
'nonce',
|
48 |
'meta',
|
|
|
49 |
];
|
50 |
}
|
51 |
}
|
46 |
'url',
|
47 |
'nonce',
|
48 |
'meta',
|
49 |
+
'old_install_id', // Can remove this eventually
|
50 |
];
|
51 |
}
|
52 |
}
|
templates/twig/notices/does-not-meet-requirements.twig
CHANGED
@@ -1,7 +1,8 @@
|
|
1 |
{% extends "/notices/base-error.twig" %}
|
2 |
|
3 |
{% block notice_body %}
|
4 |
-
{{ strings.summary_title }}
|
|
|
5 |
<ul style="list-style: inside none disc;">
|
6 |
{% for req in strings.requirements %}
|
7 |
<li>{{ req }}</li>
|
1 |
{% extends "/notices/base-error.twig" %}
|
2 |
|
3 |
{% block notice_body %}
|
4 |
+
<p>{{ strings.summary_title }}</p>
|
5 |
+
<p>{{ strings.recommend }}</p>
|
6 |
<ul style="list-style: inside none disc;">
|
7 |
{% for req in strings.requirements %}
|
8 |
<li>{{ req }}</li>
|