WP Security Audit Log - Version 4.1.3

Version Description

(2020-08-11) =

Release notes: WP Activity Log 4.1.3: New extension for WooCommerce & other updates

  • IMPORTANT

    • Only update from 4.1.2 to 4.1.3. If you are using an older version, first update to 4.1.2 before updating to 4.1.3.
  • New features

    • The all new WP Activity Log for WooCommerce extension (needed to keep a log of changes on WooCommerce store, products, orders & much more).
    • New plugin and activity log privileges that allow super admins on a multisite network to restrict activity log access to site admins and other super admins.
    • Coverage for changes done to relationship custom fields created with ACF.
  • New activity log events

    • ID 2131: Added relationships in a custom field.
    • ID 2132: Removed relationships from a custom field.
    • ID 9101: Created new product tag in WooCommerce.
    • ID 9102: Deleted a product tag in WooCommerce.
    • ID 9103: Renamed a product tag in WooCommerce.
    • ID 9104: Changed the slug of a product tag in WooCommerce.

Refer to the complete list of activity log event IDs for more detailed information.

  • Improvements

    • Improved the plugin's coverage of WooCommerce stores, products, orders etc by adding new events, and updating the current sensor.
    • Plugin now uses the default WordPress options table to store settings (performance enhancement).
    • Refactored all settings in the database so they all use yes/no values.
    • Restricted the plugin's and activity log settings to the network dashboard only on a multisite network.
    • Change in wp_wsal_sessions table structure: now plugin uses session ID as unique identifier in table.
    • Plugin keeps the ID of the sites a user is logged in to on a multisite network.
    • Removed the Import/Export plugin settings functionality (a much better utility will be designed and launched as a replacement).
    • File changes detected by the Website File Changes Monitor plugin are now reported in the daily summary email.
    • Log files working directory in uploads directory renamed to wp-activity-log.
    • If no path is specified for the log files working directory, the default path is used.
    • Improved activity log privileges - on multisite super admin can restrict site admins from seeing their own site's activity logs.
    • WooCommerce front end sensor is automatically enabled if admin enables events to track purchases of non-logged in users.
    • Improved the text of the third party plugins extensions notifications.
    • Updated the format of event IDs 9070 and 4020 to matches the standard template.
    • Coverage of WooCommerce coupon changes has been improved andplugin can now keep a log of usage restriction changes in coupons.
    • IP address in list of logged in users is now linked to WhatIsMyIPAddress.com.
    • Added a message for when no sessions are shown in the Logged In users section.
    • Minor changes in the plugin's settings pages.
    • Updated some notifications used by the third party plugins extensions.
    • Third party plugins extensions are now automatically activated on multsite network when installed.
    • Removed all code that was used for file scanning. Now plugin is fully integrated with Website File Changes Monitor.
  • Bug fixes

    • Extensions notifications were wrongly shown to sub sites admins on multisite.
    • Event 1002 (failed user login) was wrongly reported when a user session is blocked.
    • When the setting Delete data on uninstall was enabled the plugin was not deleting all the data from the database.
    • Event ID 1002 (failed user login) incorrectly links to log file.
    • Plugin does not send logs to Activity Log for MainWP extension when child site uses a non-default admin URL.
    • Error when loading user session tokens from usermeta table in some cases.
    • Users sessions table was moved to external database when activity log is stored in an external database.
    • Plugin was reporting event ID 1000 (login) when user changes own password in user profile page.
    • Plugin's log files working directory was hardcoded (uploads directory).
    • When super admins changed the plugin's settings on a child site, the settings were not applied globally.
    • Users who are allowed to view the activity log can also see who is logged in.
    • The old plugin name was shown on the daily summary email template.
    • Plugin created working directory in wrong location when site address is different than WordPress address.
    • Setup wizard shows all the extensions for third party plugins instead of those for the installed plugins.
    • Wrong anchor text "view post in editor" used for WooCommerce products.
    • Unknown object reported instead of actual Object in some of the WPForms activity log events.
    • Event ID 2080 not reported when the last item was removed from the site menu.
    • Plugin logo missing from license activation screen.
    • Website File Changes Monitor custom posts type changes were reported (these are ignored by default).

Refer to the complete plugin changelog for more detailed information about what was new, improved and fixed in previous versions of the WP Activity Log plugin.

Download this release

Release Info

Developer WPWhiteSecurity
Plugin Icon 128x128 WP Security Audit Log
Version 4.1.3
Comparing to
See all releases

Code changes from version 4.1.2 to 4.1.3

Files changed (57) hide show
  1. classes/AbstractMetaDataSensor.php +115 -0
  2. classes/AbstractSensor.php +2 -0
  3. classes/AbstractView.php +1 -1
  4. classes/Adapters/MySQL/ActiveRecordAdapter.php +19 -0
  5. classes/Adapters/MySQL/OptionAdapter.php +19 -0
  6. classes/Alert.php +7 -0
  7. classes/AlertManager.php +34 -39
  8. classes/AuditLogGridView.php +23 -23
  9. classes/AuditLogListView.php +23 -23
  10. classes/Connector/AbstractConnector.php +0 -5
  11. classes/Connector/ConnectorFactory.php +7 -10
  12. classes/Connector/MySQLDB.php +13 -5
  13. classes/Helpers/Options.php +189 -39
  14. classes/Loggers/Database.php +13 -13
  15. classes/Models/Occurrence.php +5 -1
  16. classes/Models/Option.php +11 -2
  17. classes/SensorManager.php +5 -6
  18. classes/Sensors/ACFMeta.php +156 -0
  19. classes/Sensors/Content.php +2 -2
  20. classes/Sensors/Database.php +223 -120
  21. classes/Sensors/FrontendLogin.php +2 -2
  22. classes/Sensors/FrontendSystem.php +15 -18
  23. classes/Sensors/FrontendWooCommerce.php +21 -2
  24. classes/Sensors/LogInOut.php +44 -51
  25. classes/Sensors/Menus.php +4 -4
  26. classes/Sensors/MetaData.php +13 -90
  27. classes/Sensors/PhpErrors.php +3 -3
  28. classes/Sensors/PluginsThemes.php +13 -13
  29. classes/Sensors/Public.php +21 -2
  30. classes/Sensors/Request.php +4 -5
  31. classes/Sensors/System.php +93 -98
  32. classes/Settings.php +427 -240
  33. classes/Uninstall.php +17 -0
  34. classes/Update/Task/MoveSettingsToOptionsTable.php +59 -22
  35. classes/Utilities/Emailer.php +6 -6
  36. classes/Utilities/PluginInstallAndActivate.php +12 -3
  37. classes/Utilities/PluginInstallerAction.php +17 -3
  38. classes/ViewManager.php +40 -129
  39. classes/Views/AuditLog.php +59 -67
  40. classes/Views/ExternalDB.php +1 -1
  41. classes/Views/Help.php +5 -5
  42. classes/Views/Settings.php +696 -807
  43. classes/Views/SetupWizard.php +42 -28
  44. classes/Views/ToggleAlerts.php +52 -91
  45. classes/WidgetManager.php +3 -3
  46. defaults.php +33 -139
  47. img/addons/woocommerce.png +0 -0
  48. img/mails/daily-notification/alert-icon.png +0 -0
  49. img/mails/daily-notification/logo.png +0 -0
  50. js/auditlog-pointer.js +1 -2
  51. js/settings.js +44 -334
  52. languages/wp-security-audit-log.pot +1222 -2202
  53. readme.txt +274 -222
  54. sdk/freemius/assets/img/plugin-icon.png +0 -0
  55. sdk/freemius/assets/img/wp-security-audit-log.png +0 -0
  56. sdk/wsal-freemius.php +2 -1
  57. wp-security-audit-log.php +550 -133
classes/AbstractMetaDataSensor.php ADDED
@@ -0,0 +1,115 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ /**
3
+ * Sensor: Abstract meta data
4
+ *
5
+ * Abstract meta data sensor file.
6
+ *
7
+ * @since 4.1.3
8
+ * @package Wsal
9
+ */
10
+
11
+ // Exit if accessed directly.
12
+ if ( ! defined( 'ABSPATH' ) ) {
13
+ exit;
14
+ }
15
+
16
+ /**
17
+ * Abstract sensor for meta data.
18
+ *
19
+ * @package Wsal
20
+ * @subpackage Sensors
21
+ * @since 4.1.3
22
+ */
23
+ abstract class WSAL_AbstractMetaDataSensor extends WSAL_AbstractSensor {
24
+
25
+ /**
26
+ * Array of meta data being updated.
27
+ *
28
+ * @var array
29
+ */
30
+ protected $old_meta = array();
31
+
32
+ /**
33
+ * Check "Excluded Custom Fields" or meta keys starts with "_".
34
+ *
35
+ * @param int $object_id - Object ID.
36
+ * @param string $meta_key - Meta key.
37
+ *
38
+ * @return boolean can log true|false
39
+ */
40
+ protected function CanLogMetaKey( $object_id, $meta_key ) {
41
+ // Check if excluded meta key or starts with _.
42
+ if ( '_' === substr( $meta_key, 0, 1 ) ) {
43
+ /**
44
+ * List of hidden keys allowed to log.
45
+ *
46
+ * @since 3.4.1
47
+ */
48
+ $log_hidden_keys = apply_filters( 'wsal_log_hidden_meta_keys', array() );
49
+
50
+ // If the meta key is allowed to log then return true.
51
+ if ( in_array( $meta_key, $log_hidden_keys, true ) ) {
52
+ return true;
53
+ }
54
+
55
+ return false;
56
+ } elseif ( $this->IsExcludedCustomFields( $meta_key ) ) {
57
+ return false;
58
+ } else {
59
+ return true;
60
+ }
61
+ }
62
+
63
+ /**
64
+ * Get editor link.
65
+ *
66
+ * @param stdClass|int $post - The post.
67
+ *
68
+ * @return array $editor_link - Name and value link
69
+ */
70
+ protected function GetEditorLink( $post ) {
71
+ $post_id = is_int( $post ) ? intval( $post ) : $post->ID;
72
+ return array(
73
+ 'name' => 'EditorLinkPost',
74
+ 'value' => get_edit_post_link( $post_id ),
75
+ );
76
+ }
77
+
78
+ /**
79
+ * Check "Excluded Custom Fields".
80
+ * Used in the above function.
81
+ *
82
+ * @param string $custom - Custom meta key.
83
+ *
84
+ * @return boolean is excluded from monitoring true|false
85
+ */
86
+ public function IsExcludedCustomFields( $custom ) {
87
+ $custom_fields = $this->plugin->settings()->GetExcludedMonitoringCustom();
88
+
89
+ if ( in_array( $custom, $custom_fields ) ) {
90
+ return true;
91
+ }
92
+
93
+ foreach ( $custom_fields as $field ) {
94
+ if ( false !== strpos( $field, '*' ) ) {
95
+ // Wildcard str[any_character] when you enter (str*).
96
+ if ( substr( $field, - 1 ) == '*' ) {
97
+ $field = rtrim( $field, '*' );
98
+ if ( preg_match( "/^$field/", $custom ) ) {
99
+ return true;
100
+ }
101
+ }
102
+
103
+ // Wildcard [any_character]str when you enter (*str).
104
+ if ( '*' === substr( $field, 0, 1 ) ) {
105
+ $field = ltrim( $field, '*' );
106
+ if ( preg_match( "/$field$/", $custom ) ) {
107
+ return true;
108
+ }
109
+ }
110
+ }
111
+ }
112
+
113
+ return false;
114
+ }
115
+ }
classes/AbstractSensor.php CHANGED
@@ -102,6 +102,7 @@ abstract class WSAL_AbstractSensor {
102
  * Check to see whether or not the specified directory is accessible.
103
  *
104
  * @param string $dir_path - Directory path.
 
105
  * @return boolean
106
  */
107
  protected function CheckDirectory( $dir_path ) {
@@ -114,6 +115,7 @@ abstract class WSAL_AbstractSensor {
114
  if ( ! is_writable( $dir_path ) ) {
115
  return false;
116
  }
 
117
  return true;
118
  }
119
  }
102
  * Check to see whether or not the specified directory is accessible.
103
  *
104
  * @param string $dir_path - Directory path.
105
+ *
106
  * @return boolean
107
  */
108
  protected function CheckDirectory( $dir_path ) {
115
  if ( ! is_writable( $dir_path ) ) {
116
  return false;
117
  }
118
+
119
  return true;
120
  }
121
  }
classes/AbstractView.php CHANGED
@@ -67,7 +67,7 @@ abstract class WSAL_AbstractView {
67
  * @internal
68
  */
69
  public function AjaxDismissNotice() {
70
- if ( ! $this->_plugin->settings->CurrentUserCan( 'view' ) ) {
71
  die( 'Access Denied.' );
72
  }
73
 
67
  * @internal
68
  */
69
  public function AjaxDismissNotice() {
70
+ if ( ! $this->_plugin->settings()->CurrentUserCan( 'view' ) ) {
71
  die( 'Access Denied.' );
72
  }
73
 
classes/Adapters/MySQL/ActiveRecordAdapter.php CHANGED
@@ -885,4 +885,23 @@ class WSAL_Adapters_MySQL_ActiveRecord implements WSAL_Adapters_ActiveRecordInte
885
  $sql = rtrim( $sql, ', ' );
886
  $_wpdb->query( $sql );
887
  }
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
888
  }
885
  $sql = rtrim( $sql, ', ' );
886
  $_wpdb->query( $sql );
887
  }
888
+
889
+ /**
890
+ * Updates records in DB matching a query.
891
+ *
892
+ * @param string $table Table name
893
+ * @param array $data Data to update (in column => value pairs).
894
+ * Both $data columns and $data values should be "raw" (neither should be SQL escaped).
895
+ * Sending a null value will cause the column to be set to NULL - the corresponding
896
+ * format is ignored in this case.
897
+ * @param array $where A named array of WHERE clauses (in column => value pairs).
898
+ * Multiple clauses will be joined with ANDs.
899
+ * Both $where columns and $where values should be "raw".
900
+ * Sending a null value will create an IS NULL comparison - the corresponding format will be ignored in this case.
901
+ * @return int|false The number of rows updated, or false on error.
902
+ * @since 4.1.3
903
+ */
904
+ public function UpdateQuery( $table, $data, $where ) {
905
+ return $this->connection->update( $table, $data, $where );
906
+ }
907
  }
classes/Adapters/MySQL/OptionAdapter.php CHANGED
@@ -182,4 +182,23 @@ class WSAL_Adapters_MySQL_Option extends WSAL_Adapters_MySQL_ActiveRecord {
182
  $db_connection->query( 'CREATE INDEX option_name ON ' . $this->GetTable() . ' (option_name)' );
183
  }
184
  }
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
185
  }
182
  $db_connection->query( 'CREATE INDEX option_name ON ' . $this->GetTable() . ' (option_name)' );
183
  }
184
  }
185
+
186
+ /**
187
+ * Renames option,
188
+ *
189
+ * @param $old_name
190
+ * @param $new_name
191
+ *
192
+ * @return false|int
193
+ * @since 4.1.3
194
+ */
195
+ public function Rename( $old_name, $new_name ) {
196
+ return parent::UpdateQuery(
197
+ $this->GetTable(), [
198
+ 'option_name' => $new_name
199
+ ], [
200
+ 'option_name' => $old_name
201
+ ]
202
+ );
203
+ }
204
  }
classes/Alert.php CHANGED
@@ -92,6 +92,13 @@ final class WSAL_Alert {
92
  * @return mixed The value nearest to the expression.
93
  */
94
  protected function GetMetaExprValue( $expr, $meta_data = array() ) {
 
 
 
 
 
 
 
95
  // TODO: Handle function calls (and methods?).
96
  $expr = explode( '->', $expr );
97
  $meta = array_shift( $expr );
92
  * @return mixed The value nearest to the expression.
93
  */
94
  protected function GetMetaExprValue( $expr, $meta_data = array() ) {
95
+ if ( 'IPAddress' == $expr ) {
96
+ if (array_key_exists( 'IPAddress', $meta_data ) ) {
97
+ return implode( ', ', $meta_data['IPAddress'] );
98
+ }
99
+ return null;
100
+ }
101
+
102
  // TODO: Handle function calls (and methods?).
103
  $expr = explode( '->', $expr );
104
  $meta = array_shift( $expr );
classes/AlertManager.php CHANGED
@@ -125,24 +125,22 @@ final class WSAL_AlertManager {
125
  */
126
  $this->ignored_cpts = apply_filters(
127
  'wsal_ignored_custom_post_types',
128
- array(
129
- 'attachment', // Attachment CPT.
130
- 'revision', // Revision CPT.
131
- 'nav_menu_item', // Nav menu item CPT.
132
- 'customize_changeset', // Customize changeset CPT.
133
- 'custom_css', // Custom CSS CPT.
134
- 'product', // WooCommerce Product CPT.
135
- 'shop_coupon', // WooCommerse Coupon CPT.
136
- 'shop_order', // WooCommerce Order CPT.
137
- 'shop_order_refund', // WooCommerce Order Refund CPT.
138
- 'product_variation', // WooCommerce Product Variation CPT.
139
- 'wc_product_tab', // WooCommerce Product Tab CPT.
140
  )
141
  );
142
 
143
- $this->date_format = $this->plugin->settings->GetDateFormat();
144
- $this->datetime_format = $this->plugin->settings->GetDatetimeFormat( false );
145
- $timezone = $this->plugin->settings->GetTimezone();
146
 
147
  if ( '0' === $timezone ) {
148
  $timezone = 'utc';
@@ -163,7 +161,7 @@ final class WSAL_AlertManager {
163
  */
164
  public function schedule_log_events() {
165
  // Get external buffer option.
166
- $use_buffer = $this->plugin->GetGlobalOption( 'adapter-use-buffer' );
167
 
168
  // If external DB buffer is enabled then set the cron.
169
  if ( $use_buffer ) {
@@ -233,7 +231,7 @@ final class WSAL_AlertManager {
233
  */
234
  public function Trigger( $type, $data = array(), $delayed = false ) {
235
  // Get buffer use option.
236
- $use_buffer = $this->plugin->GetGlobalOption( 'adapter-use-buffer' );
237
 
238
  // Log temporary alerts first.
239
  if ( ! $use_buffer ) {
@@ -268,7 +266,7 @@ final class WSAL_AlertManager {
268
  $data['CurrentUserRoles'] = $roles;
269
  } else {
270
  // not a switched user so get the current user roles.
271
- $roles = $this->plugin->settings->GetCurrentUserRoles();
272
  }
273
  if ( empty( $roles ) && ! empty( $data['CurrentUserRoles'] ) ) {
274
  $roles = $data['CurrentUserRoles'];
@@ -324,7 +322,7 @@ final class WSAL_AlertManager {
324
  */
325
  public function TriggerIf( $type, $data, $cond = null ) {
326
  $username = wp_get_current_user()->user_login;
327
- $roles = $this->plugin->settings->GetCurrentUserRoles();
328
 
329
  if ( $this->CheckEnableUserRoles( $username, $roles ) ) {
330
  $this->_pipeline[] = array(
@@ -519,7 +517,7 @@ final class WSAL_AlertManager {
519
  * @param int[] $types Alert type codes to be disabled.
520
  */
521
  public function SetDisabledAlerts( $types ) {
522
- $this->plugin->settings->SetDisabledAlerts( $types );
523
  }
524
 
525
  /**
@@ -528,7 +526,7 @@ final class WSAL_AlertManager {
528
  * @return int[]
529
  */
530
  public function GetDisabledAlerts() {
531
- return $this->plugin->settings->GetDisabledAlerts();
532
  }
533
 
534
  /**
@@ -549,13 +547,13 @@ final class WSAL_AlertManager {
549
  */
550
  protected function Log( $event_id, $event_data = array() ) {
551
  if ( ! isset( $event_data['ClientIP'] ) ) {
552
- $client_ip = $this->plugin->settings->GetMainClientIP();
553
  if ( ! empty( $client_ip ) ) {
554
  $event_data['ClientIP'] = $client_ip;
555
  }
556
  }
557
- if ( ! isset( $event_data['OtherIPs'] ) && $this->plugin->settings->IsMainIPFromProxy() ) {
558
- $other_ips = $this->plugin->settings->GetClientIPs();
559
  if ( ! empty( $other_ips ) ) {
560
  $event_data['OtherIPs'] = $other_ips;
561
  }
@@ -571,7 +569,7 @@ final class WSAL_AlertManager {
571
  }
572
  }
573
  if ( ! isset( $event_data['CurrentUserRoles'] ) && function_exists( 'is_user_logged_in' ) && is_user_logged_in() ) {
574
- $current_user_roles = $this->plugin->settings->GetCurrentUserRoles();
575
  if ( ! empty( $current_user_roles ) ) {
576
  $event_data['CurrentUserRoles'] = $current_user_roles;
577
  }
@@ -779,7 +777,7 @@ final class WSAL_AlertManager {
779
  * @return array.
780
  */
781
  public function GetDisabledUsers() {
782
- return $this->plugin->settings->GetExcludedMonitoringUsers();
783
  }
784
 
785
  /**
@@ -804,7 +802,7 @@ final class WSAL_AlertManager {
804
  * @return array
805
  */
806
  public function GetDisabledRoles() {
807
- return $this->plugin->settings->GetExcludedMonitoringRoles();
808
  }
809
 
810
  /**
@@ -825,7 +823,7 @@ final class WSAL_AlertManager {
825
  * @since 2.6.7
826
  */
827
  public function get_disabled_post_types() {
828
- return $this->plugin->settings->get_excluded_post_types();
829
  }
830
 
831
  /**
@@ -833,16 +831,16 @@ final class WSAL_AlertManager {
833
  */
834
  private function IsDisabledIP() {
835
  $is_disabled = false;
836
- $ip = $this->plugin->settings->GetMainClientIP();
837
- $excluded_ips = $this->plugin->settings->GetExcludedMonitoringIP();
838
 
839
  if ( ! empty( $excluded_ips ) ) {
840
  foreach ( $excluded_ips as $excluded_ip ) {
841
  if ( false !== strpos( $excluded_ip, '-' ) ) {
842
- $ip_range = $this->plugin->settings->get_ipv4_by_range( $excluded_ip );
843
  $ip_range = $ip_range->lower . '-' . $ip_range->upper;
844
 
845
- if ( $this->plugin->settings->check_ipv4_in_range( $ip, $ip_range ) ) {
846
  $is_disabled = true;
847
  break;
848
  }
@@ -864,7 +862,7 @@ final class WSAL_AlertManager {
864
  */
865
  public function log_temp_alerts() {
866
  // Get temporary alerts.
867
- $temp_alerts = get_option( 'wsal_temp_alerts', array() );
868
 
869
  if ( empty( $temp_alerts ) ) {
870
  return;
@@ -897,7 +895,7 @@ final class WSAL_AlertManager {
897
  }
898
 
899
  // Delete temporary alerts.
900
- delete_option( 'wsal_temp_alerts' );
901
  return true;
902
  }
903
  }
@@ -944,6 +942,7 @@ final class WSAL_AlertManager {
944
  }
945
 
946
  // Execute the query.
 
947
  $events = $events_query->getAdapter()->Execute( $events_query );
948
 
949
  if ( ! empty( $events ) && is_array( $events ) ) {
@@ -1033,7 +1032,7 @@ final class WSAL_AlertManager {
1033
  $occ_query = new WSAL_Models_OccurrenceQuery();
1034
 
1035
  // Get site id.
1036
- $site_id = (int) $this->plugin->settings->get_view_site_id();
1037
  if ( $site_id ) {
1038
  $occ_query->addCondition( 'site_id = %d ', $site_id );
1039
  }
@@ -1115,10 +1114,6 @@ final class WSAL_AlertManager {
1115
  'setting' => __( 'Setting', 'wp-security-audit-log' ),
1116
  'file' => __( 'File', 'wp-security-audit-log' ),
1117
  'system-setting' => __( 'System Setting', 'wp-security-audit-log' ),
1118
- 'woocommerce-product' => __( 'WooCommerce Product', 'wp-security-audit-log' ),
1119
- 'woocommerce-store' => __( 'WooCommerce Store', 'wp-security-audit-log' ),
1120
- 'woocommerce-coupon' => __( 'WooCommerce Coupon', 'wp-security-audit-log' ),
1121
- 'woocommerce-category' => __( 'WooCommerce Category', 'wp-security-audit-log' ),
1122
  'mainwp-network' => __( 'MainWP Network', 'wp-security-audit-log' ),
1123
  'mainwp' => __( 'MainWP', 'wp-security-audit-log' ),
1124
  'yoast-seo' => __( 'Yoast SEO', 'wp-security-audit-log' ),
125
  */
126
  $this->ignored_cpts = apply_filters(
127
  'wsal_ignored_custom_post_types',
128
+ array_unique(
129
+ array_merge(
130
+ $this->get_disabled_post_types(), array(
131
+ 'attachment', // Attachment CPT.
132
+ 'revision', // Revision CPT.
133
+ 'nav_menu_item', // Nav menu item CPT.
134
+ 'customize_changeset', // Customize changeset CPT.
135
+ 'custom_css', // Custom CSS CPT.
136
+ )
137
+ )
 
 
138
  )
139
  );
140
 
141
+ $this->date_format = $this->plugin->settings()->GetDateFormat();
142
+ $this->datetime_format = $this->plugin->settings()->GetDatetimeFormat( false );
143
+ $timezone = $this->plugin->settings()->GetTimezone();
144
 
145
  if ( '0' === $timezone ) {
146
  $timezone = 'utc';
161
  */
162
  public function schedule_log_events() {
163
  // Get external buffer option.
164
+ $use_buffer = $this->plugin->GetGlobalBooleanSetting( 'adapter-use-buffer' );
165
 
166
  // If external DB buffer is enabled then set the cron.
167
  if ( $use_buffer ) {
231
  */
232
  public function Trigger( $type, $data = array(), $delayed = false ) {
233
  // Get buffer use option.
234
+ $use_buffer = $this->plugin->GetGlobalBooleanSetting( 'adapter-use-buffer' );
235
 
236
  // Log temporary alerts first.
237
  if ( ! $use_buffer ) {
266
  $data['CurrentUserRoles'] = $roles;
267
  } else {
268
  // not a switched user so get the current user roles.
269
+ $roles = $this->plugin->settings()->GetCurrentUserRoles();
270
  }
271
  if ( empty( $roles ) && ! empty( $data['CurrentUserRoles'] ) ) {
272
  $roles = $data['CurrentUserRoles'];
322
  */
323
  public function TriggerIf( $type, $data, $cond = null ) {
324
  $username = wp_get_current_user()->user_login;
325
+ $roles = $this->plugin->settings()->GetCurrentUserRoles();
326
 
327
  if ( $this->CheckEnableUserRoles( $username, $roles ) ) {
328
  $this->_pipeline[] = array(
517
  * @param int[] $types Alert type codes to be disabled.
518
  */
519
  public function SetDisabledAlerts( $types ) {
520
+ $this->plugin->settings()->SetDisabledAlerts( $types );
521
  }
522
 
523
  /**
526
  * @return int[]
527
  */
528
  public function GetDisabledAlerts() {
529
+ return $this->plugin->settings()->GetDisabledAlerts();
530
  }
531
 
532
  /**
547
  */
548
  protected function Log( $event_id, $event_data = array() ) {
549
  if ( ! isset( $event_data['ClientIP'] ) ) {
550
+ $client_ip = $this->plugin->settings()->GetMainClientIP();
551
  if ( ! empty( $client_ip ) ) {
552
  $event_data['ClientIP'] = $client_ip;
553
  }
554
  }
555
+ if ( ! isset( $event_data['OtherIPs'] ) && $this->plugin->settings()->IsMainIPFromProxy() ) {
556
+ $other_ips = $this->plugin->settings()->GetClientIPs();
557
  if ( ! empty( $other_ips ) ) {
558
  $event_data['OtherIPs'] = $other_ips;
559
  }
569
  }
570
  }
571
  if ( ! isset( $event_data['CurrentUserRoles'] ) && function_exists( 'is_user_logged_in' ) && is_user_logged_in() ) {
572
+ $current_user_roles = $this->plugin->settings()->GetCurrentUserRoles();
573
  if ( ! empty( $current_user_roles ) ) {
574
  $event_data['CurrentUserRoles'] = $current_user_roles;
575
  }
777
  * @return array.
778
  */
779
  public function GetDisabledUsers() {
780
+ return $this->plugin->settings()->GetExcludedMonitoringUsers();
781
  }
782
 
783
  /**
802
  * @return array
803
  */
804
  public function GetDisabledRoles() {
805
+ return $this->plugin->settings()->GetExcludedMonitoringRoles();
806
  }
807
 
808
  /**
823
  * @since 2.6.7
824
  */
825
  public function get_disabled_post_types() {
826
+ return $this->plugin->settings()->get_excluded_post_types();
827
  }
828
 
829
  /**
831
  */
832
  private function IsDisabledIP() {
833
  $is_disabled = false;
834
+ $ip = $this->plugin->settings()->GetMainClientIP();
835
+ $excluded_ips = $this->plugin->settings()->GetExcludedMonitoringIP();
836
 
837
  if ( ! empty( $excluded_ips ) ) {
838
  foreach ( $excluded_ips as $excluded_ip ) {
839
  if ( false !== strpos( $excluded_ip, '-' ) ) {
840
+ $ip_range = $this->plugin->settings()->get_ipv4_by_range( $excluded_ip );
841
  $ip_range = $ip_range->lower . '-' . $ip_range->upper;
842
 
843
+ if ( $this->plugin->settings()->check_ipv4_in_range( $ip, $ip_range ) ) {
844
  $is_disabled = true;
845
  break;
846
  }
862
  */
863
  public function log_temp_alerts() {
864
  // Get temporary alerts.
865
+ $temp_alerts = $this->plugin->GetGlobalSetting('temp_alerts', array() );
866
 
867
  if ( empty( $temp_alerts ) ) {
868
  return;
895
  }
896
 
897
  // Delete temporary alerts.
898
+ $this->plugin->options_helper->delete_option( 'wsal_temp_alerts' );
899
  return true;
900
  }
901
  }
942
  }
943
 
944
  // Execute the query.
945
+ /** @var \WSAL\MainWPExtension\Models\Occurrence[] $events */
946
  $events = $events_query->getAdapter()->Execute( $events_query );
947
 
948
  if ( ! empty( $events ) && is_array( $events ) ) {
1032
  $occ_query = new WSAL_Models_OccurrenceQuery();
1033
 
1034
  // Get site id.
1035
+ $site_id = (int) $this->plugin->settings()->get_view_site_id();
1036
  if ( $site_id ) {
1037
  $occ_query->addCondition( 'site_id = %d ', $site_id );
1038
  }
1114
  'setting' => __( 'Setting', 'wp-security-audit-log' ),
1115
  'file' => __( 'File', 'wp-security-audit-log' ),
1116
  'system-setting' => __( 'System Setting', 'wp-security-audit-log' ),
 
 
 
 
1117
  'mainwp-network' => __( 'MainWP Network', 'wp-security-audit-log' ),
1118
  'mainwp' => __( 'MainWP', 'wp-security-audit-log' ),
1119
  'yoast-seo' => __( 'Yoast SEO', 'wp-security-audit-log' ),
classes/AuditLogGridView.php CHANGED
@@ -93,7 +93,7 @@ class WSAL_AuditLogGridView extends WP_List_Table {
93
  public function __construct( $plugin, $query_args ) {
94
  $this->_plugin = $plugin;
95
  $this->query_args = $query_args;
96
- $timezone = $this->_plugin->settings->GetTimezone();
97
 
98
  /**
99
  * Transform timezone values.
@@ -181,9 +181,9 @@ class WSAL_AuditLogGridView extends WP_List_Table {
181
  */
182
  public function extra_tablenav( $which ) {
183
  // If the position is not top then render.
184
- if ( 'top' !== $which && ! $this->_plugin->settings->is_infinite_scroll() ) :
185
  // Items-per-page widget.
186
- $p = $this->_plugin->settings->GetViewPerPage();
187
  $items = array( 5, 10, 15, 30, 50 );
188
  if ( ! in_array( $p, $items, true ) ) {
189
  $items[] = $p;
@@ -203,7 +203,7 @@ class WSAL_AuditLogGridView extends WP_List_Table {
203
  <?php
204
  endif;
205
 
206
- if ( 'top' !== $which && $this->_plugin->settings->is_infinite_scroll() ) :
207
  ?>
208
  <div id="wsal-auditlog-end"><p><?php esc_html_e( '— End of Activity Log —', 'wp-security-audit-log' ); ?></p></div>
209
  <div id="wsal-event-loader"><div class="wsal-lds-ellipsis"><div></div><div></div><div></div><div></div></div></div>
@@ -214,10 +214,10 @@ class WSAL_AuditLogGridView extends WP_List_Table {
214
  // NOTE: this is shown when the filter IS NOT true.
215
  if ( $this->is_multisite() && $this->is_main_blog() && ! apply_filters( 'search_extensition_active', false ) ) {
216
  if (
217
- ( 'top' === $which && $this->_plugin->settings->is_infinite_scroll() )
218
- || ! $this->_plugin->settings->is_infinite_scroll()
219
  ) {
220
- $curr = $this->_plugin->settings->get_view_site_id();
221
  ?>
222
  <div class="wsal-ssa wsal-ssa-<?php echo esc_attr( $which ); ?>">
223
  <?php if ( $this->get_site_count() > 15 ) : ?>
@@ -240,10 +240,10 @@ class WSAL_AuditLogGridView extends WP_List_Table {
240
  }
241
 
242
  // Switch to live or archive DB.
243
- if ( $this->_plugin->settings->IsArchivingEnabled() ) {
244
  if (
245
- ( 'top' === $which && $this->_plugin->settings->is_infinite_scroll() )
246
- || ! $this->_plugin->settings->is_infinite_scroll()
247
  ) {
248
  $selected = 'live';
249
  $selected_db = get_transient( 'wsal_wp_selected_db' );
@@ -325,7 +325,7 @@ class WSAL_AuditLogGridView extends WP_List_Table {
325
 
326
  // Get selected columns from settings.
327
  if ( empty( $this->selected_columns ) && ! is_array( $this->selected_columns ) ) {
328
- $this->selected_columns = $this->_plugin->settings->GetColumnsSelected();
329
  }
330
 
331
  // If selected columns are not empty, then unset default columns.
@@ -383,7 +383,7 @@ class WSAL_AuditLogGridView extends WP_List_Table {
383
  */
384
  public function column_default( $item, $column_name ) {
385
  // Get date format.
386
- $datetime_format = $this->_plugin->settings->GetDatetimeFormat();
387
 
388
  // Store meta if not set.
389
  if ( ! isset( $this->item_meta[ $item->getId() ] ) ) {
@@ -408,7 +408,7 @@ class WSAL_AuditLogGridView extends WP_List_Table {
408
  }
409
  }
410
 
411
- if ( ! $this->_plugin->settings->CurrentUserCan( 'edit' ) ) {
412
  return '<span class="log-disable">' . str_pad( $item->alert_id, 4, '0', STR_PAD_LEFT ) . ' </span>';
413
  }
414
  // add description to $extra_msg only if one is available.
@@ -444,9 +444,9 @@ class WSAL_AuditLogGridView extends WP_List_Table {
444
  $data_link = '';
445
  $modification_alerts = array( 1002, 1003, 6007, 6023 );
446
 
447
- $date_format = $this->_plugin->settings->GetDateFormat();
448
- $show_microseconds = $this->_plugin->settings->get_show_milliseconds();
449
- if ( 'no' === $show_microseconds ) {
450
  // remove the microseconds placeholder from format string.
451
  $datetime_format = str_replace( '.$$$', '', $datetime_format );
452
  }
@@ -468,7 +468,7 @@ class WSAL_AuditLogGridView extends WP_List_Table {
468
  $username = $item->GetUsername( $this->item_meta[ $item->getId() ] ); // Get username.
469
  $user = get_user_by( 'login', $username ); // Get user.
470
  if ( empty( $this->name_type ) ) {
471
- $this->name_type = $this->_plugin->settings->get_type_username();
472
  }
473
 
474
  // Check if the username and user exists.
@@ -653,7 +653,7 @@ class WSAL_AuditLogGridView extends WP_List_Table {
653
  }
654
 
655
  /**
656
- * Method: Meta data formater.
657
  *
658
  * @param string $name - Name of the data.
659
  * @param mixed $value - Value of the data.
@@ -856,7 +856,7 @@ class WSAL_AuditLogGridView extends WP_List_Table {
856
  $total_items = isset( $query_events['total_items'] ) ? $query_events['total_items'] : false;
857
  $per_page = isset( $query_events['per_page'] ) ? $query_events['per_page'] : false;
858
 
859
- if ( ! $this->_plugin->settings->is_infinite_scroll() ) {
860
  $this->set_pagination_args(
861
  array(
862
  'total_items' => $total_items,
@@ -996,11 +996,11 @@ class WSAL_AuditLogGridView extends WP_List_Table {
996
  * @return array
997
  */
998
  public function query_events( $paged = 0 ) {
999
- if ( $this->_plugin->settings->IsArchivingEnabled() ) {
1000
  // Switch to Archive DB.
1001
  $selected_db = get_transient( 'wsal_wp_selected_db' );
1002
  if ( $selected_db && 'archive' === $selected_db ) {
1003
- $this->_plugin->settings->SwitchToArchiveDB();
1004
  }
1005
  }
1006
 
@@ -1023,9 +1023,9 @@ class WSAL_AuditLogGridView extends WP_List_Table {
1023
  */
1024
  $query = apply_filters( 'wsal_auditlog_query', $query );
1025
 
1026
- if ( ! $this->_plugin->settings->is_infinite_scroll() ) {
1027
  $total_items = $query->getAdapter()->Count( $query );
1028
- $per_page = $this->_plugin->settings->GetViewPerPage();
1029
  $offset = ( $this->get_pagenum() - 1 ) * $per_page;
1030
  } else {
1031
  $total_items = false;
93
  public function __construct( $plugin, $query_args ) {
94
  $this->_plugin = $plugin;
95
  $this->query_args = $query_args;
96
+ $timezone = $this->_plugin->settings()->GetTimezone();
97
 
98
  /**
99
  * Transform timezone values.
181
  */
182
  public function extra_tablenav( $which ) {
183
  // If the position is not top then render.
184
+ if ( 'top' !== $which && ! $this->_plugin->settings()->is_infinite_scroll() ) :
185
  // Items-per-page widget.
186
+ $p = $this->_plugin->settings()->GetViewPerPage();
187
  $items = array( 5, 10, 15, 30, 50 );
188
  if ( ! in_array( $p, $items, true ) ) {
189
  $items[] = $p;
203
  <?php
204
  endif;
205
 
206
+ if ( 'top' !== $which && $this->_plugin->settings()->is_infinite_scroll() ) :
207
  ?>
208
  <div id="wsal-auditlog-end"><p><?php esc_html_e( '— End of Activity Log —', 'wp-security-audit-log' ); ?></p></div>
209
  <div id="wsal-event-loader"><div class="wsal-lds-ellipsis"><div></div><div></div><div></div><div></div></div></div>
214
  // NOTE: this is shown when the filter IS NOT true.
215
  if ( $this->is_multisite() && $this->is_main_blog() && ! apply_filters( 'search_extensition_active', false ) ) {
216
  if (
217
+ ( 'top' === $which && $this->_plugin->settings()->is_infinite_scroll() )
218
+ || ! $this->_plugin->settings()->is_infinite_scroll()
219
  ) {
220
+ $curr = $this->_plugin->settings()->get_view_site_id();
221
  ?>
222
  <div class="wsal-ssa wsal-ssa-<?php echo esc_attr( $which ); ?>">
223
  <?php if ( $this->get_site_count() > 15 ) : ?>
240
  }
241
 
242
  // Switch to live or archive DB.
243
+ if ( $this->_plugin->settings()->IsArchivingEnabled() ) {
244
  if (
245
+ ( 'top' === $which && $this->_plugin->settings()->is_infinite_scroll() )
246
+ || ! $this->_plugin->settings()->is_infinite_scroll()
247
  ) {
248
  $selected = 'live';
249
  $selected_db = get_transient( 'wsal_wp_selected_db' );
325
 
326
  // Get selected columns from settings.
327
  if ( empty( $this->selected_columns ) && ! is_array( $this->selected_columns ) ) {
328
+ $this->selected_columns = $this->_plugin->settings()->GetColumnsSelected();
329
  }
330
 
331
  // If selected columns are not empty, then unset default columns.
383
  */
384
  public function column_default( $item, $column_name ) {
385
  // Get date format.
386
+ $datetime_format = $this->_plugin->settings()->GetDatetimeFormat();
387
 
388
  // Store meta if not set.
389
  if ( ! isset( $this->item_meta[ $item->getId() ] ) ) {
408
  }
409
  }
410
 
411
+ if ( ! $this->_plugin->settings()->CurrentUserCan( 'edit' ) ) {
412
  return '<span class="log-disable">' . str_pad( $item->alert_id, 4, '0', STR_PAD_LEFT ) . ' </span>';
413
  }
414
  // add description to $extra_msg only if one is available.
444
  $data_link = '';
445
  $modification_alerts = array( 1002, 1003, 6007, 6023 );
446
 
447
+ $date_format = $this->_plugin->settings()->GetDateFormat();
448
+ $show_microseconds = $this->_plugin->settings()->get_show_milliseconds();
449
+ if ( ! $show_microseconds ) {
450
  // remove the microseconds placeholder from format string.
451
  $datetime_format = str_replace( '.$$$', '', $datetime_format );
452
  }
468
  $username = $item->GetUsername( $this->item_meta[ $item->getId() ] ); // Get username.
469
  $user = get_user_by( 'login', $username ); // Get user.
470
  if ( empty( $this->name_type ) ) {
471
+ $this->name_type = $this->_plugin->settings()->get_type_username();
472
  }
473
 
474
  // Check if the username and user exists.
653
  }
654
 
655
  /**
656
+ * Method: Meta data formatter.
657
  *
658
  * @param string $name - Name of the data.
659
  * @param mixed $value - Value of the data.
856
  $total_items = isset( $query_events['total_items'] ) ? $query_events['total_items'] : false;
857
  $per_page = isset( $query_events['per_page'] ) ? $query_events['per_page'] : false;
858
 
859
+ if ( ! $this->_plugin->settings()->is_infinite_scroll() ) {
860
  $this->set_pagination_args(
861
  array(
862
  'total_items' => $total_items,
996
  * @return array
997
  */
998
  public function query_events( $paged = 0 ) {
999
+ if ( $this->_plugin->settings()->IsArchivingEnabled() ) {
1000
  // Switch to Archive DB.
1001
  $selected_db = get_transient( 'wsal_wp_selected_db' );
1002
  if ( $selected_db && 'archive' === $selected_db ) {
1003
+ $this->_plugin->settings()->SwitchToArchiveDB();
1004
  }
1005
  }
1006
 
1023
  */
1024
  $query = apply_filters( 'wsal_auditlog_query', $query );
1025
 
1026
+ if ( ! $this->_plugin->settings()->is_infinite_scroll() ) {
1027
  $total_items = $query->getAdapter()->Count( $query );
1028
+ $per_page = $this->_plugin->settings()->GetViewPerPage();
1029
  $offset = ( $this->get_pagenum() - 1 ) * $per_page;
1030
  } else {
1031
  $total_items = false;
classes/AuditLogListView.php CHANGED
@@ -93,7 +93,7 @@ class WSAL_AuditLogListView extends WP_List_Table {
93
  public function __construct( $plugin, $query_args ) {
94
  $this->_plugin = $plugin;
95
  $this->query_args = $query_args;
96
- $timezone = $this->_plugin->settings->GetTimezone();
97
 
98
  /**
99
  * Transform timezone values.
@@ -187,9 +187,9 @@ class WSAL_AuditLogListView extends WP_List_Table {
187
  */
188
  public function extra_tablenav( $which ) {
189
  // If the position is not top then render.
190
- if ( 'top' !== $which && ! $this->_plugin->settings->is_infinite_scroll() ) :
191
  // Items-per-page widget.
192
- $p = $this->_plugin->settings->GetViewPerPage();
193
  $items = array( 5, 10, 15, 30, 50 );
194
  if ( ! in_array( $p, $items, true ) ) {
195
  $items[] = $p;
@@ -209,7 +209,7 @@ class WSAL_AuditLogListView extends WP_List_Table {
209
  <?php
210
  endif;
211
 
212
- if ( 'top' !== $which && $this->_plugin->settings->is_infinite_scroll() ) :
213
  ?>
214
  <div id="wsal-auditlog-end"><p><?php esc_html_e( '— End of Activity Log —', 'wp-security-audit-log' ); ?></p></div>
215
  <div id="wsal-event-loader"><div class="wsal-lds-ellipsis"><div></div><div></div><div></div><div></div></div></div>
@@ -220,10 +220,10 @@ class WSAL_AuditLogListView extends WP_List_Table {
220
  // NOTE: this is shown when the filter IS NOT true.
221
  if ( $this->is_multisite() && $this->is_main_blog() && ! apply_filters( 'search_extensition_active', false ) ) {
222
  if (
223
- ( 'top' === $which && $this->_plugin->settings->is_infinite_scroll() )
224
- || ! $this->_plugin->settings->is_infinite_scroll()
225
  ) {
226
- $curr = $this->_plugin->settings->get_view_site_id();
227
  ?>
228
  <div class="wsal-ssa wsal-ssa-<?php echo esc_attr( $which ); ?>">
229
  <?php if ( $this->get_site_count() > 15 ) : ?>
@@ -247,10 +247,10 @@ class WSAL_AuditLogListView extends WP_List_Table {
247
 
248
 
249
  // Switch to live or archive DB.
250
- if ( $this->_plugin->settings->IsArchivingEnabled() ) {
251
  if (
252
- ( 'top' === $which && $this->_plugin->settings->is_infinite_scroll() )
253
- || ! $this->_plugin->settings->is_infinite_scroll()
254
  ) {
255
  $selected = 'live';
256
  $selected_db = get_transient( 'wsal_wp_selected_db' );
@@ -318,7 +318,7 @@ class WSAL_AuditLogListView extends WP_List_Table {
318
  public function get_columns() {
319
  // Get user information from settings.
320
  // if ( empty( $this->name_type ) ) {
321
- // $this->name_type = $this->_plugin->settings->get_type_username();
322
  // }
323
  // if ( 'display_name' === $this->name_type || 'first_last_name' === $this->name_type ) {
324
  // $name_column = __( 'User', 'wp-security-audit-log' );
@@ -345,7 +345,7 @@ class WSAL_AuditLogListView extends WP_List_Table {
345
 
346
  // Get selected columns from settings.
347
  if ( empty( $this->selected_columns ) && ! is_array( $this->selected_columns ) ) {
348
- $this->selected_columns = $this->_plugin->settings->GetColumnsSelected();
349
  }
350
 
351
  // If selected columns are not empty, then unset default columns.
@@ -424,7 +424,7 @@ class WSAL_AuditLogListView extends WP_List_Table {
424
  */
425
  public function column_default( $item, $column_name ) {
426
  // Get date format.
427
- $datetime_format = $this->_plugin->settings->GetDatetimeFormat();
428
 
429
  // Store meta if not set.
430
  if ( ! isset( $this->item_meta[ $item->getId() ] ) ) {
@@ -459,7 +459,7 @@ class WSAL_AuditLogListView extends WP_List_Table {
459
  }
460
  }
461
 
462
- if ( ! $this->_plugin->settings->CurrentUserCan( 'edit' ) ) {
463
  return '<span class="log-disable">' . str_pad( $item->alert_id, 4, '0', STR_PAD_LEFT ) . ' </span>';
464
  }
465
 
@@ -472,8 +472,8 @@ class WSAL_AuditLogListView extends WP_List_Table {
472
 
473
  return '<a class="tooltip" href="#" data-tooltip="' . esc_html( $const->name ) . '"><span class="log-type log-type-' . $const->value . '"></span></a>';
474
  case 'crtd':
475
- $show_milliseconds = $this->_plugin->settings->get_show_milliseconds();
476
- if ( 'no' === $show_milliseconds ) {
477
  // remove the milliseconds placeholder from format string.
478
  $datetime_format = str_replace( '.$$$', '', $datetime_format );
479
  }
@@ -488,7 +488,7 @@ class WSAL_AuditLogListView extends WP_List_Table {
488
  $username = $item->GetUsername( $this->item_meta[ $item->getId() ] ); // Get username.
489
  $user = get_user_by( 'login', $username ); // Get user.
490
  if ( empty( $this->name_type ) ) {
491
- $this->name_type = $this->_plugin->settings->get_type_username();
492
  }
493
 
494
  // Check if the username and user exists.
@@ -653,7 +653,7 @@ class WSAL_AuditLogListView extends WP_List_Table {
653
  }
654
 
655
  /**
656
- * Method: Meta data formater.
657
  *
658
  * @param string $name - Name of the data.
659
  * @param mixed $value - Value of the data.
@@ -856,7 +856,7 @@ class WSAL_AuditLogListView extends WP_List_Table {
856
  $total_items = isset( $query_events['total_items'] ) ? $query_events['total_items'] : false;
857
  $per_page = isset( $query_events['per_page'] ) ? $query_events['per_page'] : false;
858
 
859
- if ( ! $this->_plugin->settings->is_infinite_scroll() ) {
860
  $this->set_pagination_args(
861
  array(
862
  'total_items' => $total_items,
@@ -996,11 +996,11 @@ class WSAL_AuditLogListView extends WP_List_Table {
996
  * @return array
997
  */
998
  public function query_events( $paged = 0 ) {
999
- if ( $this->_plugin->settings->IsArchivingEnabled() ) {
1000
  // Switch to Archive DB.
1001
  $selected_db = get_transient( 'wsal_wp_selected_db' );
1002
  if ( $selected_db && 'archive' === $selected_db ) {
1003
- $this->_plugin->settings->SwitchToArchiveDB();
1004
  }
1005
  }
1006
 
@@ -1023,9 +1023,9 @@ class WSAL_AuditLogListView extends WP_List_Table {
1023
  */
1024
  $query = apply_filters( 'wsal_auditlog_query', $query );
1025
 
1026
- if ( ! $this->_plugin->settings->is_infinite_scroll() ) {
1027
  $total_items = $query->getAdapter()->Count( $query );
1028
- $per_page = $this->_plugin->settings->GetViewPerPage();
1029
  $offset = ( $this->get_pagenum() - 1 ) * $per_page;
1030
  } else {
1031
  $total_items = false;
93
  public function __construct( $plugin, $query_args ) {
94
  $this->_plugin = $plugin;
95
  $this->query_args = $query_args;
96
+ $timezone = $this->_plugin->settings()->GetTimezone();
97
 
98
  /**
99
  * Transform timezone values.
187
  */
188
  public function extra_tablenav( $which ) {
189
  // If the position is not top then render.
190
+ if ( 'top' !== $which && ! $this->_plugin->settings()->is_infinite_scroll() ) :
191
  // Items-per-page widget.
192
+ $p = $this->_plugin->settings()->GetViewPerPage();
193
  $items = array( 5, 10, 15, 30, 50 );
194
  if ( ! in_array( $p, $items, true ) ) {
195
  $items[] = $p;
209
  <?php
210
  endif;
211
 
212
+ if ( 'top' !== $which && $this->_plugin->settings()->is_infinite_scroll() ) :
213
  ?>
214
  <div id="wsal-auditlog-end"><p><?php esc_html_e( '— End of Activity Log —', 'wp-security-audit-log' ); ?></p></div>
215
  <div id="wsal-event-loader"><div class="wsal-lds-ellipsis"><div></div><div></div><div></div><div></div></div></div>
220
  // NOTE: this is shown when the filter IS NOT true.
221
  if ( $this->is_multisite() && $this->is_main_blog() && ! apply_filters( 'search_extensition_active', false ) ) {
222
  if (
223
+ ( 'top' === $which && $this->_plugin->settings()->is_infinite_scroll() )
224
+ || ! $this->_plugin->settings()->is_infinite_scroll()
225
  ) {
226
+ $curr = $this->_plugin->settings()->get_view_site_id();
227
  ?>
228
  <div class="wsal-ssa wsal-ssa-<?php echo esc_attr( $which ); ?>">
229
  <?php if ( $this->get_site_count() > 15 ) : ?>
247
 
248
 
249
  // Switch to live or archive DB.
250
+ if ( $this->_plugin->settings()->IsArchivingEnabled() ) {
251
  if (
252
+ ( 'top' === $which && $this->_plugin->settings()->is_infinite_scroll() )
253
+ || ! $this->_plugin->settings()->is_infinite_scroll()
254
  ) {
255
  $selected = 'live';
256
  $selected_db = get_transient( 'wsal_wp_selected_db' );
318
  public function get_columns() {
319
  // Get user information from settings.
320
  // if ( empty( $this->name_type ) ) {
321
+ // $this->name_type = $this->_plugin->settings()->get_type_username();
322
  // }
323
  // if ( 'display_name' === $this->name_type || 'first_last_name' === $this->name_type ) {
324
  // $name_column = __( 'User', 'wp-security-audit-log' );
345
 
346
  // Get selected columns from settings.
347
  if ( empty( $this->selected_columns ) && ! is_array( $this->selected_columns ) ) {
348
+ $this->selected_columns = $this->_plugin->settings()->GetColumnsSelected();
349
  }
350
 
351
  // If selected columns are not empty, then unset default columns.
424
  */
425
  public function column_default( $item, $column_name ) {
426
  // Get date format.
427
+ $datetime_format = $this->_plugin->settings()->GetDatetimeFormat();
428
 
429
  // Store meta if not set.
430
  if ( ! isset( $this->item_meta[ $item->getId() ] ) ) {
459
  }
460
  }
461
 
462
+ if ( ! $this->_plugin->settings()->CurrentUserCan( 'edit' ) ) {
463
  return '<span class="log-disable">' . str_pad( $item->alert_id, 4, '0', STR_PAD_LEFT ) . ' </span>';
464
  }
465
 
472
 
473
  return '<a class="tooltip" href="#" data-tooltip="' . esc_html( $const->name ) . '"><span class="log-type log-type-' . $const->value . '"></span></a>';
474
  case 'crtd':
475
+ $show_milliseconds = $this->_plugin->settings()->get_show_milliseconds();
476
+ if ( ! $show_milliseconds ) {
477
  // remove the milliseconds placeholder from format string.
478
  $datetime_format = str_replace( '.$$$', '', $datetime_format );
479
  }
488
  $username = $item->GetUsername( $this->item_meta[ $item->getId() ] ); // Get username.
489
  $user = get_user_by( 'login', $username ); // Get user.
490
  if ( empty( $this->name_type ) ) {
491
+ $this->name_type = $this->_plugin->settings()->get_type_username();
492
  }
493
 
494
  // Check if the username and user exists.
653
  }
654
 
655
  /**
656
+ * Method: Meta data formatter.
657
  *
658
  * @param string $name - Name of the data.
659
  * @param mixed $value - Value of the data.
856
  $total_items = isset( $query_events['total_items'] ) ? $query_events['total_items'] : false;
857
  $per_page = isset( $query_events['per_page'] ) ? $query_events['per_page'] : false;
858
 
859
+ if ( ! $this->_plugin->settings()->is_infinite_scroll() ) {
860
  $this->set_pagination_args(
861
  array(
862
  'total_items' => $total_items,
996
  * @return array
997
  */
998
  public function query_events( $paged = 0 ) {
999
+ if ( $this->_plugin->settings()->IsArchivingEnabled() ) {
1000
  // Switch to Archive DB.
1001
  $selected_db = get_transient( 'wsal_wp_selected_db' );
1002
  if ( $selected_db && 'archive' === $selected_db ) {
1003
+ $this->_plugin->settings()->SwitchToArchiveDB();
1004
  }
1005
  }
1006
 
1023
  */
1024
  $query = apply_filters( 'wsal_auditlog_query', $query );
1025
 
1026
+ if ( ! $this->_plugin->settings()->is_infinite_scroll() ) {
1027
  $total_items = $query->getAdapter()->Count( $query );
1028
+ $per_page = $this->_plugin->settings()->GetViewPerPage();
1029
  $offset = ( $this->get_pagenum() - 1 ) * $per_page;
1030
  } else {
1031
  $total_items = false;
classes/Connector/AbstractConnector.php CHANGED
@@ -52,11 +52,6 @@ abstract class WSAL_Connector_AbstractConnector {
52
  */
53
  public function __construct( $adapters_dir_name = null ) {
54
  $this->adaptersBasePath = __DIR__ . DIRECTORY_SEPARATOR . '..' . DIRECTORY_SEPARATOR . 'Adapters' . DIRECTORY_SEPARATOR;
55
-
56
- // require_once($this->adaptersBasePath . 'ActiveRecordInterface.php');
57
- // require_once($this->adaptersBasePath . 'MetaInterface.php');
58
- // require_once($this->adaptersBasePath . 'OccurrenceInterface.php');
59
- // require_once($this->adaptersBasePath . 'QueryInterface.php');
60
  if ( ! empty( $adapters_dir_name ) ) {
61
  $this->adaptersDirName = $adapters_dir_name;
62
  require_once( $this->getAdaptersDirectory() . DIRECTORY_SEPARATOR . 'ActiveRecordAdapter.php' );
52
  */
53
  public function __construct( $adapters_dir_name = null ) {
54
  $this->adaptersBasePath = __DIR__ . DIRECTORY_SEPARATOR . '..' . DIRECTORY_SEPARATOR . 'Adapters' . DIRECTORY_SEPARATOR;
 
 
 
 
 
55
  if ( ! empty( $adapters_dir_name ) ) {
56
  $this->adaptersDirName = $adapters_dir_name;
57
  require_once( $this->getAdaptersDirectory() . DIRECTORY_SEPARATOR . 'ActiveRecordAdapter.php' );
classes/Connector/ConnectorFactory.php CHANGED
@@ -27,14 +27,7 @@ abstract class WSAL_Connector_ConnectorFactory {
27
  *
28
  * @var array
29
  */
30
- public static $connector;
31
-
32
- /**
33
- * Default Connector.
34
- *
35
- * @var bool
36
- */
37
- public static $defaultConnector;
38
 
39
  /**
40
  * Adapter.
@@ -53,7 +46,8 @@ abstract class WSAL_Connector_ConnectorFactory {
53
  private static $is_installed;
54
 
55
  /**
56
- * Returns the a default WPDB connector for saving options
 
57
  */
58
  public static function GetDefaultConnector() {
59
  return new WSAL_Connector_MySQLDB();
@@ -63,8 +57,10 @@ abstract class WSAL_Connector_ConnectorFactory {
63
  * Returns a connector singleton
64
  *
65
  * @param array $config - Connection config.
66
- * @param bool $reset - True if reset.
 
67
  * @return WSAL_Connector_ConnectorInterface
 
68
  */
69
  public static function GetConnector( $config = null, $reset = false ) {
70
  if ( ! empty( $config ) ) {
@@ -90,6 +86,7 @@ abstract class WSAL_Connector_ConnectorFactory {
90
  * Get the adapter config stored in the DB
91
  *
92
  * @return array|null adapter config
 
93
  */
94
  public static function GetConfig() {
95
  $conf = new WSAL_Settings( WpSecurityAuditLog::GetInstance() );
27
  *
28
  * @var array
29
  */
30
+ private static $connector;
 
 
 
 
 
 
 
31
 
32
  /**
33
  * Adapter.
46
  private static $is_installed;
47
 
48
  /**
49
+ * Returns the a default WPDB connector that must be always used for some data, for example user sessions and
50
+ * also custom options table in the past.
51
  */
52
  public static function GetDefaultConnector() {
53
  return new WSAL_Connector_MySQLDB();
57
  * Returns a connector singleton
58
  *
59
  * @param array $config - Connection config.
60
+ * @param bool $reset - True if reset.
61
+ *
62
  * @return WSAL_Connector_ConnectorInterface
63
+ * @throws Freemius_Exception
64
  */
65
  public static function GetConnector( $config = null, $reset = false ) {
66
  if ( ! empty( $config ) ) {
86
  * Get the adapter config stored in the DB
87
  *
88
  * @return array|null adapter config
89
+ * @throws Freemius_Exception
90
  */
91
  public static function GetConfig() {
92
  $conf = new WSAL_Settings( WpSecurityAuditLog::GetInstance() );
classes/Connector/MySQLDB.php CHANGED
@@ -171,9 +171,9 @@ class WSAL_Connector_MySQLDB extends WSAL_Connector_AbstractConnector implements
171
  /**
172
  * Install all DB tables.
173
  *
174
- * @param bool $exclude_options - True if excluding.
175
  */
176
- public function installAll( $exclude_options = false ) {
177
  $plugin = WpSecurityAuditLog::GetInstance();
178
  $adapter_list = glob( $this->getAdaptersDirectory() . DIRECTORY_SEPARATOR . '*.php' );
179
  $adapter_list = apply_filters( 'wsal_install_apapters_list', $adapter_list );
@@ -186,12 +186,18 @@ class WSAL_Connector_MySQLDB extends WSAL_Connector_AbstractConnector implements
186
  $class = new $class_name( $this->getConnection() );
187
  }
188
 
189
- if ( $exclude_options && $class instanceof WSAL_Adapters_MySQL_Option ) {
 
190
  continue;
191
  }
192
 
193
- // Exclude the tmp_users table.
194
- if ( ! $exclude_options && $class instanceof WSAL_Adapters_MySQL_TmpUser ) {
 
 
 
 
 
195
  continue;
196
  }
197
 
@@ -324,6 +330,8 @@ class WSAL_Connector_MySQLDB extends WSAL_Connector_AbstractConnector implements
324
  *
325
  * @param integer $index - Index.
326
  * @param integer $limit - Limit.
 
 
327
  */
328
  public function MigrateBackOccurrence( $index, $limit ) {
329
  $result = null;
171
  /**
172
  * Install all DB tables.
173
  *
174
+ * @param bool $is_external_database If true, some tables will not be created.
175
  */
176
+ public function installAll( $is_external_database = false ) {
177
  $plugin = WpSecurityAuditLog::GetInstance();
178
  $adapter_list = glob( $this->getAdaptersDirectory() . DIRECTORY_SEPARATOR . '*.php' );
179
  $adapter_list = apply_filters( 'wsal_install_apapters_list', $adapter_list );
186
  $class = new $class_name( $this->getConnection() );
187
  }
188
 
189
+ if ( $is_external_database && $class instanceof WSAL_Adapters_MySQL_Session ) {
190
+ // sessions table should only ever exist only in local database
191
  continue;
192
  }
193
 
194
+ if ( $is_external_database && $class instanceof WSAL_Adapters_MySQL_Option ) {
195
+ // options table should only ever exist only in local database
196
+ continue;
197
+ }
198
+
199
+ if ( ! $is_external_database && $class instanceof WSAL_Adapters_MySQL_TmpUser ) {
200
+ // exclude the tmp_users table for local database
201
  continue;
202
  }
203
 
330
  *
331
  * @param integer $index - Index.
332
  * @param integer $limit - Limit.
333
+ *
334
+ * @return array
335
  */
336
  public function MigrateBackOccurrence( $index, $limit ) {
337
  $result = null;
classes/Helpers/Options.php CHANGED
@@ -13,7 +13,7 @@ namespace WSAL\Helpers;
13
  /**
14
  * WordPress options are always loaded from the default WordPress database.
15
  *
16
- * NOTE: there is primiarily a wrapper class around core functions and it has
17
  * no cache layer here as wp has an internal options cache of it's own.
18
  *
19
  * @since 4.0.2
@@ -40,13 +40,11 @@ class Options {
40
  * Sets up this class with the main plugin instance and a prefix.
41
  *
42
  * @method __construct
 
 
43
  * @since 4.0.2
44
- * @param WpSecurityAuditLog $plugin The main plugin class instance.
45
- * @param string $prefix A prefix to use when setting/getting.
46
  */
47
- public function __construct( $plugin, $prefix = '' ) {
48
- // the main plugin file incase we need to get data from it.
49
- $this->plugin = $plugin;
50
  // sets the prefix used when getting all options through this class.
51
  $this->set_prefix( $prefix );
52
  }
@@ -65,9 +63,6 @@ class Options {
65
  /**
66
  * Gets the value of an option.
67
  *
68
- * First attempts to get it from the class cache, then looks in the WP
69
- * options table. If it gets fetched then store it in the cache.
70
- *
71
  * @method get_option_value
72
  * @since 4.0.2
73
  * @param string $option_name option name we want to get a value for.
@@ -79,7 +74,14 @@ class Options {
79
  if ( empty( $option_name ) || ! is_string( $option_name ) ) {
80
  return;
81
  }
82
- return \get_option( $this->prefix . $option_name, $default );
 
 
 
 
 
 
 
83
  }
84
 
85
  /**
@@ -97,13 +99,25 @@ class Options {
97
  if ( empty( $option_name ) || null === $value ) {
98
  return;
99
  }
100
- return \update_option( $this->prefix . $option_name, $value, $autoload );
 
 
 
 
 
 
 
 
 
 
 
 
101
  }
102
 
103
  /**
104
  * Deletes an option from the WP options table.
105
  *
106
- * NOTE: This is just a strait wrapper around the core function - if the
107
  * item is prefixed then pass the prefix in the option name.
108
  *
109
  * @method delete_option
@@ -112,48 +126,184 @@ class Options {
112
  * @return bool
113
  */
114
  public function delete_option( $option_name = '' ) {
115
- return \delete_option( $option_name );
 
 
 
 
 
 
 
 
 
 
116
  }
117
 
118
  /**
119
- * Retrieves the logging directory from the settings. Returns a file path
120
- * with a trailing slash.
121
  *
122
- * Uses as default:
123
- * /wp-content/uploads/wp-security-audit-log/
 
 
 
 
 
 
 
 
 
 
 
 
124
  *
125
- * @method get_logging_path
126
- * @since 4.1.0
127
- * @return string
 
 
 
 
 
 
 
 
 
 
 
128
  */
129
- public function get_logging_path() {
130
- if ( ! \function_exists( 'get_home_path' ) ) {
131
- require_once ABSPATH . 'wp-admin/includes/file.php';
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
132
  }
133
- $relative_path = $this->get_option_value( 'custom-logging-dir', \WSAL_Settings::DEFAULT_LOGGING_DIR );
134
- $absolute_path = trailingslashit( ABSPATH ) . trailingslashit( ltrim( $relative_path, '/' ) );
135
- return $absolute_path;
 
 
 
 
136
  }
137
 
138
  /**
139
- * Retrieves the logging directory from the settings to generate a url.
140
- * Returns a url with a trailing slash.
141
  *
142
- * Uses as default:
143
- * /wp-content/uploads/wp-security-audit-log/
 
 
 
144
  *
145
- * @method get_logging_url
146
- * @since 4.1.0
147
- * @return string
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
148
  */
149
- public function get_logging_url() {
150
- if ( ! \function_exists( 'get_home_url' ) ) {
151
- require_once ABSPATH . 'wp-admin/includes/file.php';
 
 
 
 
 
152
  }
153
- $relative_url = $this->get_option_value( 'custom-logging-dir', \WSAL_Settings::DEFAULT_LOGGING_DIR );
154
- $absolute_url = trailingslashit( \get_site_url() ) . trailingslashit( ltrim( $relative_url, '/' ) );
155
- return $absolute_url;
156
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
157
  }
158
 
 
 
 
 
 
 
 
 
 
 
 
 
 
159
  }
13
  /**
14
  * WordPress options are always loaded from the default WordPress database.
15
  *
16
+ * NOTE: there is primarily a wrapper class around core functions and it has
17
  * no cache layer here as wp has an internal options cache of it's own.
18
  *
19
  * @since 4.0.2
40
  * Sets up this class with the main plugin instance and a prefix.
41
  *
42
  * @method __construct
43
+ * @param string $prefix A prefix to use when setting/getting.
44
+ *
45
  * @since 4.0.2
 
 
46
  */
47
+ public function __construct( $prefix = '' ) {
 
 
48
  // sets the prefix used when getting all options through this class.
49
  $this->set_prefix( $prefix );
50
  }
63
  /**
64
  * Gets the value of an option.
65
  *
 
 
 
66
  * @method get_option_value
67
  * @since 4.0.2
68
  * @param string $option_name option name we want to get a value for.
74
  if ( empty( $option_name ) || ! is_string( $option_name ) ) {
75
  return;
76
  }
77
+
78
+ $actual_option_name = $option_name;
79
+ if (!preg_match( '/\A' .preg_quote($this->prefix) . '/', $option_name)) {
80
+ // remove prefix duplicate if present
81
+ $actual_option_name = $this->prefix . $option_name;
82
+ }
83
+
84
+ return self::_get_option_value( $actual_option_name, $default);
85
  }
86
 
87
  /**
99
  if ( empty( $option_name ) || null === $value ) {
100
  return;
101
  }
102
+
103
+ $actual_option_name = $option_name;
104
+ if (preg_match( '/\A' .preg_quote(\WpSecurityAuditLog::OPT_PRFX) . '/', $option_name)) {
105
+ // remove legacy prefix
106
+ $actual_option_name = substr($option_name, strlen(\WpSecurityAuditLog::OPT_PRFX));
107
+ }
108
+
109
+ if (!preg_match( '/\A' .preg_quote($this->prefix) . '/', $option_name)) {
110
+ // prepend prefix if not already present
111
+ $actual_option_name = $this->prefix . $option_name;
112
+ }
113
+
114
+ return self::_set_option_value($actual_option_name, $value, $autoload);
115
  }
116
 
117
  /**
118
  * Deletes an option from the WP options table.
119
  *
120
+ * NOTE: This is just a straight wrapper around the core function - if the
121
  * item is prefixed then pass the prefix in the option name.
122
  *
123
  * @method delete_option
126
  * @return bool
127
  */
128
  public function delete_option( $option_name = '' ) {
129
+ if (is_multisite()) {
130
+ switch_to_blog(get_main_network_id());
131
+ }
132
+
133
+ $result = \delete_option( $option_name );
134
+
135
+ if (is_multisite()) {
136
+ restore_current_blog();
137
+ }
138
+
139
+ return $result;
140
  }
141
 
142
  /**
143
+ * Get options by prefix (notifications stored in json format).
 
144
  *
145
+ * @param string $opt_prefix - Prefix.
146
+ * @return array|null - Options.
147
+ */
148
+ public function GetNotificationsSetting( $opt_prefix ) {
149
+ global $wpdb;
150
+ $prepared_query = $wpdb->prepare(
151
+ "SELECT * FROM {$wpdb->options} WHERE option_name LIKE %s;",
152
+ $opt_prefix . '%%'
153
+ );
154
+ return $wpdb->get_results($prepared_query);
155
+ }
156
+
157
+ /**
158
+ * @param int $id Notification ID.
159
  *
160
+ * @return array|object|void|null
161
+ * @since 4.1.3
162
+ */
163
+ public function GetNotification($id) {
164
+ global $wpdb;
165
+ $prepared_query = $wpdb->prepare("SELECT * FROM {$wpdb->options} WHERE option_id = %d LIMIT 1;", $id);
166
+ return $wpdb->get_row( $prepared_query );
167
+ }
168
+
169
+ /**
170
+ * Number of options start with prefix.
171
+ *
172
+ * @param string $opt_prefix - Prefix.
173
+ * @return integer Indicates the number of items.
174
  */
175
+ public function CountNotifications( $opt_prefix ) {
176
+ global $wpdb;
177
+
178
+ $prepared_query = $wpdb->prepare(
179
+ "SELECT COUNT(option_id) FROM {$wpdb->options} WHERE option_name LIKE %s;",
180
+ $opt_prefix . '%%'
181
+ );
182
+ return (int) $wpdb->get_var( $prepared_query );
183
+
184
+ }
185
+
186
+ /**
187
+ * Static function for retrieving an option value statically.
188
+ *
189
+ * WARNING!
190
+ * ========
191
+ * This should be used only when absolutely necessary. For example in very early stages of WordPress application
192
+ * lifecycle before the whole plugin is loaded. At the time of writing this function, only frontend events settings
193
+ * was needed to be treated this way.
194
+ *
195
+ * In all other cases function \WpSecurityAuditLog::GetGlobalSetting() should be used instead.
196
+ *
197
+ * @see \WpSecurityAuditLog::GetGlobalSetting()
198
+ * @since 4.1.3
199
+ * @param string $option_name Option name we want to get a value for including necessary plugin prefix.
200
+ * @param mixed $default a default value to use when one doesn't exist.
201
+ * @return mixed
202
+ */
203
+ public static function get_option_value_ignore_prefix( $option_name = '', $default = null) {
204
+ return self::_get_option_value($option_name, $default);
205
+ }
206
+
207
+ /**
208
+ * Internal function used to get the value of an option. Any necessary prefixes are already contained in the option
209
+ * name.
210
+ *
211
+ * @since 4.1.3
212
+ * @param string $option_name Option name we want to get a value for including necessary plugin prefix.
213
+ * @param mixed $default a default value to use when one doesn't exist.
214
+ * @return mixed
215
+ */
216
+ private static function _get_option_value( $option_name = '', $default = null ) {
217
+ // bail early if no option name was requested.
218
+ if ( empty( $option_name ) || ! is_string( $option_name ) ) {
219
+ return;
220
+ }
221
+
222
+ if (is_multisite()) {
223
+ switch_to_blog(get_main_network_id());
224
  }
225
+
226
+ $result = \get_option( $option_name, $default );
227
+
228
+ if (is_multisite()) {
229
+ restore_current_blog();
230
+ }
231
+ return maybe_unserialize($result);
232
  }
233
 
234
  /**
235
+ * Static function for saving an option value statically.
 
236
  *
237
+ * WARNING!
238
+ * ========
239
+ * This should be used only when absolutely necessary. For example in very early stages of WordPress application
240
+ * lifecycle before the whole plugin is loaded. At the time of writing this function, only frontend events settings
241
+ * was needed to be treated this way.
242
  *
243
+ * In all other cases function \WpSecurityAuditLog::SetGlobalSetting() should be used instead.
244
+ *
245
+ * @see \WpSecurityAuditLog::SetGlobalSetting()
246
+ * @since 4.1.3
247
+ * @param string $option_name Option name we want to get a value for including necessary plugin prefix.
248
+ * @param mixed $value A value to store under the option name.
249
+ * @param bool $autoload Whether or not to autoload this option.
250
+ * @return mixed
251
+ */
252
+ public static function set_option_value_ignore_prefix( $option_name = '', $value = null, $autoload = true ) {
253
+ return self::_set_option_value( $option_name, $value, $autoload = true );
254
+ }
255
+
256
+ /**
257
+ * Internal function used to set the value of an option. Any necessary prefixes are already contained in the option
258
+ * name.
259
+ *
260
+ * @since 4.1.3
261
+ * @param string $option_name Option name we want to save a value for including necessary plugin prefix.
262
+ * @param mixed $value A value to store under the option name.
263
+ * @param bool $autoload Whether or not to autoload this option.
264
+ * @return bool Whether or not the option was updated.
265
  */
266
+ private static function _set_option_value( $option_name = '', $value = null, $autoload = true ) {
267
+ // bail early if no option name or value was passed.
268
+ if ( empty( $option_name ) || null === $value ) {
269
+ return;
270
+ }
271
+
272
+ if (is_multisite()) {
273
+ switch_to_blog(get_main_network_id());
274
  }
 
 
 
275
 
276
+ $result = \update_option( $option_name, $value, $autoload );
277
+
278
+ if (is_multisite()) {
279
+ restore_current_blog();
280
+ }
281
+
282
+ return $result;
283
+ }
284
+
285
+ /**
286
+ * Converts a string (e.g. 'yes' or 'no') to a bool.
287
+ *
288
+ * @since 4.1.3
289
+ * @param string $string String to convert.
290
+ * @return bool
291
+ */
292
+ public static function string_to_bool( $string ) {
293
+ return is_bool( $string ) ? $string : ( 'yes' === $string || 1 === $string || 'true' === $string || '1' === $string || 'on' === $string || 'enable' === $string);
294
  }
295
 
296
+ /**
297
+ * Converts a bool to a 'yes' or 'no'.
298
+ *
299
+ * @since 4.1.3
300
+ * @param bool $bool String to convert.
301
+ * @return string
302
+ */
303
+ public static function bool_to_string( $bool ) {
304
+ if ( ! is_bool( $bool ) ) {
305
+ $bool = self::string_to_bool( $bool );
306
+ }
307
+ return true === $bool ? 'yes' : 'no';
308
+ }
309
  }
classes/Loggers/Database.php CHANGED
@@ -52,7 +52,7 @@ class WSAL_Loggers_Database extends WSAL_AbstractLogger {
52
  */
53
  public function Log( $type, $data = array(), $date = null, $siteid = null, $migrated = false, $override_buffer = false ) {
54
  // Is this a php alert, and if so, are we logging such alerts?
55
- if ( $type < 0010 && ! $this->plugin->settings->IsPhpErrorLoggingEnabled() ) {
56
  return;
57
  }
58
 
@@ -67,7 +67,7 @@ class WSAL_Loggers_Database extends WSAL_AbstractLogger {
67
  $db_config = WSAL_Connector_ConnectorFactory::GetConfig(); // Get DB connector configuration.
68
 
69
  // Get external buffer option.
70
- $use_buffer = $this->plugin->GetGlobalOption( 'adapter-use-buffer' );
71
  if ( $override_buffer ) {
72
  $use_buffer = false;
73
  }
@@ -127,7 +127,7 @@ class WSAL_Loggers_Database extends WSAL_AbstractLogger {
127
  // Check event occurrence object.
128
  if ( ! empty( $occ ) && $occ instanceof WSAL_Models_Occurrence ) {
129
  // Get temporary stored alerts.
130
- $temp_alerts = get_option( 'wsal_temp_alerts', array() );
131
 
132
  // Store current event in a temporary buffer.
133
  $temp_alerts[ $occ->created_on ]['alert'] = array(
@@ -139,7 +139,7 @@ class WSAL_Loggers_Database extends WSAL_AbstractLogger {
139
  $temp_alerts[ $occ->created_on ]['alert_data'] = $event_data;
140
 
141
  // Save temporary alerts to options.
142
- update_option( 'wsal_temp_alerts', $temp_alerts );
143
  return true;
144
  }
145
 
@@ -152,10 +152,10 @@ class WSAL_Loggers_Database extends WSAL_AbstractLogger {
152
  */
153
  public function CleanUp() {
154
  $now = current_time( 'timestamp' );
155
- $max_sdate = $this->plugin->settings->GetPruningDate();
156
- $max_count = $this->plugin->settings->GetPruningLimit();
157
- $is_date_e = $this->plugin->settings->IsPruningDateEnabled();
158
- $is_limt_e = $this->plugin->settings->IsPruningLimitEnabled();
159
 
160
  // Return if retention is disabled.
161
  if ( ! $is_date_e && ! $is_limt_e ) {
@@ -163,14 +163,14 @@ class WSAL_Loggers_Database extends WSAL_AbstractLogger {
163
  }
164
 
165
  // Return if archiving cron is running.
166
- if ( $this->plugin->GetGlobalOption( 'archiving-cron-started', false ) ) {
167
  return;
168
  }
169
 
170
  // If archiving is enabled then events are deleted from the archive database.
171
- if ( $this->plugin->settings->IsArchivingEnabled() ) {
172
  // Switch to Archive DB.
173
- $this->plugin->settings->SwitchToArchiveDB();
174
  }
175
 
176
  $occ = new WSAL_Models_Occurrence();
@@ -254,7 +254,7 @@ class WSAL_Loggers_Database extends WSAL_AbstractLogger {
254
  * @return integer $promoToSend - The array index.
255
  */
256
  private function GetPromoAlert() {
257
- $last_promo_sent_id = $this->plugin->GetGlobalOption( 'promo-send-id' );
258
  $last_promo_sent_id = empty( $last_promo_sent_id ) ? 0 : $last_promo_sent_id;
259
  $promo_to_send = null;
260
  $promo_alerts = $this->GetActivePromoText();
@@ -266,7 +266,7 @@ class WSAL_Loggers_Database extends WSAL_AbstractLogger {
266
  } else {
267
  $last_promo_sent_id = 0;
268
  }
269
- $this->plugin->SetGlobalOption( 'promo-send-id', $last_promo_sent_id );
270
  }
271
  return $promo_to_send;
272
  }
52
  */
53
  public function Log( $type, $data = array(), $date = null, $siteid = null, $migrated = false, $override_buffer = false ) {
54
  // Is this a php alert, and if so, are we logging such alerts?
55
+ if ( $type < 0010 && ! $this->plugin->settings()->IsPhpErrorLoggingEnabled() ) {
56
  return;
57
  }
58
 
67
  $db_config = WSAL_Connector_ConnectorFactory::GetConfig(); // Get DB connector configuration.
68
 
69
  // Get external buffer option.
70
+ $use_buffer = $this->plugin->GetGlobalBooleanSetting( 'adapter-use-buffer' );
71
  if ( $override_buffer ) {
72
  $use_buffer = false;
73
  }
127
  // Check event occurrence object.
128
  if ( ! empty( $occ ) && $occ instanceof WSAL_Models_Occurrence ) {
129
  // Get temporary stored alerts.
130
+ $temp_alerts = $this->plugin->GetGlobalSetting( 'temp_alerts', array() );
131
 
132
  // Store current event in a temporary buffer.
133
  $temp_alerts[ $occ->created_on ]['alert'] = array(
139
  $temp_alerts[ $occ->created_on ]['alert_data'] = $event_data;
140
 
141
  // Save temporary alerts to options.
142
+ $this->plugin->SetGlobalSetting( 'temp_alerts', $temp_alerts );
143
  return true;
144
  }
145
 
152
  */
153
  public function CleanUp() {
154
  $now = current_time( 'timestamp' );
155
+ $max_sdate = $this->plugin->settings()->GetPruningDate();
156
+ $max_count = $this->plugin->settings()->GetPruningLimit();
157
+ $is_date_e = $this->plugin->settings()->IsPruningDateEnabled();
158
+ $is_limt_e = $this->plugin->settings()->IsPruningLimitEnabled();
159
 
160
  // Return if retention is disabled.
161
  if ( ! $is_date_e && ! $is_limt_e ) {
163
  }
164
 
165
  // Return if archiving cron is running.
166
+ if ( $this->plugin->GetGlobalSetting( 'archiving-cron-started', false ) ) {
167
  return;
168
  }
169
 
170
  // If archiving is enabled then events are deleted from the archive database.
171
+ if ( $this->plugin->settings()->IsArchivingEnabled() ) {
172
  // Switch to Archive DB.
173
+ $this->plugin->settings()->SwitchToArchiveDB();
174
  }
175
 
176
  $occ = new WSAL_Models_Occurrence();
254
  * @return integer $promoToSend - The array index.
255
  */
256
  private function GetPromoAlert() {
257
+ $last_promo_sent_id = $this->plugin->GetGlobalSetting( 'promo-send-id' );
258
  $last_promo_sent_id = empty( $last_promo_sent_id ) ? 0 : $last_promo_sent_id;
259
  $promo_to_send = null;
260
  $promo_alerts = $this->GetActivePromoText();
266
  } else {
267
  $last_promo_sent_id = 0;
268
  }
269
+ $this->plugin->SetGlobalSetting( 'promo-send-id', $last_promo_sent_id );
270
  }
271
  return $promo_to_send;
272
  }
classes/Models/Occurrence.php CHANGED
@@ -204,6 +204,10 @@ class WSAL_Models_Occurrence extends WSAL_Models_ActiveRecord {
204
  'name' => __( 'BBPress', 'wp-security-audit-log' ),
205
  'event_ids' => array( 8000, 8001, 8002, 8003, 8004, 8005, 8006, 8007, 8008, 8009, 8010, 8011, 8012, 8013, 8014, 8015, 8016, 8017, 8018, 8019, 8020, 8021, 8022, 8023 ),
206
  ),
 
 
 
 
207
  'wfcm' => array(
208
  'name' => __( 'WFCM', 'wp-security-audit-log' ),
209
  'event_ids' => array( 6028, 6029, 6030, 6031, 6032, 6033 ),
@@ -215,7 +219,7 @@ class WSAL_Models_Occurrence extends WSAL_Models_ActiveRecord {
215
  if ( in_array( $this->alert_id, $addon['event_ids'], true ) ) {
216
  // check key and update message here.
217
  $message = sprintf(
218
- 'The details of this event are unknown. You need to install the add-on for %1$s to see the details.%2$s%3$sInstall and activate extension %4$s',
219
  esc_html( $addon['name'] ),
220
  '<br />',
221
  '<button type="button" class="button-primary wsal-addon-install-trigger" data-nonce="' . esc_attr( $installer_nonce ) . '" data-addon-name="' . esc_attr( $key ) . '">',
204
  'name' => __( 'BBPress', 'wp-security-audit-log' ),
205
  'event_ids' => array( 8000, 8001, 8002, 8003, 8004, 8005, 8006, 8007, 8008, 8009, 8010, 8011, 8012, 8013, 8014, 8015, 8016, 8017, 8018, 8019, 8020, 8021, 8022, 8023 ),
206
  ),
207
+ 'woocommerce' => array(
208
+ 'name' => __( 'WooCommerce', 'wp-security-audit-log' ),
209
+ 'event_ids' => array( 9000, 9001, 9003, 9004, 9005, 9006, 9007, 9008, 9009, 9010, 9011, 9012, 9013, 9014, 9015, 9072, 9073, 9077, 9016, 9017, 9018, 9019, 9020, 9021, 9022, 9023, 9024, 9025, 9026, 9042, 9043, 9044, 9045, 9046, 9105, 9047, 9048, 9049, 9050, 9051, 9027, 9028, 9029, 9030, 9031, 9032, 9033, 9034, 9085, 9086, 9087, 9088, 9089, 9090, 9091, 9092, 9093, 9094, 9074, 9075, 9076, 9078, 9079, 9080, 9081, 9082, 9002, 9052, 9053, 9054, 9055, 9056, 9057, 9058, 9059, 9060, 9061, 9062, 9063, 9064, 9065, 9066, 9067, 9068, 9069, 9070, 9071, 9035, 9036, 9037, 9038, 9039, 9040, 9041, 9083, 9084, 9101, 9102, 9103, 9104 ),
210
+ ),
211
  'wfcm' => array(
212
  'name' => __( 'WFCM', 'wp-security-audit-log' ),
213
  'event_ids' => array( 6028, 6029, 6030, 6031, 6032, 6033 ),
219
  if ( in_array( $this->alert_id, $addon['event_ids'], true ) ) {
220
  // check key and update message here.
221
  $message = sprintf(
222
+ 'To view this event you need to install the activity log extension for %1$s. %2$s%3$sInstall and activate extension %4$s',
223
  esc_html( $addon['name'] ),
224
  '<br />',
225
  '<button type="button" class="button-primary wsal-addon-install-trigger" data-nonce="' . esc_attr( $installer_nonce ) . '" data-addon-name="' . esc_attr( $key ) . '">',
classes/Models/Option.php CHANGED
@@ -18,6 +18,9 @@ if ( ! defined( 'ABSPATH' ) ) {
18
  * Option Model gets and sets the options of the wsal_options table in the database.
19
  *
20
  * @package Wsal
 
 
 
21
  */
22
  class WSAL_Models_Option extends WSAL_Models_ActiveRecord {
23
 
@@ -67,10 +70,16 @@ class WSAL_Models_Option extends WSAL_Models_ActiveRecord {
67
  * Sets Option record.
68
  *
69
  * @param string $name - Option name.
70
- * @param mixed $value - Option value.
 
 
71
  */
72
  public function SetOptionValue( $name, $value ) {
73
- $option = $this->getAdapter()->GetNamedOption( $name );
 
 
 
 
74
  $this->id = $option['id'];
75
  $this->option_name = $name;
76
 
18
  * Option Model gets and sets the options of the wsal_options table in the database.
19
  *
20
  * @package Wsal
21
+ *
22
+ * @deprecated 4.1.3
23
+ * @see \WSAL\Helpers\Options
24
  */
25
  class WSAL_Models_Option extends WSAL_Models_ActiveRecord {
26
 
70
  * Sets Option record.
71
  *
72
  * @param string $name - Option name.
73
+ * @param mixed $value - Option value.
74
+ *
75
+ * @return bool|int|void
76
  */
77
  public function SetOptionValue( $name, $value ) {
78
+ $option = $this->getAdapter()->GetNamedOption( $name );
79
+ if ( $option == null ) {
80
+ return;
81
+ }
82
+
83
  $this->id = $option['id'];
84
  $this->option_name = $name;
85
 
classes/SensorManager.php CHANGED
@@ -50,10 +50,9 @@ final class WSAL_SensorManager extends WSAL_AbstractSensor {
50
  }
51
 
52
  /**
53
- * Load Custom Sensor files from /wp-content/uploads/wp-security-audit-log/custom-sensors/
54
  */
55
- $upload_dir = wp_upload_dir();
56
- $uploads_dir_path = trailingslashit( $upload_dir['basedir'] ) . 'wp-security-audit-log' . DIRECTORY_SEPARATOR . 'custom-sensors' . DIRECTORY_SEPARATOR;
57
 
58
  /*
59
  * Get an array of directories to loop through to add custom sensors.
@@ -199,7 +198,7 @@ final class WSAL_SensorManager extends WSAL_AbstractSensor {
199
  // Get file name.
200
  $filename = basename( $filepath, '.php' );
201
 
202
- $frontend_events = $this->plugin->settings->get_frontend_events();
203
 
204
  // Check to see if LogInOut, FrontendLogin, and FrontendRegister sensors should load on login page.
205
  if ( WpSecurityAuditLog::is_login_screen() ) {
@@ -222,7 +221,7 @@ final class WSAL_SensorManager extends WSAL_AbstractSensor {
222
  *
223
  * @param array $public_sensors - List of sensors to be loaded for visitors.
224
  */
225
- $public_sensors = apply_filters( 'wsal_load_public_sensors', array( 'FrontendLogin', 'FrontendSystem', 'FrontendRegister', 'FrontendWooCommerce' ) );
226
 
227
  if ( WpSecurityAuditLog::is_frontend() && ! is_user_logged_in() && ! in_array( $filename, $public_sensors, true ) ) {
228
  return false;
@@ -336,7 +335,7 @@ final class WSAL_SensorManager extends WSAL_AbstractSensor {
336
  * frontend, i.e., just before setting up wp query.
337
  */
338
  public function load_frontend_system_sensor() {
339
- $frontend_events = $this->plugin->settings->get_frontend_events();
340
 
341
  if ( ! empty( $frontend_events['system'] ) && is_404() ) {
342
  $sensor = new WSAL_Sensors_FrontendSystem( $this->plugin );
50
  }
51
 
52
  /**
53
+ * Load Custom Sensor files from {plugin working dir}/custom-sensors/
54
  */
55
+ $uploads_dir_path = $plugin->settings()->get_working_dir_path( 'custom-sensors', true, true );
 
56
 
57
  /*
58
  * Get an array of directories to loop through to add custom sensors.
198
  // Get file name.
199
  $filename = basename( $filepath, '.php' );
200
 
201
+ $frontend_events = WSAL_Settings::get_frontend_events();
202
 
203
  // Check to see if LogInOut, FrontendLogin, and FrontendRegister sensors should load on login page.
204
  if ( WpSecurityAuditLog::is_login_screen() ) {
221
  *
222
  * @param array $public_sensors - List of sensors to be loaded for visitors.
223
  */
224
+ $public_sensors = apply_filters( 'wsal_load_public_sensors', array( 'FrontendLogin', 'FrontendSystem', 'FrontendRegister' ) );
225
 
226
  if ( WpSecurityAuditLog::is_frontend() && ! is_user_logged_in() && ! in_array( $filename, $public_sensors, true ) ) {
227
  return false;
335
  * frontend, i.e., just before setting up wp query.
336
  */
337
  public function load_frontend_system_sensor() {
338
+ $frontend_events = WSAL_Settings::get_frontend_events();
339
 
340
  if ( ! empty( $frontend_events['system'] ) && is_404() ) {
341
  $sensor = new WSAL_Sensors_FrontendSystem( $this->plugin );
classes/Sensors/ACFMeta.php ADDED
@@ -0,0 +1,156 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ /**
3
+ * Sensor: Advanced Custom Fields
4
+ *
5
+ * Advanced Custom Fields sensor file.
6
+ *
7
+ * @since 4.1.3
8
+ * @package Wsal
9
+ */
10
+
11
+ // Exit if accessed directly.
12
+ if ( ! defined( 'ABSPATH' ) ) {
13
+ exit;
14
+ }
15
+
16
+ /**
17
+ * Sensor for events specific to Advanced Custom Fields plugin.
18
+ *
19
+ * 2131 ACF relationship added
20
+ * 2132 ACF relationship removed
21
+ *
22
+ * @package Wsal
23
+ * @subpackage Sensors
24
+ * @since 4.1.3
25
+ */
26
+ class WSAL_Sensors_ACFMeta extends WSAL_AbstractMetaDataSensor {
27
+
28
+ /**
29
+ * Array of meta data being updated.
30
+ *
31
+ * @var array
32
+ */
33
+ protected $old_meta = array();
34
+
35
+ /**
36
+ * Listening to events using WP hooks.
37
+ */
38
+ public function HookEvents() {
39
+ add_filter( "acf/pre_update_value", array( $this, 'prepare_relationship_update_check' ), 10, 4 );
40
+
41
+ // relationship field is only available for posts to we don't need to check other meta types (comment, term, or user)
42
+ add_action( "updated_post_meta", array( $this, 'on_field_updated' ), 10, 4 );
43
+ add_action( "deleted_post_meta", array( $this, 'on_field_updated' ), 10, 4 );
44
+ }
45
+
46
+ /**
47
+ * Runs before an ACF field value is updated. It stores locally information
48
+ * about relationship fields that are being updated.
49
+ *
50
+ * @param mixed $check
51
+ * @param mixed $value
52
+ * @param int $post_id
53
+ * @param array $field
54
+ *
55
+ * @return mixed
56
+ */
57
+ public function prepare_relationship_update_check( $check, $value, $post_id, $field ) {
58
+ if ( 'relationship' == $field['type'] ) {
59
+ $this->old_meta[ $field['name'] ] = [
60
+ 'field' => $field,
61
+ 'value' => get_field( $field['name'] ),
62
+ 'post_id' => $post_id
63
+ ];
64
+ }
65
+
66
+ return $check;
67
+ }
68
+
69
+ /**
70
+ * Fires immediately after updating metadata of a specific type.
71
+ *
72
+ * @param int $meta_id ID of updated metadata entry.
73
+ * @param int $object_id ID of the object metadata is for.
74
+ * @param string $meta_key Metadata key.
75
+ * @param mixed $_meta_value Metadata value. Serialized if non-scalar.
76
+ */
77
+ public function on_field_updated( $meta_id, $object_id, $meta_key, $_meta_value ) {
78
+ if ( in_array( $meta_key, array_keys( $this->old_meta ) ) ) {
79
+ if ( $this->CanLogMetaKey( $object_id, $meta_key ) ) {
80
+ $old_value = $this->convert_to_array_of_post_ids( $this->old_meta[ $meta_key ]['value'] );
81
+ $new_value = $this->convert_to_array_of_post_ids( $_meta_value );
82
+ $removed = array_diff( $old_value, $new_value );
83
+ $added = array_diff( $new_value, $old_value );
84
+
85
+ if ( ! empty( $added ) ) {
86
+ $this->log_event( 2131, $added, $object_id, $meta_key, $meta_id );
87
+ }
88
+
89
+ if ( ! empty( $removed ) ) {
90
+ $this->log_event( 2132, $removed, $object_id, $meta_key, $meta_id );
91
+ }
92
+ }
93
+ }
94
+ }
95
+
96
+ /**
97
+ * Convert arbitrary value to an array of post IDs.
98
+ *
99
+ * @param mixed $value An array of posts or post IDs or post ID as string.
100
+ *
101
+ * @return int[]
102
+ */
103
+ private function convert_to_array_of_post_ids( $value ) {
104
+ $result = [];
105
+ if ( is_array( $value ) ) {
106
+ $result = array_map( function ( $item ) {
107
+ return ( $item instanceof WP_Post ) ? $item->ID : intval( $item );
108
+ }, $value );
109
+ }
110
+
111
+ return $result;
112
+ }
113
+
114
+ /**
115
+ * Log event related to ACF relationship field.
116
+ *
117
+ * @param int $event_id
118
+ * @param int[]|WP_Post[] $relationship_post_ids
119
+ * @param int $object_id
120
+ * @param string $meta_key
121
+ * @param int $meta_id
122
+ */
123
+ private function log_event( $event_id, $relationship_post_ids, $object_id, $meta_key, $meta_id ) {
124
+ $post = get_post( $object_id );
125
+ $editor_link = $this->GetEditorLink( $object_id );
126
+ $this->plugin->alerts->Trigger(
127
+ $event_id,
128
+ array(
129
+ 'PostID' => $object_id,
130
+ 'PostTitle' => $post->post_title,
131
+ 'PostStatus' => $post->post_status,
132
+ 'PostType' => $post->post_type,
133
+ 'PostDate' => $post->post_date,
134
+ 'PostUrl' => get_permalink( $post->ID ),
135
+ 'MetaID' => $meta_id,
136
+ 'MetaKey' => $meta_key,
137
+ 'Relationships' => $this->format_relationships_label( $relationship_post_ids ),
138
+ 'MetaLink' => $meta_key,
139
+ $editor_link['name'] => $editor_link['value'],
140
+ )
141
+ );
142
+ }
143
+
144
+ /**
145
+ * Formats the relationship label for the activity log entry.
146
+ *
147
+ * @param int[] $post_ids
148
+ *
149
+ * @return string
150
+ */
151
+ private function format_relationships_label( $post_ids ) {
152
+ return implode( ', ', array_map( function ( $post_id ) {
153
+ return get_the_title( $post_id ) . ' (' . $post_id . ')';
154
+ }, $post_ids ) );
155
+ }
156
+ }
classes/Sensors/Content.php CHANGED
@@ -1264,7 +1264,7 @@ class WSAL_Sensors_Content extends WSAL_AbstractSensor {
1264
  }
1265
 
1266
  // Get post meta events.
1267
- $meta_events = array( 2053, 2054, 2055, 2062, 2016, 2120, 2119 );
1268
  foreach ( $meta_events as $meta_event ) {
1269
  if ( $this->plugin->alerts->WillOrHasTriggered( $meta_event ) ) {
1270
  return 0; // Return if any meta event has or will trigger.
@@ -1426,7 +1426,7 @@ class WSAL_Sensors_Content extends WSAL_AbstractSensor {
1426
  private function check_auto_draft( $code, $title ) {
1427
  $ignore = 0;
1428
  if ( 2008 === $code && ( 'auto-draft' === $title || 'Auto Draft' === $title ) ) {
1429
- $ignore = ( $this->plugin->settings->IsWPBackend() ) ? 0 : 1;
1430
  }
1431
  return $ignore;
1432
  }
1264
  }
1265
 
1266
  // Get post meta events.
1267
+ $meta_events = array( 2053, 2054, 2055, 2062, 2016, 2120, 2119, 2131, 2132 );
1268
  foreach ( $meta_events as $meta_event ) {
1269
  if ( $this->plugin->alerts->WillOrHasTriggered( $meta_event ) ) {
1270
  return 0; // Return if any meta event has or will trigger.
1426
  private function check_auto_draft( $code, $title ) {
1427
  $ignore = 0;
1428
  if ( 2008 === $code && ( 'auto-draft' === $title || 'Auto Draft' === $title ) ) {
1429
+ $ignore = ! $this->plugin->settings()->IsWPBackend();
1430
  }
1431
  return $ignore;
1432
  }
classes/Sensors/Database.php CHANGED
@@ -16,21 +16,41 @@ if ( ! defined( 'ABSPATH' ) ) {
16
  /**
17
  * Database sensor.
18
  *
19
- * 5010 Plugin created tables
20
- * 5011 Plugin modified tables structure
21
- * 5012 Plugin deleted tables
22
  * 5013 Theme created tables
23
  * 5014 Theme modified tables structure
24
  * 5015 Theme deleted tables
25
  * 5016 Unknown component created tables
26
  * 5017 Unknown component modified tables structure
27
  * 5018 Unknown component deleted tables
 
 
 
28
  *
29
  * @package Wsal
30
  * @subpackage Sensors
31
  */
32
  class WSAL_Sensors_Database extends WSAL_AbstractSensor {
33
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
34
  /**
35
  * Listening to events using WP hooks.
36
  */
@@ -44,132 +64,225 @@ class WSAL_Sensors_Database extends WSAL_AbstractSensor {
44
  /**
45
  * Checks for drop query.
46
  *
47
- * @param WP_Query $query - Query object.
 
 
48
  */
49
  public function EventDropQuery( $query ) {
 
 
 
50
  global $wpdb;
51
  $table_names = array();
52
  $str = explode( ' ', $query );
53
-
54
  if ( preg_match( '|DROP TABLE ([^ ]*)|', $query ) ) {
55
  if ( ! empty( $str[4] ) ) {
56
  array_push( $table_names, $str[4] );
57
  } else {
58
  array_push( $table_names, $str[2] );
59
  }
60
-
61
- $actype = isset( $_SERVER['SCRIPT_NAME'] ) ? basename( sanitize_text_field( wp_unslash( $_SERVER['SCRIPT_NAME'] ) ), '.php' ) : false;
62
- $alert_options = $this->GetActionType( $actype );
63
- $type_query = 'delete';
64
  } elseif ( preg_match( '|CREATE TABLE IF NOT EXISTS ([^ ]*)|', $query ) ) {
65
  $table_name = str_replace( '`', '', $str[5] );
66
  if ( $table_name !== $wpdb->get_var( "SHOW TABLES LIKE '" . $table_name . "'" ) ) {
67
  /**
68
  * Some plugins keep trying to create tables even
69
- * when they already exist- would result in too
70
  * many alerts.
71
  */
72
  array_push( $table_names, $table_name );
73
- $actype = isset( $_SERVER['SCRIPT_NAME'] ) ? basename( sanitize_text_field( wp_unslash( $_SERVER['SCRIPT_NAME'] ) ), '.php' ) : false;
74
- $alert_options = $this->GetActionType( $actype );
75
- $type_query = 'create';
76
  }
77
  }
78
 
 
 
 
 
 
 
 
 
 
 
 
 
 
79
  if ( ! empty( $table_names ) ) {
80
- $event_code = $this->GetEventQueryType( $actype, $type_query );
 
 
 
 
 
 
 
81
  $alert_options['TableNames'] = implode( ',', $table_names );
82
  $this->plugin->alerts->Trigger( $event_code, $alert_options );
83
  }
84
-
85
- return $query;
86
  }
87
 
88
  /**
89
- * Checks DB Delta queries.
 
 
90
  *
91
- * @param array $queries - Array of query.
92
  */
93
- public function EventDBDeltaQuery( $queries ) {
94
- $type_queries = array(
95
- 'create' => array(),
96
- 'update' => array(),
97
- 'delete' => array(),
98
- );
99
- global $wpdb;
100
 
101
- foreach ( $queries as $qry ) {
102
- $qry = str_replace( '`', '', $qry );
103
- $str = explode( ' ', $qry );
104
- if ( preg_match( '|CREATE TABLE ([^ ]*)|', $qry ) ) {
105
- if ( $str[2] !== $wpdb->get_var( "SHOW TABLES LIKE '" . $str[2] . "'" ) ) {
106
- /**
107
- * Some plugins keep trying to create tables even
108
- * when they already exist- would result in too
109
- * many alerts.
110
- */
111
- array_push( $type_queries['create'], $str[2] );
112
- }
113
- } elseif ( preg_match( '|ALTER TABLE ([^ ]*)|', $qry ) ) {
114
- array_push( $type_queries['update'], $str[2] );
115
- } elseif ( preg_match( '|DROP TABLE ([^ ]*)|', $qry ) ) {
116
- if ( ! empty( $str[4] ) ) {
117
- array_push( $type_queries['delete'], $str[4] );
118
- } else {
119
- array_push( $type_queries['delete'], $str[2] );
 
 
 
 
 
 
 
 
120
  }
121
  }
122
  }
123
 
124
- if ( ! empty( $type_queries['create'] ) || ! empty( $type_queries['update'] ) || ! empty( $type_queries['delete'] ) ) {
125
- $actype = isset( $_SERVER['SCRIPT_NAME'] ) ? basename( sanitize_text_field( wp_unslash( $_SERVER['SCRIPT_NAME'] ) ), '.php' ) : false;
126
- $alert_options = $this->GetActionType( $actype );
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
127
 
128
- foreach ( $type_queries as $query_type => $table_names ) {
129
- if ( ! empty( $table_names ) ) {
130
- $event_code = $this->GetEventQueryType( $actype, $query_type );
131
- $alert_options['TableNames'] = implode( ',', $table_names );
132
- $this->plugin->alerts->Trigger( $event_code, $alert_options );
 
 
 
 
 
 
133
  }
134
- }
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
135
  }
136
- return $queries;
 
137
  }
138
 
139
  /**
140
- * Get code alert by action and type query.
 
 
 
141
  *
142
- * @param string $type_action - Plugins, themes or unknown.
143
- * @param string $type_query - Create, update or delete.
144
  */
145
- protected function GetEventQueryType( $type_action, $type_query ) {
146
- switch ( $type_action ) {
147
  case 'plugins':
148
- if ( 'create' === $type_query ) {
149
  return 5010;
150
- } elseif ( 'update' === $type_query ) {
151
  return 5011;
152
- } elseif ( 'delete' === $type_query ) {
153
  return 5012;
154
  }
155
  break;
156
 
157
  case 'themes':
158
- if ( 'create' === $type_query ) {
159
  return 5013;
160
- } elseif ( 'update' === $type_query ) {
161
  return 5014;
162
- } elseif ( 'delete' === $type_query ) {
163
  return 5015;
164
  }
165
  break;
166
 
 
 
 
 
 
 
 
 
 
167
  default:
168
- if ( 'create' === $type_query ) {
169
  return 5016;
170
- } elseif ( 'update' === $type_query ) {
171
  return 5017;
172
- } elseif ( 'delete' === $type_query ) {
173
  return 5018;
174
  }
175
  break;
@@ -177,63 +290,53 @@ class WSAL_Sensors_Database extends WSAL_AbstractSensor {
177
  }
178
 
179
  /**
180
- * Get info by action type.
 
 
181
  *
182
- * @param string $actype - Plugins, themes or unknown.
183
  */
184
- protected function GetActionType( $actype ) {
185
- // Check the component type (theme or plugin).
186
- $is_themes = 'themes' === $actype;
187
- $is_plugins = 'plugins' === $actype;
188
 
189
- // Action Plugin Component.
190
- $alert_options = array();
191
- if ( $is_plugins ) {
192
- $plugin_file = '';
193
- // @codingStandardsIgnoreStart
194
- if ( isset( $_GET['plugin'] ) ) {
195
- $plugin_file = sanitize_text_field( wp_unslash( $_GET['plugin'] ) );
196
- } elseif ( isset( $_GET['checked'] ) ) {
197
- $plugin_file = sanitize_text_field( wp_unslash( $_GET['checked'][0] ) );
198
- }
199
- // @codingStandardsIgnoreEnd
200
-
201
- // Get plugin data.
202
- $plugins = get_plugins();
203
- if ( isset( $plugins[ $plugin_file ] ) ) {
204
- $plugin = $plugins[ $plugin_file ];
205
-
206
- // Set alert options.
207
- $alert_options['Plugin'] = (object) array(
208
- 'Name' => $plugin['Name'],
209
- 'PluginURI' => $plugin['PluginURI'],
210
- 'Version' => $plugin['Version'],
211
- );
212
- } else {
213
- $plugin_name = basename( $plugin_file, '.php' );
214
- $plugin_name = str_replace( array( '_', '-', ' ' ), ' ', $plugin_name );
215
- $plugin_name = ucwords( $plugin_name );
216
- $alert_options['Plugin'] = (object) array( 'Name' => $plugin_name );
217
  }
218
- } elseif ( $is_themes ) {
219
- // Action Theme Component.
220
- $theme_name = '';
221
-
222
- // @codingStandardsIgnoreStart
223
- if ( isset( $_GET['theme'] ) ) {
224
- $theme_name = sanitize_text_field( wp_unslash( $_GET['theme'] ) );
225
- } elseif ( isset( $_GET['checked'] ) ) {
226
- $theme_name = sanitize_text_field( wp_unslash( $_GET['checked'][0] ) );
227
  }
228
- // @codingStandardsIgnoreEnd
229
-
230
- $theme_name = str_replace( array( '_', '-', ' ' ), ' ', $theme_name );
231
- $theme_name = ucwords( $theme_name );
232
- $alert_options['Theme'] = (object) array( 'Name' => $theme_name );
233
- } else {
234
- // Action Unknown Component.
235
- $alert_options['Component'] = 'Unknown';
236
  }
237
- return $alert_options;
 
238
  }
239
  }
16
  /**
17
  * Database sensor.
18
  *
19
+ * 5010 Plugin created table
20
+ * 5011 Plugin modified table structure
21
+ * 5012 Plugin deleted table
22
  * 5013 Theme created tables
23
  * 5014 Theme modified tables structure
24
  * 5015 Theme deleted tables
25
  * 5016 Unknown component created tables
26
  * 5017 Unknown component modified tables structure
27
  * 5018 Unknown component deleted tables
28
+ * 5022 WordPress created tables
29
+ * 5023 WordPress modified tables structure
30
+ * 5024 WordPress deleted tables
31
  *
32
  * @package Wsal
33
  * @subpackage Sensors
34
  */
35
  class WSAL_Sensors_Database extends WSAL_AbstractSensor {
36
 
37
+ /**
38
+ * Local cache for basename of current script. It used used to improve performance
39
+ * of determining the actor of current action.
40
+ *
41
+ * @var string|bool
42
+ */
43
+ private $script_basename = null;
44
+
45
+ /**
46
+ * If true, database events are being logged. This is used by the plugin's update process to temporarily disable
47
+ * the database sensor to prevent errors (events are registered after the upgrade process is run).
48
+ *
49
+ * @var bool
50
+ * @since 4.1.3
51
+ */
52
+ public static $enabled = true;
53
+
54
  /**
55
  * Listening to events using WP hooks.
56
  */
64
  /**
65
  * Checks for drop query.
66
  *
67
+ * @param string $query - Database query string.
68
+ *
69
+ * @return string
70
  */
71
  public function EventDropQuery( $query ) {
72
+ if ( ! self::$enabled ) {
73
+ return $query;
74
+ }
75
  global $wpdb;
76
  $table_names = array();
77
  $str = explode( ' ', $query );
78
+ $query_type = '';
79
  if ( preg_match( '|DROP TABLE ([^ ]*)|', $query ) ) {
80
  if ( ! empty( $str[4] ) ) {
81
  array_push( $table_names, $str[4] );
82
  } else {
83
  array_push( $table_names, $str[2] );
84
  }
85
+ $query_type = 'delete';
 
 
 
86
  } elseif ( preg_match( '|CREATE TABLE IF NOT EXISTS ([^ ]*)|', $query ) ) {
87
  $table_name = str_replace( '`', '', $str[5] );
88
  if ( $table_name !== $wpdb->get_var( "SHOW TABLES LIKE '" . $table_name . "'" ) ) {
89
  /**
90
  * Some plugins keep trying to create tables even
91
+ * when they already exist - would result in too
92
  * many alerts.
93
  */
94
  array_push( $table_names, $table_name );
95
+ $query_type = 'create';
 
 
96
  }
97
  }
98
 
99
+ $this->MaybeTriggerEvent( $query_type, $table_names );
100
+
101
+ return $query;
102
+ }
103
+
104
+ /**
105
+ * Triggers an event if the list of tables is not empty. It also checks if
106
+ * the event should be logged for events originated by WordPress.
107
+ *
108
+ * @param string $query_type
109
+ * @param string[] $table_names
110
+ */
111
+ private function MaybeTriggerEvent( $query_type, $table_names ) {
112
  if ( ! empty( $table_names ) ) {
113
+ $actor = $this->GetActor( $table_names );
114
+ if ( 'wordpress' === $actor && ! $this->plugin->settings()->IsWPBackend() ) {
115
+ // event is not fired if the monitoring of background events is disabled
116
+ return;
117
+ }
118
+
119
+ $alert_options = $this->GetEventOptions( $actor );
120
+ $event_code = $this->GetEventCode( $actor, $query_type );
121
  $alert_options['TableNames'] = implode( ',', $table_names );
122
  $this->plugin->alerts->Trigger( $event_code, $alert_options );
123
  }
 
 
124
  }
125
 
126
  /**
127
+ * Determine the actor of database change.
128
+ *
129
+ * @param string[] $table_names Names of the tables that are being changed.
130
  *
131
+ * @return bool|string Theme, plugin or false if unknown.
132
  */
133
+ private function GetActor( $table_names ) {
134
+ // default actor (treated as an unknown component)
135
+ $result = false;
 
 
 
 
136
 
137
+ // use current script name to determine if the actor is theme or a plugin
138
+
139
+ if ( is_null( $this->script_basename ) ) {
140
+ $this->script_basename = isset( $_SERVER['SCRIPT_NAME'] ) ? basename( sanitize_text_field( wp_unslash( $_SERVER['SCRIPT_NAME'] ) ), '.php' ) : false;
141
+ }
142
+
143
+ $result = $this->script_basename;
144
+
145
+ // check table names for default WordPress table names (including network tables)
146
+ if ( $this->ContainsWordPressTable( $table_names ) ) {
147
+ $result = 'wordpress';
148
+ }
149
+
150
+ return $result;
151
+ }
152
+
153
+ private function ContainsWordPressTable( $tables ) {
154
+ if ( ! empty( $tables ) ) {
155
+ global $wpdb;
156
+ $prefix = preg_quote( $wpdb->prefix );
157
+ $site_regex = '/\b' . $prefix . '(\d+_)?(commentmeta|comments|links|options|postmeta|posts|terms|termmeta|term_relationships|term_relationships|term_taxonomy|usermeta|users)\b/';
158
+ $network_regex = '/\b' . $prefix . '(blogs|blog_versions|registration_log|signups|site|sitemeta|users|usermeta)\b/';
159
+
160
+ foreach ( $tables as $table ) {
161
+ if ( preg_match( $site_regex, $table ) || preg_match( $network_regex, $table ) ) {
162
+ // stop as soon as the first WordPress table is found
163
+ return true;
164
  }
165
  }
166
  }
167
 
168
+ return false;
169
+ }
170
+
171
+ /**
172
+ * Get event options by actor.
173
+ *
174
+ * @param string $actor - Plugins, themes, WordPress or unknown.
175
+ *
176
+ * @return array
177
+ */
178
+ protected function GetEventOptions( $actor ) {
179
+ // Check the actor
180
+ $alert_options = array();
181
+ switch ( $actor ) {
182
+ case 'plugins':
183
+ // Action Plugin Component.
184
+ $plugin_file = '';
185
+ // @codingStandardsIgnoreStart
186
+ if ( isset( $_GET['plugin'] ) ) {
187
+ $plugin_file = sanitize_text_field( wp_unslash( $_GET['plugin'] ) );
188
+ } elseif ( isset( $_GET['checked'] ) ) {
189
+ $plugin_file = sanitize_text_field( wp_unslash( $_GET['checked'][0] ) );
190
+ }
191
+ // @codingStandardsIgnoreEnd
192
+
193
+ // Get plugin data.
194
+ $plugins = get_plugins();
195
+ if ( isset( $plugins[ $plugin_file ] ) ) {
196
+ $plugin = $plugins[ $plugin_file ];
197
 
198
+ // Set alert options.
199
+ $alert_options['Plugin'] = (object) array(
200
+ 'Name' => $plugin['Name'],
201
+ 'PluginURI' => $plugin['PluginURI'],
202
+ 'Version' => $plugin['Version'],
203
+ );
204
+ } else {
205
+ $plugin_name = basename( $plugin_file, '.php' );
206
+ $plugin_name = str_replace( array( '_', '-', ' ' ), ' ', $plugin_name );
207
+ $plugin_name = ucwords( $plugin_name );
208
+ $alert_options['Plugin'] = (object) array( 'Name' => $plugin_name );
209
  }
210
+ break;
211
+ case 'themes':
212
+ // Action Theme Component.
213
+ $theme_name = '';
214
+
215
+ // @codingStandardsIgnoreStart
216
+ if ( isset( $_GET['theme'] ) ) {
217
+ $theme_name = sanitize_text_field( wp_unslash( $_GET['theme'] ) );
218
+ } elseif ( isset( $_GET['checked'] ) ) {
219
+ $theme_name = sanitize_text_field( wp_unslash( $_GET['checked'][0] ) );
220
+ }
221
+ // @codingStandardsIgnoreEnd
222
+
223
+ $theme_name = str_replace( array( '_', '-', ' ' ), ' ', $theme_name );
224
+ $theme_name = ucwords( $theme_name );
225
+ $alert_options['Theme'] = (object) array( 'Name' => $theme_name );
226
+ break;
227
+
228
+ case 'wordpress':
229
+ $alert_options['Component'] = 'WordPress';
230
+ break;
231
+
232
+ default:
233
+ // Action Unknown Component.
234
+ $alert_options['Component'] = 'Unknown';
235
+
236
  }
237
+
238
+ return $alert_options;
239
  }
240
 
241
  /**
242
+ * Get alert code by actor and query type.
243
+ *
244
+ * @param string $actor - Plugins, themes, WordPress or unknown.
245
+ * @param string $query_type - Create, update or delete.
246
  *
247
+ * @return int Event code.
 
248
  */
249
+ protected function GetEventCode( $actor, $query_type ) {
250
+ switch ( $actor ) {
251
  case 'plugins':
252
+ if ( 'create' === $query_type ) {
253
  return 5010;
254
+ } elseif ( 'update' === $query_type ) {
255
  return 5011;
256
+ } elseif ( 'delete' === $query_type ) {
257
  return 5012;
258
  }
259
  break;
260
 
261
  case 'themes':
262
+ if ( 'create' === $query_type ) {
263
  return 5013;
264
+ } elseif ( 'update' === $query_type ) {
265
  return 5014;
266
+ } elseif ( 'delete' === $query_type ) {
267
  return 5015;
268
  }
269
  break;
270
 
271
+ case 'wordpress':
272
+ if ( 'create' === $query_type ) {
273
+ return 5022;
274
+ } elseif ( 'update' === $query_type ) {
275
+ return 5023;
276
+ } elseif ( 'delete' === $query_type ) {
277
+ return 5024;
278
+ }
279
+ break;
280
  default:
281
+ if ( 'create' === $query_type ) {
282
  return 5016;
283
+ } elseif ( 'update' === $query_type ) {
284
  return 5017;
285
+ } elseif ( 'delete' === $query_type ) {
286
  return 5018;
287
  }
288
  break;
290
  }
291
 
292
  /**
293
+ * Checks DB Delta queries.
294
+ *
295
+ * @param array $queries - Array of queries.
296
  *
297
+ * @return array
298
  */
299
+ public function EventDBDeltaQuery( $queries ) {
300
+ if ( ! self::$enabled ) {
301
+ return $queries;
302
+ }
303
 
304
+ $query_types = array(
305
+ 'create' => array(),
306
+ 'update' => array(),
307
+ 'delete' => array(),
308
+ );
309
+
310
+ global $wpdb;
311
+ foreach ( $queries as $qry ) {
312
+ $qry = str_replace( '`', '', $qry );
313
+ $str = explode( ' ', $qry );
314
+ if ( preg_match( '|CREATE TABLE ([^ ]*)|', $qry ) ) {
315
+ if ( $str[2] !== $wpdb->get_var( "SHOW TABLES LIKE '" . $str[2] . "'" ) ) {
316
+ /**
317
+ * Some plugins keep trying to create tables even
318
+ * when they already exist- would result in too
319
+ * many alerts.
320
+ */
321
+ array_push( $query_types['create'], $str[2] );
322
+ }
323
+ } elseif ( preg_match( '|ALTER TABLE ([^ ]*)|', $qry ) ) {
324
+ array_push( $query_types['update'], $str[2] );
325
+ } elseif ( preg_match( '|DROP TABLE ([^ ]*)|', $qry ) ) {
326
+ if ( ! empty( $str[4] ) ) {
327
+ array_push( $query_types['delete'], $str[4] );
328
+ } else {
329
+ array_push( $query_types['delete'], $str[2] );
330
+ }
 
331
  }
332
+ }
333
+
334
+ if ( ! empty( $query_types['create'] ) || ! empty( $query_types['update'] ) || ! empty( $query_types['delete'] ) ) {
335
+ foreach ( $query_types as $query_type => $table_names ) {
336
+ $this->MaybeTriggerEvent( $query_type, $table_names );
 
 
 
 
337
  }
 
 
 
 
 
 
 
 
338
  }
339
+
340
+ return $queries;
341
  }
342
  }
classes/Sensors/FrontendLogin.php CHANGED
@@ -35,9 +35,9 @@ class WSAL_Sensors_FrontendLogin extends WSAL_AbstractSensor {
35
  }
36
 
37
  $user_login = $user->data->user_login;
38
- $user_roles = $this->plugin->settings->GetCurrentUserRoles( $user->roles );
39
 
40
- if ( $this->plugin->settings->IsLoginSuperAdmin( $user_login ) ) {
41
  $user_roles[] = 'superadmin';
42
  }
43
 
35
  }
36
 
37
  $user_login = $user->data->user_login;
38
+ $user_roles = $this->plugin->settings()->GetCurrentUserRoles( $user->roles );
39
 
40
+ if ( $this->plugin->settings()->IsLoginSuperAdmin( $user_login ) ) {
41
  $user_roles[] = 'superadmin';
42
  }
43
 
classes/Sensors/FrontendSystem.php CHANGED
@@ -43,7 +43,7 @@ class WSAL_Sensors_FrontendSystem extends WSAL_AbstractSensor {
43
  $msg = 'times';
44
  list( $y, $m, $d ) = explode( '-', date( 'Y-m-d' ) );
45
  $site_id = function_exists( 'get_current_blog_id' ) ? get_current_blog_id() : 0;
46
- $ip = $this->plugin->settings->GetMainClientIP();
47
 
48
  if ( ! is_user_logged_in() ) {
49
  $username = 'Website Visitor';
@@ -171,7 +171,7 @@ class WSAL_Sensors_FrontendSystem extends WSAL_AbstractSensor {
171
  * @return integer limit
172
  */
173
  protected function get_visitor_404_log_limit() {
174
- return $this->plugin->settings->GetVisitor404LogLimit();
175
  }
176
 
177
  /**
@@ -185,7 +185,7 @@ class WSAL_Sensors_FrontendSystem extends WSAL_AbstractSensor {
185
  return false;
186
  }
187
 
188
- if ( in_array( $url, $this->plugin->settings->get_excluded_urls() ) ) {
189
  return true;
190
  }
191
  }
@@ -194,19 +194,21 @@ class WSAL_Sensors_FrontendSystem extends WSAL_AbstractSensor {
194
  * Write Log.
195
  *
196
  * Write a new line on 404 log file.
197
- * Folder: /uploads/wp-security-audit-log/404s/
198
  *
199
- * @param int $attempts - Number of attempt.
200
- * @param string $ip - IP address.
201
  * @param string $username - Username.
202
- * @param string $url - 404 URL.
 
 
203
  */
204
  private function write_log( $attempts, $ip, $username = '', $url = null ) {
205
  $name_file = null;
206
 
207
- if ( 'on' === $this->plugin->options_helper->get_option_value( 'log-visitor-404', 'off' ) ) {
208
  // Get option to log referrer.
209
- $log_referrer = $this->plugin->options_helper->get_option_value( 'log-visitor-404-referrer' );
210
 
211
  // Check localhost.
212
  if ( '127.0.0.1' == $ip || '::1' == $ip ) {
@@ -243,21 +245,16 @@ class WSAL_Sensors_FrontendSystem extends WSAL_AbstractSensor {
243
  $username = '';
244
 
245
  // get the custom logging path from settings.
246
- $custom_logging_path = $this->plugin->options_helper->get_logging_path() . '404s/';
247
- $custom_logging_url = $this->plugin->options_helper->get_logging_url() . '404s/';
248
-
249
- if ( ! $this->CheckDirectory( $custom_logging_path ) ) {
250
- $dir_made = wp_mkdir_p( $custom_logging_path );
251
- if ( $dir_made ) {
252
  // make an empty index.php in the directory.
253
  @file_put_contents( $custom_logging_path . 'index.php', '<?php // Silence is golden' );
254
  }
255
- }
256
 
257
- // Check directory.
258
- if ( $this->CheckDirectory( $custom_logging_path ) ) {
259
  $filename = '6023_' . date( 'Ymd' ) . '.log';
260
  $fp = $custom_logging_path . $filename;
 
261
  $name_file = $custom_logging_url . $filename;
262
  if ( ! $file = fopen( $fp, 'a' ) ) {
263
  $i = 1;
43
  $msg = 'times';
44
  list( $y, $m, $d ) = explode( '-', date( 'Y-m-d' ) );
45
  $site_id = function_exists( 'get_current_blog_id' ) ? get_current_blog_id() : 0;
46
+ $ip = $this->plugin->settings()->GetMainClientIP();
47
 
48
  if ( ! is_user_logged_in() ) {
49
  $username = 'Website Visitor';
171
  * @return integer limit
172
  */
173
  protected function get_visitor_404_log_limit() {
174
+ return $this->plugin->settings()->GetVisitor404LogLimit();
175
  }
176
 
177
  /**
185
  return false;
186
  }
187
 
188
+ if ( in_array( $url, $this->plugin->settings()->get_excluded_urls() ) ) {
189
  return true;
190
  }
191
  }
194
  * Write Log.
195
  *
196
  * Write a new line on 404 log file.
197
+ * Folder: {plugin working folder}/404s/
198
  *
199
+ * @param int $attempts - Number of attempt.
200
+ * @param string $ip - IP address.
201
  * @param string $username - Username.
202
+ * @param string $url - 404 URL.
203
+ *
204
+ * @return string|null
205
  */
206
  private function write_log( $attempts, $ip, $username = '', $url = null ) {
207
  $name_file = null;
208
 
209
+ if ( $this->plugin->GetGlobalBooleanSetting( 'log-visitor-404', false ) ) {
210
  // Get option to log referrer.
211
+ $log_referrer = $this->plugin->GetGlobalBooleanSetting( 'log-visitor-404-referrer' );
212
 
213
  // Check localhost.
214
  if ( '127.0.0.1' == $ip || '::1' == $ip ) {
245
  $username = '';
246
 
247
  // get the custom logging path from settings.
248
+ $custom_logging_path = $this->plugin->settings()->get_working_dir_path( '404s' );
249
+ if ( ! is_wp_error( $custom_logging_path ) ) {
250
+ if ( ! file_exists( $custom_logging_path . 'index.php' ) ) {
 
 
 
251
  // make an empty index.php in the directory.
252
  @file_put_contents( $custom_logging_path . 'index.php', '<?php // Silence is golden' );
253
  }
 
254
 
 
 
255
  $filename = '6023_' . date( 'Ymd' ) . '.log';
256
  $fp = $custom_logging_path . $filename;
257
+ $custom_logging_url = $this->plugin->settings()->get_working_dir_url( '404s' );
258
  $name_file = $custom_logging_url . $filename;
259
  if ( ! $file = fopen( $fp, 'a' ) ) {
260
  $i = 1;
classes/Sensors/FrontendWooCommerce.php CHANGED
@@ -1,6 +1,7 @@
1
  <?php
2
  /**
3
  * Frontend WooCommerce sensor.
 
4
  *
5
  * @package wsal
6
  */
@@ -46,7 +47,6 @@ class WSAL_Sensors_FrontendWooCommerce extends WSAL_AbstractSensor {
46
  $order_post = get_post( $order_id ); // Get order post object.
47
  $order_title = ( null !== $order_post && $order_post instanceof WP_Post ) ? $order_post->post_title : false;
48
  $editor_link = $this->get_editor_link( $order_post );
49
-
50
  $this->plugin->alerts->Trigger(
51
  9035,
52
  array(
@@ -171,11 +171,29 @@ class WSAL_Sensors_FrontendWooCommerce extends WSAL_AbstractSensor {
171
  );
172
  }
173
 
174
- $wc_all_stock_changes = $this->plugin->GetGlobalOption( 'wc-all-stock-changes', 'on' );
175
 
176
  // If stock has changed then trigger the alert.
177
  if ( ( $old_stock !== $new_stock ) && ( 'on' === $wc_all_stock_changes ) ) {
178
  $editor_link = $this->get_editor_link( $post );
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
179
  /**
180
  * Event was changed from 9019 to 9105
181
  *
@@ -190,6 +208,7 @@ class WSAL_Sensors_FrontendWooCommerce extends WSAL_AbstractSensor {
190
  'OldValue' => ! empty( $old_stock ) ? $old_stock : 0,
191
  'NewValue' => $new_stock,
192
  'Username' => $username,
 
193
  $editor_link['name'] => $editor_link['value'],
194
  )
195
  );
1
  <?php
2
  /**
3
  * Frontend WooCommerce sensor.
4
+ * Although WC is handled by an extension, this is kept to avoid causing issue.
5
  *
6
  * @package wsal
7
  */
47
  $order_post = get_post( $order_id ); // Get order post object.
48
  $order_title = ( null !== $order_post && $order_post instanceof WP_Post ) ? $order_post->post_title : false;
49
  $editor_link = $this->get_editor_link( $order_post );
 
50
  $this->plugin->alerts->Trigger(
51
  9035,
52
  array(
171
  );
172
  }
173
 
174
+ $wc_all_stock_changes = $this->plugin->GetGlobalBooleanSetting( 'wc-all-stock-changes', true );
175
 
176
  // If stock has changed then trigger the alert.
177
  if ( ( $old_stock !== $new_stock ) && ( 'on' === $wc_all_stock_changes ) ) {
178
  $editor_link = $this->get_editor_link( $post );
179
+
180
+ // Check if this was done via an order by looking for event 9035.
181
+ // If so, we are going to add its data.
182
+ $query = new WSAL_Models_OccurrenceQuery();
183
+ $query->addOrderBy( 'created_on', true );
184
+ $query->setLimit( 1 );
185
+ $last_occurence = $query->getAdapter()->Execute( $query );
186
+ if ( isset( $last_occurence[0] ) && 9035 === $last_occurence[0]->alert_id ) {
187
+ $latest_event = $this->plugin->alerts->get_latest_events();
188
+ $latest_event = isset( $latest_event[0] ) ? $latest_event[0] : false;
189
+ $event_meta = $latest_event ? $latest_event->GetMetaArray() : false;
190
+ $order_id = isset( $event_meta['OrderID'] ) ? $event_meta['OrderID'] : false;
191
+ $order_title = isset( $event_meta['OrderTitle'] ) ? $event_meta['OrderTitle'] : false;
192
+ } else {
193
+ $order_id = false;
194
+ $order_title = false;
195
+ }
196
+
197
  /**
198
  * Event was changed from 9019 to 9105
199
  *
208
  'OldValue' => ! empty( $old_stock ) ? $old_stock : 0,
209
  'NewValue' => $new_stock,
210
  'Username' => $username,
211
+ 'StockOrderID' => $order_id,
212
  $editor_link['name'] => $editor_link['value'],
213
  )
214
  );
classes/Sensors/LogInOut.php CHANGED
@@ -60,35 +60,6 @@ class WSAL_Sensors_LogInOut extends WSAL_AbstractSensor {
60
  if ( WpSecurityAuditLog::is_plugin_active( 'user-switching/user-switching.php' ) ) {
61
  add_action( 'switch_to_user', array( $this, 'user_switched_event' ), 10, 2 );
62
  }
63
-
64
- // Directory for logged in users log files.
65
- $user_upload_dir = wp_upload_dir();
66
- $failed_login_dir = trailingslashit( $user_upload_dir['basedir'] . '/wp-security-audit-log/failed-logins/' );
67
-
68
- /**
69
- * Check if failed login directory exists then
70
- * delete all files within this directory and
71
- * remove the directory itself.
72
- *
73
- * @since 3.1.2
74
- */
75
- if ( is_dir( $failed_login_dir ) ) {
76
- // Get all files inside failed logins folder.
77
- $files = glob( $failed_login_dir . '*' );
78
-
79
- if ( ! empty( $files ) ) {
80
- // Unlink each file.
81
- foreach ( $files as $file ) {
82
- // Check if valid file.
83
- if ( is_file( $file ) ) {
84
- // Delete the file.
85
- unlink( $file );
86
- }
87
- }
88
- }
89
- // Remove the directory.
90
- rmdir( $failed_login_dir );
91
- }
92
  }
93
 
94
  /**
@@ -124,9 +95,9 @@ class WSAL_Sensors_LogInOut extends WSAL_AbstractSensor {
124
  // If provider and user are set and provider is known then log the event.
125
  if ( $provider && $user && in_array( $provider, $providers_2fa, true ) ) {
126
  // Get user roles.
127
- $user_roles = $this->plugin->settings->GetCurrentUserRoles( $user->roles );
128
 
129
- if ( $this->plugin->settings->IsLoginSuperAdmin( $user->user_login ) ) {
130
  $user_roles[] = 'superadmin';
131
  }
132
 
@@ -178,7 +149,7 @@ class WSAL_Sensors_LogInOut extends WSAL_AbstractSensor {
178
 
179
  // Log user changed password alert.
180
  if ( ! empty( $user ) ) {
181
- $user_roles = $this->plugin->settings->GetCurrentUserRoles( $user->roles );
182
  $this->plugin->alerts->Trigger(
183
  4003,
184
  array(
@@ -198,9 +169,9 @@ class WSAL_Sensors_LogInOut extends WSAL_AbstractSensor {
198
  return;
199
  }
200
  $user_login = $user->data->user_login;
201
- $user_roles = $this->plugin->settings->GetCurrentUserRoles( $user->roles );
202
 
203
- if ( $this->plugin->settings->IsLoginSuperAdmin( $user_login ) ) {
204
  $user_roles[] = 'superadmin';
205
  }
206
 
@@ -212,10 +183,17 @@ class WSAL_Sensors_LogInOut extends WSAL_AbstractSensor {
212
  $alert_data['SessionID'] = WSAL_UserSessions_Helpers::hash_token( $token );
213
  }
214
 
215
- $this->plugin->alerts->Trigger(
216
  1000,
217
  $alert_data,
218
- true
 
 
 
 
 
 
 
219
  );
220
 
221
  }
@@ -226,7 +204,7 @@ class WSAL_Sensors_LogInOut extends WSAL_AbstractSensor {
226
  public function EventLogout() {
227
  if ( $this->_current_user->ID ) {
228
  // get the list of excluded users.
229
- $excluded_users = $this->plugin->settings->GetExcludedMonitoringUsers();
230
  $excluded_user_ids = array();
231
  // convert excluded usernames into IDs.
232
  if ( ! empty( $excluded_users ) && is_array( $excluded_users ) ) {
@@ -243,7 +221,7 @@ class WSAL_Sensors_LogInOut extends WSAL_AbstractSensor {
243
  1001,
244
  array(
245
  'CurrentUserID' => $this->_current_user->ID,
246
- 'CurrentUserRoles' => $this->plugin->settings->GetCurrentUserRoles( $this->_current_user->roles ),
247
  ),
248
  true
249
  );
@@ -256,7 +234,7 @@ class WSAL_Sensors_LogInOut extends WSAL_AbstractSensor {
256
  * @return int
257
  */
258
  protected function GetLoginFailureLogLimit() {
259
- return $this->plugin->settings->get_failed_login_limit();
260
  }
261
 
262
  /**
@@ -265,7 +243,7 @@ class WSAL_Sensors_LogInOut extends WSAL_AbstractSensor {
265
  * @return int
266
  */
267
  protected function GetVisitorLoginFailureLogLimit() {
268
- return $this->plugin->settings->get_visitor_failed_login_limit();
269
  }
270
 
271
  /**
@@ -345,7 +323,7 @@ class WSAL_Sensors_LogInOut extends WSAL_AbstractSensor {
345
  public function EventLoginFailure( $username ) {
346
  list($y, $m, $d) = explode( '-', date( 'Y-m-d' ) );
347
 
348
- $ip = $this->plugin->settings->GetMainClientIP();
349
 
350
  // Filter $_POST global array for security.
351
  $post_array = filter_input_array( INPUT_POST );
@@ -357,8 +335,8 @@ class WSAL_Sensors_LogInOut extends WSAL_AbstractSensor {
357
  $site_id = ( function_exists( 'get_current_blog_id' ) ? get_current_blog_id() : 0 );
358
  if ( $user ) {
359
  $new_alert_code = 1002;
360
- $user_roles = $this->plugin->settings->GetCurrentUserRoles( $user->roles );
361
- if ( $this->plugin->settings->IsLoginSuperAdmin( $username ) ) {
362
  $user_roles[] = 'superadmin';
363
  }
364
  }
@@ -390,13 +368,19 @@ class WSAL_Sensors_LogInOut extends WSAL_AbstractSensor {
390
  );
391
  $occ = count( $occ ) ? $occ[0] : null;
392
 
 
 
 
 
 
393
  if ( ! empty( $occ ) ) {
394
  // Update existing record exists user.
395
  $this->IncrementLoginFailure( $ip, $site_id, $user );
396
  $new = $occ->GetMetaValue( 'Attempts', 0 ) + 1;
397
 
398
- if ( -1 !== (int) $this->GetLoginFailureLogLimit()
399
- && $new > $this->GetLoginFailureLogLimit() ) {
 
400
  $new = $this->GetLoginFailureLogLimit() . '+';
401
  }
402
 
@@ -415,7 +399,16 @@ class WSAL_Sensors_LogInOut extends WSAL_AbstractSensor {
415
  'Username' => $username,
416
  'LogFileText' => '',
417
  'CurrentUserRoles' => $user_roles,
418
- )
 
 
 
 
 
 
 
 
 
419
  );
420
  }
421
  } else {
@@ -487,7 +480,7 @@ class WSAL_Sensors_LogInOut extends WSAL_AbstractSensor {
487
  */
488
  public function EventPasswordReset( $user, $new_pass ) {
489
  if ( ! empty( $user ) ) {
490
- $user_roles = $this->plugin->settings->GetCurrentUserRoles( $user->roles );
491
  $this->plugin->alerts->Trigger(
492
  4003,
493
  array(
@@ -516,8 +509,8 @@ class WSAL_Sensors_LogInOut extends WSAL_AbstractSensor {
516
  }
517
 
518
  // get the users roles.
519
- $user_roles = $this->plugin->settings->GetCurrentUserRoles( $user->roles );
520
- if ( $this->plugin->settings->IsLoginSuperAdmin( $username ) ) {
521
  $user_roles[] = 'superadmin';
522
  }
523
 
@@ -574,10 +567,10 @@ class WSAL_Sensors_LogInOut extends WSAL_AbstractSensor {
574
  */
575
  public function user_switched_event( $new_user_id, $old_user_id ) {
576
  $target_user = get_user_by( 'ID', $new_user_id );
577
- $target_user_roles = $this->plugin->settings->GetCurrentUserRoles( $target_user->roles );
578
  $target_user_roles = implode( ', ', $target_user_roles );
579
  $old_user = get_user_by( 'ID', $old_user_id );
580
- $old_user_roles = $this->plugin->settings->GetCurrentUserRoles( $old_user->roles );
581
 
582
  $this->plugin->alerts->Trigger(
583
  1008,
60
  if ( WpSecurityAuditLog::is_plugin_active( 'user-switching/user-switching.php' ) ) {
61
  add_action( 'switch_to_user', array( $this, 'user_switched_event' ), 10, 2 );
62
  }
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
63
  }
64
 
65
  /**
95
  // If provider and user are set and provider is known then log the event.
96
  if ( $provider && $user && in_array( $provider, $providers_2fa, true ) ) {
97
  // Get user roles.
98
+ $user_roles = $this->plugin->settings()->GetCurrentUserRoles( $user->roles );
99
 
100
+ if ( $this->plugin->settings()->IsLoginSuperAdmin( $user->user_login ) ) {
101
  $user_roles[] = 'superadmin';
102
  }
103
 
149
 
150
  // Log user changed password alert.
151
  if ( ! empty( $user ) ) {
152
+ $user_roles = $this->plugin->settings()->GetCurrentUserRoles( $user->roles );
153
  $this->plugin->alerts->Trigger(
154
  4003,
155
  array(
169
  return;
170
  }
171
  $user_login = $user->data->user_login;
172
+ $user_roles = $this->plugin->settings()->GetCurrentUserRoles( $user->roles );
173
 
174
+ if ( $this->plugin->settings()->IsLoginSuperAdmin( $user_login ) ) {
175
  $user_roles[] = 'superadmin';
176
  }
177
 
183
  $alert_data['SessionID'] = WSAL_UserSessions_Helpers::hash_token( $token );
184
  }
185
 
186
+ $this->plugin->alerts->TriggerIf(
187
  1000,
188
  $alert_data,
189
+ /**
190
+ * @param WSAL_AlertManager$manager
191
+ * @return bool
192
+ */
193
+ function ( $manager ) {
194
+ // don't fire if the user is changing their password via admin profile page
195
+ return ! $manager->WillOrHasTriggered(4003);
196
+ }
197
  );
198
 
199
  }
204
  public function EventLogout() {
205
  if ( $this->_current_user->ID ) {
206
  // get the list of excluded users.
207
+ $excluded_users = $this->plugin->settings()->GetExcludedMonitoringUsers();
208
  $excluded_user_ids = array();
209
  // convert excluded usernames into IDs.
210
  if ( ! empty( $excluded_users ) && is_array( $excluded_users ) ) {
221
  1001,
222
  array(
223
  'CurrentUserID' => $this->_current_user->ID,
224
+ 'CurrentUserRoles' => $this->plugin->settings()->GetCurrentUserRoles( $this->_current_user->roles ),
225
  ),
226
  true
227
  );
234
  * @return int
235
  */
236
  protected function GetLoginFailureLogLimit() {
237
+ return $this->plugin->settings()->get_failed_login_limit();
238
  }
239
 
240
  /**
243
  * @return int
244
  */
245
  protected function GetVisitorLoginFailureLogLimit() {
246
+ return $this->plugin->settings()->get_visitor_failed_login_limit();
247
  }
248
 
249
  /**
323
  public function EventLoginFailure( $username ) {
324
  list($y, $m, $d) = explode( '-', date( 'Y-m-d' ) );
325
 
326
+ $ip = $this->plugin->settings()->GetMainClientIP();
327
 
328
  // Filter $_POST global array for security.
329
  $post_array = filter_input_array( INPUT_POST );
335
  $site_id = ( function_exists( 'get_current_blog_id' ) ? get_current_blog_id() : 0 );
336
  if ( $user ) {
337
  $new_alert_code = 1002;
338
+ $user_roles = $this->plugin->settings()->GetCurrentUserRoles( $user->roles );
339
+ if ( $this->plugin->settings()->IsLoginSuperAdmin( $username ) ) {
340
  $user_roles[] = 'superadmin';
341
  }
342
  }
368
  );
369
  $occ = count( $occ ) ? $occ[0] : null;
370
 
371
+ if ($this->plugin->alerts->WillOrHasTriggered(1004)) {
372
+ // skip if 1004 (session block) is already in place
373
+ return;
374
+ }
375
+
376
  if ( ! empty( $occ ) ) {
377
  // Update existing record exists user.
378
  $this->IncrementLoginFailure( $ip, $site_id, $user );
379
  $new = $occ->GetMetaValue( 'Attempts', 0 ) + 1;
380
 
381
+ $login_failure_log_limit = $this->GetLoginFailureLogLimit();
382
+ if ( - 1 !== (int) $this->GetLoginFailureLogLimit()
383
+ && $new > $this->GetLoginFailureLogLimit() ) {
384
  $new = $this->GetLoginFailureLogLimit() . '+';
385
  }
386
 
399
  'Username' => $username,
400
  'LogFileText' => '',
401
  'CurrentUserRoles' => $user_roles,
402
+ ),
403
+ /**
404
+ * @param WSAL_AlertManager $manager
405
+ *
406
+ * @return bool
407
+ */
408
+ function ($manager) {
409
+ // skip if 1004 (session block) is already in place
410
+ return !$manager->WillOrHasTriggered(1004);
411
+ }
412
  );
413
  }
414
  } else {
480
  */
481
  public function EventPasswordReset( $user, $new_pass ) {
482
  if ( ! empty( $user ) ) {
483
+ $user_roles = $this->plugin->settings()->GetCurrentUserRoles( $user->roles );
484
  $this->plugin->alerts->Trigger(
485
  4003,
486
  array(
509
  }
510
 
511
  // get the users roles.
512
+ $user_roles = $this->plugin->settings()->GetCurrentUserRoles( $user->roles );
513
+ if ( $this->plugin->settings()->IsLoginSuperAdmin( $username ) ) {
514
  $user_roles[] = 'superadmin';
515
  }
516
 
567
  */
568
  public function user_switched_event( $new_user_id, $old_user_id ) {
569
  $target_user = get_user_by( 'ID', $new_user_id );
570
+ $target_user_roles = $this->plugin->settings()->GetCurrentUserRoles( $target_user->roles );
571
  $target_user_roles = implode( ', ', $target_user_roles );
572
  $old_user = get_user_by( 'ID', $old_user_id );
573
+ $old_user_roles = $this->plugin->settings()->GetCurrentUserRoles( $old_user->roles );
574
 
575
  $this->plugin->alerts->Trigger(
576
  1008,
classes/Sensors/Menus.php CHANGED
@@ -259,10 +259,10 @@ class WSAL_Sensors_Menus extends WSAL_AbstractSensor {
259
  if ( $old_menu_term['name'] != $post_array['menu-name'] ) {
260
  $this->EventChangeName( $old_menu_term['name'], $post_array['menu-name'] );
261
  } else {
262
- // Remove the last menu item.
263
- // if ( count( $content_names_old ) == 1 && count( $content_types_old ) == 1 ) {
264
- // $this->EventRemoveItems( $content_types_old[0], $content_names_old[0], $post_array['menu-name'] );
265
- // }
266
  }
267
  }
268
  }
259
  if ( $old_menu_term['name'] != $post_array['menu-name'] ) {
260
  $this->EventChangeName( $old_menu_term['name'], $post_array['menu-name'] );
261
  } else {
262
+ //Remove the last menu item.
263
+ if ( count( $content_names_old ) == 1 && count( $content_types_old ) == 1 ) {
264
+ $this->EventRemoveItems( $content_types_old[0], $content_names_old[0], $post_array['menu-name'] );
265
+ }
266
  }
267
  }
268
  }
classes/Sensors/MetaData.php CHANGED
@@ -39,14 +39,7 @@ if ( ! defined( 'ABSPATH' ) ) {
39
  * @subpackage Sensors
40
  * @since 1.0.0
41
  */
42
- class WSAL_Sensors_MetaData extends WSAL_AbstractSensor {
43
-
44
- /**
45
- * Array of meta data being updated.
46
- *
47
- * @var array
48
- */
49
- protected $old_meta = array();
50
 
51
  /**
52
  * Empty meta counter.
@@ -70,72 +63,6 @@ class WSAL_Sensors_MetaData extends WSAL_AbstractSensor {
70
  add_action( 'user_register', array( $this, 'reset_null_meta_counter' ), 10 );
71
  }
72
 
73
- /**
74
- * Check "Excluded Custom Fields" or meta keys starts with "_".
75
- *
76
- * @param int $object_id - Object ID.
77
- * @param string $meta_key - Meta key.
78
- * @return boolean can log true|false
79
- */
80
- protected function CanLogMetaKey( $object_id, $meta_key ) {
81
- // Check if excluded meta key or starts with _.
82
- if ( '_' === substr( $meta_key, 0, 1 ) ) {
83
- /**
84
- * List of hidden keys allowed to log.
85
- *
86
- * @since 3.4.1
87
- */
88
- $log_hidden_keys = apply_filters( 'wsal_log_hidden_meta_keys', array() );
89
-
90
- // If the meta key is allowed to log then return true.
91
- if ( in_array( $meta_key, $log_hidden_keys, true ) ) {
92
- return true;
93
- }
94
-
95
- return false;
96
- } elseif ( $this->IsExcludedCustomFields( $meta_key ) ) {
97
- return false;
98
- } else {
99
- return true;
100
- }
101
- }
102
-
103
- /**
104
- * Check "Excluded Custom Fields".
105
- * Used in the above function.
106
- *
107
- * @param string $custom - Custom meta key.
108
- * @return boolean is excluded from monitoring true|false
109
- */
110
- public function IsExcludedCustomFields( $custom ) {
111
- $custom_fields = $this->plugin->settings->GetExcludedMonitoringCustom();
112
-
113
- if ( in_array( $custom, $custom_fields ) ) {
114
- return true;
115
- }
116
-
117
- foreach ( $custom_fields as $field ) {
118
- if ( false !== strpos( $field, '*' ) ) {
119
- // Wildcard str[any_character] when you enter (str*).
120
- if ( substr( $field, -1 ) == '*' ) {
121
- $field = rtrim( $field, '*' );
122
- if ( preg_match( "/^$field/", $custom ) ) {
123
- return true;
124
- }
125
- }
126
-
127
- // Wildcard [any_character]str when you enter (*str).
128
- if ( '*' === substr( $field, 0, 1 ) ) {
129
- $field = ltrim( $field, '*' );
130
- if ( preg_match( "/$field$/", $custom ) ) {
131
- return true;
132
- }
133
- }
134
- }
135
- }
136
- return false;
137
- }
138
-
139
  /**
140
  * Created a custom field.
141
  *
@@ -297,7 +224,7 @@ class WSAL_Sensors_MetaData extends WSAL_AbstractSensor {
297
  );
298
  } elseif ( $log_meta_event && $this->old_meta[ $meta_id ]->val !== $meta_value ) { // Check change in meta value.
299
  $editor_link = $this->GetEditorLink( $post );
300
- $this->plugin->alerts->Trigger(
301
  2054,
302
  array(
303
  'PostID' => $object_id,
@@ -312,7 +239,16 @@ class WSAL_Sensors_MetaData extends WSAL_AbstractSensor {
312
  'MetaValueOld' => $this->old_meta[ $meta_id ]->val,
313
  'MetaLink' => $meta_key,
314
  $editor_link['name'] => $editor_link['value'],
315
- )
 
 
 
 
 
 
 
 
 
316
  );
317
  }
318
  // Remove old meta update data.
@@ -368,7 +304,7 @@ class WSAL_Sensors_MetaData extends WSAL_AbstractSensor {
368
  if ( in_array( $post->post_type, $this->plugin->alerts->ignored_cpts, true ) ) {
369
  return;
370
  }
371
-
372
  // If not allowed to log meta event then skip it.
373
  if ( ! $log_meta_event ) {
374
  continue;
@@ -403,19 +339,6 @@ class WSAL_Sensors_MetaData extends WSAL_AbstractSensor {
403
  $this->null_meta_counter = 0;
404
  }
405
 
406
- /**
407
- * Get editor link.
408
- *
409
- * @param stdClass $post - The post.
410
- * @return array $editor_link - Name and value link
411
- */
412
- private function GetEditorLink( $post ) {
413
- return array(
414
- 'name' => 'EditorLinkPost',
415
- 'value' => get_edit_post_link( $post->ID ),
416
- );
417
- }
418
-
419
  /**
420
  * Create a custom field name/value.
421
  *
39
  * @subpackage Sensors
40
  * @since 1.0.0
41
  */
42
+ class WSAL_Sensors_MetaData extends WSAL_AbstractMetaDataSensor {
 
 
 
 
 
 
 
43
 
44
  /**
45
  * Empty meta counter.
63
  add_action( 'user_register', array( $this, 'reset_null_meta_counter' ), 10 );
64
  }
65
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
66
  /**
67
  * Created a custom field.
68
  *
224
  );
225
  } elseif ( $log_meta_event && $this->old_meta[ $meta_id ]->val !== $meta_value ) { // Check change in meta value.
226
  $editor_link = $this->GetEditorLink( $post );
227
+ $this->plugin->alerts->TriggerIf(
228
  2054,
229
  array(
230
  'PostID' => $object_id,
239
  'MetaValueOld' => $this->old_meta[ $meta_id ]->val,
240
  'MetaLink' => $meta_key,
241
  $editor_link['name'] => $editor_link['value'],
242
+ ),
243
+ /**
244
+ * @param WSAL_AlertManager$manager
245
+ * @return bool
246
+ */
247
+ function ( $manager ) {
248
+ // don't fire if there's already an event 2131 or 2132 (ACF relationship change)
249
+ return ! $manager->WillOrHasTriggered( 2131 )
250
+ && ! $manager->WillOrHasTriggered( 2132 );
251
+ }
252
  );
253
  }
254
  // Remove old meta update data.
304
  if ( in_array( $post->post_type, $this->plugin->alerts->ignored_cpts, true ) ) {
305
  return;
306
  }
307
+
308
  // If not allowed to log meta event then skip it.
309
  if ( ! $log_meta_event ) {
310
  continue;
339
  $this->null_meta_counter = 0;
340
  }
341
 
 
 
 
 
 
 
 
 
 
 
 
 
 
342
  /**
343
  * Create a custom field name/value.
344
  *
classes/Sensors/PhpErrors.php CHANGED
@@ -58,7 +58,7 @@ class WSAL_Sensors_PhpErrors extends WSAL_AbstractSensor {
58
  * Listening to Php events.
59
  */
60
  public function HookEvents() {
61
- if ( $this->plugin->settings->IsPhpErrorLoggingEnabled() ) {
62
  set_error_handler( array( $this, 'EventError' ), E_ALL );
63
  set_exception_handler( array( $this, 'EventException' ) );
64
  register_shutdown_function( array( $this, 'EventShutdown' ) );
@@ -92,7 +92,7 @@ class WSAL_Sensors_PhpErrors extends WSAL_AbstractSensor {
92
  }
93
 
94
  $errbacktrace = 'No Backtrace';
95
- if ( $this->plugin->settings->IsBacktraceLoggingEnabled() ) {
96
  ob_start();
97
  debug_print_backtrace();
98
  $errbacktrace = ob_get_clean();
@@ -131,7 +131,7 @@ class WSAL_Sensors_PhpErrors extends WSAL_AbstractSensor {
131
  }
132
 
133
  $errbacktrace = 'No Backtrace';
134
- if ( $this->plugin->settings->IsBacktraceLoggingEnabled() ) {
135
  $errbacktrace = $ex->getTraceAsString();
136
  }
137
 
58
  * Listening to Php events.
59
  */
60
  public function HookEvents() {
61
+ if ( $this->plugin->settings()->IsPhpErrorLoggingEnabled() ) {
62
  set_error_handler( array( $this, 'EventError' ), E_ALL );
63
  set_exception_handler( array( $this, 'EventException' ) );
64
  register_shutdown_function( array( $this, 'EventShutdown' ) );
92
  }
93
 
94
  $errbacktrace = 'No Backtrace';
95
+ if ( $this->plugin->settings()->IsBacktraceLoggingEnabled() ) {
96
  ob_start();
97
  debug_print_backtrace();
98
  $errbacktrace = ob_get_clean();
131
  }
132
 
133
  $errbacktrace = 'No Backtrace';
134
+ if ( $this->plugin->settings()->IsBacktraceLoggingEnabled() ) {
135
  $errbacktrace = $ex->getTraceAsString();
136
  }
137
 
classes/Sensors/PluginsThemes.php CHANGED
@@ -1179,7 +1179,7 @@ class WSAL_Sensors_PluginsThemes extends WSAL_AbstractSensor {
1179
  $content_option = 'site_content';
1180
 
1181
  // Get site plugins options.
1182
- $this->site_content = $this->plugin->GetGlobalOption( $content_option, false );
1183
 
1184
  /**
1185
  * Initiate the content option.
@@ -1203,7 +1203,7 @@ class WSAL_Sensors_PluginsThemes extends WSAL_AbstractSensor {
1203
  $this->site_content->skip_themes[] = strtolower( $theme );
1204
  }
1205
 
1206
- $this->plugin->SetGlobalOption( $content_option, $this->site_content );
1207
  }
1208
 
1209
  // Check if type is plugin and content is not empty.
@@ -1213,7 +1213,7 @@ class WSAL_Sensors_PluginsThemes extends WSAL_AbstractSensor {
1213
  // Add the plugin to the list and save it.
1214
  $this->site_content->plugins[] = strtolower( $content );
1215
  $this->site_content->skip_plugins[] = strtolower( $content );
1216
- $this->plugin->SetGlobalOption( $content_option, $this->site_content );
1217
  }
1218
  } elseif ( 'theme' === $type && ! empty( $content ) ) {
1219
  // If the theme is not already present in the current list then.
@@ -1221,7 +1221,7 @@ class WSAL_Sensors_PluginsThemes extends WSAL_AbstractSensor {
1221
  // Add the theme to the list and save it.
1222
  $this->site_content->themes[] = strtolower( $content );
1223
  $this->site_content->skip_themes[] = strtolower( $content );
1224
- $this->plugin->SetGlobalOption( $content_option, $this->site_content );
1225
  }
1226
  }
1227
  }
@@ -1275,7 +1275,7 @@ class WSAL_Sensors_PluginsThemes extends WSAL_AbstractSensor {
1275
  // If key is found then remove it from the array and save the plugins list.
1276
  if ( false !== $key ) {
1277
  unset( $this->site_content->plugins[ $key ] );
1278
- $this->plugin->SetGlobalOption( 'site_content', $this->site_content );
1279
  return true;
1280
  }
1281
  } elseif ( 'theme' === $type && in_array( $content, $this->site_content->themes, true ) ) {
@@ -1285,7 +1285,7 @@ class WSAL_Sensors_PluginsThemes extends WSAL_AbstractSensor {
1285
  // If key is found then remove it from the array and save the themes list.
1286
  if ( false !== $key ) {
1287
  unset( $this->site_content->themes[ $key ] );
1288
- $this->plugin->SetGlobalOption( 'site_content', $this->site_content );
1289
  return true;
1290
  }
1291
  }
@@ -1336,11 +1336,11 @@ class WSAL_Sensors_PluginsThemes extends WSAL_AbstractSensor {
1336
  // Add plugin to skip file alerts list.
1337
  if ( 'plugin' === $type ) {
1338
  $this->site_content->skip_plugins[] = $content;
1339
- $this->plugin->SetGlobalOption( 'site_content', $this->site_content );
1340
  } elseif ( 'theme' === $type ) {
1341
  // Add theme to skip file alerts list.
1342
  $this->site_content->skip_themes[] = $content;
1343
- $this->plugin->SetGlobalOption( 'site_content', $this->site_content );
1344
  }
1345
  return true;
1346
  }
@@ -1461,15 +1461,15 @@ class WSAL_Sensors_PluginsThemes extends WSAL_AbstractSensor {
1461
  $addon_slug = array( array_search( $plugin, array_column( $predefined_plugins, 'addon_for', 'plugin_slug' ) ) );
1462
  $is_addon_installed = array_intersect( $all_plugins, $addon_slug );
1463
  if ( empty( $is_addon_installed ) ) {
1464
- $current_value = get_option( 'wsal_installed_plugin_addon_available' );
1465
  $plugin_filename = array( $plugin_filename );
1466
  if ( isset( $current_value ) && is_array( $current_value ) ) {
1467
  $new_plugin_filenames = array_unique( array_merge( $current_value, $plugin_filename ) );
1468
  } else {
1469
  $new_plugin_filenames = $plugin_filename;
1470
  }
1471
- $this->plugin->options_helper->set_option_value( 'installed_plugin_addon_available', $new_plugin_filenames );
1472
- delete_option( 'wsal_addon_available_notice_dismissed' );
1473
  }
1474
  }
1475
  }
@@ -1492,14 +1492,14 @@ class WSAL_Sensors_PluginsThemes extends WSAL_AbstractSensor {
1492
  foreach ( $predefined_plugins_addon as $plugin ) {
1493
  // Check if plugin file starts with the same string as our addon_for, or if its equal.
1494
  if ( $plugin_filename === $plugin ) {
1495
- $current_installed = get_option( 'wsal_installed_plugin_addon_available' );
1496
  if ( isset( $current_installed ) && ! empty( $current_installed ) ) {
1497
  if ( ( $key = array_search( $plugin, $current_installed ) ) !== false ) {
1498
  unset( $current_installed[$key] );
1499
  }
1500
  }
1501
 
1502
- $this->plugin->options_helper->set_option_value( 'installed_plugin_addon_available', $current_installed );
1503
  }
1504
  }
1505
  }
1179
  $content_option = 'site_content';
1180
 
1181
  // Get site plugins options.
1182
+ $this->site_content = $this->plugin->GetGlobalSetting( $content_option, false );
1183
 
1184
  /**
1185
  * Initiate the content option.
1203
  $this->site_content->skip_themes[] = strtolower( $theme );
1204
  }
1205
 
1206
+ $this->plugin->SetGlobalSetting( $content_option, $this->site_content );
1207
  }
1208
 
1209
  // Check if type is plugin and content is not empty.
1213
  // Add the plugin to the list and save it.
1214
  $this->site_content->plugins[] = strtolower( $content );
1215
  $this->site_content->skip_plugins[] = strtolower( $content );
1216
+ $this->plugin->SetGlobalSetting( $content_option, $this->site_content );
1217
  }
1218
  } elseif ( 'theme' === $type && ! empty( $content ) ) {
1219
  // If the theme is not already present in the current list then.
1221
  // Add the theme to the list and save it.
1222
  $this->site_content->themes[] = strtolower( $content );
1223
  $this->site_content->skip_themes[] = strtolower( $content );
1224
+ $this->plugin->SetGlobalSetting( $content_option, $this->site_content );
1225
  }
1226
  }
1227
  }
1275
  // If key is found then remove it from the array and save the plugins list.
1276
  if ( false !== $key ) {
1277
  unset( $this->site_content->plugins[ $key ] );
1278
+ $this->plugin->SetGlobalSetting( 'site_content', $this->site_content );
1279
  return true;
1280
  }
1281
  } elseif ( 'theme' === $type && in_array( $content, $this->site_content->themes, true ) ) {
1285
  // If key is found then remove it from the array and save the themes list.
1286
  if ( false !== $key ) {
1287
  unset( $this->site_content->themes[ $key ] );
1288
+ $this->plugin->SetGlobalSetting( 'site_content', $this->site_content );
1289
  return true;
1290
  }
1291
  }
1336
  // Add plugin to skip file alerts list.
1337
  if ( 'plugin' === $type ) {
1338
  $this->site_content->skip_plugins[] = $content;
1339
+ $this->plugin->SetGlobalSetting( 'site_content', $this->site_content );
1340
  } elseif ( 'theme' === $type ) {
1341
  // Add theme to skip file alerts list.
1342
  $this->site_content->skip_themes[] = $content;
1343
+ $this->plugin->SetGlobalSetting( 'site_content', $this->site_content );
1344
  }
1345
  return true;
1346
  }
1461
  $addon_slug = array( array_search( $plugin, array_column( $predefined_plugins, 'addon_for', 'plugin_slug' ) ) );
1462
  $is_addon_installed = array_intersect( $all_plugins, $addon_slug );
1463
  if ( empty( $is_addon_installed ) ) {
1464
+ $current_value = $this->plugin->GetGlobalSetting( 'installed_plugin_addon_available' );
1465
  $plugin_filename = array( $plugin_filename );
1466
  if ( isset( $current_value ) && is_array( $current_value ) ) {
1467
  $new_plugin_filenames = array_unique( array_merge( $current_value, $plugin_filename ) );
1468
  } else {
1469
  $new_plugin_filenames = $plugin_filename;
1470
  }
1471
+ $this->plugin->SetGlobalSetting( 'installed_plugin_addon_available', $new_plugin_filenames );
1472
+ $this->plugin->options_helper->delete_option( 'wsal_addon_available_notice_dismissed' );
1473
  }
1474
  }
1475
  }
1492
  foreach ( $predefined_plugins_addon as $plugin ) {
1493
  // Check if plugin file starts with the same string as our addon_for, or if its equal.
1494
  if ( $plugin_filename === $plugin ) {
1495
+ $current_installed = $this->plugin->GetGlobalSetting( 'installed_plugin_addon_available' );
1496
  if ( isset( $current_installed ) && ! empty( $current_installed ) ) {
1497
  if ( ( $key = array_search( $plugin, $current_installed ) ) !== false ) {
1498
  unset( $current_installed[$key] );
1499
  }
1500
  }
1501
 
1502
+ $this->plugin->SetGlobalSetting( 'installed_plugin_addon_available', $current_installed );
1503
  }
1504
  }
1505
  }
classes/Sensors/Public.php CHANGED
@@ -211,7 +211,6 @@ class WSAL_Sensors_Public extends WSAL_AbstractSensor {
211
  $order_post = get_post( $order_id ); // Get order post object.
212
  $order_title = ( null !== $order_post && $order_post instanceof WP_Post ) ? $order_post->post_title : false;
213
  $editor_link = $this->get_editor_link( $order_post );
214
-
215
  $this->plugin->alerts->Trigger(
216
  9035,
217
  array(
@@ -356,11 +355,29 @@ class WSAL_Sensors_Public extends WSAL_AbstractSensor {
356
  );
357
  }
358
 
359
- $wc_all_stock_changes = $this->plugin->GetGlobalOption( 'wc-all-stock-changes', 'on' );
360
 
361
  // If stock has changed then trigger the alert.
362
  if ( ( $old_stock !== $new_stock ) && ( 'on' === $wc_all_stock_changes ) ) {
363
  $editor_link = $this->get_editor_link( $post );
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
364
  /**
365
  * Event was changed from 9019 to 9105
366
  *
@@ -375,6 +392,8 @@ class WSAL_Sensors_Public extends WSAL_AbstractSensor {
375
  'OldValue' => ! empty( $old_stock ) ? $old_stock : 0,
376
  'NewValue' => $new_stock,
377
  'Username' => $username,
 
 
378
  $editor_link['name'] => $editor_link['value'],
379
  )
380
  );
211
  $order_post = get_post( $order_id ); // Get order post object.
212
  $order_title = ( null !== $order_post && $order_post instanceof WP_Post ) ? $order_post->post_title : false;
213
  $editor_link = $this->get_editor_link( $order_post );
 
214
  $this->plugin->alerts->Trigger(
215
  9035,
216
  array(
355
  );
356
  }
357
 
358
+ $wc_all_stock_changes = $this->plugin->GetGlobalBooleanSetting( 'wc-all-stock-changes', true );
359
 
360
  // If stock has changed then trigger the alert.
361
  if ( ( $old_stock !== $new_stock ) && ( 'on' === $wc_all_stock_changes ) ) {
362
  $editor_link = $this->get_editor_link( $post );
363
+
364
+ // Check if this was done via an order by looking for event 9035.
365
+ // If so, we are going to add its data.
366
+ $query = new WSAL_Models_OccurrenceQuery();
367
+ $query->addOrderBy( 'created_on', true );
368
+ $query->setLimit( 1 );
369
+ $last_occurence = $query->getAdapter()->Execute( $query );
370
+ if ( isset( $last_occurence[0] ) && 9035 === $last_occurence[0]->alert_id ) {
371
+ $latest_event = $this->plugin->alerts->get_latest_events();
372
+ $latest_event = isset( $latest_event[0] ) ? $latest_event[0] : false;
373
+ $event_meta = $latest_event ? $latest_event->GetMetaArray() : false;
374
+ $order_id = isset( $event_meta['OrderID'] ) ? $event_meta['OrderID'] : false;
375
+ $order_title = isset( $event_meta['OrderTitle'] ) ? $event_meta['OrderTitle'] : false;
376
+ } else {
377
+ $order_id = false;
378
+ $order_title = false;
379
+ }
380
+
381
  /**
382
  * Event was changed from 9019 to 9105
383
  *
392
  'OldValue' => ! empty( $old_stock ) ? $old_stock : 0,
393
  'NewValue' => $new_stock,
394
  'Username' => $username,
395
+ 'StockOrderID' => $order_id,
396
+ 'Username' => $username,
397
  $editor_link['name'] => $editor_link['value'],
398
  )
399
  );
classes/Sensors/Request.php CHANGED
@@ -32,7 +32,7 @@ class WSAL_Sensors_Request extends WSAL_AbstractSensor {
32
  * Listening to events using WP hooks.
33
  */
34
  public function HookEvents() {
35
- if ( $this->plugin->settings->IsRequestLoggingEnabled() ) {
36
  add_action( 'shutdown', array( $this, 'EventShutdown' ) );
37
  }
38
  }
@@ -46,10 +46,9 @@ class WSAL_Sensors_Request extends WSAL_AbstractSensor {
46
  $server_array = filter_input_array( INPUT_SERVER );
47
 
48
  // get the custom logging path from settings.
49
- $custom_logging_path = $this->plugin->options_helper->get_logging_path();
50
-
51
- if ( ! $this->CheckDirectory( $custom_logging_path ) ) {
52
- wp_mkdir_p( $custom_logging_path );
53
  }
54
 
55
  $file = $custom_logging_path . 'Request.log.php';
32
  * Listening to events using WP hooks.
33
  */
34
  public function HookEvents() {
35
+ if ( $this->plugin->settings()->IsRequestLoggingEnabled() ) {
36
  add_action( 'shutdown', array( $this, 'EventShutdown' ) );
37
  }
38
  }
46
  $server_array = filter_input_array( INPUT_SERVER );
47
 
48
  // get the custom logging path from settings.
49
+ $custom_logging_path = $this->plugin->settings()->get_working_dir_path();
50
+ if ( is_wp_error($custom_logging_path) ) {
51
+ return;
 
52
  }
53
 
54
  $file = $custom_logging_path . 'Request.log.php';
classes/Sensors/System.php CHANGED
@@ -67,28 +67,26 @@ class WSAL_Sensors_System extends WSAL_AbstractSensor {
67
  add_filter( 'template_redirect', array( $this, 'Event404' ) );
68
 
69
  // get the logging location.
70
- $custom_logging_path_base = $this->plugin->options_helper->get_logging_path();
71
- $custom_logging_path = $custom_logging_path_base . '404s/';
72
- if ( ! $this->CheckDirectory( $custom_logging_path ) ) {
73
- $dir_made = wp_mkdir_p( $custom_logging_path );
74
- if ( $dir_made ) {
75
  // make an empty index.php in the directory.
76
- @file_put_contents( $custom_logging_path . 'index.php', '<?php // Silence is golden' );
77
  }
78
- }
79
-
80
- // Directory for logged in users log files.
81
- $user_upload_path = trailingslashit( $custom_logging_path_base . '404s/users/' );
82
- $this->remove_sub_directories( $user_upload_path ); // Remove it.
83
 
84
- // Directory for visitor log files.
85
- $visitor_upload_path = trailingslashit( $custom_logging_path_base . '/404s/visitors/' );
86
- $this->remove_sub_directories( $visitor_upload_path ); // Remove it.
87
 
 
 
 
 
88
 
89
  if ( ! wp_next_scheduled( self::SCHEDULED_HOOK_LOG_FILE_PRUDING ) ) {
90
  wp_schedule_event( time(), 'daily', self::SCHEDULED_HOOK_LOG_FILE_PRUDING );
91
  }
 
92
  // Cron Job 404 log files pruning.
93
  add_action( self::SCHEDULED_HOOK_LOG_FILE_PRUDING, array( $this, 'LogFilesPruning' ) );
94
  // whitelist options.
@@ -172,7 +170,7 @@ class WSAL_Sensors_System extends WSAL_AbstractSensor {
172
  * @return integer limit
173
  */
174
  protected function Get404LogLimit() {
175
- return $this->plugin->settings->Get404LogLimit();
176
  }
177
 
178
  /**
@@ -235,7 +233,7 @@ class WSAL_Sensors_System extends WSAL_AbstractSensor {
235
  list( $y, $m, $d ) = explode( '-', date( 'Y-m-d' ) );
236
 
237
  $site_id = ( function_exists( 'get_current_blog_id' ) ? get_current_blog_id() : 0 );
238
- $ip = $this->plugin->settings->GetMainClientIP();
239
 
240
  if ( ! is_user_logged_in() ) {
241
  $username = 'Website Visitor';
@@ -292,6 +290,7 @@ class WSAL_Sensors_System extends WSAL_AbstractSensor {
292
  $new = 'more than ' . $this->Get404LogLimit();
293
  $msg .= ' This could possible be a scan, therefore keep an eye on the activity from this IP Address';
294
  }
 
295
  $link_file = $this->WriteLog( $new, $ip, $username, true, $url_404 );
296
 
297
  $occ->UpdateMetaValue( 'Attempts', $new );
@@ -332,7 +331,7 @@ class WSAL_Sensors_System extends WSAL_AbstractSensor {
332
  return false;
333
  }
334
 
335
- if ( in_array( $url, $this->plugin->settings->get_excluded_urls() ) ) {
336
  return true;
337
  }
338
  }
@@ -500,12 +499,12 @@ class WSAL_Sensors_System extends WSAL_AbstractSensor {
500
  );
501
 
502
  // Get `site_content` option.
503
- $site_content = $this->plugin->GetGlobalOption( 'site_content' );
504
 
505
  // Check if the option is instance of stdClass.
506
  if ( $site_content instanceof stdClass ) {
507
  $site_content->skip_core = true; // Set skip core to true to skip file alerts after a core update.
508
- $this->plugin->SetGlobalOption( 'site_content', $site_content ); // Save the option.
509
  }
510
  }
511
  }
@@ -529,12 +528,12 @@ class WSAL_Sensors_System extends WSAL_AbstractSensor {
529
  );
530
 
531
  // Get `site_content` option.
532
- $site_content = $this->plugin->GetGlobalOption( 'site_content' );
533
 
534
  // Check if the option is instance of stdClass.
535
  if ( $site_content instanceof stdClass ) {
536
  $site_content->skip_core = true; // Set skip core to true to skip file alerts after a core update.
537
- $this->plugin->SetGlobalOption( 'site_content', $site_content ); // Save the option.
538
  }
539
  }
540
  }
@@ -543,44 +542,42 @@ class WSAL_Sensors_System extends WSAL_AbstractSensor {
543
  * Purge log files older than one month.
544
  */
545
  public function LogFilesPruning() {
546
- if ( $this->plugin->options_helper->get_option_value( 'purge-404-log', 'off' ) == 'on' ) {
547
- $custom_logging_path = $this->plugin->options_helper->get_logging_path();
548
- $custom_logging_path = $custom_logging_path . '404s/';
549
- if ( is_dir( $custom_logging_path ) ) {
550
- if ( $handle = opendir( $custom_logging_path ) ) {
551
- while ( false !== ( $entry = readdir( $handle ) ) ) {
552
- if ( '.' != $entry && '..' != $entry ) {
553
- if ( strpos( $entry, '6007' ) && file_exists( $custom_logging_path . $entry ) ) {
554
- $modified = filemtime( $custom_logging_path . $entry );
555
- if ( $modified < strtotime( '-4 weeks' ) ) {
556
- // Delete file.
557
- unlink( $custom_logging_path . $entry );
558
- }
559
- }
560
- }
561
- }
562
- closedir( $handle );
563
- }
564
- }
565
  }
566
- if ( 'on' == $this->plugin->options_helper->get_option_value( 'purge-visitor-404-log', 'off' ) ) {
567
- $custom_logging_path = $this->plugin->options_helper->get_logging_path();
568
- $custom_logging_path = $custom_logging_path . '404s/';
569
- if ( is_dir( $custom_logging_path ) ) {
570
- if ( $handle = opendir( $custom_logging_path ) ) {
571
- while ( false !== ( $entry = readdir( $handle ) ) ) {
572
- if ( $entry != '.' && $entry != '..' ) {
573
- if ( strpos( $entry, '6023' ) && file_exists( $custom_logging_path . $entry ) ) {
574
- $modified = filemtime( $custom_logging_path . $entry );
575
- if ( $modified < strtotime( '-4 weeks' ) ) {
576
- // Delete file.
577
- unlink( $custom_logging_path . $entry );
578
- }
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
579
  }
580
  }
581
  }
582
- closedir( $handle );
583
  }
 
584
  }
585
  }
586
  }
@@ -714,26 +711,28 @@ class WSAL_Sensors_System extends WSAL_AbstractSensor {
714
  * Write Log.
715
  *
716
  * Write a new line on 404 log file.
717
- * Folder: /uploads/wp-security-audit-log/404s/
 
 
 
 
 
 
718
  *
719
- * @param int $attempts - Number of attempt.
720
- * @param string $ip - IP address.
721
- * @param string $username - Username.
722
- * @param bool $logged_in - True if logged in.
723
- * @param string $url - 404 URL.
724
  */
725
  private function WriteLog( $attempts, $ip, $username = '', $logged_in = true, $url = null ) {
726
  $name_file = null;
727
- if ( $logged_in && 'on' === $this->plugin->options_helper->get_option_value( 'log-404', 'off' ) ) {
728
  // Get option to log referrer.
729
- $log_referrer = $this->plugin->options_helper->get_option_value( 'log-404-referrer' );
730
 
731
  // Check localhost.
732
  if ( '127.0.0.1' == $ip || '::1' == $ip ) {
733
  $ip = 'localhost';
734
  }
735
 
736
- if ( 'on' === $log_referrer ) {
737
  // Get the referer.
738
  $referrer = filter_input( INPUT_SERVER, 'HTTP_REFERER', FILTER_SANITIZE_STRING );
739
  if ( empty( $referrer ) && isset( $_SERVER['HTTP_REFERER'] ) && ! empty( $_SERVER['HTTP_REFERER'] ) ) {
@@ -766,47 +765,43 @@ class WSAL_Sensors_System extends WSAL_AbstractSensor {
766
  }
767
 
768
  // get the custom logging path from settings.
769
- $custom_logging_path = $this->plugin->options_helper->get_logging_path() . '404s/';
770
- $custom_logging_url = $this->plugin->options_helper->get_logging_url() . '404s/';
771
-
772
- if ( ! $this->CheckDirectory( ABSPATH . $custom_logging_path ) ) {
773
- $dir_made = wp_mkdir_p( $custom_logging_path );
774
- if ( $dir_made ) {
775
  // make an empty index.php in the directory.
776
  @file_put_contents( $custom_logging_path . 'index.php', '<?php // Silence is golden' );
777
  }
778
- }
779
-
780
 
781
-
782
- // Check directory.
783
- if ( $this->CheckDirectory( $custom_logging_path ) ) {
784
- $filename = '6007_' . date( 'Ymd' ) . '.log';
785
- $fp = $custom_logging_path . $filename;
786
- $name_file = $custom_logging_url . $filename;
787
- if ( ! $file = fopen( $fp, 'a' ) ) {
788
- $i = 1;
789
- $file_opened = false;
790
- do {
791
- $fp2 = substr( $fp, 0, -4 ) . '_' . $i . '.log';
792
- if ( ! file_exists( $fp2 ) ) {
793
- if ( $file = fopen( $fp2, 'a' ) ) {
794
- $file_opened = true;
795
- $name_file = $custom_logging_url . substr( $name_file, 0, -4 ) . '_' . $i . '.log';
796
- }
797
- } else {
798
- $latest_filename = $this->GetLastModified( $custom_logging_path, $filename );
799
- $fp_last = $custom_logging_path . $latest_filename;
800
- if ( $file = fopen( $fp_last, 'a' ) ) {
801
- $file_opened = true;
802
- $name_file = $custom_logging_url . $latest_filename;
 
803
  }
804
- }
805
- $i++;
806
- } while ( ! $file_opened );
 
 
807
  }
808
- fwrite( $file, sprintf( "%s\n", $data ) );
809
- fclose( $file );
810
  }
811
  }
812
  return $name_file;
67
  add_filter( 'template_redirect', array( $this, 'Event404' ) );
68
 
69
  // get the logging location.
70
+ $custom_logging_path_base = $this->plugin->settings()->get_working_dir_path( '404s' );
71
+ if ( ! is_wp_error( $custom_logging_path_base ) ) {
72
+ if ( ! file_exists( $custom_logging_path_base . 'index.php' ) ) {
 
 
73
  // make an empty index.php in the directory.
74
+ @file_put_contents( $custom_logging_path_base . 'index.php', '<?php // Silence is golden' );
75
  }
 
 
 
 
 
76
 
77
+ // Directory for logged in users log files.
78
+ $user_upload_path = $custom_logging_path_base . 'users' . DIRECTORY_SEPARATOR;
79
+ $this->remove_sub_directories( $user_upload_path ); // Remove it.
80
 
81
+ // Directory for visitor log files.
82
+ $visitor_upload_path = $custom_logging_path_base . 'visitors' . DIRECTORY_SEPARATOR;
83
+ $this->remove_sub_directories( $visitor_upload_path ); // Remove it.
84
+ }
85
 
86
  if ( ! wp_next_scheduled( self::SCHEDULED_HOOK_LOG_FILE_PRUDING ) ) {
87
  wp_schedule_event( time(), 'daily', self::SCHEDULED_HOOK_LOG_FILE_PRUDING );
88
  }
89
+
90
  // Cron Job 404 log files pruning.
91
  add_action( self::SCHEDULED_HOOK_LOG_FILE_PRUDING, array( $this, 'LogFilesPruning' ) );
92
  // whitelist options.
170
  * @return integer limit
171
  */
172
  protected function Get404LogLimit() {
173
+ return $this->plugin->settings()->Get404LogLimit();
174
  }
175
 
176
  /**
233
  list( $y, $m, $d ) = explode( '-', date( 'Y-m-d' ) );
234
 
235
  $site_id = ( function_exists( 'get_current_blog_id' ) ? get_current_blog_id() : 0 );
236
+ $ip = $this->plugin->settings()->GetMainClientIP();
237
 
238
  if ( ! is_user_logged_in() ) {
239
  $username = 'Website Visitor';
290
  $new = 'more than ' . $this->Get404LogLimit();
291
  $msg .= ' This could possible be a scan, therefore keep an eye on the activity from this IP Address';
292
  }
293
+
294
  $link_file = $this->WriteLog( $new, $ip, $username, true, $url_404 );
295
 
296
  $occ->UpdateMetaValue( 'Attempts', $new );
331
  return false;
332
  }
333
 
334
+ if ( in_array( $url, $this->plugin->settings()->get_excluded_urls() ) ) {
335
  return true;
336
  }
337
  }
499
  );
500
 
501
  // Get `site_content` option.
502
+ $site_content = $this->plugin->GetGlobalSetting( 'site_content' );
503
 
504
  // Check if the option is instance of stdClass.
505
  if ( $site_content instanceof stdClass ) {
506
  $site_content->skip_core = true; // Set skip core to true to skip file alerts after a core update.
507
+ $this->plugin->SetGlobalSetting( 'site_content', $site_content ); // Save the option.
508
  }
509
  }
510
  }
528
  );
529
 
530
  // Get `site_content` option.
531
+ $site_content = $this->plugin->GetGlobalSetting( 'site_content' );
532
 
533
  // Check if the option is instance of stdClass.
534
  if ( $site_content instanceof stdClass ) {
535
  $site_content->skip_core = true; // Set skip core to true to skip file alerts after a core update.
536
+ $this->plugin->SetGlobalSetting( 'site_content', $site_content ); // Save the option.
537
  }
538
  }
539
  }
542
  * Purge log files older than one month.
543
  */
544
  public function LogFilesPruning() {
545
+ if ( $this->plugin->GetGlobalBooleanSetting( 'purge-404-log', false ) ) {
546
+ $this->Prune404FilesByPrefix( '6007' );
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
547
  }
548
+
549
+ if ( $this->plugin->GetGlobalBooleanSetting( 'purge-visitor-404-log', false ) ) {
550
+ $this->Prune404FilesByPrefix( '6023' );
551
+ }
552
+ }
553
+
554
+ /**
555
+ * Deletes files in 404s log folder that start with a specific prefix.
556
+ *
557
+ * @param string $prefix
558
+ * @since 4.1.3
559
+ */
560
+ private function Prune404FilesByPrefix( $prefix ) {
561
+ // prevent deleting all files by accident when the prefix is empty or not what we expect
562
+ if ( ! is_string( $prefix ) || empty( $prefix ) ) {
563
+ return;
564
+ }
565
+
566
+ $custom_logging_path = $this->plugin->settings()->get_working_dir_path( '404s', true );
567
+ if ( is_dir( $custom_logging_path ) ) {
568
+ if ( $handle = opendir( $custom_logging_path ) ) {
569
+ while ( false !== ( $entry = readdir( $handle ) ) ) {
570
+ if ( '.' != $entry && '..' != $entry ) {
571
+ if ( strpos( $entry, $prefix ) && file_exists( $custom_logging_path . $entry ) ) {
572
+ $modified = filemtime( $custom_logging_path . $entry );
573
+ if ( $modified < strtotime( '-4 weeks' ) ) {
574
+ // Delete file.
575
+ unlink( $custom_logging_path . $entry );
576
  }
577
  }
578
  }
 
579
  }
580
+ closedir( $handle );
581
  }
582
  }
583
  }
711
  * Write Log.
712
  *
713
  * Write a new line on 404 log file.
714
+ * Folder: {plugin working folder}/404s/
715
+ *
716
+ * @param int $attempts - Number of attempt.
717
+ * @param string $ip - IP address.
718
+ * @param string $username - Username.
719
+ * @param bool $logged_in - True if logged in.
720
+ * @param string $url - 404 URL.
721
  *
722
+ * @return string|null
 
 
 
 
723
  */
724
  private function WriteLog( $attempts, $ip, $username = '', $logged_in = true, $url = null ) {
725
  $name_file = null;
726
+ if ( $logged_in && $this->plugin->GetGlobalBooleanSetting( 'log-404', false ) ) {
727
  // Get option to log referrer.
728
+ $log_referrer = $this->plugin->GetGlobalBooleanSetting( 'log-404-referrer' );
729
 
730
  // Check localhost.
731
  if ( '127.0.0.1' == $ip || '::1' == $ip ) {
732
  $ip = 'localhost';
733
  }
734
 
735
+ if ( $log_referrer ) {
736
  // Get the referer.
737
  $referrer = filter_input( INPUT_SERVER, 'HTTP_REFERER', FILTER_SANITIZE_STRING );
738
  if ( empty( $referrer ) && isset( $_SERVER['HTTP_REFERER'] ) && ! empty( $_SERVER['HTTP_REFERER'] ) ) {
765
  }
766
 
767
  // get the custom logging path from settings.
768
+ $custom_logging_path = $this->plugin->settings()->get_working_dir_path( '404s' );
769
+ if ( ! is_wp_error( $custom_logging_path ) ) {
770
+ if ( ! file_exists( $custom_logging_path . 'index.php' ) ) {
 
 
 
771
  // make an empty index.php in the directory.
772
  @file_put_contents( $custom_logging_path . 'index.php', '<?php // Silence is golden' );
773
  }
 
 
774
 
775
+ // Check directory.
776
+ if ( $this->CheckDirectory( $custom_logging_path ) ) {
777
+ $filename = '6007_' . date( 'Ymd' ) . '.log';
778
+ $fp = $custom_logging_path . $filename;
779
+ $custom_logging_url = $this->plugin->settings()->get_working_dir_url( '404s' );
780
+ $name_file = $custom_logging_url . $filename;
781
+ if ( ! $file = fopen( $fp, 'a' ) ) {
782
+ $i = 1;
783
+ $file_opened = false;
784
+ do {
785
+ $fp2 = substr( $fp, 0, - 4 ) . '_' . $i . '.log';
786
+ if ( ! file_exists( $fp2 ) ) {
787
+ if ( $file = fopen( $fp2, 'a' ) ) {
788
+ $file_opened = true;
789
+ $name_file = $custom_logging_url . substr( $name_file, 0, - 4 ) . '_' . $i . '.log';
790
+ }
791
+ } else {
792
+ $latest_filename = $this->GetLastModified( $custom_logging_path, $filename );
793
+ $fp_last = $custom_logging_path . $latest_filename;
794
+ if ( $file = fopen( $fp_last, 'a' ) ) {
795
+ $file_opened = true;
796
+ $name_file = $custom_logging_url . $latest_filename;
797
+ }
798
  }
799
+ $i ++;
800
+ } while ( ! $file_opened );
801
+ }
802
+ fwrite( $file, sprintf( "%s\n", $data ) );
803
+ fclose( $file );
804
  }
 
 
805
  }
806
  }
807
  return $name_file;
classes/Settings.php CHANGED
@@ -19,6 +19,13 @@ if ( ! defined( 'ABSPATH' ) ) {
19
  */
20
  class WSAL_Settings {
21
 
 
 
 
 
 
 
 
22
  /**
23
  * Instance of the main plugin.
24
  *
@@ -32,8 +39,6 @@ class WSAL_Settings {
32
  const OPT_DEV_BACKTRACE_LOG = 'b';
33
  const ERROR_CODE_INVALID_IP = 901;
34
 
35
- const DEFAULT_LOGGING_DIR = '/wp-content/uploads/wp-security-audit-log/';
36
-
37
  /**
38
  * List of Site Admins.
39
  *
@@ -69,13 +74,6 @@ class WSAL_Settings {
69
  */
70
  protected $_viewers = null;
71
 
72
- /**
73
- * Allowed Plugin Editors.
74
- *
75
- * @var array
76
- */
77
- protected $_editors = null;
78
-
79
  /**
80
  * Alerts per page.
81
  *
@@ -131,7 +129,7 @@ class WSAL_Settings {
131
  *
132
  * @var array
133
  */
134
- public $geek_alerts = array( 1004, 1005, 1006, 1007, 2023, 2024, 2053, 2054, 2055, 2062, 2100, 2106, 2111, 2112, 2124, 2125, 2094, 2095, 2043, 2071, 2082, 2083, 2085, 2089, 4014, 4015, 4016, 5010, 5011, 5012, 5019, 5025, 5013, 5014, 5015, 5016, 5017, 5018, 6001, 6002, 6007, 6008, 6010, 6011, 6012, 6013, 6014, 6015, 6016, 6017, 6018, 6023, 6024, 6025 );
135
 
136
  /**
137
  * Current screen object.
@@ -154,6 +152,132 @@ class WSAL_Settings {
154
  add_action( 'deactivated_plugin', array( $this, 'reset_stealth_mode' ), 10, 1 );
155
  }
156
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
157
  /**
158
  * Enable Basic Mode.
159
  */
@@ -186,7 +310,7 @@ class WSAL_Settings {
186
  */
187
  public function IsDevOptionEnabled( $option ) {
188
  if ( is_null( $this->_devoption ) ) {
189
- $this->_devoption = $this->_plugin->GetGlobalOption(
190
  'dev-options',
191
  implode( ',', $this->GetDefaultDevOptions() )
192
  );
@@ -201,7 +325,7 @@ class WSAL_Settings {
201
  * @return boolean
202
  */
203
  public function IsAnyDevOptionEnabled() {
204
- return ! ! $this->_plugin->GetGlobalOption( 'dev-options', null );
205
  }
206
 
207
  /**
@@ -222,7 +346,7 @@ class WSAL_Settings {
222
  $this->_devoption[] = $option;
223
  }
224
  // Commit option.
225
- $this->_plugin->SetGlobalOption(
226
  'dev-options',
227
  implode( ',', $this->_devoption )
228
  );
@@ -233,7 +357,7 @@ class WSAL_Settings {
233
  */
234
  public function ClearDevOptions() {
235
  $this->_devoption = array();
236
- $this->_plugin->SetGlobalOption( 'dev-options', '' );
237
  }
238
 
239
  /**
@@ -278,7 +402,7 @@ class WSAL_Settings {
278
  * @return boolean
279
  */
280
  public function IsWidgetsEnabled() {
281
- return ! $this->_plugin->GetGlobalOption( 'disable-widgets' );
282
  }
283
 
284
  /**
@@ -287,7 +411,7 @@ class WSAL_Settings {
287
  * @param boolean $newvalue - True if enabled.
288
  */
289
  public function SetWidgetsEnabled( $newvalue ) {
290
- $this->_plugin->SetGlobalOption( 'disable-widgets', ! $newvalue );
291
  }
292
 
293
  /**
@@ -298,7 +422,7 @@ class WSAL_Settings {
298
  * @return boolean
299
  */
300
  public function is_admin_bar_notif() {
301
- return ! $this->_plugin->GetGlobalOption( 'disable-admin-bar-notif' );
302
  }
303
 
304
  /**
@@ -309,7 +433,7 @@ class WSAL_Settings {
309
  * @param boolean $newvalue - True if enabled.
310
  */
311
  public function set_admin_bar_notif( $newvalue ) {
312
- $this->_plugin->SetGlobalOption( 'disable-admin-bar-notif', ! $newvalue );
313
  }
314
 
315
  /**
@@ -320,7 +444,7 @@ class WSAL_Settings {
320
  * @return string
321
  */
322
  public function get_admin_bar_notif_updates() {
323
- return $this->_plugin->GetGlobalOption( 'admin-bar-notif-updates', 'page-refresh' );
324
  }
325
 
326
  /**
@@ -331,7 +455,7 @@ class WSAL_Settings {
331
  * @param string $newvalue - New option value.
332
  */
333
  public function set_admin_bar_notif_updates( $newvalue ) {
334
- $this->_plugin->SetGlobalOption( 'admin-bar-notif-updates', $newvalue );
335
  }
336
 
337
  /**
@@ -340,7 +464,7 @@ class WSAL_Settings {
340
  * @return boolean
341
  */
342
  public function IsRefreshAlertsEnabled() {
343
- return ! $this->_plugin->GetGlobalOption( 'disable-refresh' );
344
  }
345
 
346
  /**
@@ -349,7 +473,7 @@ class WSAL_Settings {
349
  * @param boolean $newvalue - True if enabled.
350
  */
351
  public function SetRefreshAlertsEnabled( $newvalue ) {
352
- $this->_plugin->SetGlobalOption( 'disable-refresh', ! $newvalue );
353
  }
354
 
355
  /**
@@ -386,7 +510,7 @@ class WSAL_Settings {
386
  */
387
  public function GetPruningDate() {
388
  if ( ! $this->_pruning ) {
389
- $this->_pruning = $this->_plugin->options_helper->get_option_value( 'pruning-date' );
390
  if ( ! strtotime( $this->_pruning ) ) {
391
  $this->_pruning = $this->GetDefaultPruningDate();
392
  }
@@ -401,7 +525,7 @@ class WSAL_Settings {
401
  */
402
  public function SetPruningDate( $newvalue ) {
403
  if ( strtotime( $newvalue ) ) {
404
- $this->_plugin->options_helper->set_option_value( 'pruning-date', $newvalue );
405
  $this->_pruning = $newvalue;
406
  }
407
  }
@@ -412,7 +536,7 @@ class WSAL_Settings {
412
  * @return string
413
  */
414
  public function get_pruning_unit() {
415
- return $this->_plugin->options_helper->get_option_value( 'pruning-unit', 'months' );
416
  }
417
 
418
  /**
@@ -421,7 +545,7 @@ class WSAL_Settings {
421
  * @param string $newvalue – New value of pruning unit.
422
  */
423
  public function set_pruning_unit( $newvalue ) {
424
- $this->_plugin->options_helper->set_option_value( 'pruning-unit', $newvalue );
425
  }
426
 
427
  /**
@@ -430,7 +554,7 @@ class WSAL_Settings {
430
  * @return integer
431
  */
432
  public function GetPruningLimit() {
433
- $val = (int) $this->_plugin->options_helper->get_option_value( 'pruning-limit' );
434
  return $val ? $val : $this->GetMaxAllowedAlerts();
435
  }
436
 
@@ -441,27 +565,23 @@ class WSAL_Settings {
441
  */
442
  public function SetPruningLimit( $newvalue ) {
443
  $newvalue = max( /*min(*/ (int) $newvalue/*, $this->GetMaxAllowedAlerts())*/, 1 );
444
- $this->_plugin->options_helper->set_option_value( 'pruning-limit', $newvalue );
445
  }
446
 
447
  public function SetPruningDateEnabled( $enabled ) {
448
- $this->_plugin->options_helper->set_option_value( 'pruning-date-e', $enabled );
449
  }
450
 
451
  public function SetPruningLimitEnabled( $enabled ) {
452
- $this->_plugin->options_helper->set_option_value( 'pruning-limit-e', $enabled );
453
  }
454
 
455
  public function IsPruningDateEnabled() {
456
- return $this->_plugin->options_helper->get_option_value( 'pruning-date-e' );
457
  }
458
 
459
  public function IsPruningLimitEnabled() {
460
- return $this->_plugin->options_helper->get_option_value( 'pruning-limit-e' );
461
- }
462
-
463
- public function IsRestrictAdmins() {
464
- return $this->_plugin->GetGlobalOption( 'restrict-admins', false );
465
  }
466
 
467
  /**
@@ -473,17 +593,13 @@ class WSAL_Settings {
473
  return esc_html__( 'This function is deprecated', 'wp-security-audit-log' );
474
  }
475
 
476
- public function SetRestrictAdmins( $enable ) {
477
- $this->_plugin->SetGlobalOption( 'restrict-admins', (bool) $enable );
478
- }
479
-
480
  /**
481
  * Method: Set Login Page Notification.
482
  *
483
  * @param bool $enable - Enable/Disable.
484
  */
485
  public function set_login_page_notification( $enable ) {
486
- $this->_plugin->SetGlobalOption( 'login_page_notification', $enable );
487
  }
488
 
489
  /**
@@ -492,7 +608,7 @@ class WSAL_Settings {
492
  * @return bool - True if set, false if not.
493
  */
494
  public function is_login_page_notification() {
495
- return $this->_plugin->GetGlobalOption( 'login_page_notification', false );
496
  }
497
 
498
  /**
@@ -502,7 +618,7 @@ class WSAL_Settings {
502
  */
503
  public function set_login_page_notification_text( $text ) {
504
  $text = wp_kses( $text, $this->_plugin->allowed_html_tags );
505
- $this->_plugin->SetGlobalOption( 'login_page_notification_text', $text );
506
  }
507
 
508
  /**
@@ -511,7 +627,7 @@ class WSAL_Settings {
511
  * @return string|bool - Text if set, false if not.
512
  */
513
  public function get_login_page_notification_text() {
514
- return $this->_plugin->GetGlobalOption( 'login_page_notification_text', false );
515
  }
516
 
517
  public function GetDefaultDisabledAlerts() {
@@ -526,7 +642,7 @@ class WSAL_Settings {
526
  public function GetDisabledAlerts() {
527
  if ( ! $this->_disabled ) {
528
  $this->_disabled = implode( ',', $this->GetDefaultDisabledAlerts() );
529
- $this->_disabled = $this->_plugin->options_helper->get_option_value( 'disabled-alerts', $this->_disabled );
530
  $this->_disabled = ( '' == $this->_disabled ) ? array() : explode( ',', $this->_disabled );
531
  $this->_disabled = array_map( 'intval', $this->_disabled );
532
  }
@@ -540,26 +656,32 @@ class WSAL_Settings {
540
  */
541
  public function SetDisabledAlerts( $types ) {
542
  $this->_disabled = array_unique( array_map( 'intval', $types ) );
543
- $this->_plugin->options_helper->set_option_value( 'disabled-alerts', implode( ',', $this->_disabled ) );
544
  }
545
 
 
 
 
546
  public function IsIncognito() {
547
- return $this->_plugin->GetGlobalOption( 'hide-plugin' );
548
  }
549
 
 
 
 
550
  public function SetIncognito( $enabled ) {
551
- $this->_plugin->SetGlobalOption( 'hide-plugin', $enabled );
552
  }
553
 
554
  /**
555
  * Checking if the data will be removed.
556
  */
557
  public function IsDeleteData() {
558
- return $this->_plugin->GetGlobalOption( 'delete-data' );
559
  }
560
 
561
  public function SetDeleteData( $enabled ) {
562
- $this->_plugin->SetGlobalOption( 'delete-data', $enabled );
563
  }
564
 
565
  /**
@@ -569,7 +691,7 @@ class WSAL_Settings {
569
  */
570
  public function SetAllowedPluginViewers( $users_or_roles ) {
571
  $this->_viewers = $users_or_roles;
572
- $this->_plugin->SetGlobalOption( 'plugin-viewers', implode( ',', $this->_viewers ) );
573
  }
574
 
575
  /**
@@ -577,62 +699,57 @@ class WSAL_Settings {
577
  */
578
  public function GetAllowedPluginViewers() {
579
  if ( is_null( $this->_viewers ) ) {
580
- $this->_viewers = array_unique( array_filter( explode( ',', $this->_plugin->GetGlobalOption( 'plugin-viewers' ) ) ) );
581
  }
582
  return $this->_viewers;
583
  }
584
 
585
  /**
586
- * Set Plugin Editors.
587
  *
588
- * @param array $users_or_rolesUsers/Roles.
 
589
  */
590
- public function SetAllowedPluginEditors( $users_or_roles ) {
591
- $this->_editors = $users_or_roles;
592
- $this->_plugin->SetGlobalOption( 'plugin-editors', implode( ',', $this->_editors ) );
593
  }
594
 
595
  /**
596
- * Get Plugin Editors.
 
 
597
  */
598
- public function GetAllowedPluginEditors() {
599
- if ( is_null( $this->_editors ) ) {
600
- $this->_editors = array_unique( array_filter( explode( ',', $this->_plugin->GetGlobalOption( 'plugin-editors' ) ) ) );
601
- }
602
- return $this->_editors;
603
  }
604
 
605
  /**
606
- * Set restrict plugin setting.
607
  *
608
- * @param string $setting – Setting.
609
- * @since 3.2.3
610
  */
611
- public function set_restrict_plugin_setting( $setting ) {
612
- $this->_plugin->SetGlobalOption( 'restrict-plugin-settings', $setting );
613
  }
614
 
615
  /**
616
- * Get restrict plugin setting.
617
  *
618
- * @since 3.2.3
 
619
  */
620
- public function get_restrict_plugin_setting() {
621
- $default_value = 'only_admins';
622
- if ( $this->IsRestrictAdmins() ) {
623
- $default_value = 'only_me';
624
- }
625
- return $this->_plugin->GetGlobalOption( 'restrict-plugin-settings', $default_value );
626
  }
627
 
628
  public function SetViewPerPage( $newvalue ) {
629
  $this->_perpage = max( $newvalue, 1 );
630
- $this->_plugin->SetGlobalOption( 'items-per-page', $this->_perpage );
631
  }
632
 
633
  public function GetViewPerPage() {
634
  if ( is_null( $this->_perpage ) ) {
635
- $this->_perpage = (int) $this->_plugin->GetGlobalOption( 'items-per-page', 10 );
636
  }
637
  return $this->_perpage;
638
  }
@@ -692,68 +809,108 @@ class WSAL_Settings {
692
  }
693
 
694
  /**
695
- * Returns access tokens for a particular action.
696
  *
697
- * @param string $action - Type of action.
698
- * @throws Exception - Unknown action exception.
699
- * @return array - List of tokens (usernames, roles etc).
700
  */
701
- public function GetAccessTokens( $action ) {
702
- $allowed = array();
 
 
 
 
 
 
 
703
  switch ( $action ) {
704
  case 'view':
705
- $allowed = $this->GetAllowedPluginViewers();
706
- $allowed = array_merge( $allowed, $this->GetAllowedPluginEditors() );
707
- if ( ! $this->_plugin->IsMultisite() && ! $this->IsRestrictAdmins() ) {
708
- $allowed = array_merge( $allowed, $this->GetSuperAdmins() );
709
- $allowed = array_merge( $allowed, $this->GetAdmins() );
710
- } elseif ( $this->_plugin->IsMultisite() && ! $this->IsRestrictAdmins() ) {
711
- if ( 'only_superadmins' === $this->get_restrict_plugin_setting() ) {
712
- $allowed = array_merge( $allowed, $this->GetSuperAdmins() );
713
- } else {
714
- $allowed = array_merge( $allowed, $this->GetSuperAdmins() );
715
- $allowed = array_merge( $allowed, $this->GetAdmins() );
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
716
  }
717
  }
718
  break;
719
  case 'edit':
720
- $allowed = $this->GetAllowedPluginEditors();
721
- if ( ! $this->IsRestrictAdmins() ) {
722
- $allowed = array_merge( $allowed, $this->_plugin->IsMultisite() ? $this->GetSuperAdmins() : $this->GetAdmins() );
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
723
  }
724
  break;
725
  default:
726
- throw new Exception( 'Unknown action "' . $action . '".' );
727
- }
728
- if ( ! $this->IsRestrictAdmins() ) {
729
- if ( is_multisite() ) {
730
- $allowed = array_merge( $allowed, get_super_admins() );
731
- } else {
732
- $allowed[] = 'administrator';
733
- }
734
  }
735
- return array_unique( $allowed );
736
- }
737
 
738
- /**
739
- * Check if user can perform an action.
740
- *
741
- * @param integer|WP_user $user - User object to check.
742
- * @param string $action - Type of action, either 'view' or 'edit'.
743
- * @return boolean If user has access or not.
744
- */
745
- public function UserCan( $user, $action ) {
746
- if ( is_int( $user ) ) {
747
- $user = get_userdata( $user );
748
- }
749
- $allowed = $this->GetAccessTokens( $action );
750
- $check = array_merge( $user->roles, array( $user->user_login ) );
751
- foreach ( $check as $item ) {
752
- if ( in_array( $item, $allowed ) ) {
753
- return true;
754
- }
755
- }
756
- return false;
757
  }
758
 
759
  public function GetCurrentUserRoles( $base_roles = null ) {
@@ -772,19 +929,19 @@ class WSAL_Settings {
772
  }
773
 
774
  public function IsMainIPFromProxy() {
775
- return $this->_plugin->GetGlobalOption( 'use-proxy-ip' );
776
  }
777
 
778
  public function SetMainIPFromProxy( $enabled ) {
779
- $this->_plugin->SetGlobalOption( 'use-proxy-ip', $enabled );
780
  }
781
 
782
  public function IsInternalIPsFiltered() {
783
- return $this->_plugin->GetGlobalOption( 'filter-internal-ip' );
784
  }
785
 
786
  public function SetInternalIPsFiltering( $enabled ) {
787
- $this->_plugin->SetGlobalOption( 'filter-internal-ip', $enabled );
788
  }
789
 
790
  /**
@@ -894,12 +1051,12 @@ class WSAL_Settings {
894
  */
895
  public function SetExcludedMonitoringUsers( $users ) {
896
  $this->_excluded_users = $users;
897
- $this->_plugin->SetGlobalOption( 'excluded-users', esc_html( implode( ',', $this->_excluded_users ) ) );
898
  }
899
 
900
  public function GetExcludedMonitoringUsers() {
901
  if ( empty( $this->_excluded_users ) ) {
902
- $this->_excluded_users = array_unique( array_filter( explode( ',', $this->_plugin->GetGlobalOption( 'excluded-users' ) ) ) );
903
  }
904
  return $this->_excluded_users;
905
  }
@@ -912,7 +1069,7 @@ class WSAL_Settings {
912
  */
913
  public function set_excluded_post_types( $post_types ) {
914
  $this->_post_types = $post_types;
915
- $this->_plugin->SetGlobalOption( 'custom-post-types', esc_html( implode( ',', $this->_post_types ) ) );
916
  }
917
 
918
  /**
@@ -922,7 +1079,7 @@ class WSAL_Settings {
922
  */
923
  public function get_excluded_post_types() {
924
  if ( empty( $this->_post_types ) ) {
925
- $this->_post_types = array_unique( array_filter( explode( ',', $this->_plugin->GetGlobalOption( 'custom-post-types' ) ) ) );
926
  }
927
  return $this->_post_types;
928
  }
@@ -937,7 +1094,7 @@ class WSAL_Settings {
937
  $urls = array_map( 'untrailingslashit', $urls );
938
  $urls = array_unique( $urls );
939
  $this->excluded_urls = $urls;
940
- $this->_plugin->SetGlobalOption( 'excluded-urls', esc_html( implode( ',', $this->excluded_urls ) ) );
941
  }
942
 
943
  /**
@@ -947,7 +1104,7 @@ class WSAL_Settings {
947
  */
948
  public function get_excluded_urls() {
949
  if ( empty( $this->excluded_urls ) ) {
950
- $this->excluded_urls = array_unique( array_filter( explode( ',', $this->_plugin->GetGlobalOption( 'excluded-urls' ) ) ) );
951
  }
952
  return $this->excluded_urls;
953
  }
@@ -959,7 +1116,7 @@ class WSAL_Settings {
959
  */
960
  public function SetExcludedMonitoringRoles( $roles ) {
961
  $this->_excluded_roles = $roles;
962
- $this->_plugin->SetGlobalOption( 'excluded-roles', esc_html( implode( ',', $this->_excluded_roles ) ) );
963
  }
964
 
965
  /**
@@ -967,7 +1124,7 @@ class WSAL_Settings {
967
  */
968
  public function GetExcludedMonitoringRoles() {
969
  if ( empty( $this->_excluded_roles ) ) {
970
- $this->_excluded_roles = array_unique( array_filter( explode( ',', $this->_plugin->GetGlobalOption( 'excluded-roles' ) ) ) );
971
  }
972
  return $this->_excluded_roles;
973
  }
@@ -977,12 +1134,12 @@ class WSAL_Settings {
977
  */
978
  public function SetExcludedMonitoringCustom( $custom ) {
979
  $this->_excluded_custom = $custom;
980
- $this->_plugin->SetGlobalOption( 'excluded-custom', esc_html( implode( ',', $this->_excluded_custom ) ) );
981
  }
982
 
983
  public function GetExcludedMonitoringCustom() {
984
  if ( empty( $this->_excluded_custom ) ) {
985
- $this->_excluded_custom = array_unique( array_filter( explode( ',', $this->_plugin->GetGlobalOption( 'excluded-custom' ) ) ) );
986
  asort( $this->_excluded_custom );
987
  }
988
  return $this->_excluded_custom;
@@ -993,12 +1150,12 @@ class WSAL_Settings {
993
  */
994
  public function SetExcludedMonitoringIP( $ip ) {
995
  $this->_excluded_ip = $ip;
996
- $this->_plugin->SetGlobalOption( 'excluded-ip', esc_html( implode( ',', $this->_excluded_ip ) ) );
997
  }
998
 
999
  public function GetExcludedMonitoringIP() {
1000
  if ( empty( $this->_excluded_ip ) ) {
1001
- $this->_excluded_ip = array_unique( array_filter( explode( ',', $this->_plugin->GetGlobalOption( 'excluded-ip' ) ) ) );
1002
  }
1003
  return $this->_excluded_ip;
1004
  }
@@ -1067,11 +1224,11 @@ class WSAL_Settings {
1067
  * Server's timezone or WordPress' timezone.
1068
  */
1069
  public function GetTimezone() {
1070
- return $this->_plugin->options_helper->get_option_value( 'timezone', 'wp' );
1071
  }
1072
 
1073
  public function SetTimezone( $newvalue ) {
1074
- $this->_plugin->options_helper->set_option_value( 'timezone', $newvalue );
1075
  }
1076
 
1077
  /**
@@ -1083,7 +1240,7 @@ class WSAL_Settings {
1083
  * @return bool
1084
  */
1085
  public function get_show_milliseconds() {
1086
- return $this->_plugin->GetGlobalOption( 'show_milliseconds', 'yes' );
1087
  }
1088
 
1089
  /**
@@ -1096,8 +1253,7 @@ class WSAL_Settings {
1096
  * @param mixed $newvalue ideally always bool. If not bool then it's cast to true.
1097
  */
1098
  public function set_show_milliseconds( $newvalue ) {
1099
- $newvalue = ( ! empty( $newvalue ) ) ? 'yes' : 'no';
1100
- $this->_plugin->SetGlobalOption( 'show_milliseconds', $newvalue );
1101
  }
1102
 
1103
 
@@ -1105,7 +1261,7 @@ class WSAL_Settings {
1105
  * Get type of username to display.
1106
  */
1107
  public function get_type_username() {
1108
- return $this->_plugin->options_helper->get_option_value( 'type_username', 'display_name' );
1109
  }
1110
 
1111
  /**
@@ -1115,15 +1271,15 @@ class WSAL_Settings {
1115
  * @since 2.6.5
1116
  */
1117
  public function set_type_username( $newvalue ) {
1118
- $this->_plugin->options_helper->set_option_value( 'type_username', $newvalue );
1119
  }
1120
 
1121
  public function GetAdapterConfig( $name_field, $default_value = false ) {
1122
- return $this->_plugin->GetGlobalOption( $name_field, $default_value );
1123
  }
1124
 
1125
  public function SetAdapterConfig( $name_field, $newvalue ) {
1126
- $this->_plugin->SetGlobalOption( $name_field, trim( $newvalue ) );
1127
  }
1128
 
1129
  /**
@@ -1176,19 +1332,19 @@ class WSAL_Settings {
1176
  }
1177
 
1178
  public function GetColumnsSelected() {
1179
- return $this->_plugin->options_helper->get_option_value( 'columns', array() );
1180
  }
1181
 
1182
  public function SetColumns( $columns ) {
1183
- $this->_plugin->options_helper->set_option_value( 'columns', json_encode( $columns ) );
1184
  }
1185
 
1186
  public function IsWPBackend() {
1187
- return $this->_plugin->options_helper->get_option_value( 'wp-backend' );
1188
  }
1189
 
1190
  public function SetWPBackend( $enabled ) {
1191
- $this->_plugin->options_helper->set_option_value( 'wp-backend', $enabled );
1192
  }
1193
 
1194
  /**
@@ -1197,7 +1353,7 @@ class WSAL_Settings {
1197
  * @param string $use – Setting value.
1198
  */
1199
  public function set_use_email( $use ) {
1200
- $this->_plugin->SetGlobalOption( 'use-email', $use );
1201
  }
1202
 
1203
  /**
@@ -1206,31 +1362,31 @@ class WSAL_Settings {
1206
  * @return string
1207
  */
1208
  public function get_use_email() {
1209
- return $this->_plugin->GetGlobalOption( 'use-email', 'default_email' );
1210
  }
1211
 
1212
  public function SetFromEmail( $email_address ) {
1213
- $this->_plugin->SetGlobalOption( 'from-email', trim( $email_address ) );
1214
  }
1215
 
1216
  public function GetFromEmail() {
1217
- return $this->_plugin->GetGlobalOption( 'from-email' );
1218
  }
1219
 
1220
  public function SetDisplayName( $display_name ) {
1221
- $this->_plugin->SetGlobalOption( 'display-name', trim( $display_name ) );
1222
  }
1223
 
1224
  public function GetDisplayName() {
1225
- return $this->_plugin->GetGlobalOption( 'display-name' );
1226
  }
1227
 
1228
  public function Set404LogLimit( $value ) {
1229
- $this->_plugin->options_helper->set_option_value( 'log-404-limit', abs( $value ) );
1230
  }
1231
 
1232
  public function Get404LogLimit() {
1233
- return $this->_plugin->options_helper->get_option_value( 'log-404-limit', 99 );
1234
  }
1235
 
1236
  /**
@@ -1240,7 +1396,7 @@ class WSAL_Settings {
1240
  * @since 2.6.3
1241
  */
1242
  public function SetVisitor404LogLimit( $value ) {
1243
- $this->_plugin->options_helper->set_option_value( 'log-visitor-404-limit', abs( $value ) );
1244
  }
1245
 
1246
  /**
@@ -1249,7 +1405,7 @@ class WSAL_Settings {
1249
  * @since 2.6.3
1250
  */
1251
  public function GetVisitor404LogLimit() {
1252
- return $this->_plugin->options_helper->get_option_value( 'log-visitor-404-limit', 99 );
1253
  }
1254
 
1255
  /**
@@ -1260,9 +1416,9 @@ class WSAL_Settings {
1260
  */
1261
  public function set_failed_login_limit( $value ) {
1262
  if ( ! empty( $value ) ) {
1263
- $this->_plugin->options_helper->set_option_value( 'log-failed-login-limit', abs( $value ) );
1264
  } else {
1265
- $this->_plugin->options_helper->set_option_value( 'log-failed-login-limit', -1 );
1266
  }
1267
  }
1268
 
@@ -1272,7 +1428,7 @@ class WSAL_Settings {
1272
  * @since 2.6.3
1273
  */
1274
  public function get_failed_login_limit() {
1275
- return $this->_plugin->options_helper->get_option_value( 'log-failed-login-limit', 10 );
1276
  }
1277
 
1278
  /**
@@ -1283,9 +1439,9 @@ class WSAL_Settings {
1283
  */
1284
  public function set_visitor_failed_login_limit( $value ) {
1285
  if ( ! empty( $value ) ) {
1286
- $this->_plugin->options_helper->set_option_value( 'log-visitor-failed-login-limit', abs( $value ) );
1287
  } else {
1288
- $this->_plugin->options_helper->set_option_value( 'log-visitor-failed-login-limit', -1 );
1289
  }
1290
  }
1291
 
@@ -1295,11 +1451,11 @@ class WSAL_Settings {
1295
  * @since 2.6.3
1296
  */
1297
  public function get_visitor_failed_login_limit() {
1298
- return $this->_plugin->options_helper->get_option_value( 'log-visitor-failed-login-limit', 10 );
1299
  }
1300
 
1301
  public function IsArchivingEnabled() {
1302
- return $this->_plugin->GetGlobalOption( 'archiving-e' );
1303
  }
1304
 
1305
  /**
@@ -1307,66 +1463,58 @@ class WSAL_Settings {
1307
  */
1308
  public function SwitchToArchiveDB() {
1309
  if ( $this->IsArchivingEnabled() ) {
1310
- $archive_type = $this->_plugin->GetGlobalOption( 'archive-type' );
1311
- $archive_user = $this->_plugin->GetGlobalOption( 'archive-user' );
1312
- $password = $this->_plugin->GetGlobalOption( 'archive-password' );
1313
- $archive_name = $this->_plugin->GetGlobalOption( 'archive-name' );
1314
- $archive_hostname = $this->_plugin->GetGlobalOption( 'archive-hostname' );
1315
- $archive_baseprefix = $this->_plugin->GetGlobalOption( 'archive-base-prefix' );
1316
- $archive_ssl = $this->_plugin->GetGlobalOption( 'archive-ssl', false );
1317
- $archive_cc = $this->_plugin->GetGlobalOption( 'archive-client-certificate', false );
1318
- $archive_ssl_ca = $this->_plugin->GetGlobalOption( 'archive-ssl-ca', false );
1319
- $archive_ssl_cert = $this->_plugin->GetGlobalOption( 'archive-ssl-cert', false );
1320
- $archive_ssl_key = $this->_plugin->GetGlobalOption( 'archive-ssl-key', false );
1321
  $config = WSAL_Connector_ConnectorFactory::GetConfigArray( $archive_type, $archive_user, $password, $archive_name, $archive_hostname, $archive_baseprefix, $archive_ssl, $archive_cc, $archive_ssl_ca, $archive_ssl_cert, $archive_ssl_key );
1322
  $this->_plugin->getConnector( $config )->getAdapter( 'Occurrence' );
1323
  }
1324
  }
1325
 
1326
  /**
1327
- * Generate index.php file for each wsal sub-directory
1328
- * present in the uploads directory.
1329
  *
1330
  * @since 3.1.2
1331
  */
1332
  public function generate_index_files() {
1333
- // Get uploads directory.
1334
- $uploads_dir = wp_upload_dir();
1335
- $wsal_uploads_dir = trailingslashit( $uploads_dir['basedir'] . '/wp-security-audit-log/' );
1336
 
1337
  // If the directory exists then generate index.php file for every sub-directory.
1338
- if ( ! empty( $wsal_uploads_dir ) && is_dir( $wsal_uploads_dir ) ) {
1339
  // Generate index.php for the main directory.
1340
- if ( ! file_exists( $wsal_uploads_dir . '/index.php' ) ) {
1341
  // Generate index.php file.
1342
- $this->create_index_file( $wsal_uploads_dir );
1343
  }
1344
 
1345
  // Generate .htaccess for the main directory.
1346
- if ( ! file_exists( $wsal_uploads_dir . '/.htaccess' ) ) {
1347
  // Generate .htaccess file.
1348
- $this->create_htaccess_file( $wsal_uploads_dir );
1349
  }
1350
 
1351
  // Fetch all files in the uploads directory.
1352
- $sub_directories = glob( $wsal_uploads_dir . '*' );
1353
  foreach ( $sub_directories as $sub_dir ) {
1354
  // index.php file.
1355
- if ( is_dir( $sub_dir ) && ! file_exists( $sub_dir . '/index.php' ) ) {
1356
  // Generate index.php file.
1357
  $this->create_index_file( $sub_dir . '/' );
1358
  }
1359
 
1360
  // .htaccess file.
1361
- if ( is_dir( $sub_dir ) && ! file_exists( $sub_dir . '/.htaccess' ) ) {
1362
- // Check for failed-logins, users, visitors and don't create file in it.
1363
- if ( strpos( $sub_dir, 'failed-logins' )
1364
- || strpos( $sub_dir, 'users' )
1365
- || strpos( $sub_dir, 'visitors' ) ) {
1366
- continue;
1367
- }
1368
  // Generate .htaccess file.
1369
- $this->create_htaccess_file( $sub_dir . '/' );
1370
  }
1371
  }
1372
  }
@@ -1492,13 +1640,13 @@ class WSAL_Settings {
1492
  */
1493
  public function set_mainwp_child_stealth_mode() {
1494
  if (
1495
- 'yes' !== $this->_plugin->GetGlobalOption( 'mwp-child-stealth-mode', 'no' ) // MainWP Child Stealth Mode is not already active.
1496
  && WpSecurityAuditLog::is_mainwp_active() // And if MainWP Child plugin is installed & active.
1497
  ) {
1498
  // Check if freemius state is anonymous.
1499
- if ( ! wsal_freemius()->is_premium() && 'anonymous' === get_site_option( 'wsal_freemius_state', 'anonymous' ) ) {
1500
  // Update freemius state to skipped.
1501
- update_site_option( 'wsal_freemius_state', 'skipped' );
1502
 
1503
  if ( ! $this->_plugin->IsMultisite() ) {
1504
  wsal_freemius()->skip_connection(); // Opt out.
@@ -1515,12 +1663,13 @@ class WSAL_Settings {
1515
  FS_Admin_Notices::instance( 'wp-security-audit-log' )->remove_sticky( 'trial_promotion' );
1516
  }
1517
 
1518
- $this->SetIncognito( '1' ); // Incognito mode to hide WSAL on plugins page.
1519
- $this->SetRestrictAdmins( true ); // Restrict other admins.
1520
- $editors = array();
1521
- $editors[] = wp_get_current_user()->user_login; // Set the current user as the editor of WSAL.
1522
- $this->SetAllowedPluginEditors( $editors ); // Save the editors.
1523
- $this->_plugin->SetGlobalOption( 'mwp-child-stealth-mode', 'yes' ); // Save stealth mode option.
 
1524
  }
1525
  }
1526
 
@@ -1530,10 +1679,11 @@ class WSAL_Settings {
1530
  * @since 3.2.3.3
1531
  */
1532
  public function deactivate_mainwp_child_stealth_mode() {
1533
- $this->SetIncognito( '0' ); // Disable incognito mode to hide WSAL on plugins page.
1534
- $this->SetRestrictAdmins( false ); // Give access to other admins.
1535
- $this->SetAllowedPluginEditors( array() ); // Empty the editors.
1536
- $this->_plugin->SetGlobalOption( 'mwp-child-stealth-mode', 'no' ); // Disable stealth mode option.
 
1537
  }
1538
 
1539
  /**
@@ -1546,7 +1696,7 @@ class WSAL_Settings {
1546
  return;
1547
  }
1548
 
1549
- if ( 'yes' === $this->_plugin->GetGlobalOption( 'mwp-child-stealth-mode', 'no' ) ) {
1550
  $this->deactivate_mainwp_child_stealth_mode();
1551
  }
1552
  }
@@ -1557,18 +1707,19 @@ class WSAL_Settings {
1557
  * @return boolean
1558
  */
1559
  public function is_stealth_mode() {
1560
- $stealth_mode = $this->_plugin->GetGlobalOption( 'mwp-child-stealth-mode', 'no' );
1561
- return 'yes' === $stealth_mode;
1562
  }
1563
 
1564
  /**
1565
- * Method: Meta data formater.
 
 
 
 
 
1566
  *
1567
- * @param string $name - Name of the data.
1568
- * @param mixed $value - Value of the data.
1569
- * @param integer $occ_id - Event occurrence ID.
1570
- * @param mixed $highlight - Highlight format.
1571
  * @return string
 
1572
  */
1573
  public function meta_formatter( $name, $value, $occ_id, $highlight ) {
1574
  if ( $highlight && 'daily-report' === $highlight ) {
@@ -1603,15 +1754,12 @@ class WSAL_Settings {
1603
  }
1604
  return false;
1605
 
1606
- case in_array( $name, array( '%EditorLinkPost%', '%EditorLinkProduct%', '%EditorLinkCoupon%' ) ):
1607
  return '<a target="_blank" href="' . esc_url( $value ) . '">' . __( 'View post in the editor', 'wp-security-audit-log' ) . '</a>';
1608
 
1609
  case '%EditorLinkOrder%' == $name:
1610
  return '<a target="_blank" href="' . esc_url( $value ) . '">' . __( 'View Order', 'wp-security-audit-log' ) . '</a>';
1611
 
1612
- case '%EditorLinkPage%' == $name:
1613
- return '<a target="_blank" href="' . esc_url( $value ) . '">' . __( 'View post in the editor', 'wp-security-audit-log' ) . '</a>';
1614
-
1615
  case '%CategoryLink%' == $name:
1616
  case '%cat_link%' == $name:
1617
  case '%ProductCatLink%' == $name:
@@ -1632,6 +1780,7 @@ class WSAL_Settings {
1632
  ) . $highlight_end_tag;
1633
 
1634
  case '%ClientIP%' == $name:
 
1635
  if ( is_string( $value ) ) {
1636
  return $highlight_start_tag . str_replace( array( '"', '[', ']' ), '', $value ) . $highlight_end_tag;
1637
  } else {
@@ -1846,7 +1995,7 @@ class WSAL_Settings {
1846
  }
1847
 
1848
  /**
1849
- * Method: Meta data formater.
1850
  *
1851
  * @since 3.3
1852
  *
@@ -1883,9 +2032,6 @@ class WSAL_Settings {
1883
  case '%EditorLinkOrder%' === $name:
1884
  return ' <' . esc_url( $value ) . '|View Order>';
1885
 
1886
- case '%EditorLinkPage%' === $name:
1887
- return ' View the <' . esc_url( $value ) . '|page>';
1888
-
1889
  case '%CategoryLink%' === $name:
1890
  case '%cat_link%' === $name:
1891
  case '%ProductCatLink%' == $name:
@@ -2014,7 +2160,7 @@ class WSAL_Settings {
2014
  * @return string
2015
  */
2016
  public function get_events_type_nav() {
2017
- return $this->_plugin->GetGlobalOption( 'events-nav-type', 'infinite-scroll' );
2018
  }
2019
 
2020
  /**
@@ -2028,7 +2174,7 @@ class WSAL_Settings {
2028
  * @return string
2029
  */
2030
  public function set_events_type_nav( $nav_type ) {
2031
- $this->_plugin->SetGlobalOption( 'events-nav-type', $nav_type );
2032
  }
2033
 
2034
  /**
@@ -2263,7 +2409,7 @@ class WSAL_Settings {
2263
  *
2264
  * @return array
2265
  */
2266
- public function get_frontend_events() {
2267
  // Option defaults.
2268
  $default = array(
2269
  'register' => false,
@@ -2273,8 +2419,7 @@ class WSAL_Settings {
2273
  );
2274
 
2275
  // Get the option.
2276
- $event_opt = 'wsal-frontend-events';
2277
- $value = ! is_multisite() ? get_option( $event_opt, $default ) : get_network_option( get_main_network_id(), $event_opt, $default );
2278
 
2279
  // Check for WooCommerce in case it is not stored.
2280
  $value['woocommerce'] = ! isset( $value['woocommerce'] ) ? WpSecurityAuditLog::is_woocommerce_active() : $value['woocommerce'];
@@ -2288,7 +2433,49 @@ class WSAL_Settings {
2288
  * @return bool
2289
  */
2290
  public function set_frontend_events( $value = array() ) {
2291
- $event_opt = 'wsal-frontend-events';
2292
- return ! is_multisite() ? update_option( $event_opt, $value ) : update_network_option( get_main_network_id(), $event_opt, $value );
2293
  }
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
2294
  }
19
  */
20
  class WSAL_Settings {
21
 
22
+ /**
23
+ * Option name for front-end events.
24
+ *
25
+ * @var string
26
+ */
27
+ const FRONT_END_EVENTS_OPTION_NAME = 'wsal_frontend-events';
28
+
29
  /**
30
  * Instance of the main plugin.
31
  *
39
  const OPT_DEV_BACKTRACE_LOG = 'b';
40
  const ERROR_CODE_INVALID_IP = 901;
41
 
 
 
42
  /**
43
  * List of Site Admins.
44
  *
74
  */
75
  protected $_viewers = null;
76
 
 
 
 
 
 
 
 
77
  /**
78
  * Alerts per page.
79
  *
129
  *
130
  * @var array
131
  */
132
+ public $geek_alerts = array( 1004, 1005, 1006, 1007, 2023, 2024, 2053, 2054, 2055, 2062, 2100, 2106, 2111, 2112, 2124, 2125, 2131, 2132, 2094, 2095, 2043, 2071, 2082, 2083, 2085, 2089, 4014, 4015, 4016, 5010, 5011, 5012, 5019, 5025, 5013, 5014, 5015, 5016, 5017, 5018, 5022, 5023, 5024, 6001, 6002, 6007, 6008, 6010, 6011, 6012, 6013, 6014, 6015, 6016, 6017, 6018, 6023, 6024, 6025 );
133
 
134
  /**
135
  * Current screen object.
152
  add_action( 'deactivated_plugin', array( $this, 'reset_stealth_mode' ), 10, 1 );
153
  }
154
 
155
+ /**
156
+ * Gets path to the default working directory relative to the root of WordPress site.
157
+ *
158
+ * Uses forward slashes and result has a slash at the end.
159
+ *
160
+ * @return string
161
+ */
162
+ public function get_default_working_dir_relative() {
163
+ $upload_dir = wp_upload_dir(null, false);
164
+ if (false === $upload_dir || ! array_key_exists('basedir', $upload_dir) ||
165
+ ( array_key_exists('error', $upload_dir) && ! empty ( $upload_dir['error'] ) )
166
+ ) {
167
+ // fallback in case there is a problem with filesystem
168
+ return '/wp-content/uploads/wp-activity-log/';
169
+ }
170
+
171
+ $result = $upload_dir['basedir'] . '/wp-activity-log/';
172
+
173
+ // remove absolute path from the basedir to make it relative
174
+ if ( defined( 'ABSPATH' ) ) {
175
+ $result = preg_replace( '/^' . preg_quote( ABSPATH, '/' ) . '/', '', $result );
176
+ // add leading slash if missing
177
+ if ( '/' !== substr( $result, 0, 1) ) {
178
+ $result = '/' . $result;
179
+ }
180
+ }
181
+ return $result;
182
+ }
183
+
184
+ /**
185
+ * Retrieves the working directory from the settings relative to the WordPress root folder.
186
+ *
187
+ * Used by two public helper functions that provide the working directory path and URL for the rest of the plugin:
188
+ * - WSAL_Settings::get_working_dir_path
189
+ * - WSAL_Settings::get_working_dir_url
190
+ *
191
+ * Result contains forward slashes suitable for use in URL. It also contains the trailing slash. Replace slashes
192
+ * with system specific directory separators when used as filesystem path. This is already done in
193
+ * WSAL_Settings::get_working_dir_path in case you need it.
194
+ *
195
+ * @param string $path Optional path relative to the working directory.
196
+ * @param bool $ignore_site If true, there will be no sub-site specific subfolder in multisite context.
197
+ * @return string
198
+ * @since 4.1.3
199
+ *
200
+ * @see WSAL_Settings::get_working_dir_path()
201
+ * @see WSAL_Settings::get_working_dir_url()
202
+ * @see WSAL_Settings::get_working_dir_path_relative()
203
+ */
204
+ private function get_working_dir_path_relative( $path = '', $ignore_site = false ) {
205
+ if ( ! \function_exists( 'get_home_path' ) ) {
206
+ require_once ABSPATH . 'wp-admin/includes/file.php';
207
+ }
208
+
209
+ // get relative path from the plugin settings
210
+ $result = trailingslashit( $this->_plugin->GetGlobalSetting( 'custom-logging-dir', $this->get_default_working_dir_relative() ) );
211
+
212
+ // append site specific subfolder in multisite context
213
+ if ( ! $ignore_site && $this->_plugin->IsMultisite() ) {
214
+ $site_id = get_current_blog_id();
215
+ if ($site_id > 0) {
216
+ $result .= 'sites/' . $site_id . '/';
217
+ }
218
+ }
219
+
220
+ // append optional path passed as a parameter
221
+ if ( $path && is_string( $path ) ) {
222
+ $result .= $path . '/';
223
+ }
224
+
225
+ // result should have the trailing slash at this point, no need to trailingslashit again
226
+ return $result;
227
+ }
228
+
229
+ /**
230
+ * Retrieves the working directory URL including a trailing slash.
231
+ *
232
+ * Uses as default:
233
+ * {uploads folder}/wp-activity-log/
234
+ *
235
+ * @param string $path Optional path relative to the working directory.
236
+
237
+ * @return string
238
+ * @see WSAL_Settings::get_working_dir_path_relative()
239
+ *
240
+ * @since 4.1.0
241
+ */
242
+ public function get_working_dir_url( $path = '' ) {
243
+ $result = $this->get_default_working_dir_relative( $path );
244
+ return trailingslashit( \get_site_url() ) . $result;
245
+ }
246
+
247
+ /**
248
+ * Retrieves the working directory from the settings. Returns a folder path
249
+ * with a trailing slash. It also creates the folder unless the $skip_creation
250
+ * parameter is set to true.
251
+ *
252
+ * Uses as default:
253
+ * {uploads folder}/wp-activity-log/
254
+ *
255
+ * @param string $path Optional path relative to the working directory.
256
+ * @param bool $skip_creation If true, the folder will not be created.
257
+ * @param bool $ignore_site If true, there will be no sub-site specific subfolder in multisite context.
258
+ *
259
+ * @return string|WP_Error
260
+ * @see WSAL_Settings::get_working_dir_path_relative()
261
+ *
262
+ * @since 4.1.0
263
+ */
264
+ public function get_working_dir_path( $path = '', $skip_creation = false, $ignore_site = false ) {
265
+ $result = $this->get_working_dir_path_relative( $path, $ignore_site );
266
+ $result = trailingslashit( ABSPATH ) . $result;
267
+ $result = preg_replace('/\//', DIRECTORY_SEPARATOR, $result);
268
+ if ( ! $skip_creation ) {
269
+ if ( ! wp_mkdir_p( $result ) ) {
270
+ return new WP_Error('mkdir_failed', sprintf(
271
+ /* translators: %s: Directory path. */
272
+ __( 'Unable to create directory %s. Is its parent directory writable by the server?' ),
273
+ esc_html( $result )
274
+ ));
275
+ }
276
+ }
277
+
278
+ return $result;
279
+ }
280
+
281
  /**
282
  * Enable Basic Mode.
283
  */
310
  */
311
  public function IsDevOptionEnabled( $option ) {
312
  if ( is_null( $this->_devoption ) ) {
313
+ $this->_devoption = $this->_plugin->GetGlobalSetting(
314
  'dev-options',
315
  implode( ',', $this->GetDefaultDevOptions() )
316
  );
325
  * @return boolean
326
  */
327
  public function IsAnyDevOptionEnabled() {
328
+ return ! ! $this->_plugin->GetGlobalSetting( 'dev-options', null );
329
  }
330
 
331
  /**
346
  $this->_devoption[] = $option;
347
  }
348
  // Commit option.
349
+ $this->_plugin->SetGlobalSetting(
350
  'dev-options',
351
  implode( ',', $this->_devoption )
352
  );
357
  */
358
  public function ClearDevOptions() {
359
  $this->_devoption = array();
360
+ $this->_plugin->SetGlobalSetting( 'dev-options', '' );
361
  }
362
 
363
  /**
402
  * @return boolean
403
  */
404
  public function IsWidgetsEnabled() {
405
+ return ! $this->_plugin->GetGlobalBooleanSetting( 'disable-widgets' );
406
  }
407
 
408
  /**
411
  * @param boolean $newvalue - True if enabled.
412
  */
413
  public function SetWidgetsEnabled( $newvalue ) {
414
+ $this->_plugin->SetGlobalBooleanSetting( 'disable-widgets', ! $newvalue );
415
  }
416
 
417
  /**
422
  * @return boolean
423
  */
424
  public function is_admin_bar_notif() {
425
+ return ! $this->_plugin->GetGlobalSetting( 'disable-admin-bar-notif' );
426
  }
427
 
428
  /**
433
  * @param boolean $newvalue - True if enabled.
434
  */
435
  public function set_admin_bar_notif( $newvalue ) {
436
+ $this->_plugin->SetGlobalSetting( 'disable-admin-bar-notif', ! $newvalue );
437
  }
438
 
439
  /**
444
  * @return string
445
  */
446
  public function get_admin_bar_notif_updates() {
447
+ return $this->_plugin->GetGlobalSetting( 'admin-bar-notif-updates', 'page-refresh' );
448
  }
449
 
450
  /**
455
  * @param string $newvalue - New option value.
456
  */
457
  public function set_admin_bar_notif_updates( $newvalue ) {
458
+ $this->_plugin->SetGlobalSetting( 'admin-bar-notif-updates', $newvalue );
459
  }
460
 
461
  /**
464
  * @return boolean
465
  */
466
  public function IsRefreshAlertsEnabled() {
467
+ return ! $this->_plugin->GetGlobalSetting( 'disable-refresh' );
468
  }
469
 
470
  /**
473
  * @param boolean $newvalue - True if enabled.
474
  */
475
  public function SetRefreshAlertsEnabled( $newvalue ) {
476
+ $this->_plugin->SetGlobalSetting( 'disable-refresh', ! $newvalue );
477
  }
478
 
479
  /**
510
  */
511
  public function GetPruningDate() {
512
  if ( ! $this->_pruning ) {
513
+ $this->_pruning = $this->_plugin->GetGlobalSetting( 'pruning-date' );
514
  if ( ! strtotime( $this->_pruning ) ) {
515
  $this->_pruning = $this->GetDefaultPruningDate();
516
  }
525
  */
526
  public function SetPruningDate( $newvalue ) {
527
  if ( strtotime( $newvalue ) ) {
528
+ $this->_plugin->SetGlobalSetting( 'pruning-date', $newvalue );
529
  $this->_pruning = $newvalue;
530
  }
531
  }
536
  * @return string
537
  */
538
  public function get_pruning_unit() {
539
+ return $this->_plugin->GetGlobalSetting( 'pruning-unit', 'months' );
540
  }
541
 
542
  /**
545
  * @param string $newvalue – New value of pruning unit.
546
  */
547
  public function set_pruning_unit( $newvalue ) {
548
+ $this->_plugin->SetGlobalSetting( 'pruning-unit', $newvalue );
549
  }
550
 
551
  /**
554
  * @return integer
555
  */
556
  public function GetPruningLimit() {
557
+ $val = (int) $this->_plugin->GetGlobalSetting( 'pruning-limit' );
558
  return $val ? $val : $this->GetMaxAllowedAlerts();
559
  }
560
 
565
  */
566
  public function SetPruningLimit( $newvalue ) {
567
  $newvalue = max( /*min(*/ (int) $newvalue/*, $this->GetMaxAllowedAlerts())*/, 1 );
568
+ $this->_plugin->SetGlobalSetting( 'pruning-limit', $newvalue );
569
  }
570
 
571
  public function SetPruningDateEnabled( $enabled ) {
572
+ $this->_plugin->SetGlobalBooleanSetting( 'pruning-date-e', $enabled );
573
  }
574
 
575
  public function SetPruningLimitEnabled( $enabled ) {
576
+ $this->_plugin->SetGlobalBooleanSetting( 'pruning-limit-e', $enabled );
577
  }
578
 
579
  public function IsPruningDateEnabled() {
580
+ return $this->_plugin->GetGlobalBooleanSetting( 'pruning-date-e' );
581
  }
582
 
583
  public function IsPruningLimitEnabled() {
584
+ return $this->_plugin->GetGlobalBooleanSetting( 'pruning-limit-e' );
 
 
 
 
585
  }
586
 
587
  /**
593
  return esc_html__( 'This function is deprecated', 'wp-security-audit-log' );
594
  }
595
 
 
 
 
 
596
  /**
597
  * Method: Set Login Page Notification.
598
  *
599
  * @param bool $enable - Enable/Disable.
600
  */
601
  public function set_login_page_notification( $enable ) {
602
+ $this->_plugin->SetGlobalBooleanSetting( 'login_page_notification', $enable );
603
  }
604
 
605
  /**
608
  * @return bool - True if set, false if not.
609
  */
610
  public function is_login_page_notification() {
611
+ return $this->_plugin->GetGlobalBooleanSetting( 'login_page_notification', false );
612
  }
613
 
614
  /**
618
  */
619
  public function set_login_page_notification_text( $text ) {
620
  $text = wp_kses( $text, $this->_plugin->allowed_html_tags );
621
+ $this->_plugin->SetGlobalSetting( 'login_page_notification_text', $text );
622
  }
623
 
624
  /**
627
  * @return string|bool - Text if set, false if not.
628
  */
629
  public function get_login_page_notification_text() {
630
+ return $this->_plugin->GetGlobalSetting( 'login_page_notification_text', false );
631
  }
632
 
633
  public function GetDefaultDisabledAlerts() {
642
  public function GetDisabledAlerts() {
643
  if ( ! $this->_disabled ) {
644
  $this->_disabled = implode( ',', $this->GetDefaultDisabledAlerts() );
645
+ $this->_disabled = $this->_plugin->GetGlobalSetting( 'disabled-alerts', $this->_disabled );
646
  $this->_disabled = ( '' == $this->_disabled ) ? array() : explode( ',', $this->_disabled );
647
  $this->_disabled = array_map( 'intval', $this->_disabled );
648
  }
656
  */
657
  public function SetDisabledAlerts( $types ) {
658
  $this->_disabled = array_unique( array_map( 'intval', $types ) );
659
+ $this->_plugin->SetGlobalSetting( 'disabled-alerts', implode( ',', $this->_disabled ) );
660
  }
661
 
662
+ /**
663
+ * @return bool
664
+ */
665
  public function IsIncognito() {
666
+ return $this->_plugin->GetGlobalBooleanSetting( 'hide-plugin' );
667
  }
668
 
669
+ /**
670
+ * @param bool $enabled
671
+ */
672
  public function SetIncognito( $enabled ) {
673
+ $this->_plugin->SetGlobalBooleanSetting( 'hide-plugin', $enabled );
674
  }
675
 
676
  /**
677
  * Checking if the data will be removed.
678
  */
679
  public function IsDeleteData() {
680
+ return $this->_plugin->GetGlobalBooleanSetting( 'delete-data' );
681
  }
682
 
683
  public function SetDeleteData( $enabled ) {
684
+ $this->_plugin->SetGlobalBooleanSetting( 'delete-data', $enabled );
685
  }
686
 
687
  /**
691
  */
692
  public function SetAllowedPluginViewers( $users_or_roles ) {
693
  $this->_viewers = $users_or_roles;
694
+ $this->_plugin->SetGlobalSetting( 'plugin-viewers', implode( ',', $this->_viewers ) );
695
  }
696
 
697
  /**
699
  */
700
  public function GetAllowedPluginViewers() {
701
  if ( is_null( $this->_viewers ) ) {
702
+ $this->_viewers = array_unique( array_filter( explode( ',', $this->_plugin->GetGlobalSetting( 'plugin-viewers' ) ) ) );
703
  }
704
  return $this->_viewers;
705
  }
706
 
707
  /**
708
+ * Set restrict plugin setting.
709
  *
710
+ * @param string $settingSetting.
711
+ * @since 3.2.3
712
  */
713
+ public function set_restrict_plugin_setting( $setting ) {
714
+ $this->_plugin->SetGlobalSetting( 'restrict-plugin-settings', $setting );
 
715
  }
716
 
717
  /**
718
+ * Get restrict plugin setting.
719
+ *
720
+ * @since 3.2.3
721
  */
722
+ public function get_restrict_plugin_setting() {
723
+ return $this->_plugin->GetGlobalSetting( 'restrict-plugin-settings', 'only_admins' );
 
 
 
724
  }
725
 
726
  /**
727
+ * Get restriction setting for viewing the log viewer in multisite context.
728
  *
729
+ * @since 4.1.3
 
730
  */
731
+ public function get_restrict_log_viewer() {
732
+ return $this->_plugin->GetGlobalSetting( 'restrict-log-viewer', 'only_admins' );
733
  }
734
 
735
  /**
736
+ * Set restriction setting for viewing the log viewer in multisite context.
737
  *
738
+ * @param string $setting – Setting.
739
+ * @since 4.1.3
740
  */
741
+ public function set_restrict_log_viewer( $setting ) {
742
+ $this->_plugin->SetGlobalSetting( 'restrict-log-viewer', $setting );
 
 
 
 
743
  }
744
 
745
  public function SetViewPerPage( $newvalue ) {
746
  $this->_perpage = max( $newvalue, 1 );
747
+ $this->_plugin->SetGlobalSetting( 'items-per-page', $this->_perpage );
748
  }
749
 
750
  public function GetViewPerPage() {
751
  if ( is_null( $this->_perpage ) ) {
752
+ $this->_perpage = (int) $this->_plugin->GetGlobalSetting( 'items-per-page', 10 );
753
  }
754
  return $this->_perpage;
755
  }
809
  }
810
 
811
  /**
812
+ * Check if user can perform an action.
813
  *
814
+ * @param integer|WP_user $user - User object to check.
815
+ * @param string $action - Type of action, either 'view' or 'edit'.
816
+ * @return boolean If user has access or not.
817
  */
818
+ public function UserCan( $user, $action ) {
819
+ if ( is_int( $user ) ) {
820
+ $user = get_userdata( $user );
821
+ }
822
+
823
+ // by default the user has no privileges
824
+ $result = false;
825
+
826
+ $is_multisite = $this->_plugin->IsMultisite();
827
  switch ( $action ) {
828
  case 'view':
829
+ if ( !$is_multisite ) {
830
+ // non-multisite piggybacks on the plugin settings access
831
+ switch ( $this->get_restrict_plugin_setting() ) {
832
+ case 'only_admins':
833
+ // allow access only if the user is and admin
834
+ $result = in_array('administrator', $user->roles);
835
+ break;
836
+ case 'only_me':
837
+ // allow access only if the user matches the only user allowed access
838
+ $result = $user->ID == $this->get_only_me_user_id();
839
+ break;
840
+ default:
841
+ // no other options to allow access here
842
+ $result = false;
843
+ }
844
+ } else {
845
+ // multisite MUST respect the log viewer restriction settings plus also additional users and roles
846
+ // defined in the extra option
847
+ switch ( $this->get_restrict_log_viewer() ) {
848
+ case 'only_me':
849
+ // allow access only if the user matches the only user allowed access
850
+ $result = ( $user->ID == $this->get_only_me_user_id() );
851
+ break;
852
+ case 'only_superadmins':
853
+ // allow access only for super admins
854
+ if ( function_exists( 'is_super_admin' ) && is_super_admin($user->ID) ) {
855
+ $result = true;
856
+ }
857
+ break;
858
+ case 'only_admins':
859
+ // allow access only for super admins and admins
860
+ $result = in_array('administrator', $user->roles) || ( function_exists( 'is_super_admin' ) && is_super_admin($user->ID) );
861
+ break;
862
+ }
863
+ }
864
+
865
+ if (!$result) {
866
+ // user is still not allowed to view the logs, let's check the additional users and roles
867
+ // settings
868
+ $extra_viewers = $this->GetAllowedPluginViewers();
869
+ if (in_array($user->user_login, $extra_viewers )) {
870
+ $result = true;
871
+ } elseif (!empty(array_intersect($extra_viewers, $user->roles))) {
872
+ $result = true;
873
  }
874
  }
875
  break;
876
  case 'edit':
877
+ if ( $is_multisite ) {
878
+ // no one has access to settings on sub site inside a network
879
+ if ( wp_doing_ajax() ) {
880
+ // AJAX calls are an exception
881
+ $result = true;
882
+ } else if ( ! is_network_admin() ) {
883
+ $result = false;
884
+ break;
885
+ }
886
+ }
887
+
888
+ $restrict_plugin_setting = $this->get_restrict_plugin_setting();
889
+ if ( 'only_me' === $restrict_plugin_setting ) {
890
+ $result = ( $user->ID == $this->get_only_me_user_id());
891
+ } elseif ( 'only_admins' === $restrict_plugin_setting ) {
892
+ if ($is_multisite) {
893
+ $result = ( function_exists( 'is_super_admin' ) && is_super_admin($user->ID) );
894
+ } else {
895
+ $result = in_array('administrator', $user->roles);
896
+ }
897
  }
898
  break;
899
  default:
900
+ $result = false;
 
 
 
 
 
 
 
901
  }
 
 
902
 
903
+ /**
904
+ * Filters the user permissions result.
905
+ *
906
+ * @since 4.1.3
907
+ *
908
+ * @param bool $result User access flag after applying all internal rules.
909
+ * @param WP_User $user The user in question.
910
+ * @param string $action Action to check permissions for.
911
+ * @return bool
912
+ */
913
+ return apply_filters('wsal_user_can', $result, $user, $action);
 
 
 
 
 
 
 
 
914
  }
915
 
916
  public function GetCurrentUserRoles( $base_roles = null ) {
929
  }
930
 
931
  public function IsMainIPFromProxy() {
932
+ return $this->_plugin->GetGlobalBooleanSetting( 'use-proxy-ip' );
933
  }
934
 
935
  public function SetMainIPFromProxy( $enabled ) {
936
+ $this->_plugin->SetGlobalBooleanSetting( 'use-proxy-ip', $enabled );
937
  }
938
 
939
  public function IsInternalIPsFiltered() {
940
+ return $this->_plugin->GetGlobalSetting( 'filter-internal-ip' );
941
  }
942
 
943
  public function SetInternalIPsFiltering( $enabled ) {
944
+ $this->_plugin->SetGlobalSetting( 'filter-internal-ip', $enabled );
945
  }
946
 
947
  /**
1051
  */
1052
  public function SetExcludedMonitoringUsers( $users ) {
1053
  $this->_excluded_users = $users;
1054
+ $this->_plugin->SetGlobalSetting( 'excluded-users', esc_html( implode( ',', $this->_excluded_users ) ) );
1055
  }
1056
 
1057
  public function GetExcludedMonitoringUsers() {
1058
  if ( empty( $this->_excluded_users ) ) {
1059
+ $this->_excluded_users = array_unique( array_filter( explode( ',', $this->_plugin->GetGlobalSetting( 'excluded-users' ) ) ) );
1060
  }
1061
  return $this->_excluded_users;
1062
  }
1069
  */
1070
  public function set_excluded_post_types( $post_types ) {
1071
  $this->_post_types = $post_types;
1072
+ $this->_plugin->SetGlobalSetting( 'custom-post-types', esc_html( implode( ',', $this->_post_types ) ) );
1073
  }
1074
 
1075
  /**
1079
  */
1080
  public function get_excluded_post_types() {
1081
  if ( empty( $this->_post_types ) ) {
1082
+ $this->_post_types = array_unique( array_filter( explode( ',', $this->_plugin->GetGlobalSetting( 'custom-post-types' ) ) ) );
1083
  }
1084
  return $this->_post_types;
1085
  }
1094
  $urls = array_map( 'untrailingslashit', $urls );
1095
  $urls = array_unique( $urls );
1096
  $this->excluded_urls = $urls;
1097
+ $this->_plugin->SetGlobalSetting( 'excluded-urls', esc_html( implode( ',', $this->excluded_urls ) ) );
1098
  }
1099
 
1100
  /**
1104
  */
1105
  public function get_excluded_urls() {
1106
  if ( empty( $this->excluded_urls ) ) {
1107
+ $this->excluded_urls = array_unique( array_filter( explode( ',', $this->_plugin->GetGlobalSetting( 'excluded-urls' ) ) ) );
1108
  }
1109
  return $this->excluded_urls;
1110
  }
1116
  */
1117
  public function SetExcludedMonitoringRoles( $roles ) {
1118
  $this->_excluded_roles = $roles;
1119
+ $this->_plugin->SetGlobalSetting( 'excluded-roles', esc_html( implode( ',', $this->_excluded_roles ) ) );
1120
  }
1121
 
1122
  /**
1124
  */
1125
  public function GetExcludedMonitoringRoles() {
1126
  if ( empty( $this->_excluded_roles ) ) {
1127
+ $this->_excluded_roles = array_unique( array_filter( explode( ',', $this->_plugin->GetGlobalSetting( 'excluded-roles' ) ) ) );
1128
  }
1129
  return $this->_excluded_roles;
1130
  }
1134
  */
1135
  public function SetExcludedMonitoringCustom( $custom ) {
1136
  $this->_excluded_custom = $custom;
1137
+ $this->_plugin->SetGlobalSetting( 'excluded-custom', esc_html( implode( ',', $this->_excluded_custom ) ) );
1138
  }
1139
 
1140
  public function GetExcludedMonitoringCustom() {
1141
  if ( empty( $this->_excluded_custom ) ) {
1142
+ $this->_excluded_custom = array_unique( array_filter( explode( ',', $this->_plugin->GetGlobalSetting( 'excluded-custom' ) ) ) );
1143
  asort( $this->_excluded_custom );
1144
  }
1145
  return $this->_excluded_custom;
1150
  */
1151
  public function SetExcludedMonitoringIP( $ip ) {
1152
  $this->_excluded_ip = $ip;
1153
+ $this->_plugin->SetGlobalSetting( 'excluded-ip', esc_html( implode( ',', $this->_excluded_ip ) ) );
1154
  }
1155
 
1156
  public function GetExcludedMonitoringIP() {
1157
  if ( empty( $this->_excluded_ip ) ) {
1158
+ $this->_excluded_ip = array_unique( array_filter( explode( ',', $this->_plugin->GetGlobalSetting( 'excluded-ip' ) ) ) );
1159
  }
1160
  return $this->_excluded_ip;
1161
  }
1224
  * Server's timezone or WordPress' timezone.
1225
  */
1226
  public function GetTimezone() {
1227
+ return $this->_plugin->GetGlobalSetting( 'timezone', 'wp' );
1228
  }
1229
 
1230
  public function SetTimezone( $newvalue ) {
1231
+ $this->_plugin->SetGlobalSetting( 'timezone', $newvalue );
1232
  }
1233
 
1234
  /**
1240
  * @return bool
1241
  */
1242
  public function get_show_milliseconds() {
1243
+ return $this->_plugin->GetGlobalBooleanSetting( 'show_milliseconds', true );
1244
  }
1245
 
1246
  /**
1253
  * @param mixed $newvalue ideally always bool. If not bool then it's cast to true.
1254
  */
1255
  public function set_show_milliseconds( $newvalue ) {
1256
+ $this->_plugin->SetGlobalBooleanSetting( 'show_milliseconds', $newvalue );
 
1257
  }
1258
 
1259
 
1261
  * Get type of username to display.
1262
  */
1263
  public function get_type_username() {
1264
+ return $this->_plugin->GetGlobalSetting( 'type_username', 'display_name' );
1265
  }
1266
 
1267
  /**
1271
  * @since 2.6.5
1272
  */
1273
  public function set_type_username( $newvalue ) {
1274
+ $this->_plugin->SetGlobalSetting( 'type_username', $newvalue );
1275
  }
1276
 
1277
  public function GetAdapterConfig( $name_field, $default_value = false ) {
1278
+ return $this->_plugin->GetGlobalSetting( $name_field, $default_value );
1279
  }
1280
 
1281
  public function SetAdapterConfig( $name_field, $newvalue ) {
1282
+ $this->_plugin->SetGlobalSetting( $name_field, trim( $newvalue ) );
1283
  }
1284
 
1285
  /**
1332
  }
1333
 
1334
  public function GetColumnsSelected() {
1335
+ return $this->_plugin->GetGlobalSetting( 'columns', array() );
1336
  }
1337
 
1338
  public function SetColumns( $columns ) {
1339
+ $this->_plugin->SetGlobalSetting( 'columns', json_encode( $columns ) );
1340
  }
1341
 
1342
  public function IsWPBackend() {
1343
+ return $this->_plugin->GetGlobalBooleanSetting( 'wp-backend' );
1344
  }
1345
 
1346
  public function SetWPBackend( $enabled ) {
1347
+ $this->_plugin->SetGlobalBooleanSetting( 'wp-backend', $enabled );
1348
  }
1349
 
1350
  /**
1353
  * @param string $use – Setting value.
1354
  */
1355
  public function set_use_email( $use ) {
1356
+ $this->_plugin->SetGlobalSetting( 'use-email', $use );
1357
  }
1358
 
1359
  /**
1362
  * @return string
1363
  */
1364
  public function get_use_email() {
1365
+ return $this->_plugin->GetGlobalSetting( 'use-email', 'default_email' );
1366
  }
1367
 
1368
  public function SetFromEmail( $email_address ) {
1369
+ $this->_plugin->SetGlobalSetting( 'from-email', trim( $email_address ) );
1370
  }
1371
 
1372
  public function GetFromEmail() {
1373
+ return $this->_plugin->GetGlobalSetting( 'from-email' );
1374
  }
1375
 
1376
  public function SetDisplayName( $display_name ) {
1377
+ $this->_plugin->SetGlobalSetting( 'display-name', trim( $display_name ) );
1378
  }
1379
 
1380
  public function GetDisplayName() {
1381
+ return $this->_plugin->GetGlobalSetting( 'display-name' );
1382
  }
1383
 
1384
  public function Set404LogLimit( $value ) {
1385
+ $this->_plugin->SetGlobalSetting( 'log-404-limit', abs( $value ) );
1386
  }
1387
 
1388
  public function Get404LogLimit() {
1389
+ return $this->_plugin->GetGlobalSetting( 'log-404-limit', 99 );
1390
  }
1391
 
1392
  /**
1396
  * @since 2.6.3
1397
  */
1398
  public function SetVisitor404LogLimit( $value ) {
1399
+ $this->_plugin->SetGlobalSetting( 'log-visitor-404-limit', abs( $value ) );
1400
  }
1401
 
1402
  /**
1405
  * @since 2.6.3
1406
  */
1407
  public function GetVisitor404LogLimit() {
1408
+ return $this->_plugin->GetGlobalSetting( 'log-visitor-404-limit', 99 );
1409
  }
1410
 
1411
  /**
1416
  */
1417
  public function set_failed_login_limit( $value ) {
1418
  if ( ! empty( $value ) ) {
1419
+ $this->_plugin->SetGlobalSetting( 'log-failed-login-limit', abs( $value ) );
1420
  } else {
1421
+ $this->_plugin->SetGlobalSetting( 'log-failed-login-limit', -1 );
1422
  }
1423
  }
1424
 
1428
  * @since 2.6.3
1429
  */
1430
  public function get_failed_login_limit() {
1431
+ return $this->_plugin->GetGlobalSetting( 'log-failed-login-limit', 10 );
1432
  }
1433
 
1434
  /**
1439
  */
1440
  public function set_visitor_failed_login_limit( $value ) {
1441
  if ( ! empty( $value ) ) {
1442
+ $this->_plugin->SetGlobalSetting( 'log-visitor-failed-login-limit', abs( $value ) );
1443
  } else {
1444
+ $this->_plugin->SetGlobalSetting( 'log-visitor-failed-login-limit', -1 );
1445
  }
1446
  }
1447
 
1451
  * @since 2.6.3
1452
  */
1453
  public function get_visitor_failed_login_limit() {
1454
+ return $this->_plugin->GetGlobalSetting( 'log-visitor-failed-login-limit', 10 );
1455
  }
1456
 
1457
  public function IsArchivingEnabled() {
1458
+ return $this->_plugin->GetGlobalSetting( 'archiving-e' );
1459
  }
1460
 
1461
  /**
1463
  */
1464
  public function SwitchToArchiveDB() {
1465
  if ( $this->IsArchivingEnabled() ) {
1466
+ $archive_type = $this->_plugin->GetGlobalSetting( 'archive-type' );
1467
+ $archive_user = $this->_plugin->GetGlobalSetting( 'archive-user' );
1468
+ $password = $this->_plugin->GetGlobalSetting( 'archive-password' );
1469
+ $archive_name = $this->_plugin->GetGlobalSetting( 'archive-name' );
1470
+ $archive_hostname = $this->_plugin->GetGlobalSetting( 'archive-hostname' );
1471
+ $archive_baseprefix = $this->_plugin->GetGlobalSetting( 'archive-base-prefix' );
1472
+ $archive_ssl = $this->_plugin->GetGlobalSetting( 'archive-ssl', false );
1473
+ $archive_cc = $this->_plugin->GetGlobalSetting( 'archive-client-certificate', false );
1474
+ $archive_ssl_ca = $this->_plugin->GetGlobalSetting( 'archive-ssl-ca', false );
1475
+ $archive_ssl_cert = $this->_plugin->GetGlobalSetting( 'archive-ssl-cert', false );
1476
+ $archive_ssl_key = $this->_plugin->GetGlobalSetting( 'archive-ssl-key', false );
1477
  $config = WSAL_Connector_ConnectorFactory::GetConfigArray( $archive_type, $archive_user, $password, $archive_name, $archive_hostname, $archive_baseprefix, $archive_ssl, $archive_cc, $archive_ssl_ca, $archive_ssl_cert, $archive_ssl_key );
1478
  $this->_plugin->getConnector( $config )->getAdapter( 'Occurrence' );
1479
  }
1480
  }
1481
 
1482
  /**
1483
+ * Generate index.php file for each sub-directory present in the plugin working directory.
 
1484
  *
1485
  * @since 3.1.2
1486
  */
1487
  public function generate_index_files() {
1488
+ // get plugin working directory.
1489
+ $wsal_working_dir = $this->get_working_dir_path();
 
1490
 
1491
  // If the directory exists then generate index.php file for every sub-directory.
1492
+ if ( ! empty( $wsal_working_dir ) && is_dir( $wsal_working_dir ) ) {
1493
  // Generate index.php for the main directory.
1494
+ if ( ! file_exists( $wsal_working_dir . DIRECTORY_SEPARATOR . 'index.php' ) ) {
1495
  // Generate index.php file.
1496
+ $this->create_index_file( $wsal_working_dir );
1497
  }
1498
 
1499
  // Generate .htaccess for the main directory.
1500
+ if ( ! file_exists( $wsal_working_dir . DIRECTORY_SEPARATOR . '.htaccess' ) ) {
1501
  // Generate .htaccess file.
1502
+ $this->create_htaccess_file( $wsal_working_dir );
1503
  }
1504
 
1505
  // Fetch all files in the uploads directory.
1506
+ $sub_directories = glob( $wsal_working_dir . '*' );
1507
  foreach ( $sub_directories as $sub_dir ) {
1508
  // index.php file.
1509
+ if ( is_dir( $sub_dir ) && ! file_exists( $sub_dir . DIRECTORY_SEPARATOR . 'index.php' ) ) {
1510
  // Generate index.php file.
1511
  $this->create_index_file( $sub_dir . '/' );
1512
  }
1513
 
1514
  // .htaccess file.
1515
+ if ( is_dir( $sub_dir ) && ! file_exists( $sub_dir . DIRECTORY_SEPARATOR . '.htaccess' ) ) {
 
 
 
 
 
 
1516
  // Generate .htaccess file.
1517
+ $this->create_htaccess_file( $sub_dir . DIRECTORY_SEPARATOR );
1518
  }
1519
  }
1520
  }
1640
  */
1641
  public function set_mainwp_child_stealth_mode() {
1642
  if (
1643
+ ! $this->_plugin->GetGlobalBooleanSetting( 'mwp-child-stealth-mode', false ) // MainWP Child Stealth Mode is not already active.
1644
  && WpSecurityAuditLog::is_mainwp_active() // And if MainWP Child plugin is installed & active.
1645
  ) {
1646
  // Check if freemius state is anonymous.
1647
+ if ( ! wsal_freemius()->is_premium() && 'anonymous' === $this->_plugin->GetGlobalSetting( 'freemius_state', 'anonymous' ) ) {
1648
  // Update freemius state to skipped.
1649
+ $this->_plugin->SetGlobalSetting( 'wsal_freemius_state', 'skipped' );
1650
 
1651
  if ( ! $this->_plugin->IsMultisite() ) {
1652
  wsal_freemius()->skip_connection(); // Opt out.
1663
  FS_Admin_Notices::instance( 'wp-security-audit-log' )->remove_sticky( 'trial_promotion' );
1664
  }
1665
 
1666
+ $this->SetIncognito( true ); // Incognito mode to hide WSAL on plugins page.
1667
+ $this->set_restrict_log_viewer('only_me');
1668
+ $this->set_restrict_plugin_setting('only_me');
1669
+ // current user with fallback to default admin (in case this is triggered using WP CLI or something similar)
1670
+ $only_me_user_id = is_user_logged_in() ? get_current_user_id() : 1;
1671
+ $this->set_only_me_user_id($only_me_user_id);
1672
+ $this->_plugin->SetGlobalBooleanSetting( 'mwp-child-stealth-mode', true ); // Save stealth mode option.
1673
  }
1674
  }
1675
 
1679
  * @since 3.2.3.3
1680
  */
1681
  public function deactivate_mainwp_child_stealth_mode() {
1682
+ $this->SetIncognito( false ); // Disable incognito mode to hide WSAL on plugins page.
1683
+ $this->set_restrict_plugin_setting('only_admins');
1684
+ $this->set_restrict_log_viewer('only_admins');
1685
+ $this->set_admin_blocking_plugin_support(false);
1686
+ $this->_plugin->SetGlobalBooleanSetting( 'mwp-child-stealth-mode', false ); // Disable stealth mode option.
1687
  }
1688
 
1689
  /**
1696
  return;
1697
  }
1698
 
1699
+ if ( $this->_plugin->GetGlobalBooleanSetting( 'mwp-child-stealth-mode', false ) ) {
1700
  $this->deactivate_mainwp_child_stealth_mode();
1701
  }
1702
  }
1707
  * @return boolean
1708
  */
1709
  public function is_stealth_mode() {
1710
+ return $this->_plugin->GetGlobalBooleanSetting( 'mwp-child-stealth-mode', false );
 
1711
  }
1712
 
1713
  /**
1714
+ * Method: Meta data formatter.
1715
+ *
1716
+ * @param string $name - Name of the data.
1717
+ * @param mixed $value - Value of the data.
1718
+ * @param integer $occ_id - Event occurrence ID.
1719
+ * @param mixed $highlight - Highlight format.
1720
  *
 
 
 
 
1721
  * @return string
1722
+ * @throws Freemius_Exception
1723
  */
1724
  public function meta_formatter( $name, $value, $occ_id, $highlight ) {
1725
  if ( $highlight && 'daily-report' === $highlight ) {
1754
  }
1755
  return false;
1756
 
1757
+ case in_array( $name, array( '%EditorLinkPost%', '%EditorLinkPage%' ) ):
1758
  return '<a target="_blank" href="' . esc_url( $value ) . '">' . __( 'View post in the editor', 'wp-security-audit-log' ) . '</a>';
1759
 
1760
  case '%EditorLinkOrder%' == $name:
1761
  return '<a target="_blank" href="' . esc_url( $value ) . '">' . __( 'View Order', 'wp-security-audit-log' ) . '</a>';
1762
 
 
 
 
1763
  case '%CategoryLink%' == $name:
1764
  case '%cat_link%' == $name:
1765
  case '%ProductCatLink%' == $name:
1780
  ) . $highlight_end_tag;
1781
 
1782
  case '%ClientIP%' == $name:
1783
+ case '%IPAddress%' == $name:
1784
  if ( is_string( $value ) ) {
1785
  return $highlight_start_tag . str_replace( array( '"', '[', ']' ), '', $value ) . $highlight_end_tag;
1786
  } else {
1995
  }
1996
 
1997
  /**
1998
+ * Method: Meta data formatter.
1999
  *
2000
  * @since 3.3
2001
  *
2032
  case '%EditorLinkOrder%' === $name:
2033
  return ' <' . esc_url( $value ) . '|View Order>';
2034
 
 
 
 
2035
  case '%CategoryLink%' === $name:
2036
  case '%cat_link%' === $name:
2037
  case '%ProductCatLink%' == $name:
2160
  * @return string
2161
  */
2162
  public function get_events_type_nav() {
2163
+ return $this->_plugin->GetGlobalSetting( 'events-nav-type', 'infinite-scroll' );
2164
  }
2165
 
2166
  /**
2174
  * @return string
2175
  */
2176
  public function set_events_type_nav( $nav_type ) {
2177
+ $this->_plugin->SetGlobalSetting( 'events-nav-type', $nav_type );
2178
  }
2179
 
2180
  /**
2409
  *
2410
  * @return array
2411
  */
2412
+ public static function get_frontend_events() {
2413
  // Option defaults.
2414
  $default = array(
2415
  'register' => false,
2419
  );
2420
 
2421
  // Get the option.
2422
+ $value = \WSAL\Helpers\Options::get_option_value_ignore_prefix( self::FRONT_END_EVENTS_OPTION_NAME, $default );
 
2423
 
2424
  // Check for WooCommerce in case it is not stored.
2425
  $value['woocommerce'] = ! isset( $value['woocommerce'] ) ? WpSecurityAuditLog::is_woocommerce_active() : $value['woocommerce'];
2433
  * @return bool
2434
  */
2435
  public function set_frontend_events( $value = array() ) {
2436
+ return \WSAL\Helpers\Options::set_option_value_ignore_prefix( self::FRONT_END_EVENTS_OPTION_NAME, $value);
 
2437
  }
2438
+
2439
+ /**
2440
+ * Stores the ID of user who restricted the plugin settings access to "only me".
2441
+ *
2442
+ * @param int $user_id
2443
+ * @since 4.1.3
2444
+ */
2445
+ public function set_only_me_user_id( $user_id ) {
2446
+ $this->_plugin->SetGlobalSetting( 'only-me-user-id', $user_id );
2447
+ }
2448
+
2449
+ /**
2450
+ * Stores the ID of user who restricted the plugin settings access to "only me".
2451
+ *
2452
+ * @return int
2453
+ * @since 4.1.3
2454
+ */
2455
+ public function get_only_me_user_id() {
2456
+ return $this->_plugin->GetGlobalSetting( 'only-me-user-id' );
2457
+ }
2458
+
2459
+ /**
2460
+ * Save admin blocking plugin support enabled.
2461
+ *
2462
+ * @param bool $enabled
2463
+ */
2464
+ public function set_admin_blocking_plugin_support( $enabled ) {
2465
+ $this->_plugin->SetGlobalBooleanSetting( 'admin-blocking-plugins-support', $enabled );
2466
+ }
2467
+
2468
+ /**
2469
+ * Check if admin blocking plugin support is enabled.
2470
+ *
2471
+ * Note: this is purely for retrieving the option value. It is actually used in conjunction with
2472
+ * stealth mode setting and some other exceptions.
2473
+ *
2474
+ * @see WpSecurityAuditLog::is_admin_blocking_plugins_support_enabled()
2475
+ * @return bool
2476
+ */
2477
+ public function get_admin_blocking_plugin_support() {
2478
+ return $this->_plugin->GetGlobalBooleanSetting( 'admin-blocking-plugins-support', false );
2479
+ }
2480
+
2481
  }
classes/Uninstall.php CHANGED
@@ -27,10 +27,27 @@ class WSAL_Uninstall {
27
  self::drop_table( 'metadata' );
28
  }
29
 
 
 
 
 
 
30
  // Clear scheduled hooks.
31
  wp_clear_scheduled_hook( 'wsal_cleanup' );
32
  }
33
 
 
 
 
 
 
 
 
 
 
 
 
 
34
  /**
35
  * Returns the name of the WSAL table.
36
  *
27
  self::drop_table( 'metadata' );
28
  }
29
 
30
+ // Check if we have set things to delete upon uninstall.
31
+ if ( 'yes' === get_option( 'wsal_delete-data' ) ) {
32
+ self::delete_options_from_wp_options();
33
+ }
34
+
35
  // Clear scheduled hooks.
36
  wp_clear_scheduled_hook( 'wsal_cleanup' );
37
  }
38
 
39
+ /**
40
+ * Delete wsal options from wp_options table.
41
+ */
42
+ private static function delete_options_from_wp_options() {
43
+ global $wpdb;
44
+ $plugin_options = $wpdb->get_results( "SELECT option_name FROM $wpdb->options WHERE option_name LIKE 'wsal_%'" );
45
+
46
+ foreach( $plugin_options as $option ) {
47
+ delete_option( $option->option_name );
48
+ }
49
+ }
50
+
51
  /**
52
  * Returns the name of the WSAL table.
53
  *
classes/Update/Task/MoveSettingsToOptionsTable.php CHANGED
@@ -16,7 +16,7 @@ namespace WSAL\Update\Task;
16
  * Remaps remaps old cron names to new ones and schedules them at the same
17
  * time as the original was scheduled.
18
  */
19
- class MoveSettingsToOptionstable {
20
 
21
  /**
22
  * Holds the main plugin instance to work on.
@@ -50,24 +50,27 @@ class MoveSettingsToOptionstable {
50
  * Sets up the class properties.
51
  *
52
  * @method __construct
 
 
 
53
  * @since 4.0.3
54
- * @param \WpSecurityAuditLog $wsal An instance of the main plugin.
55
- * @param string $prefix The prefix string to prepend to options.
56
  */
57
  public function __construct( $wsal, $prefix = '' ) {
58
  $this->wsal = $wsal;
59
  $this->prefix = $prefix;
60
  add_filter( 'wsal_update_move_settings', array( $this, 'settings_to_move_4_0_3' ) );
61
  add_filter( 'wsal_update_move_settings', array( $this, 'settings_to_move_4_0_1' ) );
 
62
  }
63
 
64
  /**
65
  * Passes in the version strings so we can decide what settings to move.
66
  *
67
  * @method pass_versions
 
 
 
68
  * @since 4.0.3
69
- * @param string $old_version The old version string.
70
- * @param string $new_version The new version string.
71
  */
72
  public function set_versions( $old_version = '', $new_version = '' ) {
73
  $this->old_version = $old_version;
@@ -77,7 +80,7 @@ class MoveSettingsToOptionstable {
77
  /**
78
  * Loop through an array of cron tasks and remap them if the name changed.
79
  *
80
- * NOTE: The expected data used in this is a single dimentional array with
81
  * option names.
82
  *
83
  * @method run
@@ -102,21 +105,25 @@ class MoveSettingsToOptionstable {
102
  if ( false !== ( 'wsal-' === substr( $setting, 0, 5 ) ) ) {
103
  $setting = str_replace( 'wsal-', '', $setting );
104
  }
105
- $value = $this->wsal->options_helper->get_option_value( $setting );
106
  // to prevent override of already migrated data we will first check
107
  // if option value exists in the standard options table.
108
- if ( null !== $value ) {
109
- // skip to next item as this already exists in options table.
110
- continue;
111
- }
112
 
113
- // no options value existed in the default table, check in the
114
- // plugins custom table.
115
- $value = $this->wsal->GetGlobalOption( $setting );
116
- if ( $value ) {
117
- // if we got data from the custom table save it.
118
- $this->wsal->options_helper->set_option_value( $setting, $value );
 
119
  }
 
 
 
 
 
120
  }
121
  }
122
 
@@ -126,9 +133,10 @@ class MoveSettingsToOptionstable {
126
  * NOTE: Should fire if coming from before 4.0.1 to 4.0.3 or later.
127
  *
128
  * @method settings_to_move_4_0_3
129
- * @since 4.0.3
130
- * @param array $settings An array of settings to move.
131
  * @return array
 
132
  */
133
  public function settings_to_move_4_0_3( $settings ) {
134
  if ( \version_compare( $this->old_version, '4.0.2', '>=' ) && \version_compare( $this->old_version, '4.0.3', '<' ) ) {
@@ -149,6 +157,7 @@ class MoveSettingsToOptionstable {
149
  )
150
  );
151
  }
 
152
  // Return an array of all the setting we are wanting moved.
153
  return $settings;
154
  }
@@ -159,12 +168,13 @@ class MoveSettingsToOptionstable {
159
  * NOTE: Should fire if coming from before 4.0.1 to 4.0.3 or later.
160
  *
161
  * @method settings_to_move_4_0_3
162
- * @since 4.1.0
163
- * @param array $settings An array of settings to move.
164
  * @return array
 
165
  */
166
  public function settings_to_move_4_0_1( $settings ) {
167
- if ( \version_compare( $this->old_version, '4.0.2', '>=' ) && \version_compare( $this->old_version, '4.1.0', '<' ) ) {
168
  // settings moved in this version update.
169
  $settings = array_merge(
170
  $settings,
@@ -183,8 +193,35 @@ class MoveSettingsToOptionstable {
183
  )
184
  );
185
  }
 
186
  // Return an array of all the setting we are wanting moved.
187
  return $settings;
188
  }
189
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
190
  }
16
  * Remaps remaps old cron names to new ones and schedules them at the same
17
  * time as the original was scheduled.
18
  */
19
+ class MoveSettingsToOptionsTable {
20
 
21
  /**
22
  * Holds the main plugin instance to work on.
50
  * Sets up the class properties.
51
  *
52
  * @method __construct
53
+ * @param \WpSecurityAuditLog $wsal An instance of the main plugin.
54
+ * @param string $prefix The prefix string to prepend to options.
55
+ *
56
  * @since 4.0.3
 
 
57
  */
58
  public function __construct( $wsal, $prefix = '' ) {
59
  $this->wsal = $wsal;
60
  $this->prefix = $prefix;
61
  add_filter( 'wsal_update_move_settings', array( $this, 'settings_to_move_4_0_3' ) );
62
  add_filter( 'wsal_update_move_settings', array( $this, 'settings_to_move_4_0_1' ) );
63
+ add_filter( 'wsal_update_move_settings', array( $this, 'settings_to_move_4_1_3' ) );
64
  }
65
 
66
  /**
67
  * Passes in the version strings so we can decide what settings to move.
68
  *
69
  * @method pass_versions
70
+ * @param string $old_version The old version string.
71
+ * @param string $new_version The new version string.
72
+ *
73
  * @since 4.0.3
 
 
74
  */
75
  public function set_versions( $old_version = '', $new_version = '' ) {
76
  $this->old_version = $old_version;
80
  /**
81
  * Loop through an array of cron tasks and remap them if the name changed.
82
  *
83
+ * NOTE: The expected data used in this is a single dimensional array with
84
  * option names.
85
  *
86
  * @method run
105
  if ( false !== ( 'wsal-' === substr( $setting, 0, 5 ) ) ) {
106
  $setting = str_replace( 'wsal-', '', $setting );
107
  }
108
+ $value = $this->wsal->GetGlobalSetting( $setting );
109
  // to prevent override of already migrated data we will first check
110
  // if option value exists in the standard options table.
111
+ if ( null === $value || false === $value ) {
112
+ // only continue with the current item if it doesn't exist already in the WP options table
 
 
113
 
114
+ // no options value existed in the default table, check in the
115
+ // plugins custom table.
116
+ $value = $this->wsal->GetGlobalOption( $setting );
117
+ if ( $value ) {
118
+ // if we got data from the custom table save it.
119
+ $this->wsal->SetGlobalSetting( $setting, $value );
120
+ }
121
  }
122
+
123
+ // delete the option from the custom table
124
+ $this->wsal->DeleteByName( $setting );
125
+ $this->wsal->DeleteByName( 'wsal-' . $setting );
126
+ $this->wsal->DeleteByName( 'wsal_' . $setting );
127
  }
128
  }
129
 
133
  * NOTE: Should fire if coming from before 4.0.1 to 4.0.3 or later.
134
  *
135
  * @method settings_to_move_4_0_3
136
+ * @param array $settings An array of settings to move.
137
+ *
138
  * @return array
139
+ * @since 4.0.3
140
  */
141
  public function settings_to_move_4_0_3( $settings ) {
142
  if ( \version_compare( $this->old_version, '4.0.2', '>=' ) && \version_compare( $this->old_version, '4.0.3', '<' ) ) {
157
  )
158
  );
159
  }
160
+
161
  // Return an array of all the setting we are wanting moved.
162
  return $settings;
163
  }
168
  * NOTE: Should fire if coming from before 4.0.1 to 4.0.3 or later.
169
  *
170
  * @method settings_to_move_4_0_3
171
+ * @param array $settings An array of settings to move.
172
+ *
173
  * @return array
174
+ * @since 4.1.0
175
  */
176
  public function settings_to_move_4_0_1( $settings ) {
177
+ if ( \version_compare( $this->old_version, '4.0.2', '>' ) && \version_compare( $this->old_version, '4.1.3', '<=' ) ) {
178
  // settings moved in this version update.
179
  $settings = array_merge(
180
  $settings,
193
  )
194
  );
195
  }
196
+
197
  // Return an array of all the setting we are wanting moved.
198
  return $settings;
199
  }
200
 
201
+ /**
202
+ * Filters in a list of settings to move in the 4.1.3 update.
203
+ *
204
+ * @param array $settings An array of settings to move.
205
+ *
206
+ * @return array
207
+ * @since 4.1.3
208
+ */
209
+ public function settings_to_move_4_1_3( $settings ) {
210
+ if ( \version_compare( $this->old_version, '4.1.3', '<=' ) ) {
211
+ $this->wsal->settings();
212
+ $options = new \WSAL_Models_Option();
213
+ $adapter = $options->getAdapter();
214
+ $all_options = $adapter->LoadArray('1=%d', array(1));
215
+ if (!empty($all_options)) {
216
+ /** @var \WSAL_Models_Option $option */
217
+ foreach ($all_options as $option) {
218
+ array_push($settings, preg_replace('/^wsal[\-_]/', '', $option->option_name));
219
+ }
220
+ }
221
+ }
222
+
223
+ // Return an array of all the setting we are wanting moved.
224
+ return array_unique($settings);
225
+ }
226
+
227
  }
classes/Utilities/Emailer.php CHANGED
@@ -28,9 +28,9 @@ class WSAL_Utilities_Emailer {
28
  $wsal = WpSecurityAuditLog::GetInstance();
29
  $home_url = home_url();
30
  $safe_url = str_replace( array( 'http://', 'https://' ), '', $home_url );
31
- $type_name = $wsal->settings->get_type_username(); // Get the data to display.
32
  $user = _wp_get_current_user();
33
- $datetime_format = $wsal->settings->GetDatetimeFormat( false );
34
  $date_time = str_replace(
35
  '$$$',
36
  substr( number_format( fmod( current_time( 'timestamp' ), 1 ), 3 ), 2 ),
@@ -148,8 +148,8 @@ class WSAL_Utilities_Emailer {
148
  */
149
  public static function custom_wp_mail_from( $original_email_from ) {
150
  $wsal = WpSecurityAuditLog::GetInstance();
151
- $use_email = $wsal->settings->get_use_email();
152
- $email_from = $wsal->settings->GetFromEmail();
153
  if ( ! empty( $email_from ) && 'custom_email' === $use_email ) {
154
  return $email_from;
155
  } else {
@@ -165,8 +165,8 @@ class WSAL_Utilities_Emailer {
165
  */
166
  public static function custom_wp_mail_from_name( $original_email_from_name ) {
167
  $wsal = WpSecurityAuditLog::GetInstance();
168
- $use_email = $wsal->settings->get_use_email();
169
- $email_from_name = $wsal->settings->GetDisplayName();
170
  if ( ! empty( $email_from_name ) && 'custom_email' === $use_email ) {
171
  return $email_from_name;
172
  } else {
28
  $wsal = WpSecurityAuditLog::GetInstance();
29
  $home_url = home_url();
30
  $safe_url = str_replace( array( 'http://', 'https://' ), '', $home_url );
31
+ $type_name = $wsal->settings()->get_type_username(); // Get the data to display.
32
  $user = _wp_get_current_user();
33
+ $datetime_format = $wsal->settings()->GetDatetimeFormat( false );
34
  $date_time = str_replace(
35
  '$$$',
36
  substr( number_format( fmod( current_time( 'timestamp' ), 1 ), 3 ), 2 ),
148
  */
149
  public static function custom_wp_mail_from( $original_email_from ) {
150
  $wsal = WpSecurityAuditLog::GetInstance();
151
+ $use_email = $wsal->settings()->get_use_email();
152
+ $email_from = $wsal->settings()->GetFromEmail();
153
  if ( ! empty( $email_from ) && 'custom_email' === $use_email ) {
154
  return $email_from;
155
  } else {
165
  */
166
  public static function custom_wp_mail_from_name( $original_email_from_name ) {
167
  $wsal = WpSecurityAuditLog::GetInstance();
168
+ $use_email = $wsal->settings()->get_use_email();
169
+ $email_from_name = $wsal->settings()->GetDisplayName();
170
  if ( ! empty( $email_from_name ) && 'custom_email' === $use_email ) {
171
  return $email_from_name;
172
  } else {
classes/Utilities/PluginInstallAndActivate.php CHANGED
@@ -86,7 +86,7 @@ if ( ! class_exists( 'WSAL_PluginInstallAndActivate' ) ) {
86
  // Loop through plugins and output.
87
  foreach ( $our_plugins as $details ) {
88
  $disable_button = '';
89
- if ( is_plugin_active( $details['plugin_slug'] ) ) {
90
  $disable_button = 'disabled';
91
  }
92
  // Check if this is actually an addon for something, otherwise bail.
@@ -103,10 +103,10 @@ if ( ! class_exists( 'WSAL_PluginInstallAndActivate' ) ) {
103
  <?php
104
  if ( $this->is_plugin_installed( $details['plugin_slug'] ) && ! is_plugin_active( $details['plugin_slug'] ) ) {
105
  esc_html_e( 'Extension installed, activate now?', 'wp-security-audit-log' );
106
- } elseif ( $this->is_plugin_installed( $details['plugin_slug'] ) && is_plugin_active( $details['plugin_slug'] ) ) {
107
  esc_html_e( 'Extension installed', 'wp-security-audit-log' );
108
  } else {
109
- esc_html_e( 'Install Extension', 'wp-security-audit-log' );
110
  }
111
  ?>
112
  </button><span class="spinner" style="display: none; visibility: visible; float: none; margin: 0 0 0 8px;"></span></p>
@@ -148,6 +148,15 @@ if ( ! class_exists( 'WSAL_PluginInstallAndActivate' ) ) {
148
  'event_tab_id' => '#tab-wpforms',
149
  'plugin_description' => 'Keep a record of when someone adds, modified or delete forms, entries and more in the WPForms plugin.',
150
  ),
 
 
 
 
 
 
 
 
 
151
  array(
152
  'addon_for' => 'wfcm',
153
  'title' => 'Website File Changes Monitor',
86
  // Loop through plugins and output.
87
  foreach ( $our_plugins as $details ) {
88
  $disable_button = '';
89
+ if ( is_plugin_active( $details['plugin_slug'] ) || 'wsal-wpforms.php' === basename( $details['plugin_slug'] ) && function_exists( 'wsal_wpforms_init_actions' ) || 'wsal-bbpress.php' === basename( $details['plugin_slug'] ) && function_exists( 'wsal_bbpress_init_actions' ) ) {
90
  $disable_button = 'disabled';
91
  }
92
  // Check if this is actually an addon for something, otherwise bail.
103
  <?php
104
  if ( $this->is_plugin_installed( $details['plugin_slug'] ) && ! is_plugin_active( $details['plugin_slug'] ) ) {
105
  esc_html_e( 'Extension installed, activate now?', 'wp-security-audit-log' );
106
+ } elseif ( $this->is_plugin_installed( $details['plugin_slug'] ) && is_plugin_active( $details['plugin_slug'] ) || 'wsal-wpforms.php' === basename( $details['plugin_slug'] ) && function_exists( 'wsal_wpforms_init_actions' ) || 'wsal-bbpress.php' === basename( $details['plugin_slug'] ) && function_exists( 'wsal_bbpress_init_actions' ) ) {
107
  esc_html_e( 'Extension installed', 'wp-security-audit-log' );
108
  } else {
109
+ esc_html_e( 'Install Extension', 'wp-security-audit-log' );
110
  }
111
  ?>
112
  </button><span class="spinner" style="display: none; visibility: visible; float: none; margin: 0 0 0 8px;"></span></p>
148
  'event_tab_id' => '#tab-wpforms',
149
  'plugin_description' => 'Keep a record of when someone adds, modified or delete forms, entries and more in the WPForms plugin.',
150
  ),
151
+ array(
152
+ 'addon_for' => 'woocommerce',
153
+ 'title' => 'WooCommerce Extension',
154
+ 'image_filename' => 'woocommerce.png',
155
+ 'plugin_slug' => 'wp-activity-log-for-woocommerce/wsal-woocommerce.php',
156
+ 'plugin_url' => 'https://downloads.wordpress.org/plugin/wp-activity-log-for-woocommerce.latest-stable.zip',
157
+ 'event_tab_id' => '#tab-woocommerce',
158
+ 'plugin_description' => 'Keep a record of when someone adds, modified or delete products, orders and more in the WooCommerce plugin.',
159
+ ),
160
  array(
161
  'addon_for' => 'wfcm',
162
  'title' => 'Website File Changes Monitor',
classes/Utilities/PluginInstallerAction.php CHANGED
@@ -141,6 +141,10 @@ if ( ! class_exists( 'WSAL_PluginInstallerAction' ) ) {
141
  return;
142
  }
143
 
 
 
 
 
144
  // get core plugin functions if they are not already in runtime.
145
  if ( ! function_exists( 'activate_plugin' ) ) {
146
  require_once ABSPATH . 'wp-admin/includes/plugin.php';
@@ -164,12 +168,22 @@ if ( ! class_exists( 'WSAL_PluginInstallerAction' ) ) {
164
  return;
165
  }
166
 
167
- $current = get_option( 'active_plugins' );
 
 
 
 
 
168
  $plugin = plugin_basename( trim( $plugin_slug ) );
169
 
170
  if ( ! in_array( $plugin_slug, $current, true ) ) {
171
- $current[] = $plugin_slug;
172
- activate_plugin( $plugin_slug );
 
 
 
 
 
173
  }
174
  return null;
175
  }
141
  return;
142
  }
143
 
144
+ if ( function_exists( 'is_multisite' ) && is_multisite() ) {
145
+ return;
146
+ }
147
+
148
  // get core plugin functions if they are not already in runtime.
149
  if ( ! function_exists( 'activate_plugin' ) ) {
150
  require_once ABSPATH . 'wp-admin/includes/plugin.php';
168
  return;
169
  }
170
 
171
+ if ( function_exists( 'is_multisite' ) && is_multisite() ) {
172
+ $current = get_site_option( 'active_sitewide_plugins' );
173
+ } else {
174
+ $current = get_option( 'active_plugins' );
175
+ }
176
+
177
  $plugin = plugin_basename( trim( $plugin_slug ) );
178
 
179
  if ( ! in_array( $plugin_slug, $current, true ) ) {
180
+ if ( function_exists( 'is_multisite' ) && is_multisite() ) {
181
+ $current[] = $plugin_slug;
182
+ activate_plugin( $plugin_slug, '', true );
183
+ } else {
184
+ $current[] = $plugin_slug;
185
+ activate_plugin( $plugin_slug );
186
+ }
187
  }
188
  return null;
189
  }
classes/ViewManager.php CHANGED
@@ -56,19 +56,6 @@ class WSAL_ViewManager {
56
  // Skipped views array.
57
  $skip_views = array();
58
 
59
- // Array of views to skip for premium version.
60
- if ( wsal_freemius()->is_plan_or_trial__premium_only( 'starter' ) ) {
61
- $skip_views[] = $this->_plugin->GetBaseDir() . 'classes/Views/EmailNotifications.php';
62
- $skip_views[] = $this->_plugin->GetBaseDir() . 'classes/Views/Search.php';
63
- }
64
-
65
- if ( wsal_freemius()->is_plan_or_trial__premium_only( 'professional' ) ) {
66
- $skip_views[] = $this->_plugin->GetBaseDir() . 'classes/Views/EmailNotifications.php';
67
- $skip_views[] = $this->_plugin->GetBaseDir() . 'classes/Views/Search.php';
68
- $skip_views[] = $this->_plugin->GetBaseDir() . 'classes/Views/ExternalDB.php';
69
- $skip_views[] = $this->_plugin->GetBaseDir() . 'classes/Views/LogInUsers.php';
70
- $skip_views[] = $this->_plugin->GetBaseDir() . 'classes/Views/Reports.php';
71
- }
72
 
73
  /**
74
  * Add setup wizard page to skip views. It will only be initialized
@@ -106,6 +93,9 @@ class WSAL_ViewManager {
106
  }
107
  }
108
 
 
 
 
109
  // Add menus.
110
  add_action( 'admin_menu', array( $this, 'AddAdminMenus' ) );
111
  add_action( 'network_admin_menu', array( $this, 'AddAdminMenus' ) );
@@ -121,8 +111,8 @@ class WSAL_ViewManager {
121
 
122
  // Initialize setup wizard.
123
  if (
124
- 'no' === $this->_plugin->GetGlobalOption( 'wsal-setup-complete', 'no' )
125
- || 'no' === $this->_plugin->options_helper->get_option_value( 'setup-modal-dismissed', 'no' )
126
  ) {
127
  new WSAL_Views_SetupWizard( $plugin );
128
  }
@@ -130,18 +120,13 @@ class WSAL_ViewManager {
130
  // Reorder WSAL submenu.
131
  add_filter( 'custom_menu_order', array( $this, 'reorder_wsal_submenu' ), 10, 1 );
132
 
133
- if ( wsal_freemius()->is__premium_only() ) {
134
- if ( $this->_plugin->settings->is_admin_bar_notif() ) {
135
- add_action( 'admin_bar_menu', array( $this, 'live_notifications__premium_only' ), 1000, 1 );
136
- add_action( 'wp_ajax_wsal_adminbar_events_refresh', array( $this, 'wsal_adminbar_events_refresh__premium_only' ) );
137
- }
138
- }
139
 
140
  add_action( 'admin_head', array( $this, 'hide_freemius_sites_section' ) );
141
 
142
  // Check if WFCM is running by seeing if we have the version defined.
143
  if ( defined( 'WFCM_VERSION' ) && ( version_compare( WFCM_VERSION, '1.6.0', '<' ) ) ) {
144
  add_action( 'admin_notices', array( $this, 'update_wfcm_notice' ) );
 
145
  }
146
  }
147
 
@@ -226,41 +211,50 @@ class WSAL_ViewManager {
226
  public function AddAdminMenus() {
227
  $this->ReorderViews();
228
 
229
- if ( $this->_plugin->settings->CurrentUserCan( 'view' ) && count( $this->views ) ) {
230
  // Add main menu.
 
231
  $this->views[0]->hook_suffix = add_menu_page(
232
  'WP Activity Log',
233
  'WP Activity Log',
234
  'read', // No capability requirement.
235
- $this->views[0]->GetSafeViewName(),
236
  array( $this, 'RenderViewBody' ),
237
  $this->views[0]->GetIcon(),
238
  '2.5' // Right after dashboard.
239
  );
240
 
 
 
 
 
 
 
 
 
 
 
 
 
 
241
  // Add menu items.
242
  foreach ( $this->views as $view ) {
243
  if ( $view->IsAccessible() ) {
244
- if ( $this->GetClassNameByView( $view->GetSafeViewName() ) ) {
 
245
  continue;
246
  }
247
 
248
- if ( ( 'wsal-togglealerts' === $view->GetSafeViewName()
249
- || 'wsal-settings' === $view->GetSafeViewName()
250
- || 'wsal-ext-settings' === $view->GetSafeViewName()
251
- || 'wsal-rep-views-main' === $view->GetSafeViewName()
252
- || 'wsal-np-notifications' === $view->GetSafeViewName()
253
- )
254
- && ! $this->_plugin->settings->CurrentUserCan( 'edit' ) ) {
255
  continue;
256
  }
257
 
258
  $view->hook_suffix = add_submenu_page(
259
- $view->IsVisible() ? $this->views[0]->GetSafeViewName() : null,
260
  $view->GetTitle(),
261
  $view->GetName(),
262
  'read', // No capability requirement.
263
- $view->GetSafeViewName(),
264
  array( $this, 'RenderViewBody' )
265
  );
266
  }
@@ -282,14 +276,9 @@ class WSAL_ViewManager {
282
  $new_links[] = '<a href="' . add_query_arg( 'page', $view->GetSafeViewName(), admin_url( 'admin.php' ) ) . '">' . $view->GetName() . '</a>';
283
 
284
  if ( 1 === count( $new_links ) && ! wsal_freemius()->is__premium_only() ) {
285
- // Trial link arguments.
286
- $trial_args = array(
287
- 'page' => 'wsal-auditlog-pricing',
288
- 'billing_cycle' => 'annual',
289
- 'trial' => 'true',
290
- );
291
- $admin_url = $this->_plugin->IsMultisite() ? network_admin_url( 'admin.php' ) : admin_url( 'admin.php' );
292
- $new_links[] = '<a style="font-weight:bold" href="' . add_query_arg( $trial_args, $admin_url ) . '">' . __( 'Free Premium Trial', 'wp-security-audit-log' ) . '</a>';
293
  }
294
  }
295
  }
@@ -383,7 +372,7 @@ class WSAL_ViewManager {
383
  * Returns view instance corresponding to its class name.
384
  *
385
  * @param string $class_name View class name.
386
- * @return WSAL_AbstractView The view or false on failure.
387
  */
388
  public function FindByClassName( $class_name ) {
389
  foreach ( $this->views as $view ) {
@@ -478,93 +467,6 @@ class WSAL_ViewManager {
478
  return $menu_order;
479
  }
480
 
481
- /**
482
- * Add WSAL to WP-Admin menu bar.
483
- *
484
- * @since 3.2.4
485
- *
486
- * @param WP_Admin_Bar $admin_bar - Instance of WP_Admin_Bar.
487
- */
488
- public function live_notifications__premium_only( $admin_bar ) {
489
- if ( $this->_plugin->settings->CurrentUserCan( 'view' ) && is_admin() ) {
490
- $adn_updates = $this->_plugin->settings->get_admin_bar_notif_updates();
491
- $event = $this->_plugin->alerts->get_admin_bar_event( 'page-refresh' === $adn_updates ? true : false );
492
-
493
- if ( $event ) {
494
- $code = $this->_plugin->alerts->GetAlert(
495
- $event->alert_id,
496
- (object) array(
497
- 'mesg' => __( 'Alert message not found.', 'wp-security-audit-log' ),
498
- 'desc' => __( 'Alert description not found.', 'wp-security-audit-log' ),
499
- )
500
- );
501
- $admin_bar->add_node(
502
- array(
503
- 'id' => 'wsal-menu',
504
- 'title' => 'LIVE: ' . $code->desc . ' from ' . $event->GetSourceIp(),
505
- 'href' => add_query_arg( 'page', 'wsal-auditlog', admin_url( 'admin.php' ) ),
506
- 'meta' => array( 'class' => 'wsal-live-notif-item' ),
507
- )
508
- );
509
- }
510
- }
511
- }
512
-
513
- /**
514
- * WP-Admin bar refresh event handler.
515
- *
516
- * @since 3.2.4
517
- */
518
- public function wsal_adminbar_events_refresh__premium_only() {
519
- if ( ! $this->_plugin->settings->CurrentUserCan( 'view' ) ) {
520
- echo wp_json_encode(
521
- array(
522
- 'success' => false,
523
- 'message' => __( 'Access Denied.', 'wp-security-audit-log' ),
524
- )
525
- );
526
- die();
527
- }
528
-
529
- if ( isset( $_POST['nonce'] ) && wp_verify_nonce( sanitize_text_field( wp_unslash( $_POST['nonce'] ) ), 'wsal-common-js-nonce' ) ) {
530
- $events_count = isset( $_POST['eventsCount'] ) ? (int) sanitize_text_field( wp_unslash( $_POST['eventsCount'] ) ) : false;
531
-
532
- if ( $events_count ) {
533
- $occurrence = new WSAL_Models_Occurrence();
534
- $new_count = (int) $occurrence->Count();
535
-
536
- if ( $events_count !== $new_count ) {
537
- $event = $this->_plugin->alerts->get_admin_bar_event( true );
538
- $code = $this->_plugin->alerts->GetAlert( $event->alert_id );
539
-
540
- echo wp_json_encode(
541
- array(
542
- 'success' => true,
543
- 'count' => $new_count,
544
- 'message' => 'LIVE: ' . $code->desc . ' from ' . $event->GetSourceIp(),
545
- )
546
- );
547
- } else {
548
- echo wp_json_encode( array( 'success' => false ) );
549
- }
550
- } else {
551
- echo wp_json_encode(
552
- array(
553
- 'success' => false,
554
- 'message' => __( 'Log count parameter expected.', 'wp-security-audit-log' ),
555
- )
556
- );
557
- }
558
- } else {
559
- echo wp_json_encode(
560
- array(
561
- 'success' => false,
562
- 'message' => __( 'Nonce verification failed.', 'wp-security-audit-log' ),
563
- )
564
- );
565
- }
566
- die();
567
- }
568
 
569
  /**
570
  * Hide Freemius sites section on the account page
@@ -595,4 +497,13 @@ class WSAL_ViewManager {
595
  echo '<style type="text/css">#fs_sites {display:none;}</style>';
596
  }
597
  }
 
 
 
 
 
 
 
 
 
598
  }
56
  // Skipped views array.
57
  $skip_views = array();
58
 
 
 
 
 
 
 
 
 
 
 
 
 
 
59
 
60
  /**
61
  * Add setup wizard page to skip views. It will only be initialized
93
  }
94
  }
95
 
96
+ // stop Freemius from hiding the menu on sub sites under certain circumstances
97
+ add_filter('fs_should_hide_site_admin_settings_on_network_activation_mode_wp-security-audit-log', array( $this, 'bypass_freemius_menu_hiding'));
98
+
99
  // Add menus.
100
  add_action( 'admin_menu', array( $this, 'AddAdminMenus' ) );
101
  add_action( 'network_admin_menu', array( $this, 'AddAdminMenus' ) );
111
 
112
  // Initialize setup wizard.
113
  if (
114
+ ! $this->_plugin->GetGlobalBooleanSetting( 'setup-complete', false )
115
+ || ! $this->_plugin->GetGlobalBooleanSetting( 'setup-modal-dismissed', false )
116
  ) {
117
  new WSAL_Views_SetupWizard( $plugin );
118
  }
120
  // Reorder WSAL submenu.
121
  add_filter( 'custom_menu_order', array( $this, 'reorder_wsal_submenu' ), 10, 1 );
122
 
 
 
 
 
 
 
123
 
124
  add_action( 'admin_head', array( $this, 'hide_freemius_sites_section' ) );
125
 
126
  // Check if WFCM is running by seeing if we have the version defined.
127
  if ( defined( 'WFCM_VERSION' ) && ( version_compare( WFCM_VERSION, '1.6.0', '<' ) ) ) {
128
  add_action( 'admin_notices', array( $this, 'update_wfcm_notice' ) );
129
+ add_action( 'network_admin_notices', array( $this, 'update_wfcm_notice' ) );
130
  }
131
  }
132
 
211
  public function AddAdminMenus() {
212
  $this->ReorderViews();
213
 
214
+ if ( $this->_plugin->settings()->CurrentUserCan( 'view' ) && count( $this->views ) ) {
215
  // Add main menu.
216
+ $main_view_menu_slug = $this->views[0]->GetSafeViewName();
217
  $this->views[0]->hook_suffix = add_menu_page(
218
  'WP Activity Log',
219
  'WP Activity Log',
220
  'read', // No capability requirement.
221
+ $main_view_menu_slug,
222
  array( $this, 'RenderViewBody' ),
223
  $this->views[0]->GetIcon(),
224
  '2.5' // Right after dashboard.
225
  );
226
 
227
+ // protected views to be displayed only to user with full plugin access
228
+ $protected_views = array(
229
+ 'wsal-togglealerts',
230
+ 'wsal-usersessions-views',
231
+ 'wsal-settings',
232
+ 'wsal-ext-settings',
233
+ 'wsal-rep-views-main',
234
+ 'wsal-np-notifications'
235
+ );
236
+
237
+ // check edit privileges of the current user
238
+ $has_current_user_edit_priv = $this->_plugin->settings()->CurrentUserCan( 'edit' );
239
+
240
  // Add menu items.
241
  foreach ( $this->views as $view ) {
242
  if ( $view->IsAccessible() ) {
243
+ $safe_view_name = $view->GetSafeViewName();
244
+ if ( $this->GetClassNameByView( $safe_view_name ) ) {
245
  continue;
246
  }
247
 
248
+ if ( in_array( $safe_view_name, $protected_views ) && ! $has_current_user_edit_priv ) {
 
 
 
 
 
 
249
  continue;
250
  }
251
 
252
  $view->hook_suffix = add_submenu_page(
253
+ $view->IsVisible() ? $main_view_menu_slug : null,
254
  $view->GetTitle(),
255
  $view->GetName(),
256
  'read', // No capability requirement.
257
+ $safe_view_name,
258
  array( $this, 'RenderViewBody' )
259
  );
260
  }
276
  $new_links[] = '<a href="' . add_query_arg( 'page', $view->GetSafeViewName(), admin_url( 'admin.php' ) ) . '">' . $view->GetName() . '</a>';
277
 
278
  if ( 1 === count( $new_links ) && ! wsal_freemius()->is__premium_only() ) {
279
+ // Trial link
280
+ $trial_link = 'https://wpactivitylog.com/trial-premium-edition-plugin/?utm_source=plugin&utm_medium=referral&utm_campaign=WSAL';
281
+ $new_links[] = '<a style="font-weight:bold" href="' . $trial_link . '" target="_blank">' . __( 'Free Premium Trial', 'wp-security-audit-log' ) . '</a>';
 
 
 
 
 
282
  }
283
  }
284
  }
372
  * Returns view instance corresponding to its class name.
373
  *
374
  * @param string $class_name View class name.
375
+ * @return WSAL_AbstractView|bool The view or false on failure.
376
  */
377
  public function FindByClassName( $class_name ) {
378
  foreach ( $this->views as $view ) {
467
  return $menu_order;
468
  }
469
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
470
 
471
  /**
472
  * Hide Freemius sites section on the account page
497
  echo '<style type="text/css">#fs_sites {display:none;}</style>';
498
  }
499
  }
500
+
501
+ /**
502
+ * @param bool $should_hide
503
+ *
504
+ * @return bool
505
+ */
506
+ public function bypass_freemius_menu_hiding($should_hide) {
507
+ return false;
508
+ }
509
  }
classes/Views/AuditLog.php CHANGED
@@ -86,7 +86,7 @@ class WSAL_Views_AuditLog extends WSAL_AbstractView {
86
  add_filter( 'wsal_pointers_toplevel_page_wsal-auditlog', array( $this, 'register_privacy_pointer' ), 10, 1 );
87
  add_action( 'admin_init', array( $this, 'handle_form_submission' ) );
88
 
89
- if ( $this->_plugin->settings->is_infinite_scroll() ) {
90
  add_action( 'wp_ajax_wsal_infinite_scroll_events', array( $this, 'infinite_scroll_events' ) );
91
  }
92
 
@@ -132,11 +132,11 @@ class WSAL_Views_AuditLog extends WSAL_AbstractView {
132
  && ! class_exists( 'WSAL_Rep_Plugin' )
133
  && ! class_exists( 'WSAL_SearchExtension' )
134
  && ! class_exists( 'WSAL_UserSessions_Plugin' )
135
- && 'anonymous' !== get_site_option( 'wsal_freemius_state', 'anonymous' ) // Anonymous mode option.
136
  ) {
137
  $get_transient_fn = $this->_plugin->IsMultisite() ? 'get_site_transient' : 'get_transient'; // Check for multisite.
138
  $wsal_is_advert_dismissed = $get_transient_fn( 'wsal-is-advert-dismissed' ); // Check if advert has been dismissed.
139
- $wsal_premium_advert = $this->_plugin->GetGlobalOption( 'premium-advert', false ); // Get the advert to display.
140
  $wsal_premium_advert = false !== $wsal_premium_advert ? (int) $wsal_premium_advert : 0; // Set the default.
141
 
142
  if ( current_user_can( 'manage_options' ) && $is_current_view && ! $wsal_is_advert_dismissed ) : ?>
@@ -219,13 +219,13 @@ class WSAL_Views_AuditLog extends WSAL_AbstractView {
219
  }
220
 
221
  // Check anonymous mode.
222
- if ( 'anonymous' === get_site_option( 'wsal_freemius_state', 'anonymous' ) ) { // If user manually opt-out then don't show the notice.
223
  if (
224
  wsal_freemius()->is_anonymous() // Anonymous mode option.
225
  && wsal_freemius()->is_not_paying() // Not paying customer.
226
  && wsal_freemius()->has_api_connectivity() // Check API connectivity.
227
  && $is_current_view
228
- && $this->_plugin->settings->CurrentUserCan( 'edit' ) // Have permission to edit plugin settings.
229
  ) {
230
  if ( ! is_multisite() || ( is_multisite() && is_network_admin() ) ) :
231
  ?>
@@ -245,9 +245,9 @@ class WSAL_Views_AuditLog extends WSAL_AbstractView {
245
 
246
  // Display add-on available notice.
247
  $screen = get_current_screen();
248
- $notice_already_dismissed = get_option( 'wsal_addon_available_notice_dismissed' );
249
- if ( $screen->base === 'toplevel_page_wsal-auditlog' && $is_current_view && ! $notice_already_dismissed ) {
250
- $addons_available = get_option( 'wsal_installed_plugin_addon_available' );
251
  $all_plugins = get_plugins();
252
  $all_plugins = array_keys( $all_plugins );
253
  $predefined_plugins = WSAL_PluginInstallAndActivate::get_installable_plugins();
@@ -262,6 +262,11 @@ class WSAL_Views_AuditLog extends WSAL_AbstractView {
262
  $addon_slug = array( array_search( $addon, array_column( $predefined_plugins, 'addon_for', 'plugin_slug' ) ) );
263
  $is_addon_installed = array_intersect( $all_plugins, $addon_slug );
264
 
 
 
 
 
 
265
  if ( empty( $is_addon_installed ) ) {
266
  $addon = str_replace( '-', ' ', $addon);
267
  if ( $addon === 'bbpress' ) {
@@ -270,12 +275,15 @@ class WSAL_Views_AuditLog extends WSAL_AbstractView {
270
  if ( $addon === 'wpforms' ) {
271
  $addon = 'WPForms';
272
  }
 
 
 
273
  if ( empty( $addon_names ) ) {
274
  $addon_names .= $addon;
275
- $button_label = esc_html__( 'Install Extension', 'wp-2fa' );
276
  } else {
277
  $addon_names .= ' & ' .$addon;
278
- $button_label = esc_html__( 'Install Extensions', 'wp-2fa' );
279
  }
280
  $display_notice = true;
281
  }
@@ -287,12 +295,12 @@ class WSAL_Views_AuditLog extends WSAL_AbstractView {
287
  <p><?php $message = printf(
288
  /* translators: %1$s: is the user name, %2$s is the website name */
289
  '%1$s %2$s %3$s %4$s. <a href="%6$s" class="button button-primary">%5$s</a>',
290
- esc_html__( 'You have', 'wp-2fa' ),
291
  $addon_names,
292
- esc_html__( 'installed. Keep a log of changes in', 'wp-2fa' ),
293
  $addon_names,
294
  $button_label,
295
- esc_url( add_query_arg( 'page', 'wsal-togglealerts#tab-third-party-plugins', admin_url( 'admin.php' ) ) )
296
  ); ?></p>
297
  <?php wp_nonce_field( 'wsal_dismiss_notice_addon_available', 'wsal-dismiss-notice-addon-available', false, true ); ?>
298
  </div>
@@ -331,7 +339,7 @@ class WSAL_Views_AuditLog extends WSAL_AbstractView {
331
 
332
  // Verify nonce.
333
  if ( wp_verify_nonce( $post_array['nonce'], 'wsal_dismiss_notice_addon_available' ) ) {
334
- add_option( 'wsal_addon_available_notice_dismissed', true );
335
  die();
336
  }
337
  die( 'Nonce verification failed!' );
@@ -396,7 +404,7 @@ class WSAL_Views_AuditLog extends WSAL_AbstractView {
396
 
397
  // @codingStandardsIgnoreStart
398
  $this->page_args->page = isset( $_REQUEST['page'] ) ? sanitize_text_field( wp_unslash( $_REQUEST['page'] ) ) : false;
399
- $this->page_args->site_id = $this->_plugin->settings->get_view_site_id();
400
 
401
  // Order arguments.
402
  $this->page_args->order_by = isset( $_REQUEST['orderby'] ) ? sanitize_text_field( wp_unslash( $_REQUEST['orderby'] ) ) : false;
@@ -530,7 +538,7 @@ class WSAL_Views_AuditLog extends WSAL_AbstractView {
530
  * @since 1.0.0
531
  */
532
  public function Render() {
533
- if ( ! $this->_plugin->settings->CurrentUserCan( 'view' ) ) {
534
  wp_die( esc_html__( 'You do not have sufficient permissions to access this page.', 'wp-security-audit-log' ) );
535
  }
536
 
@@ -573,8 +581,8 @@ class WSAL_Views_AuditLog extends WSAL_AbstractView {
573
 
574
  <?php
575
  if (
576
- 'no' === $this->_plugin->GetGlobalOption( 'wsal-setup-complete', 'no' )
577
- && 'no' === $this->_plugin->options_helper->get_option_value( 'setup-modal-dismissed', 'no' )
578
  ) :
579
  ?>
580
  <div data-remodal-id="wsal-setup-modal">
@@ -590,16 +598,16 @@ class WSAL_Views_AuditLog extends WSAL_AbstractView {
590
  wsal_setup_modal.remodal().open();
591
 
592
  jQuery(document).on('confirmation', wsal_setup_modal, function () {
593
- <?php $this->_plugin->options_helper->set_option_value( 'setup-modal-dismissed', 'yes' ); ?>
594
  window.location = '<?php echo esc_url( add_query_arg( 'page', 'wsal-setup', admin_url( 'index.php' ) ) ); ?>';
595
  });
596
 
597
  jQuery(document).on('cancellation', wsal_setup_modal, function () {
598
- <?php $this->_plugin->options_helper->set_option_value( 'setup-modal-dismissed', 'yes' ); ?>
599
  });
600
 
601
  jQuery(document).on('closed', wsal_setup_modal, function () {
602
- <?php $this->_plugin->options_helper->set_option_value( 'setup-modal-dismissed', 'yes' ); ?>
603
  });
604
  });
605
  </script>
@@ -621,8 +629,8 @@ class WSAL_Views_AuditLog extends WSAL_AbstractView {
621
  'searchnone' => __( 'No Results', 'wp-security-audit-log' ),
622
  ),
623
  'autorefresh' => array(
624
- 'enabled' => ! $is_search_view ? $this->_plugin->settings->IsRefreshAlertsEnabled() : false,
625
- 'token' => $this->_plugin->settings->is_infinite_scroll() ? $this->get_total_events() : $this->GetView()->get_total_items(),
626
  ),
627
  )
628
  );
@@ -637,7 +645,7 @@ class WSAL_Views_AuditLog extends WSAL_AbstractView {
637
  * Ajax callback to display meta data inspector.
638
  */
639
  public function AjaxInspector() {
640
- if ( ! $this->_plugin->settings->CurrentUserCan( 'view' ) ) {
641
  die( 'Access Denied.' );
642
  }
643
 
@@ -654,7 +662,7 @@ class WSAL_Views_AuditLog extends WSAL_AbstractView {
654
 
655
  // Check if archive db is enabled and the current user matches the one who selected archive db.
656
  if ( ! empty( $selected_db ) && 'archive' === $selected_db && get_current_user_id() === $selected_db_user ) {
657
- $this->_plugin->settings->SwitchToArchiveDB(); // Switch to archive DB.
658
  }
659
 
660
  $occ = new WSAL_Models_Occurrence();
@@ -680,7 +688,7 @@ class WSAL_Views_AuditLog extends WSAL_AbstractView {
680
  * Ajax callback to refrest the view.
681
  */
682
  public function AjaxRefresh() {
683
- if ( ! $this->_plugin->settings->CurrentUserCan( 'view' ) ) {
684
  die( 'Access Denied.' );
685
  }
686
 
@@ -697,7 +705,7 @@ class WSAL_Views_AuditLog extends WSAL_AbstractView {
697
 
698
  // Check if the user is viewing archived db.
699
  $is_archive = false;
700
- if ( $this->_plugin->settings->IsArchivingEnabled() ) {
701
  $selected_db = get_transient( 'wsal_wp_selected_db' );
702
  if ( $selected_db && 'archive' === $selected_db ) {
703
  $is_archive = true;
@@ -723,7 +731,7 @@ class WSAL_Views_AuditLog extends WSAL_AbstractView {
723
  * show on a single page.
724
  */
725
  public function AjaxSetIpp() {
726
- if ( ! $this->_plugin->settings->CurrentUserCan( 'view' ) ) {
727
  die( 'Access Denied.' );
728
  }
729
 
@@ -733,7 +741,7 @@ class WSAL_Views_AuditLog extends WSAL_AbstractView {
733
  if ( ! isset( $post_array['count'] ) ) {
734
  die( 'Count parameter expected.' );
735
  }
736
- $this->_plugin->settings->SetViewPerPage( (int) $post_array['count'] );
737
  die;
738
  }
739
 
@@ -741,7 +749,7 @@ class WSAL_Views_AuditLog extends WSAL_AbstractView {
741
  * Ajax callback to search.
742
  */
743
  public function AjaxSearchSite() {
744
- if ( ! $this->_plugin->settings->CurrentUserCan( 'view' ) ) {
745
  die( 'Access Denied.' );
746
  }
747
 
@@ -832,28 +840,12 @@ class WSAL_Views_AuditLog extends WSAL_AbstractView {
832
 
833
  // Verify nonce.
834
  if ( ! empty( $filename ) && ! empty( $nonce ) && wp_verify_nonce( $nonce, 'wsal-download-404-log-' . $filename ) ) {
835
- $is_subsite = strpos( $filename, '/sites/' ); // Check for subsite on a multisite network.
836
-
837
- if ( ! $is_subsite ) {
838
- // Site is not a subsite on a multisite network.
839
- $uploads_dir = wp_upload_dir(); // Get uploads directory.
840
- $filename = basename( $filename ); // Get basename to prevent path traversal attack.
841
 
842
- // Construct log file path to eliminate the risks of path traversal attack.
843
- $log_file_path = trailingslashit( $uploads_dir['basedir'] ) . 'wp-security-audit-log/404s/' . $filename;
844
- } else {
845
- // Site is a subsite on a multisite network.
846
- $filepath = substr( $filename, $is_subsite ); // Get the chunk of string from `/sites/` to find the site id.
847
-
848
- // Get basename to prevent path traversal attack.
849
- $filename = basename( $filename );
850
 
851
- // Search for site id in the file path by replacing the remaining known chunks such as `/sites/` and the path after site id.
852
- $site_id = str_replace( array( '/sites/', '/wp-security-audit-log/404s/' . $filename ), '', $filepath );
853
-
854
- // Construct log file path to eliminate the risks of path traversal attack.
855
- $log_file_path = trailingslashit( WP_CONTENT_DIR ) . 'uploads/sites/' . $site_id . '/wp-security-audit-log/404s/' . $filename;
856
- }
857
 
858
  // Request the file.
859
  $response = file_get_contents( $log_file_path, true );
@@ -894,7 +886,7 @@ class WSAL_Views_AuditLog extends WSAL_AbstractView {
894
  */
895
  public function wsal_freemius_opt_in() {
896
  // Die if not have access.
897
- if ( ! $this->_plugin->settings->CurrentUserCan( 'view' ) ) {
898
  die( 'Access Denied.' );
899
  }
900
 
@@ -933,7 +925,7 @@ class WSAL_Views_AuditLog extends WSAL_AbstractView {
933
  }
934
 
935
  // Update freemius state.
936
- update_site_option( 'wsal_freemius_state', 'in' );
937
  } elseif ( 'no' === $choice ) {
938
  if ( ! is_multisite() ) {
939
  wsal_freemius()->skip_connection(); // Opt out.
@@ -942,7 +934,7 @@ class WSAL_Views_AuditLog extends WSAL_AbstractView {
942
  }
943
 
944
  // Update freemius state.
945
- update_site_option( 'wsal_freemius_state', 'skipped' );
946
  }
947
 
948
  echo wp_json_encode(
@@ -1032,7 +1024,7 @@ class WSAL_Views_AuditLog extends WSAL_AbstractView {
1032
  'searchTerm' => isset( $this->page_args->search_term ) ? $this->page_args->search_term : false,
1033
  'searchFilters' => isset( $this->page_args->search_filters ) ? $this->page_args->search_filters : false,
1034
  'viewerNonce' => wp_create_nonce( 'wsal_auditlog_viewer_nonce' ),
1035
- 'infiniteScroll' => $this->_plugin->settings->is_infinite_scroll(),
1036
  'userView' => ( in_array( $this->user_last_view, $this->supported_view_types(), true ) ) ? $this->user_last_view : 'list',
1037
  'installAddonStrings' => array(
1038
  'defaultButton' => esc_html( 'Install and activate extension', 'wp-security-audit-log' ),
@@ -1043,8 +1035,8 @@ class WSAL_Views_AuditLog extends WSAL_AbstractView {
1043
  'buttonError' => esc_html( 'Problem enabling', 'wp-security-audit-log' ),
1044
  'msgError' => sprintf(
1045
  /* translators: 1 - an opening link tag, 2 - the closing tag. */
1046
- __( '<br>An error occured when trying to install and activate the plugin. Please try install it again from the %1$sevent settings%2$s page.', 'wp-security-audit-log' ),
1047
- '<a href="' . esc_url( add_query_arg( 'page', 'wsal-togglealerts#tab-third-party-plugins', admin_url( 'admin.php' ) ) ) . '">',
1048
  '</a>'
1049
  ),
1050
  ),
@@ -1067,8 +1059,8 @@ class WSAL_Views_AuditLog extends WSAL_AbstractView {
1067
 
1068
  // Don't display notice if the wizard notice is showing.
1069
  if (
1070
- 'no' === $this->_plugin->GetGlobalOption( 'wsal-setup-complete', 'no' )
1071
- && 'no' === $this->_plugin->options_helper->get_option_value( 'setup-modal-dismissed', 'no' )
1072
  ) {
1073
  return;
1074
  }
@@ -1085,7 +1077,7 @@ class WSAL_Views_AuditLog extends WSAL_AbstractView {
1085
  }
1086
 
1087
  // Get dismissed pointers.
1088
- $dismissed = explode( ',', (string) $this->_plugin->options_helper->get_option_value( 'dismissed-privacy-notice', true ) );
1089
  $valid_pointers = array();
1090
 
1091
  // Check pointers and remove dismissed ones.
@@ -1164,7 +1156,7 @@ class WSAL_Views_AuditLog extends WSAL_AbstractView {
1164
  */
1165
  public function wsal_exclude_url() {
1166
  // Die if user does not have permission to disable.
1167
- if ( ! $this->_plugin->settings->CurrentUserCan( 'edit' ) ) {
1168
  echo '<p>' . esc_html__( 'Error: You do not have sufficient permissions to exclude this URL.', 'wp-security-audit-log' ) . '</p>';
1169
  die();
1170
  }
@@ -1182,13 +1174,13 @@ class WSAL_Views_AuditLog extends WSAL_AbstractView {
1182
  die();
1183
  }
1184
 
1185
- $excluded_urls = $this->_plugin->GetGlobalOption( 'excluded-urls' );
1186
  if ( isset( $excluded_urls ) && '' !== $excluded_urls ) {
1187
  $excluded_urls .= ',' . esc_url( $post_array['url'] );
1188
  } else {
1189
  $excluded_urls = esc_url( $post_array['url'] );
1190
  }
1191
- $this->_plugin->SetGlobalOption( 'excluded-urls', $excluded_urls );
1192
  $settings_exclude_url = add_query_arg(
1193
  array(
1194
  'page' => 'wsal-settings',
@@ -1207,7 +1199,7 @@ class WSAL_Views_AuditLog extends WSAL_AbstractView {
1207
  */
1208
  public function wsal_dismiss_advert() {
1209
  // Die if user does not have permission to dismiss.
1210
- if ( ! $this->_plugin->settings->CurrentUserCan( 'edit' ) ) {
1211
  echo wp_json_encode(
1212
  array(
1213
  'success' => false,
@@ -1235,7 +1227,7 @@ class WSAL_Views_AuditLog extends WSAL_AbstractView {
1235
  }
1236
 
1237
  $advert = 2 === $advert ? '0' : $advert + 1;
1238
- $this->_plugin->SetGlobalOption( 'premium-advert', $advert );
1239
  $set_transient_fn = $this->_plugin->IsMultisite() ? 'set_site_transient' : 'set_transient';
1240
  $set_transient_fn( 'wsal-is-advert-dismissed', true, MONTH_IN_SECONDS );
1241
  echo wp_json_encode(
@@ -1260,7 +1252,7 @@ class WSAL_Views_AuditLog extends WSAL_AbstractView {
1260
  wp_die( 0 );
1261
  }
1262
 
1263
- $dismissed = array_filter( explode( ',', (string) $this->_plugin->options_helper->get_option_value( 'dismissed-privacy-notice', true ) ) );
1264
 
1265
  if ( in_array( $pointer, $dismissed ) ) {
1266
  wp_die( 0 );
@@ -1269,7 +1261,7 @@ class WSAL_Views_AuditLog extends WSAL_AbstractView {
1269
  $dismissed[] = $pointer;
1270
  $dismissed = implode( ',', $dismissed );
1271
 
1272
- $this->_plugin->options_helper->set_option_value( 'dismissed-privacy-notice', $dismissed );
1273
  wp_die( 1 );
1274
  }
1275
 
@@ -1280,7 +1272,7 @@ class WSAL_Views_AuditLog extends WSAL_AbstractView {
1280
  */
1281
  public function infinite_scroll_events() {
1282
  // Check user permissions.
1283
- if ( ! $this->_plugin->settings->CurrentUserCan( 'view' ) ) {
1284
  die( esc_html__( 'Access Denied', 'wp-security-audit-log' ) );
1285
  }
1286
 
86
  add_filter( 'wsal_pointers_toplevel_page_wsal-auditlog', array( $this, 'register_privacy_pointer' ), 10, 1 );
87
  add_action( 'admin_init', array( $this, 'handle_form_submission' ) );
88
 
89
+ if ( $this->_plugin->settings()->is_infinite_scroll() ) {
90
  add_action( 'wp_ajax_wsal_infinite_scroll_events', array( $this, 'infinite_scroll_events' ) );
91
  }
92
 
132
  && ! class_exists( 'WSAL_Rep_Plugin' )
133
  && ! class_exists( 'WSAL_SearchExtension' )
134
  && ! class_exists( 'WSAL_UserSessions_Plugin' )
135
+ && 'anonymous' !== $this->_plugin->GetGlobalSetting( 'freemius_state', 'anonymous' ) // Anonymous mode option.
136
  ) {
137
  $get_transient_fn = $this->_plugin->IsMultisite() ? 'get_site_transient' : 'get_transient'; // Check for multisite.
138
  $wsal_is_advert_dismissed = $get_transient_fn( 'wsal-is-advert-dismissed' ); // Check if advert has been dismissed.
139
+ $wsal_premium_advert = $this->_plugin->GetGlobalSetting( 'premium-advert', false ); // Get the advert to display.
140
  $wsal_premium_advert = false !== $wsal_premium_advert ? (int) $wsal_premium_advert : 0; // Set the default.
141
 
142
  if ( current_user_can( 'manage_options' ) && $is_current_view && ! $wsal_is_advert_dismissed ) : ?>
219
  }
220
 
221
  // Check anonymous mode.
222
+ if ( 'anonymous' === $this->_plugin->GetGlobalSetting( 'freemius_state', 'anonymous' ) ) { // If user manually opt-out then don't show the notice.
223
  if (
224
  wsal_freemius()->is_anonymous() // Anonymous mode option.
225
  && wsal_freemius()->is_not_paying() // Not paying customer.
226
  && wsal_freemius()->has_api_connectivity() // Check API connectivity.
227
  && $is_current_view
228
+ && $this->_plugin->settings()->CurrentUserCan( 'edit' ) // Have permission to edit plugin settings.
229
  ) {
230
  if ( ! is_multisite() || ( is_multisite() && is_network_admin() ) ) :
231
  ?>
245
 
246
  // Display add-on available notice.
247
  $screen = get_current_screen();
248
+ $notice_already_dismissed = $this->_plugin->GetGlobalSetting( 'addon_available_notice_dismissed' );
249
+ if ( $screen->base === 'toplevel_page_wsal-auditlog' && $is_current_view && ! $notice_already_dismissed || $screen->base === 'toplevel_page_wsal-auditlog-network' && $is_current_view && ! $notice_already_dismissed ) {
250
+ $addons_available = $this->_plugin->GetGlobalSetting( 'installed_plugin_addon_available' );
251
  $all_plugins = get_plugins();
252
  $all_plugins = array_keys( $all_plugins );
253
  $predefined_plugins = WSAL_PluginInstallAndActivate::get_installable_plugins();
262
  $addon_slug = array( array_search( $addon, array_column( $predefined_plugins, 'addon_for', 'plugin_slug' ) ) );
263
  $is_addon_installed = array_intersect( $all_plugins, $addon_slug );
264
 
265
+ // Check if a function from the addon exists, just in case.
266
+ if ( $addon === 'wpforms' && function_exists( 'wsal_wpforms_init_actions' ) || $addon === 'bbpress' && function_exists( 'wsal_bbpress_init_actions' ) ) {
267
+ continue;
268
+ }
269
+
270
  if ( empty( $is_addon_installed ) ) {
271
  $addon = str_replace( '-', ' ', $addon);
272
  if ( $addon === 'bbpress' ) {
275
  if ( $addon === 'wpforms' ) {
276
  $addon = 'WPForms';
277
  }
278
+ if ( $addon === 'woocommerce' ) {
279
+ $addon = 'WooCommerce';
280
+ }
281
  if ( empty( $addon_names ) ) {
282
  $addon_names .= $addon;
283
+ $button_label = esc_html__( 'Install Extension', 'wp-security-audit-log' );
284
  } else {
285
  $addon_names .= ' & ' .$addon;
286
+ $button_label = esc_html__( 'Install Extensions', 'wp-security-audit-log' );
287
  }
288
  $display_notice = true;
289
  }
295
  <p><?php $message = printf(
296
  /* translators: %1$s: is the user name, %2$s is the website name */
297
  '%1$s %2$s %3$s %4$s. <a href="%6$s" class="button button-primary">%5$s</a>',
298
+ esc_html__( 'You have', 'wp-security-audit-log' ),
299
  $addon_names,
300
+ esc_html__( 'installed. Keep a log of changes in', 'wp-security-audit-log' ),
301
  $addon_names,
302
  $button_label,
303
+ esc_url( add_query_arg( 'page', 'wsal-togglealerts#tab-third-party-plugins', network_admin_url( 'admin.php' ) ) )
304
  ); ?></p>
305
  <?php wp_nonce_field( 'wsal_dismiss_notice_addon_available', 'wsal-dismiss-notice-addon-available', false, true ); ?>
306
  </div>
339
 
340
  // Verify nonce.
341
  if ( wp_verify_nonce( $post_array['nonce'], 'wsal_dismiss_notice_addon_available' ) ) {
342
+ $this->_plugin->SetGlobalSetting( 'addon_available_notice_dismissed', true );
343
  die();
344
  }
345
  die( 'Nonce verification failed!' );
404
 
405
  // @codingStandardsIgnoreStart
406
  $this->page_args->page = isset( $_REQUEST['page'] ) ? sanitize_text_field( wp_unslash( $_REQUEST['page'] ) ) : false;
407
+ $this->page_args->site_id = $this->_plugin->settings()->get_view_site_id();
408
 
409
  // Order arguments.
410
  $this->page_args->order_by = isset( $_REQUEST['orderby'] ) ? sanitize_text_field( wp_unslash( $_REQUEST['orderby'] ) ) : false;
538
  * @since 1.0.0
539
  */
540
  public function Render() {
541
+ if ( ! $this->_plugin->settings()->CurrentUserCan( 'view' ) ) {
542
  wp_die( esc_html__( 'You do not have sufficient permissions to access this page.', 'wp-security-audit-log' ) );
543
  }
544
 
581
 
582
  <?php
583
  if (
584
+ ! $this->_plugin->GetGlobalBooleanSetting( 'setup-complete', false )
585
+ && ! $this->_plugin->GetGlobalBooleanSetting( 'setup-modal-dismissed', false )
586
  ) :
587
  ?>
588
  <div data-remodal-id="wsal-setup-modal">
598
  wsal_setup_modal.remodal().open();
599
 
600
  jQuery(document).on('confirmation', wsal_setup_modal, function () {
601
+ <?php $this->_plugin->SetGlobalBooleanSetting( 'setup-modal-dismissed', true ); ?>
602
  window.location = '<?php echo esc_url( add_query_arg( 'page', 'wsal-setup', admin_url( 'index.php' ) ) ); ?>';
603
  });
604
 
605
  jQuery(document).on('cancellation', wsal_setup_modal, function () {
606
+ <?php $this->_plugin->SetGlobalBooleanSetting( 'setup-modal-dismissed', true ); ?>
607
  });
608
 
609
  jQuery(document).on('closed', wsal_setup_modal, function () {
610
+ <?php $this->_plugin->SetGlobalBooleanSetting( 'setup-modal-dismissed', true ); ?>
611
  });
612
  });
613
  </script>
629
  'searchnone' => __( 'No Results', 'wp-security-audit-log' ),
630
  ),
631
  'autorefresh' => array(
632
+ 'enabled' => ! $is_search_view ? $this->_plugin->settings()->IsRefreshAlertsEnabled() : false,
633
+ 'token' => $this->_plugin->settings()->is_infinite_scroll() ? $this->get_total_events() : $this->GetView()->get_total_items(),
634
  ),
635
  )
636
  );
645
  * Ajax callback to display meta data inspector.
646
  */
647
  public function AjaxInspector() {
648
+ if ( ! $this->_plugin->settings()->CurrentUserCan( 'view' ) ) {
649
  die( 'Access Denied.' );
650
  }
651
 
662
 
663
  // Check if archive db is enabled and the current user matches the one who selected archive db.
664
  if ( ! empty( $selected_db ) && 'archive' === $selected_db && get_current_user_id() === $selected_db_user ) {
665
+ $this->_plugin->settings()->SwitchToArchiveDB(); // Switch to archive DB.
666
  }
667
 
668
  $occ = new WSAL_Models_Occurrence();
688
  * Ajax callback to refrest the view.
689
  */
690
  public function AjaxRefresh() {
691
+ if ( ! $this->_plugin->settings()->CurrentUserCan( 'view' ) ) {
692
  die( 'Access Denied.' );
693
  }
694
 
705
 
706
  // Check if the user is viewing archived db.
707
  $is_archive = false;
708
+ if ( $this->_plugin->settings()->IsArchivingEnabled() ) {
709
  $selected_db = get_transient( 'wsal_wp_selected_db' );
710
  if ( $selected_db && 'archive' === $selected_db ) {
711
  $is_archive = true;
731
  * show on a single page.
732
  */
733
  public function AjaxSetIpp() {
734
+ if ( ! $this->_plugin->settings()->CurrentUserCan( 'view' ) ) {
735
  die( 'Access Denied.' );
736
  }
737
 
741
  if ( ! isset( $post_array['count'] ) ) {
742
  die( 'Count parameter expected.' );
743
  }
744
+ $this->_plugin->settings()->SetViewPerPage( (int) $post_array['count'] );
745
  die;
746
  }
747
 
749
  * Ajax callback to search.
750
  */
751
  public function AjaxSearchSite() {
752
+ if ( ! $this->_plugin->settings()->CurrentUserCan( 'view' ) ) {
753
  die( 'Access Denied.' );
754
  }
755
 
840
 
841
  // Verify nonce.
842
  if ( ! empty( $filename ) && ! empty( $nonce ) && wp_verify_nonce( $nonce, 'wsal-download-404-log-' . $filename ) ) {
 
 
 
 
 
 
843
 
844
+ // Get basename to prevent path traversal attack.
845
+ $filename = basename( $filename );
 
 
 
 
 
 
846
 
847
+ // Construct log file path to eliminate the risks of path traversal attack.
848
+ $log_file_path = $this->_plugin->settings()->get_working_dir_path( '404s' ) . $filename;
 
 
 
 
849
 
850
  // Request the file.
851
  $response = file_get_contents( $log_file_path, true );
886
  */
887
  public function wsal_freemius_opt_in() {
888
  // Die if not have access.
889
+ if ( ! $this->_plugin->settings()->CurrentUserCan( 'view' ) ) {
890
  die( 'Access Denied.' );
891
  }
892
 
925
  }
926
 
927
  // Update freemius state.
928
+ $this->_plugin->SetGlobalSetting( 'freemius_state', 'in' );
929
  } elseif ( 'no' === $choice ) {
930
  if ( ! is_multisite() ) {
931
  wsal_freemius()->skip_connection(); // Opt out.
934
  }
935
 
936
  // Update freemius state.
937
+ $this->_plugin->SetGlobalSetting( 'freemius_state', 'skipped' );
938
  }
939
 
940
  echo wp_json_encode(
1024
  'searchTerm' => isset( $this->page_args->search_term ) ? $this->page_args->search_term : false,
1025
  'searchFilters' => isset( $this->page_args->search_filters ) ? $this->page_args->search_filters : false,
1026
  'viewerNonce' => wp_create_nonce( 'wsal_auditlog_viewer_nonce' ),
1027
+ 'infiniteScroll' => $this->_plugin->settings()->is_infinite_scroll(),
1028
  'userView' => ( in_array( $this->user_last_view, $this->supported_view_types(), true ) ) ? $this->user_last_view : 'list',
1029
  'installAddonStrings' => array(
1030
  'defaultButton' => esc_html( 'Install and activate extension', 'wp-security-audit-log' ),
1035
  'buttonError' => esc_html( 'Problem enabling', 'wp-security-audit-log' ),
1036
  'msgError' => sprintf(
1037
  /* translators: 1 - an opening link tag, 2 - the closing tag. */
1038
+ __( '<br>An error occurred when trying to install and activate the plugin. Please try install it again from the %1$sevent settings%2$s page.', 'wp-security-audit-log' ),
1039
+ '<a href="' . esc_url( add_query_arg( 'page', 'wsal-togglealerts#tab-third-party-plugins', network_admin_url( 'admin.php' ) ) ) . '">',
1040
  '</a>'
1041
  ),
1042
  ),
1059
 
1060
  // Don't display notice if the wizard notice is showing.
1061
  if (
1062
+ ! $this->_plugin->GetGlobalBooleanSetting( 'setup-complete', false )
1063
+ && ! $this->_plugin->GetGlobalBooleanSetting( 'setup-modal-dismissed', false )
1064
  ) {
1065
  return;
1066
  }
1077
  }
1078
 
1079
  // Get dismissed pointers.
1080
+ $dismissed = explode( ',', (string) $this->_plugin->GetGlobalSetting( 'dismissed-privacy-notice', true ) );
1081
  $valid_pointers = array();
1082
 
1083
  // Check pointers and remove dismissed ones.
1156
  */
1157
  public function wsal_exclude_url() {
1158
  // Die if user does not have permission to disable.
1159
+ if ( ! $this->_plugin->settings()->CurrentUserCan( 'edit' ) ) {
1160
  echo '<p>' . esc_html__( 'Error: You do not have sufficient permissions to exclude this URL.', 'wp-security-audit-log' ) . '</p>';
1161
  die();
1162
  }
1174
  die();
1175
  }
1176
 
1177
+ $excluded_urls = $this->_plugin->GetGlobalSetting( 'excluded-urls' );
1178
  if ( isset( $excluded_urls ) && '' !== $excluded_urls ) {
1179
  $excluded_urls .= ',' . esc_url( $post_array['url'] );
1180
  } else {
1181
  $excluded_urls = esc_url( $post_array['url'] );
1182
  }
1183
+ $this->_plugin->SetGlobalSetting( 'excluded-urls', $excluded_urls );
1184
  $settings_exclude_url = add_query_arg(
1185
  array(
1186
  'page' => 'wsal-settings',
1199
  */
1200
  public function wsal_dismiss_advert() {
1201
  // Die if user does not have permission to dismiss.
1202
+ if ( ! $this->_plugin->settings()->CurrentUserCan( 'edit' ) ) {
1203
  echo wp_json_encode(
1204
  array(
1205
  'success' => false,
1227
  }
1228
 
1229
  $advert = 2 === $advert ? '0' : $advert + 1;
1230
+ $this->_plugin->SetGlobalSetting( 'premium-advert', $advert );
1231
  $set_transient_fn = $this->_plugin->IsMultisite() ? 'set_site_transient' : 'set_transient';
1232
  $set_transient_fn( 'wsal-is-advert-dismissed', true, MONTH_IN_SECONDS );
1233
  echo wp_json_encode(
1252
  wp_die( 0 );
1253
  }
1254
 
1255
+ $dismissed = array_filter( explode( ',', (string) $this->_plugin->GetGlobalSetting( 'dismissed-privacy-notice', true ) ) );
1256
 
1257
  if ( in_array( $pointer, $dismissed ) ) {
1258
  wp_die( 0 );
1261
  $dismissed[] = $pointer;
1262
  $dismissed = implode( ',', $dismissed );
1263
 
1264
+ $this->_plugin->SetGlobalSetting( 'dismissed-privacy-notice', $dismissed );
1265
  wp_die( 1 );
1266
  }
1267
 
1272
  */
1273
  public function infinite_scroll_events() {
1274
  // Check user permissions.
1275
+ if ( ! $this->_plugin->settings()->CurrentUserCan( 'view' ) ) {
1276
  die( esc_html__( 'Access Denied', 'wp-security-audit-log' ) );
1277
  }
1278
 
classes/Views/ExternalDB.php CHANGED
@@ -111,7 +111,7 @@ class WSAL_Views_ExternalDB extends WSAL_AbstractView {
111
  * Page View.
112
  */
113
  public function Render() {
114
- $title = __( 'Audit Log Database & Integration Tools', 'wp-security-audit-log' );
115
  $description = __( 'There are several benefits to segregating the logs from the main site database, and to be able to mirror the logs to third party and centralized business solutions. Upgrade to premium and:', 'wp-security-audit-log' );
116
  $addon_img = trailingslashit( WSAL_BASE_URL ) . 'img/' . $this->GetSafeViewName() . '.jpg';
117
  $premium_list = array(
111
  * Page View.
112
  */
113
  public function Render() {
114
+ $title = __( 'Activity log database & integration tools', 'wp-security-audit-log' );
115
  $description = __( 'There are several benefits to segregating the logs from the main site database, and to be able to mirror the logs to third party and centralized business solutions. Upgrade to premium and:', 'wp-security-audit-log' );
116
  $addon_img = trailingslashit( WSAL_BASE_URL ) . 'img/' . $this->GetSafeViewName() . '.jpg';
117
  $premium_list = array(
classes/Views/Help.php CHANGED
@@ -145,7 +145,7 @@ class WSAL_Views_Help extends WSAL_AbstractView {
145
  <nav id="wsal-tabs" class="nav-tab-wrapper">
146
  <?php
147
  foreach ( $this->wsal_help_tabs as $tab_id => $tab ) :
148
- if ( 'system-info' !== $this->current_tab || ( 'system-info' === $this->current_tab && $this->_plugin->settings->CurrentUserCan( 'edit' ) ) ) :
149
  ?>
150
  <a href="<?php echo esc_url( $tab['link'] ); ?>" class="nav-tab <?php echo ( $tab_id === $this->current_tab ) ? 'nav-tab-active' : false; ?>"><?php echo esc_html( $tab['name'] ); ?></a>
151
  <?php
@@ -158,7 +158,7 @@ class WSAL_Views_Help extends WSAL_AbstractView {
158
  <div class="wsal-help-main">
159
  <?php
160
  if ( ! empty( $this->current_tab ) && ! empty( $this->wsal_help_tabs[ $this->current_tab ]['render'] ) ) {
161
- if ( 'system-info' !== $this->current_tab || ( 'system-info' === $this->current_tab && $this->_plugin->settings->CurrentUserCan( 'edit' ) ) ) {
162
  call_user_func( $this->wsal_help_tabs[ $this->current_tab ]['render'] );
163
  }
164
  }
@@ -193,7 +193,7 @@ class WSAL_Views_Help extends WSAL_AbstractView {
193
  <h2 class="wsal-tab__heading"><?php esc_html_e( 'Plugin Documentation', 'wp-security-audit-log' ); ?></h2>
194
  <p>
195
  <?php esc_html_e( 'For more technical information about the WP Activity Log plugin please visit the plugin’s knowledge base.', 'wp-security-audit-log' ); ?>
196
- <?php esc_html_e( 'Refer to the list of WordPress security events for a complete list of Events and IDs that the plugin uses to keep a log of all the changes in the WordPress audit log.', 'wp-security-audit-log' ); ?>
197
  </p><p>
198
  <a class="button" href="https://wpactivitylog.com/?utm_source=plugin&utm_medium=referral&utm_campaign=WSAL&utm_content=plugin+website" target="_blank"><?php esc_html_e( 'Plugin Website', 'wp-security-audit-log' ); ?></a>
199
  &nbsp;&nbsp;&nbsp;&nbsp;
@@ -464,7 +464,7 @@ class WSAL_Views_Help extends WSAL_AbstractView {
464
 
465
  // WSAL options.
466
  $sysinfo .= "\n" . '-- WSAL Options --' . "\n\n";
467
- $options = $this->_plugin->settings->get_wsal_options();
468
 
469
  if ( ! empty( $options ) && is_array( $options ) ) {
470
  foreach ( $options as $option ) {
@@ -482,7 +482,7 @@ class WSAL_Views_Help extends WSAL_AbstractView {
482
  * Method: Render footer content.
483
  */
484
  public function Footer() {
485
- if ( 'system-info' === $this->current_tab && $this->_plugin->settings->CurrentUserCan( 'edit' ) ) :
486
  ?>
487
  <script>
488
  /**
145
  <nav id="wsal-tabs" class="nav-tab-wrapper">
146
  <?php
147
  foreach ( $this->wsal_help_tabs as $tab_id => $tab ) :
148
+ if ( 'system-info' !== $this->current_tab || ( 'system-info' === $this->current_tab && $this->_plugin->settings()->CurrentUserCan( 'edit' ) ) ) :
149
  ?>
150
  <a href="<?php echo esc_url( $tab['link'] ); ?>" class="nav-tab <?php echo ( $tab_id === $this->current_tab ) ? 'nav-tab-active' : false; ?>"><?php echo esc_html( $tab['name'] ); ?></a>
151
  <?php
158
  <div class="wsal-help-main">
159
  <?php
160
  if ( ! empty( $this->current_tab ) && ! empty( $this->wsal_help_tabs[ $this->current_tab ]['render'] ) ) {
161
+ if ( 'system-info' !== $this->current_tab || ( 'system-info' === $this->current_tab && $this->_plugin->settings()->CurrentUserCan( 'edit' ) ) ) {
162
  call_user_func( $this->wsal_help_tabs[ $this->current_tab ]['render'] );
163
  }
164
  }
193
  <h2 class="wsal-tab__heading"><?php esc_html_e( 'Plugin Documentation', 'wp-security-audit-log' ); ?></h2>
194
  <p>
195
  <?php esc_html_e( 'For more technical information about the WP Activity Log plugin please visit the plugin’s knowledge base.', 'wp-security-audit-log' ); ?>
196
+ <?php esc_html_e( 'Refer to the list of WordPress security events for a complete list of Events and IDs that the plugin uses to keep a log of all the changes in the WordPress activity log.', 'wp-security-audit-log' ); ?>
197
  </p><p>
198
  <a class="button" href="https://wpactivitylog.com/?utm_source=plugin&utm_medium=referral&utm_campaign=WSAL&utm_content=plugin+website" target="_blank"><?php esc_html_e( 'Plugin Website', 'wp-security-audit-log' ); ?></a>
199
  &nbsp;&nbsp;&nbsp;&nbsp;
464
 
465
  // WSAL options.
466
  $sysinfo .= "\n" . '-- WSAL Options --' . "\n\n";
467
+ $options = $this->_plugin->settings()->get_wsal_options();
468
 
469
  if ( ! empty( $options ) && is_array( $options ) ) {
470
  foreach ( $options as $option ) {
482
  * Method: Render footer content.
483
  */
484
  public function Footer() {
485
+ if ( 'system-info' === $this->current_tab && $this->_plugin->settings()->CurrentUserCan( 'edit' ) ) :
486
  ?>
487
  <script>
488
  /**
classes/Views/Settings.php CHANGED
@@ -108,13 +108,6 @@ class WSAL_Views_Settings extends WSAL_AbstractView {
108
  'save' => array( $this, 'tab_exclude_objects_save' ),
109
  'priority' => 40,
110
  ),
111
- 'import-settings' => array(
112
- 'name' => __( 'Import/Export', 'wp-security-audit-log' ),
113
- 'link' => add_query_arg( 'tab', 'import-settings', $this->GetUrl() ),
114
- 'render' => array( $this, 'tab_import_settings' ),
115
- 'save' => array( $this, 'tab_import_settings_save' ),
116
- 'priority' => 40,
117
- ),
118
  'advanced-settings' => array(
119
  'name' => __( 'Advanced Settings', 'wp-security-audit-log' ),
120
  'link' => add_query_arg( 'tab', 'advanced-settings', $this->GetUrl() ),
@@ -194,7 +187,7 @@ class WSAL_Views_Settings extends WSAL_AbstractView {
194
  * @param string $token - Token type.
195
  */
196
  protected function GetTokenType( $token ) {
197
- return $this->_plugin->settings->get_token_type( $token );
198
  }
199
 
200
  /**
@@ -204,7 +197,7 @@ class WSAL_Views_Settings extends WSAL_AbstractView {
204
  */
205
  protected function Save() {
206
  // Bail early if user does not have sufficient permissions to save.
207
- if ( ! $this->_plugin->settings->CurrentUserCan( 'edit' ) ) {
208
  throw new Exception( esc_html__( 'Current user is not allowed to save settings.', 'wp-security-audit-log' ) );
209
  }
210
  // Call respective tab save functions if they are set. Nonce is already verified at this point.
@@ -219,7 +212,7 @@ class WSAL_Views_Settings extends WSAL_AbstractView {
219
  * Method: Check security token.
220
  */
221
  public function AjaxCheckSecurityToken() {
222
- if ( ! $this->_plugin->settings->CurrentUserCan( 'view' ) ) {
223
  echo wp_json_encode(
224
  array(
225
  'success' => false,
@@ -268,18 +261,18 @@ class WSAL_Views_Settings extends WSAL_AbstractView {
268
  * Method: Run cleanup.
269
  */
270
  public function AjaxRunCleanup() {
271
- if ( ! $this->_plugin->settings->CurrentUserCan( 'view' ) ) {
272
  die( 'Access Denied.' );
273
  }
274
 
275
  $now = current_time( 'timestamp' ); // Current time.
276
- $max_sdate = $this->_plugin->settings->GetPruningDate(); // Pruning date.
277
 
278
  // If archiving is enabled then events are deleted from the archive database.
279
- $archiving = $this->_plugin->settings->IsArchivingEnabled();
280
  if ( $archiving ) {
281
  // Switch to Archive DB.
282
- $this->_plugin->settings->SwitchToArchiveDB();
283
  }
284
 
285
  // Calculate limit timestamp.
@@ -328,7 +321,7 @@ class WSAL_Views_Settings extends WSAL_AbstractView {
328
  check_admin_referer( 'wsal-settings' );
329
  }
330
 
331
- if ( ! $this->_plugin->settings->CurrentUserCan( 'edit' ) ) {
332
  wp_die( esc_html__( 'You do not have sufficient permissions to access this page.', 'wp-security-audit-log' ) );
333
  }
334
 
@@ -340,18 +333,18 @@ class WSAL_Views_Settings extends WSAL_AbstractView {
340
  $this->Save(); // Save settings.
341
  if ( 'sms-provider' === $this->current_tab && $section && 'test' === $section ) :
342
  ?>
343
- <div class="updated">
344
- <p><?php esc_html_e( 'Message sent successfully.', 'wp-security-audit-log' ); ?></p>
345
- </div>
346
  <?php else : ?>
347
- <div class="updated">
348
- <p><?php esc_html_e( 'Settings have been saved.', 'wp-security-audit-log' ); ?></p>
349
- </div>
350
- <?php
351
  endif;
352
  } catch ( Exception $ex ) {
353
  ?>
354
- <div class="error"><p><?php esc_html_e( 'Error: ', 'wp-security-audit-log' ); ?><?php echo esc_html( $ex->getMessage() ); ?></p></div>
355
  <?php
356
  }
357
  }
@@ -362,34 +355,34 @@ class WSAL_Views_Settings extends WSAL_AbstractView {
362
 
363
  if ( isset( $_GET['pruning'] ) && '1' === $_GET['pruning'] ) {
364
  ?>
365
- <div class="updated">
366
- <p><?php esc_html_e( 'Old data successfully purged.', 'wp-security-audit-log' ); ?></p>
367
- </div>
368
  <?php
369
  } elseif ( isset( $_GET['pruning'] ) && '0' === $_GET['pruning'] ) {
370
  ?>
371
- <div class="error">
372
- <p><?php esc_html_e( 'No data is old enough to be purged.', 'wp-security-audit-log' ); ?></p>
373
- </div>
374
  <?php
375
  }
376
  ?>
377
- <nav id="wsal-tabs" class="nav-tab-wrapper">
378
  <?php foreach ( $this->wsal_setting_tabs as $tab_id => $tab ) : ?>
379
- <a href="<?php echo esc_url( $tab['link'] ); ?>" class="nav-tab <?php echo ( $tab_id === $this->current_tab ) ? 'nav-tab-active' : false; ?>">
380
  <?php echo esc_html( $tab['name'] ); ?>
381
- </a>
382
  <?php endforeach; ?>
383
- </nav>
384
 
385
- <form id="audit-log-settings" method="post"<?php echo 'import-settings' === $this->current_tab ? ' enctype="multipart/form-data"' : false; ?>>
386
- <input type="hidden" name="page" value="<?php echo isset( $_GET['page'] ) ? esc_attr( sanitize_text_field( wp_unslash( $_GET['page'] ) ) ) : false; ?>" />
387
- <input type="hidden" id="ajaxurl" value="<?php echo esc_attr( admin_url( 'admin-ajax.php' ) ); ?>" />
388
  <?php wp_nonce_field( 'wsal-settings' ); ?>
389
 
390
- <div id="audit-log-adverts">
391
- </div>
392
- <div class="nav-tabs">
393
  <?php
394
  if ( ! empty( $this->current_tab ) && ! empty( $this->wsal_setting_tabs[ $this->current_tab ]['render'] ) ) {
395
  call_user_func( $this->wsal_setting_tabs[ $this->current_tab ]['render'] );
@@ -397,52 +390,52 @@ class WSAL_Views_Settings extends WSAL_AbstractView {
397
  call_user_func( $this->wsal_setting_tabs['general']['render'] );
398
  }
399
  ?>
400
- </div>
401
  <?php
402
  if ( 'sms-provider' === $this->current_tab && $section && 'test' === $section ) {
403
  submit_button( __( 'Send Message', 'wp-security-audit-log' ) );
404
- } elseif ( 'import-settings' !== $this->current_tab ) {
405
  submit_button();
406
  }
407
  ?>
408
- </form>
409
- <script type="text/javascript">
410
- <!--
411
- function delete_confirm(elementRef) {
412
- if (elementRef.checked) {
413
- if ( window.confirm('Do you want remove all data when the plugin is deleted?') == false )
414
- elementRef.checked = false;
415
- }
416
- }
417
-
418
- jQuery( document ).ready( function() {
419
- // Enable/disable setting.
420
- function wsal_update_setting( checkbox, setting ) {
421
- if ( checkbox.prop( 'checked' ) ) {
422
- setting.removeProp( 'disabled' );
423
- } else {
424
- setting.prop( 'disabled', 'disabled' );
425
- }
426
- }
427
-
428
- // Login page notification settings.
429
- var login_page_notif = jQuery( 'input[name=login_page_notification]' );
430
- var login_page_notif_text = jQuery( '#login_page_notification_text' );
431
-
432
- // Check the change event on checkbox.
433
- login_page_notif.on( 'change', function() {
434
- wsal_update_setting( login_page_notif, login_page_notif_text );
435
- } );
436
-
437
- // Proxy settings.
438
- var proxy_ip_setting = jQuery( 'input[name=EnableProxyIpCapture]' );
439
- var ip_filtering = jQuery( '#EnableIpFiltering' );
440
- wsal_update_setting( proxy_ip_setting, ip_filtering );
441
- proxy_ip_setting.on( 'change', function() {
442
- wsal_update_setting( proxy_ip_setting, ip_filtering );
443
- } );
444
- } );
445
- // --></script>
446
  <?php
447
  }
448
 
@@ -451,10 +444,10 @@ class WSAL_Views_Settings extends WSAL_AbstractView {
451
  */
452
  private function tab_general() {
453
  ?>
454
- <p class="description"><?php echo wp_kses( __( 'Need help with setting up the plugin to meet your requirements? <a href="https://wpactivitylog.com/contact/?utm_source=plugin&utm_medium=referral&utm_campaign=WSAL&utm_content=settings+pages" target="_blank">Schedule a 20 minutes consultation and setup call</a> with our experts for just $50.', 'wp-security-audit-log' ), $this->_plugin->allowed_html_tags ); ?></p>
455
 
456
- <h3><?php esc_html_e( 'Use infinite scroll or pagination for the event viewer?', 'wp-security-audit-log' ); ?></h3>
457
- <p class="description">
458
  <?php
459
  echo sprintf(
460
  /* translators: Learn more link. */
@@ -462,211 +455,211 @@ class WSAL_Views_Settings extends WSAL_AbstractView {
462
  '<a href="https://wpactivitylog.com/features/search-filters-wordpress-activity-log/?utm_source=plugin&utm_medium=referral&utm_campaign=WSAL&utm_content=settings+pages" target="_blank">' . esc_html__( '(Premium feature)', 'wp-security-audit-log' ) . '</a>'
463
  );
464
  ?>
465
- </p>
466
- <table class="form-table wsal-tab">
467
- <tbody>
468
- <tr>
469
- <th><label for="infinite-scroll"><?php esc_html_e( 'Select event viewer view type:', 'wp-security-audit-log' ); ?></label></th>
470
- <td>
471
- <fieldset>
472
- <label for="infinite-scroll">
473
- <input type="radio" name="events-type-nav" value="infinite-scroll" id="infinite-scroll" <?php checked( $this->_plugin->settings->get_events_type_nav(), 'infinite-scroll' ); ?> />
474
- <?php esc_html_e( 'Infinite Scroll (Recommended)', 'wp-security-audit-log' ); ?>
475
- </label>
476
- <br/>
477
- <label for="pagination">
478
- <input type="radio" name="events-type-nav" value="pagination" id="pagination" <?php checked( $this->_plugin->settings->get_events_type_nav(), 'pagination' ); ?> />
479
- <?php esc_html_e( 'Pagination', 'wp-security-audit-log' ); ?>
480
- </label>
481
- <br />
482
- </fieldset>
483
- </td>
484
- </tr>
485
- <!-- / Reverse Proxy / Firewall Options -->
486
- </tbody>
487
- </table>
488
- <!-- Events Navigation Type -->
489
-
490
- <h3><?php esc_html_e( 'Do you want the activity log viewer to auto refresh?', 'wp-security-audit-log' ); ?></h3>
491
- <p class="description"><?php esc_html_e( 'The activity log viewer auto refreshes every 30 seconds when opened so you can see the latest events as they happen almost in real time.', 'wp-security-audit-log' ); ?></p>
492
- <table class="form-table wsal-tab">
493
- <tbody>
494
- <tr>
495
- <th><label for="aroption_on"><?php esc_html_e( 'Refresh Audit Log Viewer', 'wp-security-audit-log' ); ?></label></th>
496
- <td>
497
- <fieldset>
498
- <?php $are = $this->_plugin->settings->IsRefreshAlertsEnabled(); ?>
499
- <label for="aroption_on">
500
- <input type="radio" name="EnableAuditViewRefresh" id="aroption_on" style="margin-top: -2px;" <?php checked( $are ); ?> value="1">
501
- <span><?php esc_html_e( 'Auto refresh', 'wp-security-audit-log' ); ?></span>
502
- </label>
503
- <br/>
504
- <label for="aroption_off">
505
- <input type="radio" name="EnableAuditViewRefresh" id="aroption_off" style="margin-top: -2px;" <?php checked( $are, false ); ?> value="0">
506
- <span><?php esc_html_e( 'Do not auto refresh', 'wp-security-audit-log' ); ?></span>
507
- </label>
508
- </fieldset>
509
- </td>
510
- </tr>
511
- <!-- Refresh Audit Log Viewer -->
512
- </tbody>
513
- </table>
514
- <!-- Refresh Audit Log -->
515
-
516
- <h3><?php esc_html_e( 'Display latest events widget in Dashboard & Admin bar', 'wp-security-audit-log' ); ?></h3>
517
- <p class="description">
518
  <?php
519
  echo sprintf(
520
  /* translators: Max number of dashboard widget alerts. */
521
  esc_html__( 'The events widget displays the latest %d security events in the dashboard and the admin bar notification displays the latest event.', 'wp-security-audit-log' ),
522
- esc_html( $this->_plugin->settings->GetDashboardWidgetMaxAlerts() )
523
  );
524
  ?>
525
- </p>
526
- <table class="form-table wsal-tab">
527
- <tbody>
528
- <tr>
529
- <th><label for="dwoption_on"><?php esc_html_e( 'Dashboard Widget', 'wp-security-audit-log' ); ?></label></th>
530
- <td>
531
- <fieldset>
532
- <?php $dwe = $this->_plugin->settings->IsWidgetsEnabled(); ?>
533
- <label for="dwoption_on">
534
- <input type="radio" name="EnableDashboardWidgets" id="dwoption_on" style="margin-top: -2px;" <?php checked( $dwe ); ?> value="1">
535
- <span><?php esc_html_e( 'Yes', 'wp-security-audit-log' ); ?></span>
536
- </label>
537
- <br/>
538
- <label for="dwoption_off">
539
- <input type="radio" name="EnableDashboardWidgets" id="dwoption_off" style="margin-top: -2px;" <?php checked( $dwe, false ); ?> value="0">
540
- <span><?php esc_html_e( 'No', 'wp-security-audit-log' ); ?></span>
541
- </label>
542
- </fieldset>
543
- </td>
544
- </tr>
545
- <!-- / Events Dashboard Widget -->
546
-
547
- <tr>
548
- <?php
549
- $disabled = '';
550
- $label = __( 'Admin Bar Notification', 'wp-security-audit-log' );
551
- if ( wsal_freemius()->is_free_plan() ) {
552
- $disabled = 'disabled';
553
- $label = __( 'Admin Bar Notification (Premium)', 'wp-security-audit-log' );
554
- }
555
- ?>
556
- <th><label for="admin_bar_notif_on"><?php echo esc_html( $label ); ?></label></th>
557
- <td>
558
- <fieldset <?php echo esc_attr( $disabled ); ?>>
559
- <?php $abn = $this->_plugin->settings->is_admin_bar_notif(); ?>
560
- <label for="admin_bar_notif_on">
561
- <input type="radio" name="admin_bar_notif" id="admin_bar_notif_on" style="margin-top: -2px;" <?php checked( $abn ); ?> value="1">
562
- <span><?php esc_html_e( 'Yes', 'wp-security-audit-log' ); ?></span>
563
- </label>
564
- <br/>
565
- <label for="admin_bar_notif_off">
566
- <input type="radio" name="admin_bar_notif" id="admin_bar_notif_off" style="margin-top: -2px;" <?php checked( $abn, false ); ?> value="0">
567
- <span><?php esc_html_e( 'No', 'wp-security-audit-log' ); ?></span>
568
- </label>
569
- </fieldset>
570
- </td>
571
- </tr>
572
- <!-- / Admin Bar Notification -->
573
-
574
- <tr>
575
- <?php
576
- $disabled = '';
577
- $label = __( 'Admin Bar Notification Updates', 'wp-security-audit-log' );
578
- if ( wsal_freemius()->is_free_plan() ) {
579
- $disabled = 'disabled';
580
- $label = __( 'Admin Bar Notification Updates (Premium)', 'wp-security-audit-log' );
581
- }
582
- ?>
583
- <th><label for="admin_bar_notif_refresh"><?php echo esc_html( $label ); ?></label></th>
584
- <td>
585
- <fieldset <?php echo esc_attr( $disabled ); ?>>
586
- <?php $abn_updates = $this->_plugin->settings->get_admin_bar_notif_updates(); ?>
587
- <label for="admin_bar_notif_realtime">
588
- <input type="radio" name="admin_bar_notif_updates" id="admin_bar_notif_realtime" style="margin-top: -2px;" <?php checked( $abn_updates, 'real-time' ); ?> value="real-time">
589
- <span><?php esc_html_e( 'Update in near real time', 'wp-security-audit-log' ); ?></span>
590
- </label>
591
- <br/>
592
- <label for="admin_bar_notif_refresh">
593
- <input type="radio" name="admin_bar_notif_updates" id="admin_bar_notif_refresh" style="margin-top: -2px;" <?php checked( $abn_updates, 'page-refresh' ); ?> value="page-refresh">
594
- <span><?php esc_html_e( 'Update only on page refreshes', 'wp-security-audit-log' ); ?></span>
595
- </label>
596
- </fieldset>
597
- </td>
598
- </tr>
599
- <!-- / Admin Bar Notification Updates -->
600
- </tbody>
601
- </table>
602
- <!-- Dashboard Widget -->
603
-
604
- <h3><?php esc_html_e( 'Add user notification on the WordPress login page', 'wp-security-audit-log' ); ?></h3>
605
- <p class="description"><?php esc_html_e( 'Many compliance regulations (such as the GDPR) require website administrators to tell the users of their website that all the changes they do when logged in are being logged.', 'wp-security-audit-log' ); ?></p>
606
- <table class="form-table wsal-tab">
607
- <tbody>
608
- <tr>
609
- <th><label for="login_page_notification"><?php esc_html_e( 'Login Page Notification', 'wp-security-audit-log' ); ?></label></th>
610
- <td>
611
- <fieldset>
612
- <?php
613
- // Get login page notification checkbox.
614
- $wsal_lpn = $this->_plugin->settings->is_login_page_notification();
615
- if ( $wsal_lpn && 'true' === $wsal_lpn ) {
616
- // If option exists, value is true then set to true.
617
- $wsal_lpn = true;
618
- } elseif ( $wsal_lpn && 'false' === $wsal_lpn ) {
619
- // If option exists, value is false then set to false.
620
- $wsal_lpn = false;
621
- } elseif ( ! $wsal_lpn ) {
622
- // Default option value.
623
- $wsal_lpn = false;
624
- }
625
- ?>
626
- <label for="wsal_lpn_yes">
627
- <input type="radio" name="login_page_notification" id="wsal_lpn_yes" <?php checked( $wsal_lpn ); ?> value="true" />
628
- <?php esc_html_e( 'Yes', 'wp-security-audit-log' ); ?>
629
- </label>
630
- <br />
631
- <?php
632
- // Get login page notification text.
633
- $wsal_lpn_text = $this->_plugin->settings->get_login_page_notification_text();
634
- $wsal_lpn_text_default = __( 'For security and auditing purposes, a record of all of your logged-in actions and changes within the WordPress dashboard will be recorded in an audit log with the <a href="https://wpactivitylog.com/?utm_source=plugin&utm_medium=referral&utm_campaign=WSAL&utm_content=settings+pages" target="_blank">WP Activity Log plugin</a>. The audit log also includes the IP address where you accessed this site from.', 'wp-security-audit-log' );
635
-
636
- // Allowed HTML tags for this setting.
637
- $allowed_tags = array(
638
- 'a' => array(
639
- 'href' => array(),
640
- 'title' => array(),
641
- 'target' => array(),
642
- ),
643
- );
644
- ?>
645
- <textarea name="login_page_notification_text"
646
- id="login_page_notification_text"
647
- cols="60" rows="6"
648
  <?php echo ( $wsal_lpn ) ? false : 'disabled'; ?>
649
  ><?php echo ( $wsal_lpn_text ) ? wp_kses( $wsal_lpn_text, $allowed_tags ) : wp_kses( $wsal_lpn_text_default, $allowed_tags ); ?></textarea>
650
- <br/>
651
- <p class="description">
652
- <?php echo wp_kses( __( '<strong>Note: </strong>', 'wp-security-audit-log' ), $this->_plugin->allowed_html_tags ) . esc_html__( 'The only HTML code allowed in the login page notification is for links ( < a href >< /a > ).', 'wp-security-audit-log' ); ?>
653
- </p>
654
- <br />
655
-
656
- <label for="wsal_lpn_no">
657
- <input type="radio" name="login_page_notification" id="wsal_lpn_no" <?php checked( $wsal_lpn, false ); ?> value="false" />
658
- <?php esc_html_e( 'No', 'wp-security-audit-log' ); ?>
659
- </label>
660
- </fieldset>
661
- </td>
662
- </tr>
663
- <!-- / Login Page Notification -->
664
- </tbody>
665
- </table>
666
- <!-- Login Page Notification -->
667
-
668
- <h3><?php esc_html_e( 'Is your website running behind a firewall or reverse proxy?', 'wp-security-audit-log' ); ?></h3>
669
- <p class="description">
670
  <?php
671
  echo sprintf(
672
  /* translators: Learn more link. */
@@ -674,110 +667,146 @@ class WSAL_Views_Settings extends WSAL_AbstractView {
674
  '<a href="https://wpactivitylog.com/support/kb/support-reverse-proxies-web-application-firewalls/?utm_source=plugin&utm_medium=referral&utm_campaign=WSAL&utm_content=settings+pages" target="_blank">' . esc_html__( 'learn more', 'wp-security-audit-log' ) . '</a>'
675
  );
676
  ?>
677
- </p>
678
- <table class="form-table wsal-tab">
679
- <tbody>
680
- <tr>
681
- <th><label for="pioption_on"><?php esc_html_e( 'Reverse Proxy / Firewall Options', 'wp-security-audit-log' ); ?></label></th>
682
- <td>
683
- <fieldset>
684
- <label for="enable_proxy_ip_capture_yes">
685
- <input type="radio" name="EnableProxyIpCapture" value="1" id="enable_proxy_ip_capture_yes" <?php checked( $this->_plugin->settings->IsMainIPFromProxy() ); ?> />
686
- <?php esc_html_e( 'Yes', 'wp-security-audit-log' ); ?>
687
- </label>
688
- <br/>
689
- <label for="EnableIpFiltering">
690
- <input type="checkbox" name="EnableIpFiltering" value="1" id="EnableIpFiltering" <?php checked( $this->_plugin->settings->IsInternalIPsFiltered() ); ?> />
691
- <?php esc_html_e( 'Filter internal IP addresses from the proxy headers. Enable this option only if you are are still seeing the internal IP addresses of the firewall or proxy.', 'wp-security-audit-log' ); ?>
692
- </label>
693
- <br/>
694
- <label for="enable_proxy_ip_capture_no">
695
- <input type="radio" name="EnableProxyIpCapture" value="0" id="enable_proxy_ip_capture_no" <?php checked( $this->_plugin->settings->IsMainIPFromProxy(), false ); ?> />
696
- <?php esc_html_e( 'No', 'wp-security-audit-log' ); ?>
697
- </label>
698
- <br />
699
- </fieldset>
700
- </td>
701
- </tr>
702
- <!-- / Reverse Proxy / Firewall Options -->
703
- </tbody>
704
- </table>
705
- <!-- Reverse Proxy -->
706
-
707
- <h3><?php esc_html_e( 'Who can change the plugin settings?', 'wp-security-audit-log' ); ?></h3>
708
- <p class="description">
709
- <?php
710
- $allowed_tags = array(
711
- 'a' => array(
712
- 'href' => true,
713
- 'target' => true,
714
- ),
715
- );
716
- echo wp_kses(
717
- sprintf(
718
  /* translators: Learn more link. */
719
- esc_html__( 'By default only users with administrator role (single site) and super administrator role (multisite) can change the settings of the plugin. Though you can restrict the privileges to just your user - %s.', 'wp-security-audit-log' ),
720
- '<a href="https://wpactivitylog.com/support/kb/managing-wordpress-activity-log-plugin-privileges/?utm_source=plugin&utm_medium=referral&utm_campaign=WSAL&utm_content=settings+pages" target="_blank">' . __( 'learn more', 'wp-security-audit-log' ) . '</a>'
721
- ),
722
- $allowed_tags
723
- );
724
- ?>
725
- </p>
726
- <table class="form-table wsal-tab">
727
- <tbody>
728
- <tr>
729
- <th><label for="RestrictAdmins"><?php esc_html_e( 'Restrict Plugin Access', 'wp-security-audit-log' ); ?></label></th>
730
- <td>
731
- <fieldset>
732
- <?php $restrict_settings = $this->_plugin->settings->get_restrict_plugin_setting(); ?>
733
- <label for="only_me">
734
- <input type="radio" name="restrict-plugin-settings" id="only_me" value="only_me" <?php checked( $restrict_settings, 'only_me' ); ?> />
735
- <?php esc_html_e( 'Only me', 'wp-security-audit-log' ); ?>
736
- </label>
737
- <br/>
738
- <label for="only_admins">
739
- <input type="radio" name="restrict-plugin-settings" id="only_admins" value="only_admins" <?php checked( $restrict_settings, 'only_admins' ); ?> />
740
- <?php
741
- if ( $this->_plugin->IsMultisite() ) {
742
- esc_html_e( 'Only superadmins', 'wp-security-audit-log' );
743
- } else {
744
- esc_html_e( 'Only administrators', 'wp-security-audit-log' );
745
- }
746
- ?>
747
- <?php ?>
748
- </label>
749
- <br/>
750
- </fieldset>
751
- </td>
752
- </tr>
753
- <!-- / Restrict Plugin Access -->
754
- </tbody>
755
- </table>
756
- <!-- Restrict Plugin Access -->
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
757
 
758
- <h3><?php esc_html_e( 'Allow other users to view the activity log', 'wp-security-audit-log' ); ?></h3>
759
- <p class="description">
760
- <?php
761
- $allowed_tags = array(
762
- 'a' => array(
763
- 'href' => true,
764
- 'target' => true,
765
- ),
766
- );
767
- echo wp_kses(
768
- sprintf(
769
- /* translators: Learn more link. */
770
- esc_html__( 'By default only users with administrator and super administrator (multisite) role can view the WordPress activity log. Though you can allow other users with no admin role to view the events - %s.', 'wp-security-audit-log' ),
771
- '<a href="https://wpactivitylog.com/support/kb/allow-users-read-access-activity-log/?utm_source=plugin&utm_medium=referral&utm_campaign=WSAL&utm_content=settings+pages" target="_blank">' . __( 'learn more', 'wp-security-audit-log' ) . '</a>'
772
- ),
773
- $allowed_tags
774
- );
775
- ?>
776
- </p>
777
- <table class="form-table wsal-tab">
778
- <tbody>
779
  <tr>
780
- <th><label for="ViewerQueryBox"><?php esc_html_e( 'Can View Events', 'wp-security-audit-log' ); ?></label></th>
 
781
  <td>
782
  <fieldset>
783
  <label>
@@ -791,7 +820,7 @@ class WSAL_Views_Settings extends WSAL_AbstractView {
791
 
792
  <div id="ViewerList">
793
  <?php
794
- foreach ( $this->_plugin->settings->GetAllowedPluginViewers() as $item ) :
795
  if ( wp_get_current_user()->user_login === $item ) {
796
  continue;
797
  }
@@ -819,7 +848,7 @@ class WSAL_Views_Settings extends WSAL_AbstractView {
819
  <th><label for="FromEmail"><?php esc_html_e( 'From Email & Name', 'wp-security-audit-log' ); ?></label></th>
820
  <td>
821
  <fieldset>
822
- <?php $use_email = $this->_plugin->GetGlobalOption( 'use-email', 'default_email' ); ?>
823
  <label for="default_email">
824
  <input type="radio" name="use-email" id="default_email" value="default_email" <?php checked( $use_email, 'default_email' ); ?> />
825
  <?php esc_html_e( 'Use the email address from the WordPress general settings', 'wp-security-audit-log' ); ?>
@@ -832,12 +861,12 @@ class WSAL_Views_Settings extends WSAL_AbstractView {
832
  <br>
833
  <label for="FromEmail">
834
  <?php esc_html_e( 'Email Address', 'wp-security-audit-log' ); ?>
835
- <input type="email" id="FromEmail" name="FromEmail" value="<?php echo esc_attr( $this->_plugin->settings->GetFromEmail() ); ?>" />
836
  </label>
837
  <br>
838
  <label for="DisplayName">
839
  <?php esc_html_e( 'Display Name', 'wp-security-audit-log' ); ?>&nbsp;
840
- <input type="text" id="DisplayName" name="DisplayName" value="<?php echo esc_attr( $this->_plugin->settings->GetDisplayName() ); ?>" />
841
  </label>
842
  </fieldset>
843
  </td>
@@ -856,12 +885,12 @@ class WSAL_Views_Settings extends WSAL_AbstractView {
856
  <td>
857
  <fieldset>
858
  <label for="incognito_yes">
859
- <input type="radio" name="Incognito" value="1" id="incognito_yes" <?php checked( $this->_plugin->settings->IsIncognito() ); ?> />
860
  <?php esc_html_e( 'Yes, hide the plugin from the list of installed plugins', 'wp-security-audit-log' ); ?>
861
  </label>
862
  <br/>
863
  <label for="incognito_no">
864
- <input type="radio" name="Incognito" value="0" id="incognito_no" <?php checked( $this->_plugin->settings->IsIncognito(), false ); ?> />
865
  <?php esc_html_e( 'No, do not hide the plugin', 'wp-security-audit-log' ); ?>
866
  </label>
867
  </fieldset>
@@ -881,50 +910,46 @@ class WSAL_Views_Settings extends WSAL_AbstractView {
881
  // Get $_POST global array.
882
  $post_array = filter_input_array( INPUT_POST );
883
 
884
- $this->_plugin->settings->SetRefreshAlertsEnabled( $post_array['EnableAuditViewRefresh'] );
885
- $this->_plugin->settings->set_events_type_nav( sanitize_text_field( $post_array['events-type-nav'] ) );
886
- $this->_plugin->settings->set_use_email( sanitize_text_field( $post_array['use-email'] ) );
887
- $this->_plugin->settings->SetFromEmail( sanitize_email( $post_array['FromEmail'] ) );
888
- $this->_plugin->settings->SetDisplayName( sanitize_text_field( $post_array['DisplayName'] ) );
889
 
890
- $this->_plugin->settings->SetWidgetsEnabled( sanitize_text_field( $post_array['EnableDashboardWidgets'] ) );
891
 
892
  if ( ! wsal_freemius()->is_free_plan() ) {
893
- $this->_plugin->settings->set_admin_bar_notif( sanitize_text_field( $post_array['admin_bar_notif'] ) );
894
- $this->_plugin->settings->set_admin_bar_notif_updates( sanitize_text_field( $post_array['admin_bar_notif_updates'] ) );
 
 
 
 
 
 
 
 
 
895
  }
896
 
897
  // Get plugin viewers.
898
  $viewers = isset( $post_array['Viewers'] ) ? array_map( 'sanitize_text_field', $post_array['Viewers'] ) : array();
899
- $this->_plugin->settings->SetAllowedPluginViewers( $viewers );
900
 
901
- // Get plugin editors.
902
- $editors = isset( $post_array['Editors'] ) ? array_map( 'sanitize_text_field', $post_array['Editors'] ) : array();
903
  $restrict_settings = isset( $post_array['restrict-plugin-settings'] ) ? sanitize_text_field( $post_array['restrict-plugin-settings'] ) : false;
904
- if ( ! empty( $restrict_settings ) ) {
905
- if ( 'only_me' === $restrict_settings ) {
906
- // Add current username to plugin editors.
907
- $editors = array(); // Empty the array to remove previous editors in restrict mode.
908
- $editors[] = wp_get_current_user()->user_login;
909
- } elseif ( 'only_selected_users' !== $restrict_settings ) {
910
- // Empty the editors if option is not user or user roles.
911
- $editors = array();
912
- }
913
  }
914
- $this->_plugin->settings->SetAllowedPluginEditors( $editors );
915
 
916
- if ( ! empty( $restrict_settings ) && 'only_me' === $restrict_settings ) {
917
- $this->_plugin->settings->SetRestrictAdmins( true );
918
- } else {
919
- $this->_plugin->settings->SetRestrictAdmins( false );
920
- }
921
 
922
- $this->_plugin->settings->set_restrict_plugin_setting( $restrict_settings );
923
- $this->_plugin->settings->set_login_page_notification( isset( $post_array['login_page_notification'] ) ? sanitize_text_field( $post_array['login_page_notification'] ) : false );
924
- $this->_plugin->settings->set_login_page_notification_text( isset( $post_array['login_page_notification_text'] ) ? $post_array['login_page_notification_text'] : false );
925
- $this->_plugin->settings->SetMainIPFromProxy( isset( $post_array['EnableProxyIpCapture'] ) ? sanitize_text_field( $post_array['EnableProxyIpCapture'] ) : false );
926
- $this->_plugin->settings->SetInternalIPsFiltering( isset( $post_array['EnableIpFiltering'] ) ? sanitize_text_field( $post_array['EnableIpFiltering'] ) : false );
927
- $this->_plugin->settings->SetIncognito( isset( $post_array['Incognito'] ) ? sanitize_text_field( $post_array['Incognito'] ) : false );
928
  }
929
 
930
  /**
@@ -932,21 +957,17 @@ class WSAL_Views_Settings extends WSAL_AbstractView {
932
  */
933
  private function tab_audit_log() {
934
  ?>
935
- <h3><?php esc_html_e( 'For how long do you want to keep the activity log events (Retention settings) ?', 'wp-security-audit-log' ); ?></h3>
936
- <p class="description">
937
  <?php
938
  esc_html_e( 'The plugin uses an efficient way to store the activity log data in the WordPress database, though the more data you keep the more disk space will be required. ', 'wp-security-audit-log' );
939
  $retention_help_text = __( '<a href="https://wpactivitylog.com/pricing/?utm_source=plugin&utm_medium=referral&utm_campaign=WSAL&utm_content=settings+pages" target="_blank">Upgrade to Premium</a> to store the activity log data in an external database.', 'wp-security-audit-log' );
940
 
941
- if ( wsal_freemius()->is__premium_only() ) {
942
- // If premium version then remove this message.
943
- $retention_help_text = '';
944
- }
945
  echo wp_kses( $retention_help_text, $this->_plugin->allowed_html_tags );
946
  ?>
947
- </p>
948
- <?php if ( $this->_plugin->settings->IsArchivingEnabled() ) : ?>
949
- <p class="description">
950
  <?php
951
  $archiving_args = array(
952
  'page' => 'wsal-ext-settings',
@@ -956,15 +977,15 @@ class WSAL_Views_Settings extends WSAL_AbstractView {
956
  /* translators: 1: Archive page link tag. 2: Link closing tag. */
957
  echo '<span class="dashicons dashicons-warning"></span> ' . sprintf( esc_html__( 'Retention settings moved to %1$s archiving settings %2$s because archiving is enabled', 'wp-security-audit-log' ), '<a href="' . esc_url( $archiving_page ) . '" target="_blank">', '</a>' );
958
  ?>
959
- </p>
960
  <?php else : ?>
961
  <table class="form-table wsal-tab">
962
  <tbody>
963
  <tr>
964
- <th><label for="delete1"><?php esc_html_e( 'Audit Log Retention', 'wp-security-audit-log' ); ?></label></th>
965
  <td>
966
  <fieldset>
967
- <?php $nbld = ! $this->_plugin->settings->IsPruningDateEnabled(); ?>
968
  <label for="delete0">
969
  <input type="radio" id="delete0" name="PruneBy" value="" <?php checked( $nbld ); ?> />
970
  <?php echo esc_html__( 'Keep all data', 'wp-security-audit-log' ); ?>
@@ -974,22 +995,22 @@ class WSAL_Views_Settings extends WSAL_AbstractView {
974
  <fieldset>
975
  <?php
976
  // Check pruning date option.
977
- $nbld = $this->_plugin->settings->IsPruningDateEnabled();
978
 
979
  // Find and replace ` months` in the string.
980
- $pruning_date = $this->_plugin->settings->GetPruningDate();
981
  $pruning_date = str_replace( ' months', '', $pruning_date );
982
  $pruning_date = str_replace( ' years', '', $pruning_date );
983
- $pruning_unit = $this->_plugin->settings->get_pruning_unit();
984
 
985
  // Check if pruning limit was enabled for backwards compatibility.
986
- if ( $this->_plugin->settings->IsPruningLimitEnabled() ) {
987
  $nbld = true;
988
  $pruning_date = '6';
989
  $pruning_unit = 'months';
990
- $this->_plugin->settings->SetPruningDate( $pruning_date . ' ' . $pruning_unit );
991
- $this->_plugin->settings->SetPruningDateEnabled( true );
992
- $this->_plugin->settings->SetPruningLimitEnabled( false );
993
  }
994
  ?>
995
  <label for="delete1">
@@ -1006,7 +1027,7 @@ class WSAL_Views_Settings extends WSAL_AbstractView {
1006
  </select>
1007
  </fieldset>
1008
 
1009
- <?php if ( $this->_plugin->settings->IsPruningDateEnabled() ) : ?>
1010
  <p class="description">
1011
  <?php
1012
  $next = wp_next_scheduled( 'wsal_cleanup' );
@@ -1026,11 +1047,11 @@ class WSAL_Views_Settings extends WSAL_AbstractView {
1026
  <?php endif; ?>
1027
  </td>
1028
  </tr>
1029
- <!-- Audit Log Retention -->
1030
  </tbody>
1031
  </table>
1032
  <?php endif; ?>
1033
- <!-- Audit Log Retention -->
1034
 
1035
  <h3><?php esc_html_e( 'What timestamp you would like to see in the WordPress activity log?', 'wp-security-audit-log' ); ?></h3>
1036
  <p class="description"><?php esc_html_e( 'Note that the WordPress\' timezone might be different from that configured on the server so when you switch from UTC to WordPress timezone or vice versa you might notice a big difference.', 'wp-security-audit-log' ); ?></p>
@@ -1041,7 +1062,7 @@ class WSAL_Views_Settings extends WSAL_AbstractView {
1041
  <td>
1042
  <fieldset>
1043
  <?php
1044
- $timezone = $this->_plugin->settings->GetTimezone();
1045
 
1046
  /**
1047
  * Transform timezone values.
@@ -1073,19 +1094,10 @@ class WSAL_Views_Settings extends WSAL_AbstractView {
1073
  <th><?php esc_html_e( 'Show Milliseconds', 'wp-security-audit-log' ); ?></th>
1074
  <td>
1075
  <fieldset>
1076
- <?php
1077
- $show_milliseconds = $this->_plugin->settings->get_show_milliseconds();
1078
-
1079
- /**
1080
- * Transform microsecond values incase of bool.
1081
- */
1082
- if ( 'no' !== $show_milliseconds ) {
1083
- $show_milliseconds = 'yes';
1084
- }
1085
- ?>
1086
  <label for="show_milliseconds">
1087
  <input type="checkbox" name="show_milliseconds" id="show_milliseconds" style="margin-top: -2px;"
1088
- <?php checked( $show_milliseconds, 'yes' ); ?> value="yes">
1089
  <?php esc_html_e( 'Show Milliseconds in list view', 'wp-security-audit-log' ); ?>
1090
  </label>
1091
  </fieldset>
@@ -1101,23 +1113,23 @@ class WSAL_Views_Settings extends WSAL_AbstractView {
1101
  <table class="form-table wsal-tab">
1102
  <tbody>
1103
  <tr>
1104
- <th><label for="timezone-default"><?php esc_html_e( 'User Information in Audit Log', 'wp-security-audit-log' ); ?></label></th>
1105
  <td>
1106
  <fieldset>
1107
- <?php $type_username = $this->_plugin->settings->get_type_username(); ?>
1108
  <label for="column_username">
1109
  <input type="radio" name="type_username" id="column_username" style="margin-top: -2px;" <?php checked( $type_username, 'username' ); ?> value="username">
1110
- <span><?php esc_html_e( 'WordPress Username', 'wp-security-audit-log' ); ?></span>
1111
  </label>
1112
  <br/>
1113
  <label for="columns_first_last_name">
1114
  <input type="radio" name="type_username" id="columns_first_last_name" style="margin-top: -2px;" <?php checked( $type_username, 'first_last_name' ); ?> value="first_last_name">
1115
- <span><?php esc_html_e( 'First Name & Last Name', 'wp-security-audit-log' ); ?></span>
1116
  </label>
1117
  <br/>
1118
  <label for="columns_display_name">
1119
  <input type="radio" name="type_username" id="columns_display_name" style="margin-top: -2px;" <?php checked( $type_username, 'display_name' ); ?> value="display_name">
1120
- <span><?php esc_html_e( 'Configured Public Display Name', 'wp-security-audit-log' ); ?></span>
1121
  </label>
1122
  </fieldset>
1123
  </td>
@@ -1132,10 +1144,10 @@ class WSAL_Views_Settings extends WSAL_AbstractView {
1132
  <table class="form-table wsal-tab">
1133
  <tbody>
1134
  <tr>
1135
- <th><label for="columns"><?php esc_html_e( 'Audit Log Columns Selection', 'wp-security-audit-log' ); ?></label></th>
1136
  <td>
1137
  <fieldset>
1138
- <?php $columns = $this->_plugin->settings->GetColumns(); ?>
1139
  <?php foreach ( $columns as $key => $value ) { ?>
1140
  <label for="columns">
1141
  <input type="checkbox" name="Columns[<?php echo esc_attr( $key ); ?>]" id="<?php echo esc_attr( $key ); ?>" class="sel-columns" style="margin-top: -2px;"
@@ -1161,11 +1173,12 @@ class WSAL_Views_Settings extends WSAL_AbstractView {
1161
  </fieldset>
1162
  </td>
1163
  </tr>
1164
- <!-- Audit Log Columns Selection -->
1165
  </tbody>
1166
  </table>
1167
- <!-- Audit Log Columns -->
1168
 
 
1169
  <h3><?php esc_html_e( 'Do you want to keep a log of WordPress background activity?', 'wp-security-audit-log' ); ?></h3>
1170
  <p class="description">
1171
  <?php esc_html_e( 'WordPress does a lot of things in the background that you do not necessarily need to know about, such as; deletion of post revisions, deletion of auto saved drafts etc. By default the plugin does not report them since there might be a lot and are irrelevant to the user.', 'wp-security-audit-log' ); ?>
@@ -1177,12 +1190,12 @@ class WSAL_Views_Settings extends WSAL_AbstractView {
1177
  <td>
1178
  <fieldset>
1179
  <label for="wp_backend_yes">
1180
- <input type="radio" name="WPBackend" value="1" id="wp_backend_yes" <?php checked( $this->_plugin->settings->IsWPBackend() ); ?> />
1181
  <?php esc_html_e( 'Yes', 'wp-security-audit-log' ); ?>
1182
  </label>
1183
  <br/>
1184
  <label for="wp_backend_no">
1185
- <input type="radio" name="WPBackend" value="0" id="wp_backend_no" <?php checked( $this->_plugin->settings->IsWPBackend(), false ); ?> />
1186
  <?php esc_html_e( 'No', 'wp-security-audit-log' ); ?>
1187
  </label>
1188
  </fieldset>
@@ -1207,17 +1220,17 @@ class WSAL_Views_Settings extends WSAL_AbstractView {
1207
  $pruning_unit = isset( $post_array['pruning-unit'] ) ? sanitize_text_field( $post_array['pruning-unit'] ) : false;
1208
  $pruning_date = ( ! empty( $pruning_date ) && ! empty( $pruning_unit ) ) ? $pruning_date . ' ' . $pruning_unit : false;
1209
 
1210
- $this->_plugin->settings->SetPruningDateEnabled( isset( $post_array['PruneBy'] ) ? 'date' === $post_array['PruneBy'] : '' );
1211
- $this->_plugin->settings->SetPruningDate( $pruning_date );
1212
- $this->_plugin->settings->set_pruning_unit( $pruning_unit );
1213
- $this->_plugin->settings->SetTimezone( $post_array['Timezone'] );
1214
- $this->_plugin->settings->set_type_username( $post_array['type_username'] );
1215
- $this->_plugin->settings->SetWPBackend( isset( $post_array['WPBackend'] ) ? sanitize_text_field( $post_array['WPBackend'] ) : false );
1216
  if ( ! empty( $post_array['Columns'] ) ) {
1217
- $this->_plugin->settings->SetColumns( $post_array['Columns'] );
1218
  }
1219
  $show_milliseconds = ( isset( $post_array['show_milliseconds'] ) && 'yes' === $post_array['show_milliseconds'] ) ? true : false;
1220
- $this->_plugin->settings->set_show_milliseconds( $show_milliseconds );
1221
  }
1222
 
1223
  /**
@@ -1232,9 +1245,9 @@ class WSAL_Views_Settings extends WSAL_AbstractView {
1232
  <?php if ( ! defined( 'WFCM_PLUGIN_FILE' ) ) : ?>
1233
  <div class="addon-wrapper" style="max-width: 380px; text-align: center; border: 1px solid #ccc; padding: 25px;">
1234
  <img src="<?php echo trailingslashit( WSAL_BASE_URL ) . 'img/help/website-file-changes-monitor.jpg'; ?>">
1235
- <h4><?php echo esc_html__( 'Website File Changes Monitor', 'wp-security-audit-log' ); ?></h4>
1236
- <p><?php echo esc_html__( 'To keep a log of file changes please install Website File Changes Monitor, a plugin which is also developed by us.', 'wp-security-audit-log' ); ?></p><br>
1237
- <p><button class="install-addon button button-primary" data-nonce="<?php echo esc_attr( wp_create_nonce( 'wsal-install-addon' ) ); ?>" data-plugin-slug="website-file-changes-monitor/website-file-changes-monitor.php" data-plugin-download-url="https://downloads.wordpress.org/plugin/website-file-changes-monitor.latest-stable.zip"><?php _e( 'Install plugin now', 'wp-security-audit-log' ); ?></button><span class="spinner" style="display: none; visibility: visible; float: none; margin: 0 0 0 8px;"></span> <a href="https://wpactivitylog.com/support/kb/wordpress-files-changes-warning-activity-logs/?utm_source=plugin&utm_medium=referral&utm_campaign=WSAL&utm_content=settings+pages" target="_blank" style="margin-left: 15px;"><?php echo esc_html__( 'Learn More', 'wp-security-audit-log' ); ?></a></p>
1238
  </div>
1239
  <?php else : ?>
1240
  <?php
@@ -1248,7 +1261,7 @@ class WSAL_Views_Settings extends WSAL_AbstractView {
1248
  $wcfm_settings_page = add_query_arg( $redirect_args, network_admin_url( 'admin.php' ) );
1249
  }
1250
  ?>
1251
- <p><?php echo esc_html__( 'Configure how often file changes scan run and other settings from the', 'wp-security-audit-log' ); ?> <a class="button button-primary" href="<?php echo esc_url( $wcfm_settings_page ); ?>"><?php echo esc_html__( 'Website File Changes plugin settings', 'wp-security-audit-log' ); ?></a></p>
1252
  <?php endif; ?>
1253
  </tr>
1254
  </tbody>
@@ -1274,7 +1287,7 @@ class WSAL_Views_Settings extends WSAL_AbstractView {
1274
  <input type="button" id="ExUserQueryAdd" class="button-primary" value="Add">
1275
  <br style="clear: both;"/>
1276
  <div id="ExUserList">
1277
- <?php foreach ( $this->_plugin->settings->GetExcludedMonitoringUsers() as $item ) : ?>
1278
  <span class="sectoken-<?php echo esc_attr( $this->GetTokenType( $item ) ); ?>">
1279
  <input type="hidden" name="ExUsers[]" value="<?php echo esc_attr( $item ); ?>"/>
1280
  <?php echo esc_html( $item ); ?>
@@ -1295,7 +1308,7 @@ class WSAL_Views_Settings extends WSAL_AbstractView {
1295
  <input type="button" id="ExRoleQueryAdd" class="button-primary" value="Add">
1296
  <br style="clear: both;"/>
1297
  <div id="ExRoleList">
1298
- <?php foreach ( $this->_plugin->settings->GetExcludedMonitoringRoles() as $item ) : ?>
1299
  <span class="sectoken-<?php echo esc_attr( $this->GetTokenType( $item ) ); ?>">
1300
  <input type="hidden" name="ExRoles[]" value="<?php echo esc_attr( $item ); ?>"/>
1301
  <?php echo esc_html( $item ); ?>
@@ -1316,88 +1329,88 @@ class WSAL_Views_Settings extends WSAL_AbstractView {
1316
  <input type="button" id="IpAddrQueryAdd" class="button-primary" value="Add">
1317
  <br style="clear: both;"/>
1318
  <div id="IpAddrList">
1319
- <?php foreach ( $this->_plugin->settings->GetExcludedMonitoringIP() as $item ) : ?>
1320
  <span class="sectoken-<?php echo esc_attr( $this->GetTokenType( $item ) ); ?>">
1321
  <input type="hidden" name="IpAddrs[]" value="<?php echo esc_attr( $item ); ?>"/>
1322
  <?php echo esc_html( $item ); ?>
1323
  <a href="javascript:;" title="Remove">&times;</a>
1324
  </span>
1325
- <?php endforeach; ?>
1326
- </div>
1327
- </fieldset>
1328
- <p class="description"><?php esc_html_e( 'You can exclude an individual IP address or a range of IP addresses. To exclude a range use the following format: [first IP]-[last octet of the last IP]. Example: 172.16.180.6-127.', 'wp-security-audit-log' ); ?></p>
1329
- </td>
1330
- </tr>
1331
- <!-- Exclude IP Addresses -->
1332
-
1333
- <tr>
1334
- <th><label for="ExCPTsQueryBox"><?php esc_html_e( 'Exclude Post Type:', 'wp-security-audit-log' ); ?></label></th>
1335
- <td>
1336
- <fieldset>
1337
- <input type="text" id="ExCPTsQueryBox" style="width: 250px;">
1338
- <input type="button" id="ExCPTsQueryAdd" class="button-primary" value="Add">
1339
- <br style="clear: both;"/>
1340
- <div id="ExCPTsList">
1341
- <?php foreach ( $this->_plugin->settings->get_excluded_post_types() as $item ) : ?>
1342
- <span class="sectoken-<?php echo esc_attr( $this->GetTokenType( $item ) ); ?>">
1343
  <input type="hidden" name="ExCPTss[]" value="<?php echo esc_attr( $item ); ?>"/>
1344
  <?php echo esc_html( $item ); ?>
1345
  <a href="javascript:;" title="Remove">&times;</a>
1346
  </span>
1347
- <?php endforeach; ?>
1348
- </div>
1349
- </fieldset>
1350
- <p class="description"><?php esc_html_e( 'WordPress has the post and page post types by default though your website might use more post types (custom post types). You can exclude all post types, including the default WordPress ones.', 'wp-security-audit-log' ); ?></p>
1351
- </td>
1352
- </tr>
1353
- <!-- Exclude Custom Post Types -->
1354
-
1355
- <tr>
1356
- <th><label for="CustomQueryBox"><?php esc_html_e( 'Exclude Custom Fields:', 'wp-security-audit-log' ); ?></label></th>
1357
- <td>
1358
- <fieldset>
1359
- <input type="text" id="CustomQueryBox" style="width: 250px;">
1360
- <input type="button" id="CustomQueryAdd" class="button-primary" value="Add">
1361
- <br style="clear: both;"/>
1362
- <div id="CustomList">
1363
- <?php foreach ( $this->_plugin->settings->GetExcludedMonitoringCustom() as $item ) : ?>
1364
- <span class="sectoken-<?php echo esc_attr( $this->GetTokenType( $item ) ); ?>">
1365
  <input type="hidden" name="Customs[]" value="<?php echo esc_attr( $item ); ?>"/>
1366
  <?php echo esc_html( $item ); ?>
1367
  <a href="javascript:;" title="Remove">&times;</a>
1368
  </span>
1369
- <?php endforeach; ?>
1370
- </div>
1371
- </fieldset>
1372
- <p class="description"><?php esc_html_e( 'You can use the * wildcard to exclude multiple matching custom fields. For example to exclude all custom fields starting with wp123 enter wp123*', 'wp-security-audit-log' ); ?></p>
1373
- </td>
1374
- </tr>
1375
- <!-- Exclude Custom Fields -->
1376
-
1377
- <tr>
1378
- <th><label for="ExURLsQueryBox"><?php esc_html_e( 'Exclude Non-Existing URLs:', 'wp-security-audit-log' ); ?></label></th>
1379
- <td>
1380
- <fieldset>
1381
- <input type="text" id="ExURLsQueryBox" style="width: 250px;">
1382
- <input type="button" id="ExURLsQueryAdd" class="button-primary" value="Add">
1383
- <br style="clear: both;"/>
1384
- <div id="ExURLsList">
1385
- <?php foreach ( $this->_plugin->settings->get_excluded_urls() as $item ) : ?>
1386
- <span class="sectoken-<?php echo esc_attr( $this->GetTokenType( $item ) ); ?>">
1387
  <input type="hidden" name="ExURLss[]" value="<?php echo esc_attr( $item ); ?>"/>
1388
  <?php echo esc_html( $item ); ?>
1389
  <a href="javascript:;" title="Remove">&times;</a>
1390
  </span>
1391
- <?php endforeach; ?>
1392
- </div>
1393
- </fieldset>
1394
- <p class="description"><?php esc_html_e( 'Add the non existing URLs for which you do not want to be alerted of HTTP 404 errors in the activity log by specifying the complete URL. Examples below:', 'wp-security-audit-log' ); ?><br><?php echo esc_html__( 'File: ', 'wp-security-audit-log' ) . esc_url( home_url() ) . '/subdirectory/file.php'; ?><br><?php echo esc_html__( 'Directory: ', 'wp-security-audit-log' ) . esc_url( home_url() ) . '/subdirectory/subdirectory2'; ?></p>
1395
- </td>
1396
- </tr>
1397
- <!-- Exclude 404 URLs -->
1398
- </tbody>
1399
- </table>
1400
- <!-- / Exclude Objects Tab -->
1401
  <?php
1402
  }
1403
 
@@ -1408,223 +1421,88 @@ class WSAL_Views_Settings extends WSAL_AbstractView {
1408
  // Get $_POST global array.
1409
  $post_array = filter_input_array( INPUT_POST );
1410
 
1411
- $this->_plugin->settings->SetExcludedMonitoringUsers( isset( $post_array['ExUsers'] ) ? $post_array['ExUsers'] : array() );
1412
- $this->_plugin->settings->SetExcludedMonitoringRoles( isset( $post_array['ExRoles'] ) ? $post_array['ExRoles'] : array() );
1413
- $this->_plugin->settings->SetExcludedMonitoringCustom( isset( $post_array['Customs'] ) ? $post_array['Customs'] : array() );
1414
- $this->_plugin->settings->SetExcludedMonitoringIP( isset( $post_array['IpAddrs'] ) ? $post_array['IpAddrs'] : array() );
1415
- $this->_plugin->settings->set_excluded_post_types( isset( $post_array['ExCPTss'] ) ? $post_array['ExCPTss'] : array() );
1416
- $this->_plugin->settings->set_excluded_urls( isset( $post_array['ExURLss'] ) ? $post_array['ExURLss'] : array() );
1417
- }
1418
-
1419
- /**
1420
- * Tab: `Import/Export`
1421
- */
1422
- private function tab_import_settings() {
1423
- $blogname = str_replace( ' ', '', get_option( 'blogname' ) );
1424
- $date = date( 'm-d-Y' );
1425
- $json_name = $blogname . '-' . $date; // Export file name.
1426
- ?>
1427
- <p class="description"><?php esc_html_e( 'You can export and import the plugin settings from here, which can also be used as a plugin configuration backup. The plugin settings are exported to a JSON file.', 'wp-security-audit-log' ); ?></p>
1428
- <h3><?php esc_html_e( 'Export Settings', 'wp-security-audit-log' ); ?></h3>
1429
- <table class="form-table wsal-tab">
1430
- <tbody>
1431
- <tr>
1432
- <th><label><?php esc_html_e( 'Export Settings', 'wp-security-audit-log' ); ?></label></th>
1433
- <td>
1434
- <fieldset>
1435
- <?php
1436
- $export_options = array();
1437
-
1438
- $options = $this->_plugin->settings->get_wsal_options();
1439
-
1440
- $ignored_options = array( 'site_content', 'local_files_0', 'local_files_1', 'local_files_2', 'local_files_3', 'local_files_4', 'local_files_5', 'local_files_6', 'is_initial_scan_0', 'is_initial_scan_1', 'is_initial_scan_2', 'is_initial_scan_3', 'is_initial_scan_4', 'is_initial_scan_5', 'is_initial_scan_6' );
1441
-
1442
- foreach ( $options as $option ) {
1443
- $option_name = str_replace( 'wsal-', '', $option->option_name );
1444
-
1445
- if ( in_array( $option_name, $ignored_options, true ) ) {
1446
- continue;
1447
- }
1448
-
1449
- $export_options[ $option_name ] = $option->option_value;
1450
- }
1451
-
1452
- $json_file = wp_json_encode( $export_options );
1453
- ?>
1454
- <input type="hidden" value="<?php echo esc_attr( $json_file ); ?>">
1455
- <button type="button" name="export" id="wsal-export-options" class="button-primary"><?php esc_html_e( 'Export Settings', 'wp-security-audit-log' ); ?></button>
1456
- </fieldset>
1457
- </td>
1458
- </tr>
1459
- </tbody>
1460
- </table>
1461
- <!-- Export Settings -->
1462
- <h3><?php esc_html_e( 'Import Settings', 'wp-security-audit-log' ); ?></h3>
1463
- <table class="form-table wsal-tab">
1464
- <tbody>
1465
- <tr>
1466
- <th><label><?php esc_html_e( 'Import Settings', 'wp-security-audit-log' ); ?></label></th>
1467
- <td>
1468
- <fieldset>
1469
- <input type="file" name="import-settings" id="wsal-import-settings" accept="application/json">
1470
- <p><button type="submit" name="import" id="wsal-import-settings-btn" class="button-primary button-disabled" disabled><?php esc_html_e( 'Import Settings', 'wp-security-audit-log' ); ?></button></p>
1471
- </fieldset>
1472
- </td>
1473
- </tr>
1474
- </tbody>
1475
- </table>
1476
- <!-- Import Settings -->
1477
- <script>
1478
- /**
1479
- * Create and download a temporary file.
1480
- *
1481
- * @param {string} filename - File name.
1482
- * @param {string} text - File content.
1483
- */
1484
- function download(filename, text) {
1485
- // Create temporary element.
1486
- var element = document.createElement('a');
1487
- element.setAttribute('href', 'data:application/json;charset=<?php echo esc_html( get_option( 'blog_charset' ) ); ?>,' + encodeURIComponent(text));
1488
- element.setAttribute('download', filename);
1489
-
1490
- // Set the element to not display.
1491
- element.style.display = 'none';
1492
- document.body.appendChild(element);
1493
-
1494
- // Simlate click on the element.
1495
- element.click();
1496
-
1497
- // Remove temporary element.
1498
- document.body.removeChild(element);
1499
- }
1500
-
1501
- jQuery( document ).ready( function() {
1502
- jQuery( '#wsal-export-options' ).click( function( event ) {
1503
- event.preventDefault();
1504
- download( '<?php echo esc_html( $json_name ); ?>', jQuery( this ).parent().find( 'input' ).val() );
1505
- } );
1506
-
1507
- jQuery( '#wsal-import-settings' ).change( function() {
1508
- jQuery( '#wsal-import-settings-btn' ).removeAttr( 'disabled' );
1509
- jQuery( '#wsal-import-settings-btn' ).removeClass( 'button-disabled' );
1510
- } );
1511
- } );
1512
- </script>
1513
- <?php
1514
- }
1515
-
1516
- /**
1517
- * Save: `Import/Export`
1518
- */
1519
- private function tab_import_settings_save() {
1520
- // bail early if user does not have sufficient permissions to import.
1521
- if ( ! $this->_plugin->settings->CurrentUserCan( 'edit' ) ) {
1522
- echo '<div class="notice notice-error"><p>' . esc_html__( 'Current user is not allowed to import files.', 'wp-security-audit-log' ) . '</p></div>';
1523
- return;
1524
- }
1525
- if ( isset( $_FILES['import-settings'] ) ) {
1526
- if ( 0 === $_FILES['import-settings']['error'] ) {
1527
- $filename = isset( $_FILES['import-settings']['name'] ) ? sanitize_text_field( wp_unslash( $_FILES['import-settings']['name'] ) ) : false;
1528
- $file_type = isset( $_FILES['import-settings']['type'] ) ? sanitize_text_field( wp_unslash( $_FILES['import-settings']['type'] ) ) : false;
1529
- $file_size = isset( $_FILES['import-settings']['size'] ) ? (int) sanitize_text_field( wp_unslash( $_FILES['import-settings']['size'] ) ) : false;
1530
-
1531
- if ( 'application/json' === $file_type && $file_size < 500000 ) {
1532
- $encoded_options = isset( $_FILES['import-settings']['tmp_name'] ) ? file_get_contents( sanitize_text_field( wp_unslash( $_FILES['import-settings']['tmp_name'] ) ) ) : false; // phpcs:ignore
1533
- $options = json_decode( $encoded_options );
1534
-
1535
- if ( $options ) {
1536
- foreach ( $options as $key => $value ) {
1537
- $value = maybe_unserialize( sanitize_text_field( $value ) );
1538
- $this->_plugin->SetGlobalOption( $key, $value );
1539
- }
1540
-
1541
- echo '<div class="notice notice-success"><p>' . esc_html__( 'The plugin settings have been imported successfully.', 'wp-security-audit-log' ) . '</p></div>';
1542
- } else {
1543
- echo '<div class="notice notice-error"><p>' . esc_html__( 'No settings found to import.', 'wp-security-audit-log' ) . '</p></div>';
1544
- }
1545
- } else {
1546
- echo '<div class="notice notice-error"><p>' . esc_html__( 'Invalid file or file size is too large.', 'wp-security-audit-log' ) . '</p></div>';
1547
- }
1548
- } else {
1549
- echo '<div class="notice notice-error"><p>' . esc_html__( 'Error occurred while uploading the file.', 'wp-security-audit-log' ) . '</p></div>';
1550
- }
1551
- }
1552
  }
1553
 
1554
  /**
1555
  * Tab: `Advanced Settings`
1556
  */
1557
  private function tab_advanced_settings() {
 
1558
  ?>
1559
- <p class="description">
1560
  <?php esc_html_e( 'These settings are for advanced users.', 'wp-security-audit-log' ); ?>
1561
  <?php echo sprintf( __( 'If you have any questions <a href="https://wpactivitylog.com/contact/?utm_source=plugin&utm_medium=referral&utm_campaign=WSAL&utm_content=settings+pages" target="_blank">contact us</a>.', 'wp-security-audit-log' ), $this->_plugin->allowed_html_tags ); ?>
1562
  </p>
1563
 
1564
- <h3><?php esc_html_e( 'Where do you want to save the log files?', 'wp-security-audit-log' ); ?></h3>
1565
- <p class="description"><?php esc_html_e( 'The plugin uses a number of log files. It uses these log files to keep a log of 1) requests to non-existing URLs from logged in users (event ID 6007) and non-logged in users (6023), 2) the request log. Use the below setting to save the log files in different location. Please specify the relative path.', 'wp-security-audit-log' ); ?></p>
1566
- <table class="form-table wsal-tab">
1567
- <tbody>
1568
- <!-- custom log directory -->
1569
- <tr>
1570
- <th><label><?php esc_html_e( 'Log files location', 'wp-security-audit-log' ); ?></label></th>
1571
- <td>
1572
- <fieldset>
1573
- <?php $location = $this->_plugin->options_helper->get_option_value( 'custom-logging-dir', \WSAL_Settings::DEFAULT_LOGGING_DIR ); ?>
1574
- <label for="wsal-custom-logs-dir">
1575
- <input type="text" name="wsal-custom-logs-dir" id="wsal-custom-logs-dir"
1576
- value="<?php echo esc_attr( $location ); ?>">
1577
- </label>
1578
- <p class="description">
1579
- <?php
1580
- echo wp_kses(
1581
- __( '<strong>Note:</strong> Enter a path from the root of your website: eg "/wp-content/uploads/wp-security-audit-log/".' ),
1582
- $this->_plugin->allowed_html_tags
1583
- );
1584
- ?>
1585
- </p>
1586
- </fieldset>
1587
- </td>
1588
- </tr>
1589
- <!-- / custom log directory -->
1590
- </tbody>
1591
- </table>
1592
-
1593
-
1594
- <h3><?php esc_html_e( 'Troubleshooting setting: Keep a debug log of all the requests this website receives', 'wp-security-audit-log' ); ?></h3>
1595
- <p class="description"><?php esc_html_e( 'Only enable the request log on testing, staging and development website. Never enable logging on a live website unless instructed to do so. Enabling request logging on a live website may degrade the performance of the website.', 'wp-security-audit-log' ); ?></p>
1596
- <table class="form-table wsal-tab">
1597
- <tbody>
1598
- <tr>
1599
- <th><label><?php esc_html_e( 'Request Log', 'wp-security-audit-log' ); ?></label></th>
1600
- <td>
1601
- <fieldset>
1602
- <?php $devoption_checked = $this->_plugin->settings->IsDevOptionEnabled( WSAL_Settings::OPT_DEV_REQUEST_LOG ); ?>
1603
- <label for="devoption_yes">
1604
- <input type="radio" name="DevOptions" id="devoption_yes"
1605
- <?php checked( $devoption_checked, true ); ?>
1606
- value="<?php echo esc_attr( WSAL_Settings::OPT_DEV_REQUEST_LOG ); ?>">
1607
- <?php esc_html_e( 'Yes', 'wp-security-audit-log' ); ?>
1608
- </label>
1609
- <br>
1610
- <label for="devoption_no">
1611
- <input type="radio" name="DevOptions" id="devoption_no" <?php checked( $devoption_checked, false ); ?> value="0">
1612
- <?php esc_html_e( 'No', 'wp-security-audit-log' ); ?>
1613
- </label>
1614
- <p class="description">
1615
- <?php
1616
- echo wp_kses(
1617
- __( '<strong>Note:</strong> The requests debug log file is saved as request.log.php in the /wp-content/uploads/wp-security-audit-log/ directory.' ),
1618
- $this->_plugin->allowed_html_tags
1619
- );
1620
- ?>
1621
- </p>
1622
- </fieldset>
1623
- </td>
1624
- </tr>
1625
- <!-- / Developer Options -->
1626
- </tbody>
1627
- </table>
1628
 
1629
  <h3><?php esc_html_e( 'Reset plugin settings to default', 'wp-security-audit-log' ); ?></h3>
1630
  <p class="description"><?php esc_html_e( 'Click the RESET button to reset ALL plugin settings to default. Note that the activity log data will be retained and only the plugin settings will be reset. To purge the data of the activity log use the setting below.', 'wp-security-audit-log' ); ?></p>
@@ -1652,6 +1530,7 @@ class WSAL_Views_Settings extends WSAL_AbstractView {
1652
  </tbody>
1653
  </table>
1654
 
 
1655
  <h3><?php esc_html_e( 'MainWP Child Site Stealth Mode', 'wp-security-audit-log' ); ?></h3>
1656
  <p class="description"><?php esc_html_e( 'This option is enabled automatically when the plugin detects the MainWP Child plugin on the site. When this setting is enabled plugin access is restricted to the administrator who installs the plugin, the plugin is not shown in the list of installed plugins and no admin notifications are shown. Disable this option to change the plugin to the default setup.', 'wp-security-audit-log' ); ?></p>
1657
  <table class="form-table wsal-tab">
@@ -1661,10 +1540,7 @@ class WSAL_Views_Settings extends WSAL_AbstractView {
1661
  <td>
1662
  <fieldset <?php echo ! WpSecurityAuditLog::is_mainwp_active() ? 'disabled' : false; ?>>
1663
  <label for="mwp_stealth_yes">
1664
- <?php $stealth_mode = $this->_plugin->settings->is_stealth_mode(); ?>
1665
- <input type="radio" name="mwp_stealth_mode" value="yes" id="mwp_stealth_yes"
1666
- <?php checked( $stealth_mode ); ?>
1667
- />
1668
  <?php esc_html_e( 'Yes', 'wp-security-audit-log' ); ?>
1669
  </label>
1670
  <br>
@@ -1677,7 +1553,20 @@ class WSAL_Views_Settings extends WSAL_AbstractView {
1677
  </fieldset>
1678
  </td>
1679
  </tr>
1680
- <!-- / Remove Data on Uninstall -->
 
 
 
 
 
 
 
 
 
 
 
 
 
1681
  </tbody>
1682
  </table>
1683
 
@@ -1691,14 +1580,14 @@ class WSAL_Views_Settings extends WSAL_AbstractView {
1691
  <fieldset>
1692
  <label for="delete_data_yes">
1693
  <input type="radio" name="DeleteData" value="1" id="delete_data_yes" onclick="return delete_confirm(this);"
1694
- <?php checked( $this->_plugin->settings->IsDeleteData() ); ?>
1695
  />
1696
  <?php esc_html_e( 'Yes', 'wp-security-audit-log' ); ?>
1697
  </label>
1698
  <br>
1699
  <label for="delete_data_no">
1700
  <input type="radio" name="DeleteData" value="0" id="delete_data_no"
1701
- <?php checked( $this->_plugin->settings->IsDeleteData(), false ); ?>
1702
  />
1703
  <?php esc_html_e( 'No', 'wp-security-audit-log' ); ?>
1704
  </label>
@@ -1740,56 +1629,56 @@ class WSAL_Views_Settings extends WSAL_AbstractView {
1740
  // Get $_POST global array.
1741
  $post_array = filter_input_array( INPUT_POST );
1742
 
1743
- $this->_plugin->settings->SetDeleteData( isset( $post_array['DeleteData'] ) ? sanitize_text_field( $post_array['DeleteData'] ) : false );
1744
- $this->_plugin->settings->ClearDevOptions();
1745
  if ( isset( $post_array['DevOptions'] ) && 'r' === $post_array['DevOptions'] ) {
1746
- $this->_plugin->settings->SetDevOptionEnabled( 'r', true );
1747
  } else {
1748
- $this->_plugin->settings->SetDevOptionEnabled( 'r', false );
1749
  }
1750
 
 
1751
  $stealth_mode = isset( $post_array['mwp_stealth_mode'] ) ? $post_array['mwp_stealth_mode'] : false;
1752
  if ( 'yes' === $stealth_mode ) {
1753
  if ( ! WpSecurityAuditLog::is_mainwp_active() ) {
1754
  throw new Exception( __( 'MainWP Child plugin is not active on this website.', 'wp-security-audit-log' ) );
1755
  }
1756
- $this->_plugin->settings->set_mainwp_child_stealth_mode();
 
 
 
 
 
 
1757
  } else {
1758
- $this->_plugin->settings->deactivate_mainwp_child_stealth_mode();
1759
  }
1760
 
1761
- $custom_logging_dir = WSAL_Settings::DEFAULT_LOGGING_DIR;
1762
  if ( isset( $post_array['wsal-custom-logs-dir'] ) ) {
1763
  $posted_logging_dir = filter_var( $post_array['wsal-custom-logs-dir'], FILTER_SANITIZE_STRING );
1764
  if (!empty($posted_logging_dir)) {
1765
- $custom_logging_dir = $posted_logging_dir;
1766
  }
1767
  }
1768
 
1769
  if ( ! empty( $custom_logging_dir ) ) {
1770
  $custom_logging_path = trailingslashit( ABSPATH ) . ltrim( trailingslashit( $custom_logging_dir ), '/' );
1771
  if ( ! is_dir( $custom_logging_path ) || ! is_readable( $custom_logging_path ) || ! is_writable( $custom_logging_path ) ) {
1772
- if ( is_writable( dirname( $custom_logging_path ) ) ) {
1773
- $dir_made = wp_mkdir_p( $custom_logging_path );
1774
- if ( $dir_made ) {
1775
- // make an empty index.php in the directory.
1776
- @file_put_contents( $custom_logging_path . 'index.php', '<?php // Silence is golden' );
1777
- }
1778
- }
1779
 
1780
- // if the directory was not made then we will try revert or use default value.
1781
  if ( ! $dir_made ) {
1782
- // revert to old/default.
1783
- $previous_path = $this->_plugin->options_helper->get_option_value( 'custom-logging-dir', false );
1784
- if ( ! false === $previous_path && is_writable( $previous_path ) ) {
1785
- $custom_logging_dir = $previous_path;
1786
- } else {
1787
- $custom_logging_dir = WSAL_Settings::DEFAULT_LOGGING_DIR;
1788
- }
1789
  }
1790
  }
1791
  // save.
1792
- $this->_plugin->options_helper->set_option_value( 'custom-logging-dir', $custom_logging_dir );
1793
  }
1794
  }
1795
 
@@ -1811,17 +1700,17 @@ class WSAL_Views_Settings extends WSAL_AbstractView {
1811
  wp_enqueue_style( 'wsal-remodal-theme', WSAL_BASE_URL . 'css/remodal-default-theme.css', array(), '1.1.1' );
1812
  }
1813
  ?>
1814
- <style type="text/css">
1815
- .wsal-tab {
1816
- /* display: none; */
1817
- }
1818
- .wsal-tab tr.alert-incomplete td {
1819
- color: #9BE;
1820
- }
1821
- .wsal-tab tr.alert-unavailable td {
1822
- color: #CCC;
1823
- }
1824
- </style>
1825
  <?php
1826
  }
1827
 
@@ -1872,18 +1761,18 @@ class WSAL_Views_Settings extends WSAL_AbstractView {
1872
  wp_localize_script( 'settings', 'wsal_data', $wsal_data );
1873
  wp_enqueue_script( 'settings' );
1874
  ?>
1875
- <script type="text/javascript">
1876
- jQuery( document ).ready( function() {
1877
- jQuery( '.sel-columns' ).change( function() {
1878
- var notChecked = 1;
1879
- jQuery( '.sel-columns' ).each( function() {
1880
- if ( this.checked ) notChecked = 0;
1881
- })
1882
- if ( notChecked == 1 ) {
1883
- alert( esc_html__( 'You have to select at least one column!', 'wp-security-audit-log' ) );
1884
- }
1885
- });
1886
- });</script>
1887
  <?php
1888
  }
1889
 
@@ -1892,7 +1781,7 @@ class WSAL_Views_Settings extends WSAL_AbstractView {
1892
  */
1893
  public function AjaxGetAllUsers() {
1894
  // Die if user does not have permission to view.
1895
- if ( ! $this->_plugin->settings->CurrentUserCan( 'view' ) ) {
1896
  die( 'Access Denied.' );
1897
  }
1898
 
@@ -1920,7 +1809,7 @@ class WSAL_Views_Settings extends WSAL_AbstractView {
1920
  */
1921
  public function AjaxGetAllRoles() {
1922
  // Die if user does not have permission to view.
1923
- if ( ! $this->_plugin->settings->CurrentUserCan( 'view' ) ) {
1924
  die( 'Access Denied.' );
1925
  }
1926
 
@@ -1950,7 +1839,7 @@ class WSAL_Views_Settings extends WSAL_AbstractView {
1950
  */
1951
  public function AjaxGetAllCPT() {
1952
  // Die if user does not have permission to view.
1953
- if ( ! $this->_plugin->settings->CurrentUserCan( 'view' ) ) {
1954
  die( 'Access Denied.' );
1955
  }
1956
 
@@ -1988,7 +1877,7 @@ class WSAL_Views_Settings extends WSAL_AbstractView {
1988
  */
1989
  public function reset_settings() {
1990
  // Die if user does not have permission to change settings.
1991
- if ( ! $this->_plugin->settings->CurrentUserCan( 'view' ) ) {
1992
  die( esc_html__( 'Access Denied.', 'wp-security-audit-log' ) );
1993
  }
1994
 
@@ -2017,7 +1906,7 @@ class WSAL_Views_Settings extends WSAL_AbstractView {
2017
  */
2018
  public function purge_activity() {
2019
  // Die if user does not have permission to change settings.
2020
- if ( ! $this->_plugin->settings->CurrentUserCan( 'view' ) ) {
2021
  die( esc_html__( 'Access Denied.', 'wp-security-audit-log' ) );
2022
  }
2023
 
108
  'save' => array( $this, 'tab_exclude_objects_save' ),
109
  'priority' => 40,
110
  ),
 
 
 
 
 
 
 
111
  'advanced-settings' => array(
112
  'name' => __( 'Advanced Settings', 'wp-security-audit-log' ),
113
  'link' => add_query_arg( 'tab', 'advanced-settings', $this->GetUrl() ),
187
  * @param string $token - Token type.
188
  */
189
  protected function GetTokenType( $token ) {
190
+ return $this->_plugin->settings()->get_token_type( $token );
191
  }
192
 
193
  /**
197
  */
198
  protected function Save() {
199
  // Bail early if user does not have sufficient permissions to save.
200
+ if ( ! $this->_plugin->settings()->CurrentUserCan( 'edit' ) ) {
201
  throw new Exception( esc_html__( 'Current user is not allowed to save settings.', 'wp-security-audit-log' ) );
202
  }
203
  // Call respective tab save functions if they are set. Nonce is already verified at this point.
212
  * Method: Check security token.
213
  */
214
  public function AjaxCheckSecurityToken() {
215
+ if ( ! $this->_plugin->settings()->CurrentUserCan( 'view' ) ) {
216
  echo wp_json_encode(
217
  array(
218
  'success' => false,
261
  * Method: Run cleanup.
262
  */
263
  public function AjaxRunCleanup() {
264
+ if ( ! $this->_plugin->settings()->CurrentUserCan( 'view' ) ) {
265
  die( 'Access Denied.' );
266
  }
267
 
268
  $now = current_time( 'timestamp' ); // Current time.
269
+ $max_sdate = $this->_plugin->settings()->GetPruningDate(); // Pruning date.
270
 
271
  // If archiving is enabled then events are deleted from the archive database.
272
+ $archiving = $this->_plugin->settings()->IsArchivingEnabled();
273
  if ( $archiving ) {
274
  // Switch to Archive DB.
275
+ $this->_plugin->settings()->SwitchToArchiveDB();
276
  }
277
 
278
  // Calculate limit timestamp.
321
  check_admin_referer( 'wsal-settings' );
322
  }
323
 
324
+ if ( ! $this->_plugin->settings()->CurrentUserCan( 'edit' ) ) {
325
  wp_die( esc_html__( 'You do not have sufficient permissions to access this page.', 'wp-security-audit-log' ) );
326
  }
327
 
333
  $this->Save(); // Save settings.
334
  if ( 'sms-provider' === $this->current_tab && $section && 'test' === $section ) :
335
  ?>
336
+ <div class="updated">
337
+ <p><?php esc_html_e( 'Message sent successfully.', 'wp-security-audit-log' ); ?></p>
338
+ </div>
339
  <?php else : ?>
340
+ <div class="updated">
341
+ <p><?php esc_html_e( 'Settings have been saved.', 'wp-security-audit-log' ); ?></p>
342
+ </div>
343
+ <?php
344
  endif;
345
  } catch ( Exception $ex ) {
346
  ?>
347
+ <div class="error"><p><?php esc_html_e( 'Error: ', 'wp-security-audit-log' ); ?><?php echo esc_html( $ex->getMessage() ); ?></p></div>
348
  <?php
349
  }
350
  }
355
 
356
  if ( isset( $_GET['pruning'] ) && '1' === $_GET['pruning'] ) {
357
  ?>
358
+ <div class="updated">
359
+ <p><?php esc_html_e( 'Old data successfully purged.', 'wp-security-audit-log' ); ?></p>
360
+ </div>
361
  <?php
362
  } elseif ( isset( $_GET['pruning'] ) && '0' === $_GET['pruning'] ) {
363
  ?>
364
+ <div class="error">
365
+ <p><?php esc_html_e( 'No data is old enough to be purged.', 'wp-security-audit-log' ); ?></p>
366
+ </div>
367
  <?php
368
  }
369
  ?>
370
+ <nav id="wsal-tabs" class="nav-tab-wrapper">
371
  <?php foreach ( $this->wsal_setting_tabs as $tab_id => $tab ) : ?>
372
+ <a href="<?php echo esc_url( $tab['link'] ); ?>" class="nav-tab <?php echo ( $tab_id === $this->current_tab ) ? 'nav-tab-active' : false; ?>">
373
  <?php echo esc_html( $tab['name'] ); ?>
374
+ </a>
375
  <?php endforeach; ?>
376
+ </nav>
377
 
378
+ <form id="audit-log-settings" method="post">
379
+ <input type="hidden" name="page" value="<?php echo isset( $_GET['page'] ) ? esc_attr( sanitize_text_field( wp_unslash( $_GET['page'] ) ) ) : false; ?>" />
380
+ <input type="hidden" id="ajaxurl" value="<?php echo esc_attr( admin_url( 'admin-ajax.php' ) ); ?>" />
381
  <?php wp_nonce_field( 'wsal-settings' ); ?>
382
 
383
+ <div id="audit-log-adverts">
384
+ </div>
385
+ <div class="nav-tabs">
386
  <?php
387
  if ( ! empty( $this->current_tab ) && ! empty( $this->wsal_setting_tabs[ $this->current_tab ]['render'] ) ) {
388
  call_user_func( $this->wsal_setting_tabs[ $this->current_tab ]['render'] );
390
  call_user_func( $this->wsal_setting_tabs['general']['render'] );
391
  }
392
  ?>
393
+ </div>
394
  <?php
395
  if ( 'sms-provider' === $this->current_tab && $section && 'test' === $section ) {
396
  submit_button( __( 'Send Message', 'wp-security-audit-log' ) );
397
+ } else {
398
  submit_button();
399
  }
400
  ?>
401
+ </form>
402
+ <script type="text/javascript">
403
+ <!--
404
+ function delete_confirm(elementRef) {
405
+ if (elementRef.checked) {
406
+ if ( window.confirm('Do you want remove all data when the plugin is deleted?') == false )
407
+ elementRef.checked = false;
408
+ }
409
+ }
410
+
411
+ jQuery( document ).ready( function() {
412
+ // Enable/disable setting.
413
+ function wsal_update_setting( checkbox, setting ) {
414
+ if ( checkbox.prop( 'checked' ) ) {
415
+ setting.removeProp( 'disabled' );
416
+ } else {
417
+ setting.prop( 'disabled', 'disabled' );
418
+ }
419
+ }
420
+
421
+ // Login page notification settings.
422
+ var login_page_notif = jQuery( 'input[name=login_page_notification]' );
423
+ var login_page_notif_text = jQuery( '#login_page_notification_text' );
424
+
425
+ // Check the change event on checkbox.
426
+ login_page_notif.on( 'change', function() {
427
+ wsal_update_setting( login_page_notif, login_page_notif_text );
428
+ } );
429
+
430
+ // Proxy settings.
431
+ var proxy_ip_setting = jQuery( 'input[name=EnableProxyIpCapture]' );
432
+ var ip_filtering = jQuery( '#EnableIpFiltering' );
433
+ wsal_update_setting( proxy_ip_setting, ip_filtering );
434
+ proxy_ip_setting.on( 'change', function() {
435
+ wsal_update_setting( proxy_ip_setting, ip_filtering );
436
+ } );
437
+ } );
438
+ // --></script>
439
  <?php
440
  }
441
 
444
  */
445
  private function tab_general() {
446
  ?>
447
+ <p class="description"><?php echo wp_kses( __( 'Need help with setting up the plugin to meet your requirements? <a href="https://wpactivitylog.com/contact/?utm_source=plugin&utm_medium=referral&utm_campaign=WSAL&utm_content=settings+pages" target="_blank">Schedule a 20 minutes consultation and setup call</a> with our experts for just $50.', 'wp-security-audit-log' ), $this->_plugin->allowed_html_tags ); ?></p>
448
 
449
+ <h3><?php esc_html_e( 'Use infinite scroll or pagination for the event viewer?', 'wp-security-audit-log' ); ?></h3>
450
+ <p class="description">
451
  <?php
452
  echo sprintf(
453
  /* translators: Learn more link. */
455
  '<a href="https://wpactivitylog.com/features/search-filters-wordpress-activity-log/?utm_source=plugin&utm_medium=referral&utm_campaign=WSAL&utm_content=settings+pages" target="_blank">' . esc_html__( '(Premium feature)', 'wp-security-audit-log' ) . '</a>'
456
  );
457
  ?>
458
+ </p>
459
+ <table class="form-table wsal-tab">
460
+ <tbody>
461
+ <tr>
462
+ <th><label for="infinite-scroll"><?php esc_html_e( 'Select event viewer view type:', 'wp-security-audit-log' ); ?></label></th>
463
+ <td>
464
+ <fieldset>
465
+ <label for="infinite-scroll">
466
+ <input type="radio" name="events-type-nav" value="infinite-scroll" id="infinite-scroll" <?php checked( $this->_plugin->settings()->get_events_type_nav(), 'infinite-scroll' ); ?> />
467
+ <?php esc_html_e( 'Infinite Scroll (Recommended)', 'wp-security-audit-log' ); ?>
468
+ </label>
469
+ <br/>
470
+ <label for="pagination">
471
+ <input type="radio" name="events-type-nav" value="pagination" id="pagination" <?php checked( $this->_plugin->settings()->get_events_type_nav(), 'pagination' ); ?> />
472
+ <?php esc_html_e( 'Pagination', 'wp-security-audit-log' ); ?>
473
+ </label>
474
+ <br />
475
+ </fieldset>
476
+ </td>
477
+ </tr>
478
+ <!-- / Reverse Proxy / Firewall Options -->
479
+ </tbody>
480
+ </table>
481
+ <!-- Events Navigation Type -->
482
+
483
+ <h3><?php esc_html_e( 'Do you want the activity log viewer to auto refresh?', 'wp-security-audit-log' ); ?></h3>
484
+ <p class="description"><?php esc_html_e( 'The activity log viewer auto refreshes every 30 seconds when opened so you can see the latest events as they happen almost in real time.', 'wp-security-audit-log' ); ?></p>
485
+ <table class="form-table wsal-tab">
486
+ <tbody>
487
+ <tr>
488
+ <th><label for="aroption_on"><?php esc_html_e( 'Refresh activity log viewer', 'wp-security-audit-log' ); ?></label></th>
489
+ <td>
490
+ <fieldset>
491
+ <?php $are = $this->_plugin->settings()->IsRefreshAlertsEnabled(); ?>
492
+ <label for="aroption_on">
493
+ <input type="radio" name="EnableAuditViewRefresh" id="aroption_on" style="margin-top: -2px;" <?php checked( $are ); ?> value="1">
494
+ <span><?php esc_html_e( 'Auto refresh', 'wp-security-audit-log' ); ?></span>
495
+ </label>
496
+ <br/>
497
+ <label for="aroption_off">
498
+ <input type="radio" name="EnableAuditViewRefresh" id="aroption_off" style="margin-top: -2px;" <?php checked( $are, false ); ?> value="0">
499
+ <span><?php esc_html_e( 'Do not auto refresh', 'wp-security-audit-log' ); ?></span>
500
+ </label>
501
+ </fieldset>
502
+ </td>
503
+ </tr>
504
+ <!-- Refresh activity log viewer -->
505
+ </tbody>
506
+ </table>
507
+ <!-- Refresh activity log -->
508
+
509
+ <h3><?php esc_html_e( 'Display latest events widget in Dashboard & Admin bar', 'wp-security-audit-log' ); ?></h3>
510
+ <p class="description">
511
  <?php
512
  echo sprintf(
513
  /* translators: Max number of dashboard widget alerts. */
514
  esc_html__( 'The events widget displays the latest %d security events in the dashboard and the admin bar notification displays the latest event.', 'wp-security-audit-log' ),
515
+ esc_html( $this->_plugin->settings()->GetDashboardWidgetMaxAlerts() )
516
  );
517
  ?>
518
+ </p>
519
+ <table class="form-table wsal-tab">
520
+ <tbody>
521
+ <tr>
522
+ <th><label for="dwoption_on"><?php esc_html_e( 'Dashboard Widget', 'wp-security-audit-log' ); ?></label></th>
523
+ <td>
524
+ <fieldset>
525
+ <?php $dwe = $this->_plugin->settings()->IsWidgetsEnabled(); ?>
526
+ <label for="dwoption_on">
527
+ <input type="radio" name="EnableDashboardWidgets" id="dwoption_on" style="margin-top: -2px;" <?php checked( $dwe ); ?> value="1">
528
+ <span><?php esc_html_e( 'Yes', 'wp-security-audit-log' ); ?></span>
529
+ </label>
530
+ <br/>
531
+ <label for="dwoption_off">
532
+ <input type="radio" name="EnableDashboardWidgets" id="dwoption_off" style="margin-top: -2px;" <?php checked( $dwe, false ); ?> value="0">
533
+ <span><?php esc_html_e( 'No', 'wp-security-audit-log' ); ?></span>
534
+ </label>
535
+ </fieldset>
536
+ </td>
537
+ </tr>
538
+ <!-- / Events Dashboard Widget -->
539
+
540
+ <tr>
541
+ <?php
542
+ $disabled = '';
543
+ $label = __( 'Admin Bar Notification', 'wp-security-audit-log' );
544
+ if ( wsal_freemius()->is_free_plan() ) {
545
+ $disabled = 'disabled';
546
+ $label = __( 'Admin Bar Notification (Premium)', 'wp-security-audit-log' );
547
+ }
548
+ ?>
549
+ <th><label for="admin_bar_notif_on"><?php echo esc_html( $label ); ?></label></th>
550
+ <td>
551
+ <fieldset <?php echo esc_attr( $disabled ); ?>>
552
+ <?php $abn = $this->_plugin->settings()->is_admin_bar_notif(); ?>
553
+ <label for="admin_bar_notif_on">
554
+ <input type="radio" name="admin_bar_notif" id="admin_bar_notif_on" style="margin-top: -2px;" <?php checked( $abn ); ?> value="1">
555
+ <span><?php esc_html_e( 'Yes', 'wp-security-audit-log' ); ?></span>
556
+ </label>
557
+ <br/>
558
+ <label for="admin_bar_notif_off">
559
+ <input type="radio" name="admin_bar_notif" id="admin_bar_notif_off" style="margin-top: -2px;" <?php checked( $abn, false ); ?> value="0">
560
+ <span><?php esc_html_e( 'No', 'wp-security-audit-log' ); ?></span>
561
+ </label>
562
+ </fieldset>
563
+ </td>
564
+ </tr>
565
+ <!-- / Admin Bar Notification -->
566
+
567
+ <tr>
568
+ <?php
569
+ $disabled = '';
570
+ $label = __( 'Admin Bar Notification Updates', 'wp-security-audit-log' );
571
+ if ( wsal_freemius()->is_free_plan() ) {
572
+ $disabled = 'disabled';
573
+ $label = __( 'Admin Bar Notification Updates (Premium)', 'wp-security-audit-log' );
574
+ }
575
+ ?>
576
+ <th><label for="admin_bar_notif_refresh"><?php echo esc_html( $label ); ?></label></th>
577
+ <td>
578
+ <fieldset <?php echo esc_attr( $disabled ); ?>>
579
+ <?php $abn_updates = $this->_plugin->settings()->get_admin_bar_notif_updates(); ?>
580
+ <label for="admin_bar_notif_realtime">
581
+ <input type="radio" name="admin_bar_notif_updates" id="admin_bar_notif_realtime" style="margin-top: -2px;" <?php checked( $abn_updates, 'real-time' ); ?> value="real-time">
582
+ <span><?php esc_html_e( 'Update in near real time', 'wp-security-audit-log' ); ?></span>
583
+ </label>
584
+ <br/>
585
+ <label for="admin_bar_notif_refresh">
586
+ <input type="radio" name="admin_bar_notif_updates" id="admin_bar_notif_refresh" style="margin-top: -2px;" <?php checked( $abn_updates, 'page-refresh' ); ?> value="page-refresh">
587
+ <span><?php esc_html_e( 'Update only on page refreshes', 'wp-security-audit-log' ); ?></span>
588
+ </label>
589
+ </fieldset>
590
+ </td>
591
+ </tr>
592
+ <!-- / Admin Bar Notification Updates -->
593
+ </tbody>
594
+ </table>
595
+ <!-- Dashboard Widget -->
596
+
597
+ <h3><?php esc_html_e( 'Add user notification on the WordPress login page', 'wp-security-audit-log' ); ?></h3>
598
+ <p class="description"><?php esc_html_e( 'Many compliance regulations (such as the GDPR) require website administrators to tell the users of their website that all the changes they do when logged in are being logged.', 'wp-security-audit-log' ); ?></p>
599
+ <table class="form-table wsal-tab">
600
+ <tbody>
601
+ <tr>
602
+ <th><label for="login_page_notification"><?php esc_html_e( 'Login Page Notification', 'wp-security-audit-log' ); ?></label></th>
603
+ <td>
604
+ <fieldset>
605
+ <?php
606
+ // Get login page notification checkbox.
607
+ $wsal_lpn = $this->_plugin->settings()->is_login_page_notification();
608
+ if ( $wsal_lpn && 'true' === $wsal_lpn ) {
609
+ // If option exists, value is true then set to true.
610
+ $wsal_lpn = true;
611
+ } elseif ( $wsal_lpn && 'false' === $wsal_lpn ) {
612
+ // If option exists, value is false then set to false.
613
+ $wsal_lpn = false;
614
+ } elseif ( ! $wsal_lpn ) {
615
+ // Default option value.
616
+ $wsal_lpn = false;
617
+ }
618
+ ?>
619
+ <label for="wsal_lpn_yes">
620
+ <input type="radio" name="login_page_notification" id="wsal_lpn_yes" <?php checked( $wsal_lpn ); ?> value="true" />
621
+ <?php esc_html_e( 'Yes', 'wp-security-audit-log' ); ?>
622
+ </label>
623
+ <br />
624
+ <?php
625
+ // Get login page notification text.
626
+ $wsal_lpn_text = $this->_plugin->settings()->get_login_page_notification_text();
627
+ $wsal_lpn_text_default = __( 'For security and auditing purposes, a record of all of your logged-in actions and changes within the WordPress dashboard will be recorded in an activity log with the <a href="https://wpactivitylog.com/?utm_source=plugin&utm_medium=referral&utm_campaign=WSAL&utm_content=settings+pages" target="_blank">WP Activity Log plugin</a>. The audit log also includes the IP address where you accessed this site from.', 'wp-security-audit-log' );
628
+
629
+ // Allowed HTML tags for this setting.
630
+ $allowed_tags = array(
631
+ 'a' => array(
632
+ 'href' => array(),
633
+ 'title' => array(),
634
+ 'target' => array(),
635
+ ),
636
+ );
637
+ ?>
638
+ <textarea name="login_page_notification_text"
639
+ id="login_page_notification_text"
640
+ cols="60" rows="6"
641
  <?php echo ( $wsal_lpn ) ? false : 'disabled'; ?>
642
  ><?php echo ( $wsal_lpn_text ) ? wp_kses( $wsal_lpn_text, $allowed_tags ) : wp_kses( $wsal_lpn_text_default, $allowed_tags ); ?></textarea>
643
+ <br/>
644
+ <p class="description">
645
+ <?php echo wp_kses( __( '<strong>Note: </strong>', 'wp-security-audit-log' ), $this->_plugin->allowed_html_tags ) . esc_html__( 'The only HTML code allowed in the login page notification is for links ( < a href >< /a > ).', 'wp-security-audit-log' ); ?>
646
+ </p>
647
+ <br />
648
+
649
+ <label for="wsal_lpn_no">
650
+ <input type="radio" name="login_page_notification" id="wsal_lpn_no" <?php checked( $wsal_lpn, false ); ?> value="false" />
651
+ <?php esc_html_e( 'No', 'wp-security-audit-log' ); ?>
652
+ </label>
653
+ </fieldset>
654
+ </td>
655
+ </tr>
656
+ <!-- / Login Page Notification -->
657
+ </tbody>
658
+ </table>
659
+ <!-- Login Page Notification -->
660
+
661
+ <h3><?php esc_html_e( 'Is your website running behind a firewall or reverse proxy?', 'wp-security-audit-log' ); ?></h3>
662
+ <p class="description">
663
  <?php
664
  echo sprintf(
665
  /* translators: Learn more link. */
667
  '<a href="https://wpactivitylog.com/support/kb/support-reverse-proxies-web-application-firewalls/?utm_source=plugin&utm_medium=referral&utm_campaign=WSAL&utm_content=settings+pages" target="_blank">' . esc_html__( 'learn more', 'wp-security-audit-log' ) . '</a>'
668
  );
669
  ?>
670
+ </p>
671
+ <table class="form-table wsal-tab">
672
+ <tbody>
673
+ <tr>
674
+ <th><label for="pioption_on"><?php esc_html_e( 'Reverse Proxy / Firewall Options', 'wp-security-audit-log' ); ?></label></th>
675
+ <td>
676
+ <fieldset>
677
+ <label for="enable_proxy_ip_capture_yes">
678
+ <input type="radio" name="EnableProxyIpCapture" value="1" id="enable_proxy_ip_capture_yes" <?php checked( $this->_plugin->settings()->IsMainIPFromProxy() ); ?> />
679
+ <?php esc_html_e( 'Yes', 'wp-security-audit-log' ); ?>
680
+ </label>
681
+ <br/>
682
+ <label for="EnableIpFiltering">
683
+ <input type="checkbox" name="EnableIpFiltering" value="1" id="EnableIpFiltering" <?php checked( $this->_plugin->settings()->IsInternalIPsFiltered() ); ?> />
684
+ <?php esc_html_e( 'Filter internal IP addresses from the proxy headers. Enable this option only if you are are still seeing the internal IP addresses of the firewall or proxy.', 'wp-security-audit-log' ); ?>
685
+ </label>
686
+ <br/>
687
+ <label for="enable_proxy_ip_capture_no">
688
+ <input type="radio" name="EnableProxyIpCapture" value="0" id="enable_proxy_ip_capture_no" <?php checked( $this->_plugin->settings()->IsMainIPFromProxy(), false ); ?> />
689
+ <?php esc_html_e( 'No', 'wp-security-audit-log' ); ?>
690
+ </label>
691
+ <br />
692
+ </fieldset>
693
+ </td>
694
+ </tr>
695
+ <!-- / Reverse Proxy / Firewall Options -->
696
+ </tbody>
697
+ </table>
698
+ <!-- Reverse Proxy -->
699
+
700
+ <h3><?php esc_html_e( 'Who can change the plugin settings?', 'wp-security-audit-log' ); ?></h3>
701
+ <p class="description">
702
+ <?php
703
+ $allowed_tags = array(
704
+ 'a' => array(
705
+ 'href' => true,
706
+ 'target' => true,
707
+ ),
708
+ );
709
+ echo wp_kses(
710
+ sprintf(
711
  /* translators: Learn more link. */
712
+ esc_html__( 'By default only users with administrator role (single site) and super administrator role (multisite) can change the settings of the plugin. Though you can restrict the privileges to just your user - %s.', 'wp-security-audit-log' ),
713
+ '<a href="https://wpactivitylog.com/support/kb/managing-wordpress-activity-log-plugin-privileges/?utm_source=plugin&utm_medium=referral&utm_campaign=WSAL&utm_content=settings+pages" target="_blank">' . __( 'learn more', 'wp-security-audit-log' ) . '</a>'
714
+ ),
715
+ $allowed_tags
716
+ );
717
+ $restrict_settings = $this->_plugin->settings()->get_restrict_plugin_setting();
718
+ ?>
719
+ </p>
720
+ <table class="form-table wsal-tab">
721
+ <tbody>
722
+ <tr>
723
+ <th><label for="RestrictAdmins"><?php esc_html_e( 'Restrict plugin access', 'wp-security-audit-log' ); ?></label></th>
724
+ <td>
725
+ <fieldset>
726
+ <label for="only_me">
727
+ <input type="radio" name="restrict-plugin-settings" id="only_me" value="only_me" <?php checked( $restrict_settings, 'only_me' ); ?> />
728
+ <?php esc_html_e( 'Only me', 'wp-security-audit-log' ); ?>
729
+ </label>
730
+ <br/>
731
+ <label for="only_admins">
732
+ <input type="radio" name="restrict-plugin-settings" id="only_admins" value="only_admins" <?php checked( $restrict_settings, 'only_admins' ); ?> />
733
+ <?php
734
+ if ( $this->_plugin->IsMultisite() ) {
735
+ esc_html_e( 'All superadmins', 'wp-security-audit-log' );
736
+ } else {
737
+ esc_html_e( 'All administrators', 'wp-security-audit-log' );
738
+ }
739
+ ?>
740
+ <?php ?>
741
+ </label>
742
+ <br/>
743
+ </fieldset>
744
+ </td>
745
+ </tr>
746
+ <!-- / Restrict Plugin Access -->
747
+ </tbody>
748
+ </table>
749
+ <!-- Restrict Plugin Access -->
750
+
751
+ <h3><?php esc_html_e( 'Allow other users to view the activity log', 'wp-security-audit-log' ); ?></h3>
752
+ <p class="description">
753
+ <?php
754
+ $allowed_tags = array(
755
+ 'a' => array(
756
+ 'href' => true,
757
+ 'target' => true,
758
+ ),
759
+ );
760
+ $is_multisite = $this->_plugin->IsMultisite();
761
+ $section_label = '';
762
+ if ($is_multisite) {
763
+ $section_label = esc_html__('By default only super administrators and the child sites\' administrators can view the WordPress activity log. Though you can change this by using the setting below.', 'wp-security-audit-log');
764
+ } else {
765
+ $section_label = esc_html__('By default only users with administrator role can view the WordPress activity log. To allow someone who does not have an admin role to view the activity log, specify them in the below setting.', 'wp-security-audit-log');
766
+ }
767
+
768
+ echo wp_kses(
769
+ $section_label . ' - <a href="https://wpactivitylog.com/support/kb/allow-users-read-access-activity-log/?utm_source=plugin&utm_medium=referral&utm_campaign=WSAL&utm_content=settings+pages" target="_blank">' . __( 'learn more', 'wp-security-audit-log' ) . '</a>',
770
+ $allowed_tags
771
+ );
772
+ ?>
773
+ </p>
774
+ <?php if ( $is_multisite ): ?>
775
+ <table class="form-table wsal-tab">
776
+ <tbody>
777
+ <tr>
778
+ <th><?php esc_html_e( 'Can view events', 'wp-security-audit-log' ); ?></th>
779
+ <td>
780
+ <fieldset>
781
+ <?php
782
+ $restrict_settings = $this->_plugin->settings()->get_restrict_log_viewer();
783
+ $viewer_restriction_options = array(
784
+ 'only_me' => __('Only me', 'wp-security-audit-log'),
785
+ 'only_superadmins' => __('Super administators only', 'wp-security-audit-log'),
786
+ 'only_admins' => __('Super administators and site administrators', 'wp-security-audit-log'),
787
+ );
788
+ ?>
789
+ <?php foreach ($viewer_restriction_options as $option => $label): ?>
790
+ <label for="log_viewer_<?php echo $option; ?>">
791
+ <?php $disabled = ('only_me' === $option && 'only_superadmins' === $restrict_settings); ?>
792
+ <input type="radio" name="restrict-log-viewer" id="log_viewer_<?php echo $option; ?>" value="<?php echo $option; ?>" <?php checked( $restrict_settings, $option ); ?> <?php disabled( $disabled ); ?> />
793
+ <?php echo esc_html( $label ); ?>
794
+ </label>
795
+ <br/>
796
+ <?php endforeach; ?>
797
+ </fieldset>
798
+ </td>
799
+ </tr>
800
+ </tbody>
801
+ </table>
802
+ <p class="description"><?php esc_html_e('To allow someone who does not have an admin role to view the activity log, specify them in the below setting.', 'wp-security-audit-log'); ?></p>
803
+ <?php endif; ?>
804
+ <table class="form-table wsal-tab">
805
+ <tbody>
806
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
807
  <tr>
808
+ <?php $row_label = $is_multisite ? esc_html__( 'Can also view events', 'wp-security-audit-log' ) : esc_html__( 'Can view events', 'wp-security-audit-log' ); ?>
809
+ <th><label for="ViewerQueryBox"><?php echo $row_label; ?></label></th>
810
  <td>
811
  <fieldset>
812
  <label>
820
 
821
  <div id="ViewerList">
822
  <?php
823
+ foreach ( $this->_plugin->settings()->GetAllowedPluginViewers() as $item ) :
824
  if ( wp_get_current_user()->user_login === $item ) {
825
  continue;
826
  }
848
  <th><label for="FromEmail"><?php esc_html_e( 'From Email & Name', 'wp-security-audit-log' ); ?></label></th>
849
  <td>
850
  <fieldset>
851
+ <?php $use_email = $this->_plugin->GetGlobalSetting( 'use-email', 'default_email' ); ?>
852
  <label for="default_email">
853
  <input type="radio" name="use-email" id="default_email" value="default_email" <?php checked( $use_email, 'default_email' ); ?> />
854
  <?php esc_html_e( 'Use the email address from the WordPress general settings', 'wp-security-audit-log' ); ?>
861
  <br>
862
  <label for="FromEmail">
863
  <?php esc_html_e( 'Email Address', 'wp-security-audit-log' ); ?>
864
+ <input type="email" id="FromEmail" name="FromEmail" value="<?php echo esc_attr( $this->_plugin->settings()->GetFromEmail() ); ?>" />
865
  </label>
866
  <br>
867
  <label for="DisplayName">
868
  <?php esc_html_e( 'Display Name', 'wp-security-audit-log' ); ?>&nbsp;
869
+ <input type="text" id="DisplayName" name="DisplayName" value="<?php echo esc_attr( $this->_plugin->settings()->GetDisplayName() ); ?>" />
870
  </label>
871
  </fieldset>
872
  </td>
885
  <td>
886
  <fieldset>
887
  <label for="incognito_yes">
888
+ <input type="radio" name="Incognito" value="yes" id="incognito_yes" <?php checked( $this->_plugin->settings()->IsIncognito() ); ?> />
889
  <?php esc_html_e( 'Yes, hide the plugin from the list of installed plugins', 'wp-security-audit-log' ); ?>
890
  </label>
891
  <br/>
892
  <label for="incognito_no">
893
+ <input type="radio" name="Incognito" value="no" id="incognito_no" <?php checked( $this->_plugin->settings()->IsIncognito(), false ); ?> />
894
  <?php esc_html_e( 'No, do not hide the plugin', 'wp-security-audit-log' ); ?>
895
  </label>
896
  </fieldset>
910
  // Get $_POST global array.
911
  $post_array = filter_input_array( INPUT_POST );
912
 
913
+ $this->_plugin->settings()->SetRefreshAlertsEnabled( $post_array['EnableAuditViewRefresh'] );
914
+ $this->_plugin->settings()->set_events_type_nav( sanitize_text_field( $post_array['events-type-nav'] ) );
915
+ $this->_plugin->settings()->set_use_email( sanitize_text_field( $post_array['use-email'] ) );
916
+ $this->_plugin->settings()->SetFromEmail( sanitize_email( $post_array['FromEmail'] ) );
917
+ $this->_plugin->settings()->SetDisplayName( sanitize_text_field( $post_array['DisplayName'] ) );
918
 
919
+ $this->_plugin->settings()->SetWidgetsEnabled( sanitize_text_field( $post_array['EnableDashboardWidgets'] ) );
920
 
921
  if ( ! wsal_freemius()->is_free_plan() ) {
922
+ $this->_plugin->settings()->set_admin_bar_notif( sanitize_text_field( $post_array['admin_bar_notif'] ) );
923
+ $this->_plugin->settings()->set_admin_bar_notif_updates( sanitize_text_field( $post_array['admin_bar_notif_updates'] ) );
924
+ }
925
+
926
+ // handle log viewer settings in multisite context
927
+ if ($this->_plugin->IsMultisite()) {
928
+ $log_viewer_restrictions = isset( $post_array['restrict-log-viewer'] ) ? sanitize_text_field( $post_array['restrict-log-viewer'] ) : '';
929
+ $this->_plugin->settings()->set_restrict_log_viewer($log_viewer_restrictions);
930
+ if ( 'only_me' === $log_viewer_restrictions ) {
931
+ $this->_plugin->settings()->set_only_me_user_id(get_current_user_id());
932
+ }
933
  }
934
 
935
  // Get plugin viewers.
936
  $viewers = isset( $post_array['Viewers'] ) ? array_map( 'sanitize_text_field', $post_array['Viewers'] ) : array();
937
+ $this->_plugin->settings()->SetAllowedPluginViewers( $viewers );
938
 
939
+ // handle plugin settings permissions
 
940
  $restrict_settings = isset( $post_array['restrict-plugin-settings'] ) ? sanitize_text_field( $post_array['restrict-plugin-settings'] ) : false;
941
+ $this->_plugin->settings()->set_restrict_plugin_setting( $restrict_settings );
942
+ if ( 'only_me' === $restrict_settings ) {
943
+ $this->_plugin->settings()->set_only_me_user_id(get_current_user_id());
 
 
 
 
 
 
944
  }
 
945
 
946
+ $this->_plugin->settings()->set_login_page_notification( isset( $post_array['login_page_notification'] ) ? sanitize_text_field( $post_array['login_page_notification'] ) : false );
947
+ $this->_plugin->settings()->set_login_page_notification_text( isset( $post_array['login_page_notification_text'] ) ? $post_array['login_page_notification_text'] : false );
948
+ $this->_plugin->settings()->SetMainIPFromProxy( isset( $post_array['EnableProxyIpCapture'] ) ? sanitize_text_field( $post_array['EnableProxyIpCapture'] ) : false );
949
+ $this->_plugin->settings()->SetInternalIPsFiltering( isset( $post_array['EnableIpFiltering'] ) ? sanitize_text_field( $post_array['EnableIpFiltering'] ) : false );
 
950
 
951
+ $is_incognito = isset( $post_array['Incognito'] ) ? \WSAL\Helpers\Options::string_to_bool( sanitize_text_field( $post_array['Incognito'] ) ) : false;
952
+ $this->_plugin->settings()->SetIncognito( $is_incognito );
 
 
 
 
953
  }
954
 
955
  /**
957
  */
958
  private function tab_audit_log() {
959
  ?>
960
+ <h3><?php esc_html_e( 'For how long do you want to keep the activity log events (Retention settings) ?', 'wp-security-audit-log' ); ?></h3>
961
+ <p class="description">
962
  <?php
963
  esc_html_e( 'The plugin uses an efficient way to store the activity log data in the WordPress database, though the more data you keep the more disk space will be required. ', 'wp-security-audit-log' );
964
  $retention_help_text = __( '<a href="https://wpactivitylog.com/pricing/?utm_source=plugin&utm_medium=referral&utm_campaign=WSAL&utm_content=settings+pages" target="_blank">Upgrade to Premium</a> to store the activity log data in an external database.', 'wp-security-audit-log' );
965
 
 
 
 
 
966
  echo wp_kses( $retention_help_text, $this->_plugin->allowed_html_tags );
967
  ?>
968
+ </p>
969
+ <?php if ( $this->_plugin->settings()->IsArchivingEnabled() ) : ?>
970
+ <p class="description">
971
  <?php
972
  $archiving_args = array(
973
  'page' => 'wsal-ext-settings',
977
  /* translators: 1: Archive page link tag. 2: Link closing tag. */
978
  echo '<span class="dashicons dashicons-warning"></span> ' . sprintf( esc_html__( 'Retention settings moved to %1$s archiving settings %2$s because archiving is enabled', 'wp-security-audit-log' ), '<a href="' . esc_url( $archiving_page ) . '" target="_blank">', '</a>' );
979
  ?>
980
+ </p>
981
  <?php else : ?>
982
  <table class="form-table wsal-tab">
983
  <tbody>
984
  <tr>
985
+ <th><label for="delete1"><?php esc_html_e( 'Activity log retention', 'wp-security-audit-log' ); ?></label></th>
986
  <td>
987
  <fieldset>
988
+ <?php $nbld = ! $this->_plugin->settings()->IsPruningDateEnabled(); ?>
989
  <label for="delete0">
990
  <input type="radio" id="delete0" name="PruneBy" value="" <?php checked( $nbld ); ?> />
991
  <?php echo esc_html__( 'Keep all data', 'wp-security-audit-log' ); ?>
995
  <fieldset>
996
  <?php
997
  // Check pruning date option.
998
+ $nbld = $this->_plugin->settings()->IsPruningDateEnabled();
999
 
1000
  // Find and replace ` months` in the string.
1001
+ $pruning_date = $this->_plugin->settings()->GetPruningDate();
1002
  $pruning_date = str_replace( ' months', '', $pruning_date );
1003
  $pruning_date = str_replace( ' years', '', $pruning_date );
1004
+ $pruning_unit = $this->_plugin->settings()->get_pruning_unit();
1005
 
1006
  // Check if pruning limit was enabled for backwards compatibility.
1007
+ if ( $this->_plugin->settings()->IsPruningLimitEnabled() ) {
1008
  $nbld = true;
1009
  $pruning_date = '6';
1010
  $pruning_unit = 'months';
1011
+ $this->_plugin->settings()->SetPruningDate( $pruning_date . ' ' . $pruning_unit );
1012
+ $this->_plugin->settings()->SetPruningDateEnabled( true );
1013
+ $this->_plugin->settings()->SetPruningLimitEnabled( false );
1014
  }
1015
  ?>
1016
  <label for="delete1">
1027
  </select>
1028
  </fieldset>
1029
 
1030
+ <?php if ( $this->_plugin->settings()->IsPruningDateEnabled() ) : ?>
1031
  <p class="description">
1032
  <?php
1033
  $next = wp_next_scheduled( 'wsal_cleanup' );
1047
  <?php endif; ?>
1048
  </td>
1049
  </tr>
1050
+ <!-- Activity log retention -->
1051
  </tbody>
1052
  </table>
1053
  <?php endif; ?>
1054
+ <!-- Activity log retention -->
1055
 
1056
  <h3><?php esc_html_e( 'What timestamp you would like to see in the WordPress activity log?', 'wp-security-audit-log' ); ?></h3>
1057
  <p class="description"><?php esc_html_e( 'Note that the WordPress\' timezone might be different from that configured on the server so when you switch from UTC to WordPress timezone or vice versa you might notice a big difference.', 'wp-security-audit-log' ); ?></p>
1062
  <td>
1063
  <fieldset>
1064
  <?php
1065
+ $timezone = $this->_plugin->settings()->GetTimezone();
1066
 
1067
  /**
1068
  * Transform timezone values.
1094
  <th><?php esc_html_e( 'Show Milliseconds', 'wp-security-audit-log' ); ?></th>
1095
  <td>
1096
  <fieldset>
1097
+ <?php $show_milliseconds = $this->_plugin->settings()->get_show_milliseconds(); ?>
 
 
 
 
 
 
 
 
 
1098
  <label for="show_milliseconds">
1099
  <input type="checkbox" name="show_milliseconds" id="show_milliseconds" style="margin-top: -2px;"
1100
+ <?php checked( $show_milliseconds ); ?> value="yes">
1101
  <?php esc_html_e( 'Show Milliseconds in list view', 'wp-security-audit-log' ); ?>
1102
  </label>
1103
  </fieldset>
1113
  <table class="form-table wsal-tab">
1114
  <tbody>
1115
  <tr>
1116
+ <th><label for="timezone-default"><?php esc_html_e( 'User information in Activity log', 'wp-security-audit-log' ); ?></label></th>
1117
  <td>
1118
  <fieldset>
1119
+ <?php $type_username = $this->_plugin->settings()->get_type_username(); ?>
1120
  <label for="column_username">
1121
  <input type="radio" name="type_username" id="column_username" style="margin-top: -2px;" <?php checked( $type_username, 'username' ); ?> value="username">
1122
+ <span><?php esc_html_e( 'WordPress username', 'wp-security-audit-log' ); ?></span>
1123
  </label>
1124
  <br/>
1125
  <label for="columns_first_last_name">
1126
  <input type="radio" name="type_username" id="columns_first_last_name" style="margin-top: -2px;" <?php checked( $type_username, 'first_last_name' ); ?> value="first_last_name">
1127
+ <span><?php esc_html_e( 'First name & last name', 'wp-security-audit-log' ); ?></span>
1128
  </label>
1129
  <br/>
1130
  <label for="columns_display_name">
1131
  <input type="radio" name="type_username" id="columns_display_name" style="margin-top: -2px;" <?php checked( $type_username, 'display_name' ); ?> value="display_name">
1132
+ <span><?php esc_html_e( 'Configured public display name', 'wp-security-audit-log' ); ?></span>
1133
  </label>
1134
  </fieldset>
1135
  </td>
1144
  <table class="form-table wsal-tab">
1145
  <tbody>
1146
  <tr>
1147
+ <th><label for="columns"><?php esc_html_e( 'Activity log columns selection', 'wp-security-audit-log' ); ?></label></th>
1148
  <td>
1149
  <fieldset>
1150
+ <?php $columns = $this->_plugin->settings()->GetColumns(); ?>
1151
  <?php foreach ( $columns as $key => $value ) { ?>
1152
  <label for="columns">
1153
  <input type="checkbox" name="Columns[<?php echo esc_attr( $key ); ?>]" id="<?php echo esc_attr( $key ); ?>" class="sel-columns" style="margin-top: -2px;"
1173
  </fieldset>
1174
  </td>
1175
  </tr>
1176
+ <!-- Activity log columns selection -->
1177
  </tbody>
1178
  </table>
1179
+ <!-- Activity log columns -->
1180
 
1181
+ <?php $is_wp_backend = $this->_plugin->settings()->IsWPBackend(); ?>
1182
  <h3><?php esc_html_e( 'Do you want to keep a log of WordPress background activity?', 'wp-security-audit-log' ); ?></h3>
1183
  <p class="description">
1184
  <?php esc_html_e( 'WordPress does a lot of things in the background that you do not necessarily need to know about, such as; deletion of post revisions, deletion of auto saved drafts etc. By default the plugin does not report them since there might be a lot and are irrelevant to the user.', 'wp-security-audit-log' ); ?>
1190
  <td>
1191
  <fieldset>
1192
  <label for="wp_backend_yes">
1193
+ <input type="radio" name="WPBackend" value="1" id="wp_backend_yes" <?php checked( $is_wp_backend ); ?> />
1194
  <?php esc_html_e( 'Yes', 'wp-security-audit-log' ); ?>
1195
  </label>
1196
  <br/>
1197
  <label for="wp_backend_no">
1198
+ <input type="radio" name="WPBackend" value="0" id="wp_backend_no" <?php checked( ! $is_wp_backend ); ?> />
1199
  <?php esc_html_e( 'No', 'wp-security-audit-log' ); ?>
1200
  </label>
1201
  </fieldset>
1220
  $pruning_unit = isset( $post_array['pruning-unit'] ) ? sanitize_text_field( $post_array['pruning-unit'] ) : false;
1221
  $pruning_date = ( ! empty( $pruning_date ) && ! empty( $pruning_unit ) ) ? $pruning_date . ' ' . $pruning_unit : false;
1222
 
1223
+ $this->_plugin->settings()->SetPruningDateEnabled( isset( $post_array['PruneBy'] ) ? 'date' === $post_array['PruneBy'] : '' );
1224
+ $this->_plugin->settings()->SetPruningDate( $pruning_date );
1225
+ $this->_plugin->settings()->set_pruning_unit( $pruning_unit );
1226
+ $this->_plugin->settings()->SetTimezone( $post_array['Timezone'] );
1227
+ $this->_plugin->settings()->set_type_username( $post_array['type_username'] );
1228
+ $this->_plugin->settings()->SetWPBackend( isset( $post_array['WPBackend'] ) ? sanitize_text_field( $post_array['WPBackend'] ) : false );
1229
  if ( ! empty( $post_array['Columns'] ) ) {
1230
+ $this->_plugin->settings()->SetColumns( $post_array['Columns'] );
1231
  }
1232
  $show_milliseconds = ( isset( $post_array['show_milliseconds'] ) && 'yes' === $post_array['show_milliseconds'] ) ? true : false;
1233
+ $this->_plugin->settings()->set_show_milliseconds( $show_milliseconds );
1234
  }
1235
 
1236
  /**
1245
  <?php if ( ! defined( 'WFCM_PLUGIN_FILE' ) ) : ?>
1246
  <div class="addon-wrapper" style="max-width: 380px; text-align: center; border: 1px solid #ccc; padding: 25px;">
1247
  <img src="<?php echo trailingslashit( WSAL_BASE_URL ) . 'img/help/website-file-changes-monitor.jpg'; ?>">
1248
+ <h4><?php echo esc_html__( 'Website File Changes Monitor', 'wp-security-audit-log' ); ?></h4>
1249
+ <p><?php echo esc_html__( 'To keep a log of file changes please install Website File Changes Monitor, a plugin which is also developed by us.', 'wp-security-audit-log' ); ?></p><br>
1250
+ <p><button class="install-addon button button-primary" data-nonce="<?php echo esc_attr( wp_create_nonce( 'wsal-install-addon' ) ); ?>" data-plugin-slug="website-file-changes-monitor/website-file-changes-monitor.php" data-plugin-download-url="https://downloads.wordpress.org/plugin/website-file-changes-monitor.latest-stable.zip"><?php _e( 'Install plugin now', 'wp-security-audit-log' ); ?></button><span class="spinner" style="display: none; visibility: visible; float: none; margin: 0 0 0 8px;"></span> <a href="https://wpactivitylog.com/support/kb/wordpress-files-changes-warning-activity-logs/?utm_source=plugin&utm_medium=referral&utm_campaign=WSAL&utm_content=settings+pages" target="_blank" style="margin-left: 15px;"><?php echo esc_html__( 'Learn More', 'wp-security-audit-log' ); ?></a></p>
1251
  </div>
1252
  <?php else : ?>
1253
  <?php
1261
  $wcfm_settings_page = add_query_arg( $redirect_args, network_admin_url( 'admin.php' ) );
1262
  }
1263
  ?>
1264
+ <p><?php echo esc_html__( 'Configure how often file changes scan run and other settings from the', 'wp-security-audit-log' ); ?> <a class="button button-primary" href="<?php echo esc_url( $wcfm_settings_page ); ?>"><?php echo esc_html__( 'Website File Changes plugin settings', 'wp-security-audit-log' ); ?></a></p>
1265
  <?php endif; ?>
1266
  </tr>
1267
  </tbody>
1287
  <input type="button" id="ExUserQueryAdd" class="button-primary" value="Add">
1288
  <br style="clear: both;"/>
1289
  <div id="ExUserList">
1290
+ <?php foreach ( $this->_plugin->settings()->GetExcludedMonitoringUsers() as $item ) : ?>
1291
  <span class="sectoken-<?php echo esc_attr( $this->GetTokenType( $item ) ); ?>">
1292
  <input type="hidden" name="ExUsers[]" value="<?php echo esc_attr( $item ); ?>"/>
1293
  <?php echo esc_html( $item ); ?>
1308
  <input type="button" id="ExRoleQueryAdd" class="button-primary" value="Add">
1309
  <br style="clear: both;"/>
1310
  <div id="ExRoleList">
1311
+ <?php foreach ( $this->_plugin->settings()->GetExcludedMonitoringRoles() as $item ) : ?>
1312
  <span class="sectoken-<?php echo esc_attr( $this->GetTokenType( $item ) ); ?>">
1313
  <input type="hidden" name="ExRoles[]" value="<?php echo esc_attr( $item ); ?>"/>
1314
  <?php echo esc_html( $item ); ?>
1329
  <input type="button" id="IpAddrQueryAdd" class="button-primary" value="Add">
1330
  <br style="clear: both;"/>
1331
  <div id="IpAddrList">
1332
+ <?php foreach ( $this->_plugin->settings()->GetExcludedMonitoringIP() as $item ) : ?>
1333
  <span class="sectoken-<?php echo esc_attr( $this->GetTokenType( $item ) ); ?>">
1334
  <input type="hidden" name="IpAddrs[]" value="<?php echo esc_attr( $item ); ?>"/>
1335
  <?php echo esc_html( $item ); ?>
1336
  <a href="javascript:;" title="Remove">&times;</a>
1337
  </span>
1338
+ <?php endforeach; ?>
1339
+ </div>
1340
+ </fieldset>
1341
+ <p class="description"><?php esc_html_e( 'You can exclude an individual IP address or a range of IP addresses. To exclude a range use the following format: [first IP]-[last octet of the last IP]. Example: 172.16.180.6-127.', 'wp-security-audit-log' ); ?></p>
1342
+ </td>
1343
+ </tr>
1344
+ <!-- Exclude IP Addresses -->
1345
+
1346
+ <tr>
1347
+ <th><label for="ExCPTsQueryBox"><?php esc_html_e( 'Exclude Post Type:', 'wp-security-audit-log' ); ?></label></th>
1348
+ <td>
1349
+ <fieldset>
1350
+ <input type="text" id="ExCPTsQueryBox" style="width: 250px;">
1351
+ <input type="button" id="ExCPTsQueryAdd" class="button-primary" value="Add">
1352
+ <br style="clear: both;"/>
1353
+ <div id="ExCPTsList">
1354
+ <?php foreach ( $this->_plugin->settings()->get_excluded_post_types() as $item ) : ?>
1355
+ <span class="sectoken-<?php echo esc_attr( $this->GetTokenType( $item ) ); ?>">
1356
  <input type="hidden" name="ExCPTss[]" value="<?php echo esc_attr( $item ); ?>"/>
1357
  <?php echo esc_html( $item ); ?>
1358
  <a href="javascript:;" title="Remove">&times;</a>
1359
  </span>
1360
+ <?php endforeach; ?>
1361
+ </div>
1362
+ </fieldset>
1363
+ <p class="description"><?php esc_html_e( 'WordPress has the post and page post types by default though your website might use more post types (custom post types). You can exclude all post types, including the default WordPress ones.', 'wp-security-audit-log' ); ?></p>
1364
+ </td>
1365
+ </tr>
1366
+ <!-- Exclude Custom Post Types -->
1367
+
1368
+ <tr>
1369
+ <th><label for="CustomQueryBox"><?php esc_html_e( 'Exclude Custom Fields:', 'wp-security-audit-log' ); ?></label></th>
1370
+ <td>
1371
+ <fieldset>
1372
+ <input type="text" id="CustomQueryBox" style="width: 250px;">
1373
+ <input type="button" id="CustomQueryAdd" class="button-primary" value="Add">
1374
+ <br style="clear: both;"/>
1375
+ <div id="CustomList">
1376
+ <?php foreach ( $this->_plugin->settings()->GetExcludedMonitoringCustom() as $item ) : ?>
1377
+ <span class="sectoken-<?php echo esc_attr( $this->GetTokenType( $item ) ); ?>">
1378
  <input type="hidden" name="Customs[]" value="<?php echo esc_attr( $item ); ?>"/>
1379
  <?php echo esc_html( $item ); ?>
1380
  <a href="javascript:;" title="Remove">&times;</a>
1381
  </span>
1382
+ <?php endforeach; ?>
1383
+ </div>
1384
+ </fieldset>
1385
+ <p class="description"><?php esc_html_e( 'You can use the * wildcard to exclude multiple matching custom fields. For example to exclude all custom fields starting with wp123 enter wp123*', 'wp-security-audit-log' ); ?></p>
1386
+ </td>
1387
+ </tr>
1388
+ <!-- Exclude Custom Fields -->
1389
+
1390
+ <tr>
1391
+ <th><label for="ExURLsQueryBox"><?php esc_html_e( 'Exclude Non-Existing URLs:', 'wp-security-audit-log' ); ?></label></th>
1392
+ <td>
1393
+ <fieldset>
1394
+ <input type="text" id="ExURLsQueryBox" style="width: 250px;">
1395
+ <input type="button" id="ExURLsQueryAdd" class="button-primary" value="Add">
1396
+ <br style="clear: both;"/>
1397
+ <div id="ExURLsList">
1398
+ <?php foreach ( $this->_plugin->settings()->get_excluded_urls() as $item ) : ?>
1399
+ <span class="sectoken-<?php echo esc_attr( $this->GetTokenType( $item ) ); ?>">
1400
  <input type="hidden" name="ExURLss[]" value="<?php echo esc_attr( $item ); ?>"/>
1401
  <?php echo esc_html( $item ); ?>
1402
  <a href="javascript:;" title="Remove">&times;</a>
1403
  </span>
1404
+ <?php endforeach; ?>
1405
+ </div>
1406
+ </fieldset>
1407
+ <p class="description"><?php esc_html_e( 'Add the non existing URLs for which you do not want to be alerted of HTTP 404 errors in the activity log by specifying the complete URL. Examples below:', 'wp-security-audit-log' ); ?><br><?php echo esc_html__( 'File: ', 'wp-security-audit-log' ) . esc_url( home_url() ) . '/subdirectory/file.php'; ?><br><?php echo esc_html__( 'Directory: ', 'wp-security-audit-log' ) . esc_url( home_url() ) . '/subdirectory/subdirectory2'; ?></p>
1408
+ </td>
1409
+ </tr>
1410
+ <!-- Exclude 404 URLs -->
1411
+ </tbody>
1412
+ </table>
1413
+ <!-- / Exclude Objects Tab -->
1414
  <?php
1415
  }
1416
 
1421
  // Get $_POST global array.
1422
  $post_array = filter_input_array( INPUT_POST );
1423
 
1424
+ $this->_plugin->settings()->SetExcludedMonitoringUsers( isset( $post_array['ExUsers'] ) ? $post_array['ExUsers'] : array() );
1425
+ $this->_plugin->settings()->SetExcludedMonitoringRoles( isset( $post_array['ExRoles'] ) ? $post_array['ExRoles'] : array() );
1426
+ $this->_plugin->settings()->SetExcludedMonitoringCustom( isset( $post_array['Customs'] ) ? $post_array['Customs'] : array() );
1427
+ $this->_plugin->settings()->SetExcludedMonitoringIP( isset( $post_array['IpAddrs'] ) ? $post_array['IpAddrs'] : array() );
1428
+ $this->_plugin->settings()->set_excluded_post_types( isset( $post_array['ExCPTss'] ) ? $post_array['ExCPTss'] : array() );
1429
+ $this->_plugin->settings()->set_excluded_urls( isset( $post_array['ExURLss'] ) ? $post_array['ExURLss'] : array() );
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1430
  }
1431
 
1432
  /**
1433
  * Tab: `Advanced Settings`
1434
  */
1435
  private function tab_advanced_settings() {
1436
+ $location = $this->_plugin->GetGlobalSetting( 'custom-logging-dir', $this->_plugin->settings()->get_default_working_dir_relative() );
1437
  ?>
1438
+ <p class="description">
1439
  <?php esc_html_e( 'These settings are for advanced users.', 'wp-security-audit-log' ); ?>
1440
  <?php echo sprintf( __( 'If you have any questions <a href="https://wpactivitylog.com/contact/?utm_source=plugin&utm_medium=referral&utm_campaign=WSAL&utm_content=settings+pages" target="_blank">contact us</a>.', 'wp-security-audit-log' ), $this->_plugin->allowed_html_tags ); ?>
1441
  </p>
1442
 
1443
+ <h3><?php esc_html_e( 'Where do you want the plugin\'s working directory for log files, reports and other files?', 'wp-security-audit-log' ); ?></h3>
1444
+ <p class="description"><?php esc_html_e( 'The plugin stores the reports it generates, a number of log files ( for example to keep a log of 404 errors), and the request log in this working directory. By default the directory is in the default WordPress uploads directory. Use the below setting to create the working directory in a different location. Note that the plugin requires write permissions to this directory. Please specify the relative path of the directory.', 'wp-security-audit-log' ); ?></p>
1445
+ <table class="form-table wsal-tab">
1446
+ <tbody>
1447
+ <!-- custom log directory -->
1448
+ <tr>
1449
+ <th><label><?php esc_html_e( 'Working directory location', 'wp-security-audit-log' ); ?></label></th>
1450
+ <td>
1451
+ <fieldset>
1452
+ <label for="wsal-custom-logs-dir">
1453
+ <input type="text" name="wsal-custom-logs-dir" id="wsal-custom-logs-dir"
1454
+ value="<?php echo esc_attr( $location ); ?>">
1455
+ </label>
1456
+ <p class="description">
1457
+ <?php
1458
+ echo wp_kses(
1459
+ __( '<strong>Note:</strong> Enter a path from the root of your website: eg "/wp-content/uploads/wp-activity-log/".' ),
1460
+ $this->_plugin->allowed_html_tags
1461
+ );
1462
+ ?>
1463
+ </p>
1464
+ </fieldset>
1465
+ </td>
1466
+ </tr>
1467
+ <!-- / custom log directory -->
1468
+ </tbody>
1469
+ </table>
1470
+
1471
+
1472
+ <h3><?php esc_html_e( 'Troubleshooting setting: Keep a debug log of all the requests this website receives', 'wp-security-audit-log' ); ?></h3>
1473
+ <p class="description"><?php esc_html_e( 'Only enable the request log on testing, staging and development website. Never enable logging on a live website unless instructed to do so. Enabling request logging on a live website may degrade the performance of the website.', 'wp-security-audit-log' ); ?></p>
1474
+ <table class="form-table wsal-tab">
1475
+ <tbody>
1476
+ <tr>
1477
+ <th><label><?php esc_html_e( 'Request Log', 'wp-security-audit-log' ); ?></label></th>
1478
+ <td>
1479
+ <fieldset>
1480
+ <?php $devoption_checked = $this->_plugin->settings()->IsDevOptionEnabled( WSAL_Settings::OPT_DEV_REQUEST_LOG ); ?>
1481
+ <label for="devoption_yes">
1482
+ <input type="radio" name="DevOptions" id="devoption_yes"
1483
+ <?php checked( $devoption_checked, true ); ?>
1484
+ value="<?php echo esc_attr( WSAL_Settings::OPT_DEV_REQUEST_LOG ); ?>">
1485
+ <?php esc_html_e( 'Yes', 'wp-security-audit-log' ); ?>
1486
+ </label>
1487
+ <br>
1488
+ <label for="devoption_no">
1489
+ <input type="radio" name="DevOptions" id="devoption_no" <?php checked( $devoption_checked, false ); ?> value="0">
1490
+ <?php esc_html_e( 'No', 'wp-security-audit-log' ); ?>
1491
+ </label>
1492
+ <p class="description">
1493
+ <?php
1494
+ echo wp_kses(
1495
+ __( '<strong>Note:</strong> The requests debug log file is saved as request.log.php in the /wp-content/uploads/wp-activity-log/ directory.' ),
1496
+ $this->_plugin->allowed_html_tags
1497
+ );
1498
+ ?>
1499
+ </p>
1500
+ </fieldset>
1501
+ </td>
1502
+ </tr>
1503
+ <!-- / Developer Options -->
1504
+ </tbody>
1505
+ </table>
 
1506
 
1507
  <h3><?php esc_html_e( 'Reset plugin settings to default', 'wp-security-audit-log' ); ?></h3>
1508
  <p class="description"><?php esc_html_e( 'Click the RESET button to reset ALL plugin settings to default. Note that the activity log data will be retained and only the plugin settings will be reset. To purge the data of the activity log use the setting below.', 'wp-security-audit-log' ); ?></p>
1530
  </tbody>
1531
  </table>
1532
 
1533
+ <?php $stealth_mode = $this->_plugin->settings()->is_stealth_mode(); ?>
1534
  <h3><?php esc_html_e( 'MainWP Child Site Stealth Mode', 'wp-security-audit-log' ); ?></h3>
1535
  <p class="description"><?php esc_html_e( 'This option is enabled automatically when the plugin detects the MainWP Child plugin on the site. When this setting is enabled plugin access is restricted to the administrator who installs the plugin, the plugin is not shown in the list of installed plugins and no admin notifications are shown. Disable this option to change the plugin to the default setup.', 'wp-security-audit-log' ); ?></p>
1536
  <table class="form-table wsal-tab">
1540
  <td>
1541
  <fieldset <?php echo ! WpSecurityAuditLog::is_mainwp_active() ? 'disabled' : false; ?>>
1542
  <label for="mwp_stealth_yes">
1543
+ <input type="radio" name="mwp_stealth_mode" value="yes" id="mwp_stealth_yes" <?php checked( $stealth_mode ); ?> />
 
 
 
1544
  <?php esc_html_e( 'Yes', 'wp-security-audit-log' ); ?>
1545
  </label>
1546
  <br>
1553
  </fieldset>
1554
  </td>
1555
  </tr>
1556
+ <!-- / MainWP Child Site Stealth Mode -->
1557
+ <?php $admin_blocking_plugins_support = $this->_plugin->settings()->get_admin_blocking_plugin_support(); ?>
1558
+ <tr>
1559
+ <th><label for="mwp_admin_blocking_support"><?php esc_html_e( 'Admin blocking plugins support', 'wp-security-audit-log' ); ?></label></th>
1560
+ <td>
1561
+ <fieldset>
1562
+ <label for="mwp_admin_blocking_support">
1563
+ <input type="checkbox" name="mwp_admin_blocking_support" value="yes" id="mwp_admin_blocking_support" <?php checked( $admin_blocking_plugins_support ); ?> <?php disabled( ! WpSecurityAuditLog::is_mainwp_active() || !$stealth_mode); ?>/>
1564
+ <?php esc_html_e( 'Enable early plugin loading on sites that use admin blocking plugins', 'wp-security-audit-log' ); ?>
1565
+ </label>
1566
+ </fieldset>
1567
+ </td>
1568
+ </tr>
1569
+ <!-- / Admin blocking plugins support -->
1570
  </tbody>
1571
  </table>
1572
 
1580
  <fieldset>
1581
  <label for="delete_data_yes">
1582
  <input type="radio" name="DeleteData" value="1" id="delete_data_yes" onclick="return delete_confirm(this);"
1583
+ <?php checked( $this->_plugin->settings()->IsDeleteData() ); ?>
1584
  />
1585
  <?php esc_html_e( 'Yes', 'wp-security-audit-log' ); ?>
1586
  </label>
1587
  <br>
1588
  <label for="delete_data_no">
1589
  <input type="radio" name="DeleteData" value="0" id="delete_data_no"
1590
+ <?php checked( $this->_plugin->settings()->IsDeleteData(), false ); ?>
1591
  />
1592
  <?php esc_html_e( 'No', 'wp-security-audit-log' ); ?>
1593
  </label>
1629
  // Get $_POST global array.
1630
  $post_array = filter_input_array( INPUT_POST );
1631
 
1632
+ $this->_plugin->settings()->SetDeleteData( isset( $post_array['DeleteData'] ) ? sanitize_text_field( $post_array['DeleteData'] ) : false );
1633
+ $this->_plugin->settings()->ClearDevOptions();
1634
  if ( isset( $post_array['DevOptions'] ) && 'r' === $post_array['DevOptions'] ) {
1635
+ $this->_plugin->settings()->SetDevOptionEnabled( 'r', true );
1636
  } else {
1637
+ $this->_plugin->settings()->SetDevOptionEnabled( 'r', false );
1638
  }
1639
 
1640
+ $was_admin_blocking_plugins_support_just_enabled = false;
1641
  $stealth_mode = isset( $post_array['mwp_stealth_mode'] ) ? $post_array['mwp_stealth_mode'] : false;
1642
  if ( 'yes' === $stealth_mode ) {
1643
  if ( ! WpSecurityAuditLog::is_mainwp_active() ) {
1644
  throw new Exception( __( 'MainWP Child plugin is not active on this website.', 'wp-security-audit-log' ) );
1645
  }
1646
+ $this->_plugin->settings()->set_mainwp_child_stealth_mode();
1647
+
1648
+ $admin_blocking_plugins_support = isset( $post_array['mwp_admin_blocking_support'] ) ? $post_array['mwp_admin_blocking_support'] : false;
1649
+ if ( 'yes' === $admin_blocking_plugins_support ) {
1650
+ $this->_plugin->settings()->set_admin_blocking_plugin_support(true);
1651
+ $was_admin_blocking_plugins_support_just_enabled = true;
1652
+ }
1653
  } else {
1654
+ $this->_plugin->settings()->deactivate_mainwp_child_stealth_mode();
1655
  }
1656
 
1657
+ $custom_logging_dir = $this->_plugin->settings()->get_default_working_dir_relative();
1658
  if ( isset( $post_array['wsal-custom-logs-dir'] ) ) {
1659
  $posted_logging_dir = filter_var( $post_array['wsal-custom-logs-dir'], FILTER_SANITIZE_STRING );
1660
  if (!empty($posted_logging_dir)) {
1661
+ $custom_logging_dir = $posted_logging_dir;
1662
  }
1663
  }
1664
 
1665
  if ( ! empty( $custom_logging_dir ) ) {
1666
  $custom_logging_path = trailingslashit( ABSPATH ) . ltrim( trailingslashit( $custom_logging_dir ), '/' );
1667
  if ( ! is_dir( $custom_logging_path ) || ! is_readable( $custom_logging_path ) || ! is_writable( $custom_logging_path ) ) {
1668
+ $dir_made = wp_mkdir_p( $custom_logging_path );
1669
+ if ( $dir_made ) {
1670
+ // make an empty index.php in the directory.
1671
+ @file_put_contents( $custom_logging_path . 'index.php', '<?php // Silence is golden' );
1672
+ }
 
 
1673
 
1674
+ // if the directory was not made then we will display an error message
1675
  if ( ! $dir_made ) {
1676
+ // throw an exception to display an error message
1677
+ throw new Exception( __( 'The plugin cannot create the directory for the log files. Please check permissions and configure it again.', 'wp-security-audit-log' ) );
 
 
 
 
 
1678
  }
1679
  }
1680
  // save.
1681
+ $this->_plugin->SetGlobalSetting( 'custom-logging-dir', $custom_logging_dir );
1682
  }
1683
  }
1684
 
1700
  wp_enqueue_style( 'wsal-remodal-theme', WSAL_BASE_URL . 'css/remodal-default-theme.css', array(), '1.1.1' );
1701
  }
1702
  ?>
1703
+ <style type="text/css">
1704
+ .wsal-tab {
1705
+ /* display: none; */
1706
+ }
1707
+ .wsal-tab tr.alert-incomplete td {
1708
+ color: #9BE;
1709
+ }
1710
+ .wsal-tab tr.alert-unavailable td {
1711
+ color: #CCC;
1712
+ }
1713
+ </style>
1714
  <?php
1715
  }
1716
 
1761
  wp_localize_script( 'settings', 'wsal_data', $wsal_data );
1762
  wp_enqueue_script( 'settings' );
1763
  ?>
1764
+ <script type="text/javascript">
1765
+ jQuery( document ).ready( function() {
1766
+ jQuery( '.sel-columns' ).change( function() {
1767
+ var notChecked = 1;
1768
+ jQuery( '.sel-columns' ).each( function() {
1769
+ if ( this.checked ) notChecked = 0;
1770
+ })
1771
+ if ( notChecked == 1 ) {
1772
+ alert( esc_html__( 'You have to select at least one column!', 'wp-security-audit-log' ) );
1773
+ }
1774
+ });
1775
+ });</script>
1776
  <?php
1777
  }
1778
 
1781
  */
1782
  public function AjaxGetAllUsers() {
1783
  // Die if user does not have permission to view.
1784
+ if ( ! $this->_plugin->settings()->CurrentUserCan( 'view' ) ) {
1785
  die( 'Access Denied.' );
1786
  }
1787
 
1809
  */
1810
  public function AjaxGetAllRoles() {
1811
  // Die if user does not have permission to view.
1812
+ if ( ! $this->_plugin->settings()->CurrentUserCan( 'view' ) ) {
1813
  die( 'Access Denied.' );
1814
  }
1815
 
1839
  */
1840
  public function AjaxGetAllCPT() {
1841
  // Die if user does not have permission to view.
1842
+ if ( ! $this->_plugin->settings()->CurrentUserCan( 'view' ) ) {
1843
  die( 'Access Denied.' );
1844
  }
1845
 
1877
  */
1878
  public function reset_settings() {
1879
  // Die if user does not have permission to change settings.
1880
+ if ( ! $this->_plugin->settings()->CurrentUserCan( 'view' ) ) {
1881
  die( esc_html__( 'Access Denied.', 'wp-security-audit-log' ) );
1882
  }
1883
 
1906
  */
1907
  public function purge_activity() {
1908
  // Die if user does not have permission to change settings.
1909
+ if ( ! $this->_plugin->settings()->CurrentUserCan( 'view' ) ) {
1910
  die( esc_html__( 'Access Denied.', 'wp-security-audit-log' ) );
1911
  }
1912
 
classes/Views/SetupWizard.php CHANGED
@@ -150,7 +150,7 @@ final class WSAL_Views_SetupWizard {
150
  return;
151
  }
152
 
153
- // Grab list of instaleld plugins.
154
  $all_plugins = get_plugins();
155
  $plugin_filenames = array();
156
  foreach ( $all_plugins as $plugin => $info ) {
@@ -260,7 +260,7 @@ final class WSAL_Views_SetupWizard {
260
  // Data array.
261
  $data_array = array(
262
  'ajaxURL' => admin_url( 'admin-ajax.php' ),
263
- 'nonce' => ( ( ! $this->wsal->settings->CurrentUserCan( 'edit' ) ) && ! 'invalid-step' === $this->current_step ) ? wp_create_nonce( 'wsal-verify-wizard-page' ) : '',
264
  'usersError' => esc_html__( 'Specified value in not a user.', 'wp-security-audit-log' ),
265
  'rolesError' => esc_html__( 'Specified value in not a role.', 'wp-security-audit-log' ),
266
  'ipError' => esc_html__( 'Specified value in not an IP address.', 'wp-security-audit-log' ),
@@ -308,7 +308,6 @@ final class WSAL_Views_SetupWizard {
308
  <?php wp_print_scripts( 'wsal-common' ); ?>
309
 
310
  <?php do_action( 'admin_print_styles' ); ?>
311
- <?php do_action( 'admin_head' ); ?>
312
  </head>
313
  <body class="wsal-setup wp-core-ui">
314
  <h1 id="wsal-logo"><a href="https://wpactivitylog.com/?utm_source=plugin&utm_medium=referral&utm_campaign=WSAL&utm_content=wizard+configuration" target="_blank"><img src="<?php echo esc_url( $this->wsal->GetBaseUrl() ); ?>/img/wsal-logo-full.png" alt="WP Activity Log" /></a></h1>
@@ -428,8 +427,8 @@ final class WSAL_Views_SetupWizard {
428
  */
429
  private function wsal_step_welcome() {
430
  // Dismiss the setup modal on audit log.
431
- if ( 'no' === $this->wsal->options_helper->get_option_value( 'setup-modal-dismissed', 'no' ) ) {
432
- $this->wsal->options_helper->set_option_value( 'setup-modal-dismissed', 'yes' );
433
  }
434
  ?>
435
  <p><?php esc_html_e( 'This wizard helps you configure the basic plugin settings. All these settings can be changed at a later stage from the plugin settings.', 'wp-security-audit-log' ); ?></p>
@@ -491,11 +490,11 @@ final class WSAL_Views_SetupWizard {
491
  }
492
 
493
  // Save log details option.
494
- $this->wsal->SetGlobalOption( 'details-level', $log_details );
495
  if ( ! empty( $log_details ) && 'basic' === $log_details ) {
496
- $this->wsal->settings->set_basic_mode();
497
  } elseif ( ! empty( $log_details ) && 'geek' === $log_details ) {
498
- $this->wsal->settings->set_geek_mode();
499
  }
500
 
501
  wp_safe_redirect( esc_url_raw( $this->get_next_step() ) );
@@ -539,12 +538,12 @@ final class WSAL_Views_SetupWizard {
539
  check_admin_referer( 'wsal-step-login' );
540
 
541
  if ( isset( $_POST['wsal-frontend-login'] ) ) {
542
- $frontend_sensors = $this->wsal->settings->get_frontend_events(); // Get the frontend sensors setting.
543
  $login_sensor = sanitize_text_field( wp_unslash( $_POST['wsal-frontend-login'] ) );
544
  $login_sensor = '1' === $login_sensor ? true : false; // Update the sensor option.
545
 
546
  $frontend_sensors['login'] = $login_sensor;
547
- $this->wsal->settings->set_frontend_events( $frontend_sensors );
548
  }
549
 
550
  wp_safe_redirect( esc_url_raw( $this->get_next_step() ) );
@@ -587,12 +586,12 @@ final class WSAL_Views_SetupWizard {
587
  check_admin_referer( 'wsal-step-404s' );
588
 
589
  if ( isset( $_POST['wsal-frontend-system'] ) ) {
590
- $frontend_sensors = $this->wsal->settings->get_frontend_events(); // Get the frontend sensors setting.
591
  $system_sensor = sanitize_text_field( wp_unslash( $_POST['wsal-frontend-system'] ) );
592
  $system_sensor = '1' === $system_sensor ? true : false; // Update the sensor option.
593
 
594
  $frontend_sensors['system'] = $system_sensor;
595
- $this->wsal->settings->set_frontend_events( $frontend_sensors );
596
  }
597
 
598
  wp_safe_redirect( esc_url_raw( $this->get_next_step() ) );
@@ -636,12 +635,12 @@ final class WSAL_Views_SetupWizard {
636
  check_admin_referer( 'wsal-step-frontend-register' );
637
 
638
  if ( isset( $_POST['wsal-frontend-register'] ) ) {
639
- $frontend_sensors = $this->wsal->settings->get_frontend_events(); // Get the frontend sensors setting.
640
  $register_sensor = sanitize_text_field( wp_unslash( $_POST['wsal-frontend-register'] ) );
641
  $register_sensor = '1' === $register_sensor ? true : false; // Update the sensor option.
642
 
643
  $frontend_sensors['register'] = $register_sensor;
644
- $this->wsal->settings->set_frontend_events( $frontend_sensors );
645
  }
646
 
647
  wp_safe_redirect( esc_url_raw( $this->get_next_step() ) );
@@ -694,10 +693,6 @@ final class WSAL_Views_SetupWizard {
694
  // Step help text.
695
  $step_help = __( 'The plugin stores the data in the WordPress database in a very efficient way, though the more data you keep the more hard disk space it will consume. If you need need to retain a lot of data we would recommend you to <a href="https://wpactivitylog.com/features/?utm_source=plugin&utm_medium=referral&utm_campaign=WSAL&utm_content=wizard+configuration" target="_blank">upgrade to Premium</a> and use the Database tools to store the WordPress activity log in an external database.', 'wp-security-audit-log' );
696
 
697
- if ( wsal_freemius()->is__premium_only() ) {
698
- // Change the help text if premium version of the plugin is active.
699
- $step_help = __( 'The plugin stores the data in the WordPress database in a very efficient way, though the more data you keep the more hard disk space it will consume. If you need need to retain a lot of data we would recommend you to store the WordPress activity log in an external database or enable archiving.', 'wp-security-audit-log' );
700
- }
701
  echo wp_kses( $step_help, $this->wsal->allowed_html_tags );
702
  ?>
703
  </em>
@@ -726,19 +721,19 @@ final class WSAL_Views_SetupWizard {
726
  switch ( $pruning_limit ) {
727
  case '6':
728
  // 6 months.
729
- $this->wsal->options_helper->set_option_value( 'pruning-date-e', true );
730
- $this->wsal->options_helper->set_option_value( 'pruning-date', $pruning_limit . ' months' );
731
  break;
732
 
733
  case '12':
734
  // 12 months.
735
- $this->wsal->options_helper->set_option_value( 'pruning-date-e', true );
736
- $this->wsal->options_helper->set_option_value( 'pruning-date', $pruning_limit . ' months' );
737
  break;
738
 
739
  case 'none':
740
  // None.
741
- $this->wsal->options_helper->set_option_value( 'pruning-date-e', false );
742
  break;
743
 
744
  default:
@@ -756,7 +751,7 @@ final class WSAL_Views_SetupWizard {
756
  * @param string $token - Token type.
757
  */
758
  protected function get_token_type( $token ) {
759
- return $this->wsal->settings->get_token_type( $token );
760
  }
761
 
762
  /**
@@ -809,7 +804,7 @@ final class WSAL_Views_SetupWizard {
809
  check_admin_referer( 'wsal-step-finish' );
810
 
811
  // Mark the finish of the setup.
812
- $this->wsal->SetGlobalOption( 'wsal-setup-complete', 'yes' );
813
 
814
  wp_safe_redirect( esc_url_raw( $this->get_next_step() ) );
815
  exit();
@@ -844,6 +839,21 @@ final class WSAL_Views_SetupWizard {
844
 
845
  private function addons_step() {
846
  $our_plugins = WSAL_PluginInstallAndActivate::get_installable_plugins();
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
847
  ?>
848
  <form method="post" class="wsal-setup-form">
849
  <?php wp_nonce_field( 'wsal-step-addon' ); ?>
@@ -851,13 +861,17 @@ final class WSAL_Views_SetupWizard {
851
  <p><?php esc_html_e( 'We noticed that the below plugins are installed on this website. You can install our extensions to also keep a log of changes users do on these plugins.', 'wp-security-audit-log' ); ?></p>
852
  <?php
853
  // Create a nonce to pass through via data attr.
854
- $nonce = wp_create_nonce( 'wsal-install-addon' );
 
855
  // Loop through plugins and output.
856
  foreach ( $our_plugins as $details ) {
857
  $disable_button = '';
858
- if ( is_plugin_active( $details['plugin_slug'] ) ) {
859
  $disable_button = 'disabled';
860
  }
 
 
 
861
  // Check if this is actually an addon for something, otherwise bail.
862
  if ( ! isset( $details['addon_for'] ) || ! isset( $details['image_filename'] ) ) {
863
  break;
@@ -873,7 +887,7 @@ final class WSAL_Views_SetupWizard {
873
  <?php
874
  if ( WSAL_PluginInstallAndActivate::is_plugin_installed( $details['plugin_slug'] ) && ! is_plugin_active( $details['plugin_slug'] ) ) {
875
  esc_html_e( 'Extension installed, activate now?', 'wp-security-audit-log' );
876
- } elseif ( WSAL_PluginInstallAndActivate::is_plugin_installed( $details['plugin_slug'] ) && is_plugin_active( $details['plugin_slug'] ) ) {
877
  esc_html_e( 'Extension installed', 'wp-security-audit-log' );
878
  } else {
879
  esc_html_e( 'Install Extension', 'wp-security-audit-log' );
150
  return;
151
  }
152
 
153
+ // Grab list of installed plugins.
154
  $all_plugins = get_plugins();
155
  $plugin_filenames = array();
156
  foreach ( $all_plugins as $plugin => $info ) {
260
  // Data array.
261
  $data_array = array(
262
  'ajaxURL' => admin_url( 'admin-ajax.php' ),
263
+ 'nonce' => ( ( ! $this->wsal->settings()->CurrentUserCan( 'edit' ) ) && ! 'invalid-step' === $this->current_step ) ? wp_create_nonce( 'wsal-verify-wizard-page' ) : '',
264
  'usersError' => esc_html__( 'Specified value in not a user.', 'wp-security-audit-log' ),
265
  'rolesError' => esc_html__( 'Specified value in not a role.', 'wp-security-audit-log' ),
266
  'ipError' => esc_html__( 'Specified value in not an IP address.', 'wp-security-audit-log' ),
308
  <?php wp_print_scripts( 'wsal-common' ); ?>
309
 
310
  <?php do_action( 'admin_print_styles' ); ?>
 
311
  </head>
312
  <body class="wsal-setup wp-core-ui">
313
  <h1 id="wsal-logo"><a href="https://wpactivitylog.com/?utm_source=plugin&utm_medium=referral&utm_campaign=WSAL&utm_content=wizard+configuration" target="_blank"><img src="<?php echo esc_url( $this->wsal->GetBaseUrl() ); ?>/img/wsal-logo-full.png" alt="WP Activity Log" /></a></h1>
427
  */
428
  private function wsal_step_welcome() {
429
  // Dismiss the setup modal on audit log.
430
+ if ( $this->wsal->GetGlobalBooleanSetting( 'setup-modal-dismissed', false ) ) {
431
+ $this->wsal->SetGlobalBooleanSetting( 'setup-modal-dismissed', true );
432
  }
433
  ?>
434
  <p><?php esc_html_e( 'This wizard helps you configure the basic plugin settings. All these settings can be changed at a later stage from the plugin settings.', 'wp-security-audit-log' ); ?></p>
490
  }
491
 
492
  // Save log details option.
493
+ $this->wsal->SetGlobalSetting( 'details-level', $log_details );
494
  if ( ! empty( $log_details ) && 'basic' === $log_details ) {
495
+ $this->wsal->settings()->set_basic_mode();
496
  } elseif ( ! empty( $log_details ) && 'geek' === $log_details ) {
497
+ $this->wsal->settings()->set_geek_mode();
498
  }
499
 
500
  wp_safe_redirect( esc_url_raw( $this->get_next_step() ) );
538
  check_admin_referer( 'wsal-step-login' );
539
 
540
  if ( isset( $_POST['wsal-frontend-login'] ) ) {
541
+ $frontend_sensors = WSAL_Settings::get_frontend_events(); // Get the frontend sensors setting.
542
  $login_sensor = sanitize_text_field( wp_unslash( $_POST['wsal-frontend-login'] ) );
543
  $login_sensor = '1' === $login_sensor ? true : false; // Update the sensor option.
544
 
545
  $frontend_sensors['login'] = $login_sensor;
546
+ $this->wsal->settings()->set_frontend_events( $frontend_sensors );
547
  }
548
 
549
  wp_safe_redirect( esc_url_raw( $this->get_next_step() ) );
586
  check_admin_referer( 'wsal-step-404s' );
587
 
588
  if ( isset( $_POST['wsal-frontend-system'] ) ) {
589
+ $frontend_sensors = WSAL_Settings::get_frontend_events(); // Get the frontend sensors setting.
590
  $system_sensor = sanitize_text_field( wp_unslash( $_POST['wsal-frontend-system'] ) );
591
  $system_sensor = '1' === $system_sensor ? true : false; // Update the sensor option.
592
 
593
  $frontend_sensors['system'] = $system_sensor;
594
+ $this->wsal->settings()->set_frontend_events( $frontend_sensors );
595
  }
596
 
597
  wp_safe_redirect( esc_url_raw( $this->get_next_step() ) );
635
  check_admin_referer( 'wsal-step-frontend-register' );
636
 
637
  if ( isset( $_POST['wsal-frontend-register'] ) ) {
638
+ $frontend_sensors = WSAL_Settings::get_frontend_events(); // Get the frontend sensors setting.
639
  $register_sensor = sanitize_text_field( wp_unslash( $_POST['wsal-frontend-register'] ) );
640
  $register_sensor = '1' === $register_sensor ? true : false; // Update the sensor option.
641
 
642
  $frontend_sensors['register'] = $register_sensor;
643
+ $this->wsal->settings()->set_frontend_events( $frontend_sensors );
644
  }
645
 
646
  wp_safe_redirect( esc_url_raw( $this->get_next_step() ) );
693
  // Step help text.
694
  $step_help = __( 'The plugin stores the data in the WordPress database in a very efficient way, though the more data you keep the more hard disk space it will consume. If you need need to retain a lot of data we would recommend you to <a href="https://wpactivitylog.com/features/?utm_source=plugin&utm_medium=referral&utm_campaign=WSAL&utm_content=wizard+configuration" target="_blank">upgrade to Premium</a> and use the Database tools to store the WordPress activity log in an external database.', 'wp-security-audit-log' );
695
 
 
 
 
 
696
  echo wp_kses( $step_help, $this->wsal->allowed_html_tags );
697
  ?>
698
  </em>
721
  switch ( $pruning_limit ) {
722
  case '6':
723
  // 6 months.
724
+ $this->wsal->SetGlobalBooleanSetting( 'pruning-date-e', true );
725
+ $this->wsal->SetGlobalSetting( 'pruning-date', $pruning_limit . ' months' );
726
  break;
727
 
728
  case '12':
729
  // 12 months.
730
+ $this->wsal->SetGlobalBooleanSetting( 'pruning-date-e', true );
731
+ $this->wsal->SetGlobalSetting( 'pruning-date', $pruning_limit . ' months' );
732
  break;
733
 
734
  case 'none':
735
  // None.
736
+ $this->wsal->SetGlobalBooleanSetting( 'pruning-date-e', false );
737
  break;
738
 
739
  default:
751
  * @param string $token - Token type.
752
  */
753
  protected function get_token_type( $token ) {
754
+ return $this->wsal->settings()->get_token_type( $token );
755
  }
756
 
757
  /**
804
  check_admin_referer( 'wsal-step-finish' );
805
 
806
  // Mark the finish of the setup.
807
+ $this->wsal->SetGlobalBooleanSetting( 'setup-complete', true );
808
 
809
  wp_safe_redirect( esc_url_raw( $this->get_next_step() ) );
810
  exit();
839
 
840
  private function addons_step() {
841
  $our_plugins = WSAL_PluginInstallAndActivate::get_installable_plugins();
842
+
843
+ // Grab list of instaleld plugins.
844
+ $all_plugins = get_plugins();
845
+ $plugin_filenames = array();
846
+ foreach ( $all_plugins as $plugin => $info ) {
847
+ // here we strip all of the plugin slug, leaving just the filename itself. Neat!
848
+ $plugin_filenames[] = preg_replace( '/\\.[^.\\s]{3,4}$/', '', substr( basename( json_encode( $plugin ) ), 0, -1 ) );
849
+ }
850
+
851
+ // Grab list of plugins we have addons for.
852
+ $predefined_plugins = array_column( $our_plugins, 'addon_for' );
853
+
854
+ // Loop through plugins and create an array of slugs, we will compare these agains the plugins we have addons for.
855
+ $we_have_addon = array_intersect( $plugin_filenames, $predefined_plugins );
856
+
857
  ?>
858
  <form method="post" class="wsal-setup-form">
859
  <?php wp_nonce_field( 'wsal-step-addon' ); ?>
861
  <p><?php esc_html_e( 'We noticed that the below plugins are installed on this website. You can install our extensions to also keep a log of changes users do on these plugins.', 'wp-security-audit-log' ); ?></p>
862
  <?php
863
  // Create a nonce to pass through via data attr.
864
+ $nonce = wp_create_nonce( 'wsal-install-addon' );
865
+ $skip_addon = false;
866
  // Loop through plugins and output.
867
  foreach ( $our_plugins as $details ) {
868
  $disable_button = '';
869
+ if ( is_plugin_active( $details['plugin_slug'] ) || 'wsal-wpforms.php' === basename( $details['plugin_slug'] ) && function_exists( 'wsal_wpforms_init_actions' ) || 'wsal-bbpress.php' === basename( $details['plugin_slug'] ) && function_exists( 'wsal_bbpress_init_actions' ) ) {
870
  $disable_button = 'disabled';
871
  }
872
+ if ( ! in_array( $details['addon_for'], $we_have_addon ) ) {
873
+ continue;
874
+ }
875
  // Check if this is actually an addon for something, otherwise bail.
876
  if ( ! isset( $details['addon_for'] ) || ! isset( $details['image_filename'] ) ) {
877
  break;
887
  <?php
888
  if ( WSAL_PluginInstallAndActivate::is_plugin_installed( $details['plugin_slug'] ) && ! is_plugin_active( $details['plugin_slug'] ) ) {
889
  esc_html_e( 'Extension installed, activate now?', 'wp-security-audit-log' );
890
+ } elseif ( WSAL_PluginInstallAndActivate::is_plugin_installed( $details['plugin_slug'] ) && is_plugin_active( $details['plugin_slug'] ) || 'wsal-wpforms.php' === basename( $details['plugin_slug'] ) && function_exists( 'wsal_wpforms_init_actions' ) || 'wsal-bbpress.php' === basename( $details['plugin_slug'] ) && function_exists( 'wsal_bbpress_init_actions' ) ) {
891
  esc_html_e( 'Extension installed', 'wp-security-audit-log' );
892
  } else {
893
  esc_html_e( 'Install Extension', 'wp-security-audit-log' );
classes/Views/ToggleAlerts.php CHANGED
@@ -78,7 +78,7 @@ class WSAL_Views_ToggleAlerts extends WSAL_AbstractView {
78
  if ( isset( $post_array['frontend-events'] ) ) {
79
  $frontend_events = array_merge( $frontend_events, $post_array['frontend-events'] );
80
  }
81
- $this->_plugin->settings->set_frontend_events( $frontend_events );
82
 
83
  $enabled = array_map( 'intval', $post_array['alert'] );
84
  $disabled = array();
@@ -88,9 +88,18 @@ class WSAL_Views_ToggleAlerts extends WSAL_AbstractView {
88
  continue;
89
  } elseif ( 6023 === $alert->type ) {
90
  continue;
 
 
 
 
91
  }
92
 
93
  if ( ! in_array( $alert->type, $enabled, true ) ) {
 
 
 
 
 
94
  $disabled[] = $alert->type;
95
  }
96
  }
@@ -98,37 +107,20 @@ class WSAL_Views_ToggleAlerts extends WSAL_AbstractView {
98
  // Save the disabled events.
99
  $this->_plugin->alerts->SetDisabledAlerts( $disabled );
100
 
101
- $this->_plugin->options_helper->set_option_value( 'log-404', isset( $post_array['log_404'] ) ? 'on' : 'off' );
102
- $this->_plugin->options_helper->set_option_value( 'purge-404-log', isset( $post_array['purge_log'] ) ? 'on' : 'off' );
103
- $this->_plugin->options_helper->set_option_value( 'log-404-referrer', isset( $post_array['log_404_referrer'] ) ? 'on' : 'off' );
104
-
105
- $this->_plugin->options_helper->set_option_value( 'log-visitor-404', isset( $post_array['log_visitor_404'] ) ? 'on' : 'off' );
106
- $this->_plugin->options_helper->set_option_value( 'purge-visitor-404-log', isset( $post_array['purge_visitor_log'] ) ? 'on' : 'off' );
107
- $this->_plugin->options_helper->set_option_value( 'log-visitor-404-referrer', isset( $post_array['log_visitor_404_referrer'] ) ? 'on' : 'off' );
108
- $this->_plugin->SetGlobalOption( 'wc-all-stock-changes', isset( $post_array['wc_all_stock_changes'] ) ? 'on' : 'off' );
109
-
110
- $this->_plugin->settings->Set404LogLimit( $post_array['user_404Limit'] );
111
- $this->_plugin->settings->SetVisitor404LogLimit( $post_array['visitor_404Limit'] );
112
-
113
- $this->_plugin->settings->set_failed_login_limit( $post_array['log_failed_login_limit'] );
114
- $this->_plugin->settings->set_visitor_failed_login_limit( $post_array['log_visitor_failed_login_limit'] );
115
 
116
- // Get file change scan alerts.
117
- $file_change_alerts = $this->_plugin->alerts->get_alerts_by_sub_category( 'File Changes' );
118
- $file_change_alerts = array_keys( $file_change_alerts );
 
119
 
120
- // Toggle file change.
121
- $file_change_toggle = 'disable';
122
-
123
- // Check each file change alert to see if it is active or not.
124
- foreach ( $file_change_alerts as $alert ) {
125
- if ( ! in_array( $alert, $disabled, true ) ) { // If any one alert is active, then.
126
- $file_change_toggle = 'enable'; // Enable the file change.
127
- }
128
- }
129
 
130
- // Set the option.
131
- $this->_plugin->SetGlobalOption( 'scan-file-changes', $file_change_toggle );
132
  }
133
 
134
  /**
@@ -136,7 +128,7 @@ class WSAL_Views_ToggleAlerts extends WSAL_AbstractView {
136
  */
137
  public function Render() {
138
  // Die if user does not have permission to view.
139
- if ( ! $this->_plugin->settings->CurrentUserCan( 'edit' ) ) {
140
  wp_die( esc_html__( 'You do not have sufficient permissions to access this page.', 'wp-security-audit-log' ) );
141
  }
142
 
@@ -171,21 +163,21 @@ class WSAL_Views_ToggleAlerts extends WSAL_AbstractView {
171
  $log_level_nonce = isset( $post_array['wsal-log-level-nonce'] ) ? sanitize_text_field( $post_array['wsal-log-level-nonce'] ) : false;
172
 
173
  if ( wp_verify_nonce( $log_level_nonce, 'wsal-log-level' ) ) {
174
- $this->_plugin->SetGlobalOption( 'details-level', $log_level );
175
 
176
  if ( 'basic' === $log_level ) {
177
- $this->_plugin->settings->set_basic_mode();
178
  } elseif ( 'geek' === $log_level ) {
179
- $this->_plugin->settings->set_geek_mode();
180
  }
181
  }
182
 
183
- $disabled_events = $this->_plugin->options_helper->get_option_value( 'disabled-alerts' ); // Get disabled events.
184
  $disabled_events = explode( ',', $disabled_events );
185
- $events_diff = array_diff( $disabled_events, $this->_plugin->settings->geek_alerts ); // Calculate the difference of events.
186
  $events_diff = array_filter( $events_diff ); // Remove empty values.
187
  $is_custom = ! empty( $events_diff ) ? true : false; // If difference is not empty then mode is custom.
188
- $log_details = $this->_plugin->GetGlobalOption( 'details-level', false ); // Get log level option.
189
 
190
  $subcat_alerts = array( 1004, 2010, 2111, 9007, 9047 );
191
  $obsolete_events = array( 9999, 2126, 6023, 9011, 9070, 9075, 4013 );
@@ -327,7 +319,7 @@ class WSAL_Views_ToggleAlerts extends WSAL_AbstractView {
327
  <th><?php esc_html_e( 'Description', 'wp-security-audit-log' ); ?></th>
328
  </tr>
329
  </thead>
330
- <tbody id="<?php echo ( __( 'File Changes', 'wp-security-audit-log' ) === $subname ) ? 'alerts-file-changes' : false; ?>">
331
  <?php if ( __( 'Content', 'wp-security-audit-log' ) === $subname ) : ?>
332
  <tr>
333
  <td colspan="4">
@@ -471,40 +463,40 @@ class WSAL_Views_ToggleAlerts extends WSAL_AbstractView {
471
  </tr>
472
  <?php
473
  if ( 6007 === $alert->type ) {
474
- $log_404 = $this->_plugin->options_helper->get_option_value( 'log-404' );
475
- $purge_log = $this->_plugin->options_helper->get_option_value( 'purge-404-log' );
476
- $log_404_referrer = $this->_plugin->options_helper->get_option_value( 'log-404-referrer', 'on' );
477
  ?>
478
  <tr>
479
  <td></td>
480
  <td>
481
  <input name="log_404" type="checkbox" class="check_log" value="1"
482
- <?php checked( $log_404, 'on' ); ?> />
483
  </td>
484
- <td colspan="2"><?php esc_html_e( 'Capture 404 requests to file (the log file are created in the /wp-content/uploads/wp-security-audit-log/404s/ directory)', 'wp-security-audit-log' ); ?></td>
485
  </tr>
486
  <tr>
487
  <td></td>
488
  <td>
489
  <input name="purge_log" type="checkbox" class="check_log" value="1"
490
- <?php checked( $purge_log, 'on' ); ?> />
491
  </td>
492
  <td colspan="2"><?php esc_html_e( 'Purge log files older than one month', 'wp-security-audit-log' ); ?></td>
493
  </tr>
494
  <tr>
495
  <td></td>
496
- <td colspan="1"><input type="number" id="user_404Limit" name="user_404Limit" value="<?php echo esc_attr( $this->_plugin->settings->Get404LogLimit() ); ?>" /></td>
497
  <td colspan="2"><?php esc_html_e( 'Number of 404 Requests to Log. By default the plugin keeps up to 99 requests to non-existing pages from the same IP address. Increase the value in this setting to the desired amount to keep a log of more or less requests.', 'wp-security-audit-log' ); ?></td>
498
  </tr>
499
  <tr>
500
  <td></td>
501
- <td><input name="log_404_referrer" type="checkbox" class="check_log" value="1" <?php checked( $log_404_referrer, 'on' ); ?>></td>
502
  <td colspan="2"><?php esc_html_e( 'Record the referrer that generated the 404 error.', 'wp-security-audit-log' ); ?></td>
503
  </tr>
504
  <?php
505
  }
506
  if ( 1002 === $alert->type ) {
507
- $log_failed_login_limit = (int) $this->_plugin->options_helper->get_option_value( 'log-failed-login-limit', 10 );
508
  $log_failed_login_limit = ( -1 === $log_failed_login_limit ) ? '0' : $log_failed_login_limit;
509
  ?>
510
  <tr>
@@ -517,7 +509,7 @@ class WSAL_Views_ToggleAlerts extends WSAL_AbstractView {
517
  <?php
518
  }
519
  if ( 1003 === $alert->type ) {
520
- $log_visitor_failed_login_limit = (int) $this->_plugin->options_helper->get_option_value( 'log-visitor-failed-login-limit', 10 );
521
  $log_visitor_failed_login_limit = ( -1 === $log_visitor_failed_login_limit ) ? '0' : $log_visitor_failed_login_limit;
522
  ?>
523
  <tr>
@@ -530,7 +522,7 @@ class WSAL_Views_ToggleAlerts extends WSAL_AbstractView {
530
  <?php
531
  }
532
  if ( 9019 === $alert->type ) {
533
- $wc_all_stock_changes = $this->_plugin->GetGlobalOption( 'wc-all-stock-changes', 'on' );
534
  ?>
535
  <tr>
536
  <td></td>
@@ -560,9 +552,9 @@ class WSAL_Views_ToggleAlerts extends WSAL_AbstractView {
560
  <td>
561
  <div class="addon-wrapper">
562
  <img src="<?php echo trailingslashit( WSAL_BASE_URL ) . 'img/help/website-file-changes-monitor.jpg'; ?>">
563
- <h4><?php echo esc_html__( 'Website File Changes Monitor', 'wp-security-audit-log' ); ?></h4>
564
- <p><?php echo esc_html__( 'To keep a log of file changes please install Website File Changes Monitor, a plugin which is also developed by us.', 'wp-security-audit-log' ); ?></p><br>
565
- <p><button class="install-addon button button-primary" data-nonce="<?php echo esc_attr( wp_create_nonce( 'wsal-install-addon' ) ); ?>" data-plugin-slug="website-file-changes-monitor/website-file-changes-monitor.php" data-plugin-download-url="https://downloads.wordpress.org/plugin/website-file-changes-monitor.latest-stable.zip"><?php _e( 'Install plugin now', 'wp-security-audit-log' ); ?></button><span class="spinner" style="display: none; visibility: visible; float: none; margin: 0 0 0 8px;"></span> <a href="https://wpactivitylog.com/support/kb/wordpress-files-changes-warning-activity-logs/?utm_source=plugin&utm_medium=referral&utm_campaign=WSAL&utm_content=settings+pages" target="_blank" style="margin-left: 15px;"><?php echo esc_html__( 'Learn More', 'wp-security-audit-log' ); ?></a></p>
566
  </div>
567
  </td>
568
  </tr>
@@ -582,7 +574,7 @@ class WSAL_Views_ToggleAlerts extends WSAL_AbstractView {
582
  </div>
583
  <?php endforeach; ?>
584
  <?php
585
- $frontend_events = $this->_plugin->settings->get_frontend_events();
586
  ?>
587
  <table id="tab-frontend-events" class="form-table wp-list-table wsal-tab widefat fixed" style="display: table;" cellspacing="0">
588
  <tbody>
@@ -625,37 +617,26 @@ class WSAL_Views_ToggleAlerts extends WSAL_AbstractView {
625
  </td>
626
  </tr>
627
  <?php
628
- $log_visitor_404 = $this->_plugin->options_helper->get_option_value( 'log-visitor-404' );
629
- $purge_visitor_log = $this->_plugin->options_helper->get_option_value( 'purge-visitor-404-log' );
630
- $log_visitor_404_referrer = $this->_plugin->options_helper->get_option_value( 'log-visitor-404-referrer', 'on' );
631
  ?>
632
  <tr>
633
- <td><input name="log_visitor_404" type="checkbox" class="check_visitor_log" value="1" <?php checked( $log_visitor_404, 'on' ); ?> /></td>
634
- <td><?php esc_html_e( 'Capture 404 requests to file (the log file are created in the /wp-content/uploads/wp-security-audit-log/404s/ directory)', 'wp-security-audit-log' ); ?></td>
635
  </tr>
636
  <tr>
637
- <td><input name="purge_visitor_log" type="checkbox" class="check_visitor_log" value="1" <?php checked( $purge_visitor_log, 'on' ); ?> /></td>
638
  <td><?php esc_html_e( 'Purge log files older than one month', 'wp-security-audit-log' ); ?></td>
639
  </tr>
640
  <tr>
641
- <td><input type="number" id="visitor_404Limit" name="visitor_404Limit" value="<?php echo esc_attr( $this->_plugin->settings->GetVisitor404LogLimit() ); ?>" /></td>
642
  <td><?php esc_html_e( 'Number of 404 Requests to Log. By default the plugin keeps up to 99 requests to non-existing pages from the same IP address. Increase the value in this setting to the desired amount to keep a log of more or less requests. Note that by increasing this value to a high number, should your website be scanned the plugin will consume more resources to log all the requests.', 'wp-security-audit-log' ); ?></td>
643
  </tr>
644
  <tr>
645
- <td><input name="log_visitor_404_referrer" type="checkbox" class="check_log" value="1" <?php checked( $log_visitor_404_referrer, 'on' ); ?>></td>
646
  <td><?php esc_html_e( 'Record the referrer that generated the 404 error.', 'wp-security-audit-log' ); ?></td>
647
  </tr>
648
- <tr>
649
- <td>
650
- <h3 style="margin:0"><?php esc_html_e( 'Front-end WooCommerce activity', 'wp-security-audit-log' ); ?></h3>
651
- </td>
652
- </tr>
653
- <tr>
654
- <th><input type="checkbox" name="frontend-events[woocommerce]" id="frontend-events-woocommerce" value="1" <?php checked( $frontend_events['woocommerce'] ); ?>></th>
655
- <td >
656
- <label for="frontend-events-woocommerce"><?php esc_html_e( 'Keep a log of product stocks and orders changes done by website visitors (non-logged in). Regardless of the state of this setting, the plugin always keeps a log of changes done by logged in users.', 'wp-security-audit-log' ); ?></label>
657
- </td>
658
- </tr>
659
  </tbody>
660
  </table>
661
  <?php
@@ -884,26 +865,6 @@ class WSAL_Views_ToggleAlerts extends WSAL_AbstractView {
884
  });
885
  });
886
 
887
- var alerts = jQuery( '#alerts-file-changes .alert' ); // File change alerts.
888
- var toggle_modal = jQuery( '[data-remodal-id=wsal-toggle-file-changes-scan]' ); // File change toggle modal.
889
-
890
- function wsal_toggle_file_changes( element ) {
891
- if ( jQuery( element ).is( ':checked' ) ) {
892
- var alert_count = 0;
893
-
894
- for ( var index = 0; index < alerts.length; index++ ) {
895
- if ( jQuery( alerts[ index ] ).is( ':checked' ) ) {
896
- alert_count++;
897
- }
898
- }
899
-
900
- if ( alert_count === 1 ) {
901
- var modal = toggle_modal.remodal();
902
- modal.open();
903
- }
904
- }
905
- }
906
-
907
  jQuery(document).on('closed', toggle_modal, function (event) {
908
  if (event.reason && event.reason === 'cancellation') {
909
  for ( var index = 0; index < alerts.length; index++ ) {
78
  if ( isset( $post_array['frontend-events'] ) ) {
79
  $frontend_events = array_merge( $frontend_events, $post_array['frontend-events'] );
80
  }
81
+ $this->_plugin->settings()->set_frontend_events( $frontend_events );
82
 
83
  $enabled = array_map( 'intval', $post_array['alert'] );
84
  $disabled = array();
88
  continue;
89
  } elseif ( 6023 === $alert->type ) {
90
  continue;
91
+ } elseif ( 9036 === $alert->type ) {
92
+ $frontend_events = WSAL_Settings::get_frontend_events();
93
+ $frontend_events = array_merge( $frontend_events, array( 'woocommerce' => true ) );
94
+ $this->_plugin->settings()->set_frontend_events( $frontend_events );
95
  }
96
 
97
  if ( ! in_array( $alert->type, $enabled, true ) ) {
98
+ if ( 9036 === $alert->type ) {
99
+ $frontend_events = WSAL_Settings::get_frontend_events();
100
+ $frontend_events = array_merge( $frontend_events, array( 'woocommerce' => false ) );
101
+ $this->_plugin->settings()->set_frontend_events( $frontend_events );
102
+ }
103
  $disabled[] = $alert->type;
104
  }
105
  }
107
  // Save the disabled events.
108
  $this->_plugin->alerts->SetDisabledAlerts( $disabled );
109
 
110
+ $this->_plugin->SetGlobalBooleanSetting( 'log-404', isset( $post_array['log_404'] ) );
111
+ $this->_plugin->SetGlobalBooleanSetting( 'purge-404-log', isset( $post_array['purge_log'] ) );
112
+ $this->_plugin->SetGlobalBooleanSetting( 'log-404-referrer', isset( $post_array['log_404_referrer'] ) );
 
 
 
 
 
 
 
 
 
 
 
113
 
114
+ $this->_plugin->SetGlobalBooleanSetting( 'log-visitor-404', isset( $post_array['log_visitor_404'] ) );
115
+ $this->_plugin->SetGlobalBooleanSetting( 'purge-visitor-404-log', isset( $post_array['purge_visitor_log'] ) );
116
+ $this->_plugin->SetGlobalBooleanSetting( 'log-visitor-404-referrer', isset( $post_array['log_visitor_404_referrer'] ) );
117
+ $this->_plugin->SetGlobalBooleanSetting( 'wc-all-stock-changes', isset( $post_array['wc_all_stock_changes'] ) );
118
 
119
+ $this->_plugin->settings()->Set404LogLimit( $post_array['user_404Limit'] );
120
+ $this->_plugin->settings()->SetVisitor404LogLimit( $post_array['visitor_404Limit'] );
 
 
 
 
 
 
 
121
 
122
+ $this->_plugin->settings()->set_failed_login_limit( $post_array['log_failed_login_limit'] );
123
+ $this->_plugin->settings()->set_visitor_failed_login_limit( $post_array['log_visitor_failed_login_limit'] );
124
  }
125
 
126
  /**
128
  */
129
  public function Render() {
130
  // Die if user does not have permission to view.
131
+ if ( ! $this->_plugin->settings()->CurrentUserCan( 'edit' ) ) {
132
  wp_die( esc_html__( 'You do not have sufficient permissions to access this page.', 'wp-security-audit-log' ) );
133
  }
134
 
163
  $log_level_nonce = isset( $post_array['wsal-log-level-nonce'] ) ? sanitize_text_field( $post_array['wsal-log-level-nonce'] ) : false;
164
 
165
  if ( wp_verify_nonce( $log_level_nonce, 'wsal-log-level' ) ) {
166
+ $this->_plugin->SetGlobalSetting( 'details-level', $log_level );
167
 
168
  if ( 'basic' === $log_level ) {
169
+ $this->_plugin->settings()->set_basic_mode();
170
  } elseif ( 'geek' === $log_level ) {
171
+ $this->_plugin->settings()->set_geek_mode();
172
  }
173
  }
174
 
175
+ $disabled_events = $this->_plugin->GetGlobalSetting( 'disabled-alerts' ); // Get disabled events.
176
  $disabled_events = explode( ',', $disabled_events );
177
+ $events_diff = array_diff( $disabled_events, $this->_plugin->settings()->geek_alerts ); // Calculate the difference of events.
178
  $events_diff = array_filter( $events_diff ); // Remove empty values.
179
  $is_custom = ! empty( $events_diff ) ? true : false; // If difference is not empty then mode is custom.
180
+ $log_details = $this->_plugin->GetGlobalSetting( 'details-level', false ); // Get log level option.
181
 
182
  $subcat_alerts = array( 1004, 2010, 2111, 9007, 9047 );
183
  $obsolete_events = array( 9999, 2126, 6023, 9011, 9070, 9075, 4013 );
319
  <th><?php esc_html_e( 'Description', 'wp-security-audit-log' ); ?></th>
320
  </tr>
321
  </thead>
322
+ <tbody>
323
  <?php if ( __( 'Content', 'wp-security-audit-log' ) === $subname ) : ?>
324
  <tr>
325
  <td colspan="4">
463
  </tr>
464
  <?php
465
  if ( 6007 === $alert->type ) {
466
+ $log_404 = $this->_plugin->GetGlobalBooleanSetting( 'log-404' );
467
+ $purge_log = $this->_plugin->GetGlobalBooleanSetting( 'purge-404-log' );
468
+ $log_404_referrer = $this->_plugin->GetGlobalBooleanSetting( 'log-404-referrer', true );
469
  ?>
470
  <tr>
471
  <td></td>
472
  <td>
473
  <input name="log_404" type="checkbox" class="check_log" value="1"
474
+ <?php checked( $log_404 ); ?> />
475
  </td>
476
+ <td colspan="2"><?php esc_html_e( 'Capture 404 requests to file (the log file are created in the /wp-content/uploads/wp-activity-log/404s/ directory)', 'wp-security-audit-log' ); ?></td>
477
  </tr>
478
  <tr>
479
  <td></td>
480
  <td>
481
  <input name="purge_log" type="checkbox" class="check_log" value="1"
482
+ <?php checked( $purge_log ); ?> />
483
  </td>
484
  <td colspan="2"><?php esc_html_e( 'Purge log files older than one month', 'wp-security-audit-log' ); ?></td>
485
  </tr>
486
  <tr>
487
  <td></td>
488
+ <td colspan="1"><input type="number" id="user_404Limit" name="user_404Limit" value="<?php echo esc_attr( $this->_plugin->settings()->Get404LogLimit() ); ?>" /></td>
489
  <td colspan="2"><?php esc_html_e( 'Number of 404 Requests to Log. By default the plugin keeps up to 99 requests to non-existing pages from the same IP address. Increase the value in this setting to the desired amount to keep a log of more or less requests.', 'wp-security-audit-log' ); ?></td>
490
  </tr>
491
  <tr>
492
  <td></td>
493
+ <td><input name="log_404_referrer" type="checkbox" class="check_log" value="1" <?php checked( $log_404_referrer ); ?>></td>
494
  <td colspan="2"><?php esc_html_e( 'Record the referrer that generated the 404 error.', 'wp-security-audit-log' ); ?></td>
495
  </tr>
496
  <?php
497
  }
498
  if ( 1002 === $alert->type ) {
499
+ $log_failed_login_limit = (int) $this->_plugin->GetGlobalSetting( 'log-failed-login-limit', 10 );
500
  $log_failed_login_limit = ( -1 === $log_failed_login_limit ) ? '0' : $log_failed_login_limit;
501
  ?>
502
  <tr>
509
  <?php
510
  }
511
  if ( 1003 === $alert->type ) {
512
+ $log_visitor_failed_login_limit = (int) $this->_plugin->GetGlobalSetting( 'log-visitor-failed-login-limit', 10 );
513
  $log_visitor_failed_login_limit = ( -1 === $log_visitor_failed_login_limit ) ? '0' : $log_visitor_failed_login_limit;
514
  ?>
515
  <tr>
522
  <?php
523
  }
524
  if ( 9019 === $alert->type ) {
525
+ $wc_all_stock_changes = $this->_plugin->GetGlobalBooleanSetting( 'wc-all-stock-changes', true );
526
  ?>
527
  <tr>
528
  <td></td>
552
  <td>
553
  <div class="addon-wrapper">
554
  <img src="<?php echo trailingslashit( WSAL_BASE_URL ) . 'img/help/website-file-changes-monitor.jpg'; ?>">
555
+ <h4><?php echo esc_html__( 'Website File Changes Monitor', 'wp-security-audit-log' ); ?></h4>
556
+ <p><?php echo esc_html__( 'To keep a log of file changes please install Website File Changes Monitor, a plugin which is also developed by us.', 'wp-security-audit-log' ); ?></p><br>
557
+ <p><button class="install-addon button button-primary" data-nonce="<?php echo esc_attr( wp_create_nonce( 'wsal-install-addon' ) ); ?>" data-plugin-slug="website-file-changes-monitor/website-file-changes-monitor.php" data-plugin-download-url="https://downloads.wordpress.org/plugin/website-file-changes-monitor.latest-stable.zip"><?php _e( 'Install plugin now', 'wp-security-audit-log' ); ?></button><span class="spinner" style="display: none; visibility: visible; float: none; margin: 0 0 0 8px;"></span> <a href="https://wpactivitylog.com/support/kb/wordpress-files-changes-warning-activity-logs/?utm_source=plugin&utm_medium=referral&utm_campaign=WSAL&utm_content=settings+pages" target="_blank" style="margin-left: 15px;"><?php echo esc_html__( 'Learn More', 'wp-security-audit-log' ); ?></a></p>
558
  </div>
559
  </td>
560
  </tr>
574
  </div>
575
  <?php endforeach; ?>
576
  <?php
577
+ $frontend_events = WSAL_Settings::get_frontend_events();
578
  ?>
579
  <table id="tab-frontend-events" class="form-table wp-list-table wsal-tab widefat fixed" style="display: table;" cellspacing="0">
580
  <tbody>
617
  </td>
618
  </tr>
619
  <?php
620
+ $log_visitor_404 = $this->_plugin->GetGlobalBooleanSetting( 'log-visitor-404' );
621
+ $purge_visitor_log = $this->_plugin->GetGlobalBooleanSetting( 'purge-visitor-404-log' );
622
+ $log_visitor_404_referrer = $this->_plugin->GetGlobalBooleanSetting( 'log-visitor-404-referrer', 'on' );
623
  ?>
624
  <tr>
625
+ <td><input name="log_visitor_404" type="checkbox" class="check_visitor_log" value="1" <?php checked( $log_visitor_404 ); ?> /></td>
626
+ <td><?php esc_html_e( 'Capture 404 requests to file (the log file are created in the /wp-content/uploads/wp-activity-log/404s/ directory)', 'wp-security-audit-log' ); ?></td>
627
  </tr>
628
  <tr>
629
+ <td><input name="purge_visitor_log" type="checkbox" class="check_visitor_log" value="1" <?php checked( $purge_visitor_log ); ?> /></td>
630
  <td><?php esc_html_e( 'Purge log files older than one month', 'wp-security-audit-log' ); ?></td>
631
  </tr>
632
  <tr>
633
+ <td><input type="number" id="visitor_404Limit" name="visitor_404Limit" value="<?php echo esc_attr( $this->_plugin->settings()->GetVisitor404LogLimit() ); ?>" /></td>
634
  <td><?php esc_html_e( 'Number of 404 Requests to Log. By default the plugin keeps up to 99 requests to non-existing pages from the same IP address. Increase the value in this setting to the desired amount to keep a log of more or less requests. Note that by increasing this value to a high number, should your website be scanned the plugin will consume more resources to log all the requests.', 'wp-security-audit-log' ); ?></td>
635
  </tr>
636
  <tr>
637
+ <td><input name="log_visitor_404_referrer" type="checkbox" class="check_log" value="1" <?php checked( $log_visitor_404_referrer ); ?>></td>
638
  <td><?php esc_html_e( 'Record the referrer that generated the 404 error.', 'wp-security-audit-log' ); ?></td>
639
  </tr>
 
 
 
 
 
 
 
 
 
 
 
640
  </tbody>
641
  </table>
642
  <?php
865
  });
866
  });
867
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
868
  jQuery(document).on('closed', toggle_modal, function (event) {
869
  if (event.reason && event.reason === 'cancellation') {
870
  for ( var index = 0; index < alerts.length; index++ ) {
classes/WidgetManager.php CHANGED
@@ -46,8 +46,8 @@ class WSAL_WidgetManager {
46
  global $pagenow;
47
 
48
  if (
49
- $this->_plugin->settings->IsWidgetsEnabled() // If widget is enabled.
50
- && $this->_plugin->settings->CurrentUserCan( 'view' ) // If user has permission to view.
51
  && 'index.php' === $pagenow // If the current page is dashboard.
52
  ) {
53
  wp_add_dashboard_widget(
@@ -116,7 +116,7 @@ class WSAL_WidgetManager {
116
  // order by date of creation.
117
  $query->addOrderBy( 'created_on', true );
118
  // set the limit based on the limit option for dashboard alerts.
119
- $query->setLimit( $this->_plugin->settings->GetDashboardWidgetMaxAlerts() );
120
  return $query;
121
  }
122
 
46
  global $pagenow;
47
 
48
  if (
49
+ $this->_plugin->settings()->IsWidgetsEnabled() // If widget is enabled.
50
+ && $this->_plugin->settings()->CurrentUserCan( 'view' ) // If user has permission to view.
51
  && 'index.php' === $pagenow // If the current page is dashboard.
52
  ) {
53
  wp_add_dashboard_widget(
116
  // order by date of creation.
117
  $query->addOrderBy( 'created_on', true );
118
  // set the limit based on the limit option for dashboard alerts.
119
+ $query->setLimit( $this->_plugin->settings()->GetDashboardWidgetMaxAlerts() );
120
  return $query;
121
  }
122
 
defaults.php CHANGED
@@ -21,15 +21,14 @@ if ( ! class_exists( 'WpSecurityAuditLog' ) ) {
21
  defined( 'E_CRITICAL' ) || define( 'E_CRITICAL', 'E_CRITICAL' );
22
 
23
  /**
24
- * Load Custom Alerts from uploads/wp-security-audit-log/custom-alerts.php if exists
25
  *
26
  * @param WpSecurityAuditLog $wsal - Instance of main plugin.
27
  */
28
  function load_include_custom_file( $wsal ) {
29
  // Custom alerts can be added via a special file inside the file and dir
30
- // wp-uploads/wp-security-audit-log/custom-alerts.php.
31
- $upload_dir = wp_upload_dir();
32
- $uploads_dir_path = trailingslashit( $upload_dir['basedir'] ) . 'wp-security-audit-log';
33
 
34
  /*
35
  * Get an array of directories to loop through to add custom alerts.
@@ -88,10 +87,10 @@ function wsaldefaults_wsal_init() {
88
  __( 'User Activity', 'wp-security-audit-log' ) => array(
89
  array( 1000, WSAL_LOW, __( 'User logged in', 'wp-security-audit-log' ), '', 'user', 'login' ),
90
  array( 1001, WSAL_LOW, __( 'User logged out', 'wp-security-audit-log' ), '', 'user', 'logout' ),
91
- array( 1002, WSAL_MEDIUM, __( 'Login failed', 'wp-security-audit-log' ), '%Attempts% failed login(s) %LineBreak% %LogFileText%', 'user', 'failed-login' ),
92
  array( 1003, WSAL_LOW, __( 'Login failed / non existing user', 'wp-security-audit-log' ), __( '%Attempts% failed login(s) %LineBreak% %LogFileText%', 'wp-security-audit-log' ), 'system', 'failed-login' ),
93
  array( 1004, WSAL_MEDIUM, __( 'Login blocked', 'wp-security-audit-log' ), __( 'Login blocked because other session(s) already exist for this user. %LineBreak% IP address: %ClientIP%', 'wp-security-audit-log' ), 'user', 'blocked' ),
94
- array( 1005, WSAL_LOW, __( 'User logged in with existing session(s)', 'wp-security-audit-log' ), __( 'User logged in however there are other session(s) already exist for this user. %LineBreak% IP address: %IPAddress%', 'wp-security-audit-log' ), 'user', 'login' ),
95
  array( 1006, WSAL_MEDIUM, __( 'User logged out all other sessions with the same username', 'wp-security-audit-log' ), __( 'Logged out all other sessions with the same user.', 'wp-security-audit-log' ), 'user', 'logout' ),
96
  array( 1007, WSAL_MEDIUM, __( 'User session destroyed and logged out', 'wp-security-audit-log' ), __( 'Terminated the session of another user. %LineBreak% User: %TargetUserName% %LineBreak% Session ID: %TargetSessionID%', 'wp-security-audit-log' ), 'user', 'logout' ),
97
  array( 1008, WSAL_MEDIUM, __( 'Switched to another user', 'wp-security-audit-log' ), __( 'Switched to another user. %LineBreak% User: %TargetUserName% %LineBreak% Role: %TargetUserRole%', 'wp-security-audit-log' ), 'user', 'login' ),
@@ -154,6 +153,23 @@ function wsaldefaults_wsal_init() {
154
  array( 2062, WSAL_LOW, __( 'User updated a custom field name for a post', 'wp-security-audit-log' ), __( 'Old custom field name: %MetaKeyOld% %LineBreak% New custom field name: %MetaKeyNew% %LineBreak% Post: %PostTitle% %LineBreak% Post ID: %PostID% %LineBreak% Post Type: %PostType% %LineBreak% Post Status: %PostStatus% %PostUrlIfPlublished% %LineBreak% %EditorLinkPost%', 'wp-security-audit-log' ), 'custom-field', 'renamed' ),
155
  ),
156
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
157
  /**
158
  * Alerts: Comments
159
  */
@@ -169,8 +185,8 @@ function wsaldefaults_wsal_init() {
169
  array( 2098, WSAL_LOW, __( 'User permanently deleted a comment', 'wp-security-audit-log' ), __( 'Permanently deleted the comment posted by %Author% on the post %PostTitle% %LineBreak% Post ID: %PostID% %LineBreak% Post Type: %PostType% %LineBreak% Post Status: %PostStatus% %PostUrlIfPlublished% %LineBreak% Comment ID: %CommentID%', 'wp-security-audit-log' ), 'comment', 'deleted' ),
170
  array( 2099, WSAL_INFORMATIONAL, __( 'User posted a comment', 'wp-security-audit-log' ), __( 'Posted a comment on the post %PostTitle% %LineBreak% Post ID: %PostID% %LineBreak% Post Type: %PostType% %LineBreak% Post Status: %PostStatus% %LineBreak% Comment ID: %CommentID% %PostUrlIfPlublished% %LineBreak% %CommentLink%', 'wp-security-audit-log' ), 'comment', 'created' ),
171
  /**
172
- * IMPORTANT: This alert is depricated but should not be
173
- * removed from the definitions for backwards compatibilty.
174
  */
175
  array( 2126, WSAL_INFORMATIONAL, __( 'Visitor posted a comment', 'wp-security-audit-log' ), __( 'Posted a comment on the post %PostTitle% %LineBreak% Post ID: %PostID% %LineBreak% Post Type: %PostType% %LineBreak% Post Status: %PostStatus% %LineBreak% Comment ID: %CommentID% %PostUrlIfPlublished% %LineBreak% %CommentLink%', 'wp-security-audit-log' ), 'comment', 'created' ),
176
  ),
@@ -205,7 +221,7 @@ function wsaldefaults_wsal_init() {
205
  * Alerts: Custom Post Types
206
  *
207
  * IMPORTANT: These alerts should not be removed from here
208
- * for backwards compatibilty.
209
  *
210
  * @deprecated 3.1.0
211
  */
@@ -245,7 +261,7 @@ function wsaldefaults_wsal_init() {
245
  * Alerts: Pages
246
  *
247
  * IMPORTANT: These alerts should not be removed from here
248
- * for backwards compatibilty.
249
  *
250
  * @deprecated 3.1.0
251
  */
@@ -300,7 +316,7 @@ function wsaldefaults_wsal_init() {
300
  array( 4017, WSAL_INFORMATIONAL, __( 'User changed first name for a user', 'wp-security-audit-log' ), __( 'Changed the first name of the user %TargetUsername% %LineBreak% Previous name: %old_firstname% %LineBreak% New name: %new_firstname% %LineBreak% Role: %Roles% %LineBreak% Last name: %LastName% %LineBreak% %EditUserLink%', 'wp-security-audit-log' ), 'user', 'modified' ),
301
  array( 4018, WSAL_INFORMATIONAL, __( 'User changed last name for a user', 'wp-security-audit-log' ), __( 'Changed the last name of the user %TargetUsername% %LineBreak% Previous last name: %old_lastname% %LineBreak% New last name: %new_lastname% %LineBreak% Role: %Roles% %LineBreak% First name: %FirstName% %LineBreak% %EditUserLink%', 'wp-security-audit-log' ), 'user', 'modified' ),
302
  array( 4019, WSAL_INFORMATIONAL, __( 'User changed nickname for a user', 'wp-security-audit-log' ), __( 'Changed the nickname of the user %TargetUsername% %LineBreak% Previous nickname: %old_nickname% New nickname: %new_nickname% %LineBreak% Role: %Roles% %LineBreak% First name: %FirstName% %LineBreak% Last name: %LastName% %LineBreak% %EditUserLink%', 'wp-security-audit-log' ), 'user', 'modified' ),
303
- array( 4020, WSAL_LOW, __( 'User changed the display name for a user', 'wp-security-audit-log' ), __( 'Changed the display name of the user %TargetUsername% %LineBreak% Previous display name: %old_displayname% New display name: %new_displayname% %LineBreak% Role: %Roles% %LineBreak% First name: %FirstName% %LineBreak% Last name: %LastName% %LineBreak% %EditUserLink%', 'wp-security-audit-log' ), 'user', 'modified' ),
304
  ),
305
 
306
  __( 'Multisite User Profiles', 'wp-security-audit-log' ) => array(
@@ -319,9 +335,9 @@ function wsaldefaults_wsal_init() {
319
  array( 5002, WSAL_HIGH, __( 'User deactivated a WordPress plugin', 'wp-security-audit-log' ), __( 'Name: %PluginData->Name% %LineBreak% Install location: %PluginFile%', 'wp-security-audit-log' ), 'plugin', 'deactivated' ),
320
  array( 5003, WSAL_HIGH, __( 'User uninstalled a plugin', 'wp-security-audit-log' ), __( 'Name: %PluginData->Name% %LineBreak% Install location: %PluginFile%', 'wp-security-audit-log' ), 'plugin', 'uninstalled' ),
321
  array( 5004, WSAL_LOW, __( 'User upgraded a plugin', 'wp-security-audit-log' ), __( 'Name: %PluginData->Name% %LineBreak% Install location: %PluginFile%', 'wp-security-audit-log' ), 'plugin', 'updated' ),
322
- array( 5010, WSAL_LOW, __( 'Plugin created tables', 'wp-security-audit-log' ), __( 'Plugin created these tables in the database %LineBreak% Plugin: %Plugin->Name% %LineBreak% Tables: %TableNames%', 'wp-security-audit-log' ), 'database', 'created' ),
323
- array( 5011, WSAL_LOW, __( 'Plugin modified tables structure', 'wp-security-audit-log' ), __( 'Plugin modified the structure of these database tables %LineBreak% Plugin: %Plugin->Name% %LineBreak% Tables: %TableNames%', 'wp-security-audit-log' ), 'database', 'modified' ),
324
- array( 5012, WSAL_MEDIUM, __( 'Plugin deleted tables', 'wp-security-audit-log' ), __( 'Plugin deleted these tables from the database %LineBreak% Plugin: %Plugin->Name% %LineBreak% Tables: %TableNames%', 'wp-security-audit-log' ), 'database', 'deleted' ),
325
  array( 5019, WSAL_MEDIUM, __( 'A plugin created a post', 'wp-security-audit-log' ), __( 'Plugin %PluginName% created the post %PostTitle% %LineBreak% Post ID: %PostID% %LineBreak% Type: %PostType% %LineBreak% Status: %PostStatus% %LineBreak% %EditorLinkPage%', 'wp-security-audit-log' ), 'post', 'created' ),
326
  array( 5025, WSAL_LOW, __( 'A plugin deleted a post', 'wp-security-audit-log' ), __( 'Plugin %PluginName% deleted the post %PostTitle% %LineBreak% Post ID: %PostID% %LineBreak% Type: %PostType%', 'wp-security-audit-log' ), 'post', 'deleted' ),
327
  array( 2051, WSAL_HIGH, __( 'User changed a file using the plugin editor', 'wp-security-audit-log' ), __( 'Modified a file with the plugin editor %LineBreak% File: %File%', 'wp-security-audit-log' ), 'file', 'modified' ),
@@ -347,6 +363,9 @@ function wsaldefaults_wsal_init() {
347
  array( 5016, WSAL_HIGH, __( 'Unknown component created tables', 'wp-security-audit-log' ), __( 'An unknown component created these tables in the database %LineBreak% Tables: %TableNames%', 'wp-security-audit-log' ), 'database', 'created' ),
348
  array( 5017, WSAL_HIGH, __( 'Unknown component modified tables structure', 'wp-security-audit-log' ), __( 'An unknown component modified the structure of these database tables %LineBreak% Tables: %TableNames%', 'wp-security-audit-log' ), 'database', 'modified' ),
349
  array( 5018, WSAL_HIGH, __( 'Unknown component deleted tables', 'wp-security-audit-log' ), __( 'An unknown component deleted these tables from the database %LineBreak% Tables: %TableNames%', 'wp-security-audit-log' ), 'database', 'deleted' ),
 
 
 
350
  ),
351
  ),
352
 
@@ -405,131 +424,6 @@ function wsaldefaults_wsal_init() {
405
  ),
406
  ),
407
 
408
- __( 'WooCommerce', 'wp-security-audit-log' ) => array(
409
- __( 'Products', 'wp-security-audit-log' ) => array(
410
- array( 9000, WSAL_LOW, __( 'User created a new product', 'wp-security-audit-log' ), __( 'Created a new product called %ProductTitle% %LineBreak% ID: %PostID% %LineBreak% Status: %ProductStatus% %LineBreak% %EditorLinkProduct%', 'wp-security-audit-log' ), 'woocommerce-product', 'created' ),
411
- array( 9001, WSAL_MEDIUM, __( 'User published a product', 'wp-security-audit-log' ), __( 'Published the product called %ProductTitle% %LineBreak% ID: %PostID% %LineBreak% Status: %ProductStatus% %LineBreak% %EditorLinkProduct%', 'wp-security-audit-log' ), 'woocommerce-product', 'published' ),
412
- array( 9003, WSAL_LOW, __( 'User changed the category of a product', 'wp-security-audit-log' ), __( 'Changed the category of the product %ProductTitle% %LineBreak% ID: %PostID% %LineBreak% Status: %ProductStatus% %LineBreak% Previous categories: %OldCategories% %LineBreak% New categories: %NewCategories% %LineBreak% %EditorLinkProduct%', 'wp-security-audit-log' ), 'woocommerce-product', 'modified' ),
413
- array( 9004, WSAL_INFORMATIONAL, __( 'User modified the short description of a product', 'wp-security-audit-log' ), __( 'Changed the short description of the product %ProductTitle% %LineBreak% ID: %PostID% %LineBreak% Status: %ProductStatus% %LineBreak% %EditorLinkProduct%', 'wp-security-audit-log' ), 'woocommerce-product', 'modified' ),
414
- array( 9005, WSAL_LOW, __( 'User modified the text of a product', 'wp-security-audit-log' ), __( 'Changed the text of the product %ProductTitle% %LineBreak% ID: %PostID% %LineBreak% Status: %ProductStatus% %LineBreak% %EditorLinkProduct%', 'wp-security-audit-log' ), 'woocommerce-product', 'modified' ),
415
- array( 9006, WSAL_LOW, __( 'User changed the URL of a product', 'wp-security-audit-log' ), __( 'Changed the URL of the product %ProductTitle% %LineBreak% ID: %PostID% %LineBreak% Status: %ProductStatus% %LineBreak% Previous URL: %OldUrl% %LineBreak% New URL: %NewUrl% %LineBreak% %EditorLinkProduct%', 'wp-security-audit-log' ), 'woocommerce-product', 'modified' ),
416
- array( 9007, WSAL_MEDIUM, __( 'User changed the Product Data of a product', 'wp-security-audit-log' ), __( 'Changed the type of the product %ProductTitle% %LineBreak% ID: %PostID% %LineBreak% Status: %ProductStatus% %LineBreak% Previous type: %OldType% %LineBreak% New type: %NewType% %LineBreak% %EditorLinkProduct%', 'wp-security-audit-log' ), 'woocommerce-product', 'modified' ),
417
- array( 9008, WSAL_INFORMATIONAL, __( 'User changed the date of a product', 'wp-security-audit-log' ), __( 'Changed the date of the product %ProductTitle% %LineBreak% ID: %PostID% %LineBreak% Status: %ProductStatus% %LineBreak% Previous date: %OldDate% %LineBreak% New date: %NewDate% %LineBreak% %EditorLinkProduct%', 'wp-security-audit-log' ), 'woocommerce-product', 'modified' ),
418
- array( 9009, WSAL_MEDIUM, __( 'User changed the visibility of a product', 'wp-security-audit-log' ), __( 'Changed the visibility of the product %ProductTitle% %LineBreak% ID: %PostID% %LineBreak% Status: %ProductStatus% %LineBreak% Previous visibility: %OldVisibility% %LineBreak% New visibility: %NewVisibility% %LineBreak% %EditorLinkProduct%', 'wp-security-audit-log' ), 'woocommerce-product', 'modified' ),
419
- array( 9010, WSAL_MEDIUM, __( 'User modified the product', 'wp-security-audit-log' ), __( 'Modified the product %ProductTitle% %LineBreak% ID: %PostID% %LineBreak% Status: %ProductStatus% %LineBreak% %EditorLinkProduct%', 'wp-security-audit-log' ), 'woocommerce-product', 'modified' ),
420
- array( 9011, E_NOTICE, __( 'User modified the draft product', 'wp-security-audit-log' ), __( 'Modified the draft product %ProductTitle%. View the product: %EditorLinkProduct%.', 'wp-security-audit-log' ), 'woocommerce-product' ),
421
- array( 9012, WSAL_HIGH, __( 'User moved a product to trash', 'wp-security-audit-log' ), __( 'Moved the product %ProductTitle% to trash %LineBreak% ID: %PostID% %LineBreak% Status: %ProductStatus%', 'wp-security-audit-log' ), 'woocommerce-product', 'deleted' ),
422
- array( 9013, WSAL_MEDIUM, __( 'User permanently deleted a product', 'wp-security-audit-log' ), __( 'Permanently deleted the product %ProductTitle% %LineBreak% ID: %PostID%', 'wp-security-audit-log' ), 'woocommerce-product', 'deleted' ),
423
- array( 9014, WSAL_HIGH, __( 'User restored a product from the trash', 'wp-security-audit-log' ), __( 'Restored the product %ProductTitle% from trash %LineBreak% ID: %PostID% %LineBreak% Status: %ProductStatus% %LineBreak% %EditorLinkProduct%', 'wp-security-audit-log' ), 'woocommerce-product', 'restored' ),
424
- array( 9015, WSAL_MEDIUM, __( 'User changed status of a product', 'wp-security-audit-log' ), __( 'Changed the status of the product %ProductTitle% %LineBreak% ID: %PostID% %LineBreak% Previous status: %OldStatus% %LineBreak% New status: %NewStatus% %LineBreak% %EditorLinkProduct%', 'wp-security-audit-log' ), 'woocommerce-product', 'modified' ),
425
- array( 9072, WSAL_INFORMATIONAL, __( 'User opened a product in the editor', 'wp-security-audit-log' ), __( 'Opened the product %ProductTitle% in the editor %LineBreak% ID: %PostID% %LineBreak% Status: %ProductStatus% %LineBreak% %EditorLinkProduct%', 'wp-security-audit-log' ), 'woocommerce-product', 'opened' ),
426
- array( 9073, WSAL_INFORMATIONAL, __( 'User viewed a product', 'wp-security-audit-log' ), __( 'Viewed the product %ProductTitle% page %LineBreak% ID: %PostID% %LineBreak% Status: %ProductStatus% %LineBreak% %EditorLinkProduct%', 'wp-security-audit-log' ), 'woocommerce-product', 'viewed' ),
427
- array( 9077, WSAL_MEDIUM, __( 'User renamed a product', 'wp-security-audit-log' ), __( 'Old name: %OldTitle% %LineBreak% New name: %NewTitle% %LineBreak% ID: %PostID% %LineBreak% Status: %ProductStatus% %LineBreak% %EditorLinkProduct%', 'wp-security-audit-log' ), 'woocommerce-product', 'renamed' ),
428
- array( 9016, WSAL_MEDIUM, __( 'User changed type of a price', 'wp-security-audit-log' ), __( 'Changed the %PriceType% of the product %ProductTitle% %LineBreak% ID: %PostID% %LineBreak% Status: %ProductStatus% %LineBreak% Previous price: %OldPrice% %LineBreak% New price: %NewPrice% %LineBreak% %EditorLinkProduct%', 'wp-security-audit-log' ), 'woocommerce-product', 'modified' ),
429
- array( 9017, WSAL_MEDIUM, __( 'User changed the SKU of a product', 'wp-security-audit-log' ), __( 'Changed the SKU of the product %ProductTitle% %LineBreak% ID: %PostID% %LineBreak% Status: %ProductStatus% %LineBreak% Previous SKU: %OldSku% %LineBreak% New SKU: %NewSku% %LineBreak% %EditorLinkProduct%', 'wp-security-audit-log' ), 'woocommerce-product', 'modified' ),
430
- array( 9018, WSAL_LOW, __( 'User changed the stock status of a product', 'wp-security-audit-log' ), __( 'Changed the stock status of the product %ProductTitle% %LineBreak% ID: %PostID% %LineBreak% Status: %ProductStatus% %LineBreak% Previous stock status: %OldStatus% %LineBreak% New stock status: %NewStatus% %LineBreak% %EditorLinkProduct%', 'wp-security-audit-log' ), 'woocommerce-product', 'modified' ),
431
- array( 9019, WSAL_LOW, __( 'User changed the stock quantity', 'wp-security-audit-log' ), __( 'Changed the stock quantity of the product %ProductTitle% %LineBreak% ID: %PostID% %LineBreak% Status: %ProductStatus% %LineBreak% Previous quantity: %OldValue% %LineBreak% New quantity: %NewValue% %LineBreak% %EditorLinkProduct%', 'wp-security-audit-log' ), 'woocommerce-product', 'modified' ),
432
- array( 9020, WSAL_MEDIUM, __( 'User set a product type', 'wp-security-audit-log' ), __( 'Changed the type of the %NewType% product %ProductTitle% %LineBreak% ID: %PostID% %LineBreak% Status: %ProductStatus% %LineBreak% Previous type: %OldType% %LineBreak% New type: %NewType% %LineBreak% %EditorLinkProduct%', 'wp-security-audit-log' ), 'woocommerce-product', 'modified' ),
433
- array( 9021, WSAL_INFORMATIONAL, __( 'User changed the weight of a product', 'wp-security-audit-log' ), __( 'Changed the weight of the product %ProductTitle% %LineBreak% ID: %PostID% %LineBreak% Status: %ProductStatus% %LineBreak% Previous weight: %OldWeight% %LineBreak% New weight: %NewWeight% %LineBreak% %EditorLinkProduct%', 'wp-security-audit-log' ), 'woocommerce-product', 'modified' ),
434
- array( 9022, WSAL_INFORMATIONAL, __( 'User changed the dimensions of a product', 'wp-security-audit-log' ), __( 'Changed the %DimensionType% dimensions of the product %ProductTitle% %LineBreak% ID: %PostID% %LineBreak% Status: %ProductStatus% %LineBreak% Previous value: %OldDimension% %LineBreak% New value: %NewDimension% %LineBreak% %EditorLinkProduct%', 'wp-security-audit-log' ), 'woocommerce-product', 'modified' ),
435
- array( 9023, WSAL_MEDIUM, __( 'User added the Downloadable File to a product', 'wp-security-audit-log' ), __( 'Added a downloadable file to the product %ProductTitle% %LineBreak% ID: %PostID% %LineBreak% Status: %ProductStatus% %LineBreak% File name: %FileName% %LineBreak% File URL: %FileUrl% %LineBreak% %EditorLinkProduct%', 'wp-security-audit-log' ), 'woocommerce-product', 'modified' ),
436
- array( 9024, WSAL_MEDIUM, __( 'User Removed the Downloadable File from a product', 'wp-security-audit-log' ), __( 'Removed the downloadable file from the product %ProductTitle% %LineBreak% ID: %PostID% %LineBreak% Status: %ProductStatus% %LineBreak% File name: %FileName% %LineBreak% File URL: %FileUrl% %LineBreak% %EditorLinkProduct%', 'wp-security-audit-log' ), 'woocommerce-product', 'modified' ),
437
- array( 9025, WSAL_INFORMATIONAL, __( 'User changed the name of a Downloadable File in a product', 'wp-security-audit-log' ), __( 'Changed the name of the downloadable file to the product %ProductTitle% %LineBreak% ID: %PostID% %LineBreak% Status: %ProductStatus% %LineBreak% Previous file name: %OldName% %LineBreak% New file name: %NewName% %LineBreak% %EditorLinkProduct%', 'wp-security-audit-log' ), 'woocommerce-product', 'modified' ),
438
- array( 9026, WSAL_MEDIUM, __( 'User changed the URL of the Downloadable File in a product', 'wp-security-audit-log' ), __( 'Changed the URL of the downloadable file to the product %ProductTitle% %LineBreak% ID: %PostID% %LineBreak% Status: %ProductStatus% %LineBreak% File name: %FileName% %LineBreak% Previous URL: %OldUrl% %LineBreak% New URL: %NewUrl% %LineBreak% %EditorLinkProduct%', 'wp-security-audit-log' ), 'woocommerce-product', 'modified' ),
439
- array( 9042, WSAL_INFORMATIONAL, __( 'User changed the catalog visibility of a product', 'wp-security-audit-log' ), __( 'Changed the product visibility of the product %ProductTitle% %LineBreak% ID: %PostID% %LineBreak% Status: %ProductStatus% %LineBreak% Previous setting: %OldVisibility% %LineBreak% New setting: %NewVisibility% %LineBreak% %EditorLinkProduct%', 'wp-security-audit-log' ), 'woocommerce-product', 'modified' ),
440
- array( 9043, WSAL_INFORMATIONAL, __( 'User changed the setting Featured Product of a product', 'wp-security-audit-log' ), __( 'The setting Featured Product for the product %ProductTitle% %LineBreak% ID: %PostID% %LineBreak% Status: %ProductStatus% %LineBreak% %EditorLinkProduct%', 'wp-security-audit-log' ), 'woocommerce-product', 'enabled' ),
441
- array( 9044, WSAL_INFORMATIONAL, __( 'User changed the Allow Backorders setting of a product', 'wp-security-audit-log' ), __( 'Changed the Allow Backorders setting for the product %ProductTitle% %LineBreak% ID: %PostID% %LineBreak% Status: %ProductStatus% %LineBreak% Previous status: %OldStatus% %LineBreak% New status: %NewStatus% %LineBreak% %EditorLinkProduct%', 'wp-security-audit-log' ), 'woocommerce-product', 'modified' ),
442
- array( 9045, WSAL_MEDIUM, __( 'User added/removed products to upsell of a product', 'wp-security-audit-log' ), __( 'Products to Upsell in the product %ProductTitle% %LineBreak% ID: %PostID% %LineBreak% Status: %ProductStatus% %LineBreak% Product: %UpsellTitle% %LineBreak% %EditorLinkProduct%', 'wp-security-audit-log' ), 'woocommerce-product', 'added' ),
443
- array( 9046, WSAL_MEDIUM, __( 'User added/removed products to cross-sells of a product', 'wp-security-audit-log' ), __( 'Product to Cross-sell in the product %ProductTitle% %LineBreak% ID: %PostID% %LineBreak% Status: %ProductStatus% %LineBreak% Product: %CrossSellTitle% %LineBreak% %EditorLinkProduct%', 'wp-security-audit-log' ), 'woocommerce-product', 'added' ),
444
- array( 9105, WSAL_LOW, __( 'System changed the stock quantity of a product', 'wp-security-audit-log' ), __( 'The stock quantity of the product %ProductTitle% was changed due to a purchase. %LineBreak% ID: %PostID% %LineBreak% Status: %ProductStatus% %LineBreak% Previous quantity: %OldValue% %LineBreak% New quantity: %NewValue% %LineBreak% %EditorLinkProduct%', 'wp-security-audit-log' ), 'woocommerce-product', 'modified' ),
445
- array( 9047, WSAL_LOW, __( 'Added a new attribute of a product', 'wp-security-audit-log' ), __( 'A new attribute to the product %ProductTitle% %LineBreak% ID: %ProductID% %LineBreak% Status: %ProductStatus% %LineBreak% Attribute name: %AttributeName% %LineBreak% Attribute value: %AttributeValue% %LineBreak% %EditorLinkProduct%', 'wp-security-audit-log' ), 'woocommerce-product', 'added' ),
446
- array( 9048, WSAL_LOW, __( 'Modified the value of an attribute of a product', 'wp-security-audit-log' ), __( 'Modified the value of an attribute in the product %ProductTitle% %LineBreak% ID: %ProductID% %LineBreak% Status: %ProductStatus% %LineBreak% Attribute name: %AttributeName% %LineBreak% Previous attribute value: %OldValue% %LineBreak% New attribute value: %NewValue% %LineBreak% %EditorLinkProduct%', 'wp-security-audit-log' ), 'woocommerce-product', 'modified' ),
447
- array( 9049, WSAL_LOW, __( 'Changed the name of an attribute of a product', 'wp-security-audit-log' ), __( 'Changed the name of an attribute in the product %ProductTitle% %LineBreak% ID: %ProductID% %LineBreak% Status: %ProductStatus% %LineBreak% Previous attribute name: %OldValue% %LineBreak% New attribute name: %NewValue% %LineBreak% %EditorLinkProduct%', 'wp-security-audit-log' ), 'woocommerce-product', 'renamed' ),
448
- array( 9050, WSAL_LOW, __( 'Deleted an attribute of a product', 'wp-security-audit-log' ), __( 'An attribute from the product %ProductTitle% %LineBreak% ID: %ProductID% %LineBreak% Status: %ProductStatus% %LineBreak% Attribute name: %AttributeName% %LineBreak% Attribute value: %AttributeValue% %LineBreak% %EditorLinkProduct%', 'wp-security-audit-log' ), 'woocommerce-product', 'deleted' ),
449
- array( 9051, WSAL_LOW, __( 'Set the attribute visibility of a product', 'wp-security-audit-log' ), __( 'Changed the visibility of an attribute in the product %ProductTitle% %LineBreak% ID: %ProductID% %LineBreak% Status: %ProductStatus% %LineBreak% Attribute name: %AttributeName% %LineBreak% Attribute visibility: %AttributeVisiblilty% %LineBreak% %EditorLinkProduct%', 'wp-security-audit-log' ), 'woocommerce-product', 'modified' ),
450
- ),
451
-
452
- __( 'Store', 'wp-security-audit-log' ) => array(
453
- array( 9027, WSAL_HIGH, __( 'User changed the Weight Unit', 'wp-security-audit-log' ), __( 'Changed the weight unit of the store %LineBreak% Previous weight unit: %OldUnit% %LineBreak% New weight unit: %NewUnit%', 'wp-security-audit-log' ), 'woocommerce-store', 'modified' ),
454
- array( 9028, WSAL_HIGH, __( 'User changed the Dimensions Unit', 'wp-security-audit-log' ), __( 'Changed the dimensions unit of the store %LineBreak% Previous dimensions unit: %OldUnit% %LineBreak% New dimensions unit: %NewUnit%', 'wp-security-audit-log' ), 'woocommerce-store', 'modified' ),
455
- array( 9029, WSAL_HIGH, __( 'User changed the Base Location', 'wp-security-audit-log' ), __( 'Changed the base location %LineBreak% Previous address: %OldLocation% %LineBreak% New address: %NewLocation%', 'wp-security-audit-log' ), 'woocommerce-store', 'modified' ),
456
- array( 9030, WSAL_HIGH, __( 'User enabled/disabled taxes', 'wp-security-audit-log' ), __( 'Taxes in WooCommerce', 'wp-security-audit-log' ), 'woocommerce-store', 'enabled' ),
457
- array( 9031, WSAL_HIGH, __( 'User changed the currency', 'wp-security-audit-log' ), __( 'Changed the currency of the store %LineBreak% Previous currency: %OldCurrency% %LineBreak% New currency: %NewCurrency%', 'wp-security-audit-log' ), 'woocommerce-store', 'modified' ),
458
- array( 9032, WSAL_HIGH, __( 'User enabled/disabled the use of coupons during checkout', 'wp-security-audit-log' ), __( 'The use of coupons during checkout', 'wp-security-audit-log' ), 'woocommerce-store', 'enabled' ),
459
- array( 9033, WSAL_MEDIUM, __( 'User enabled/disabled guest checkout', 'wp-security-audit-log' ), __( 'Guest checkout in the store', 'wp-security-audit-log' ), 'woocommerce-store', 'enabled' ),
460
- array( 9034, WSAL_HIGH, __( 'User enabled/disabled cash on delivery', 'wp-security-audit-log' ), __( 'The option cash on delivery', 'wp-security-audit-log' ), 'woocommerce-store', 'enabled' ),
461
- array( 9085, WSAL_HIGH, __( 'User modified selling location(s)', 'wp-security-audit-log' ), __( 'The setting Selling location(s) %LineBreak% Old setting: %old% %LineBreak% New Setting: %new%', 'wp-security-audit-log' ), 'woocommerce-store', 'modified' ),
462
- array( 9086, WSAL_HIGH, __( 'User modified excluded selling location(s)', 'wp-security-audit-log' ), __( 'Changed the list of excluded countries to sell to %LineBreak% Old setting: %old% %LineBreak% New Setting: %new%', 'wp-security-audit-log' ), 'woocommerce-store', 'modified' ),
463
- array( 9087, WSAL_HIGH, __( 'User modified exclusive selling location(s)', 'wp-security-audit-log' ), __( 'Changed the list of countries to sell to %LineBreak% Old setting: %old% %LineBreak% New Setting: %new%', 'wp-security-audit-log' ), 'woocommerce-store', 'modified' ),
464
- array( 9088, WSAL_HIGH, __( 'User modified shipping location(s)', 'wp-security-audit-log' ), __( 'The setting Shipping location(s) %LineBreak% Old setting: %old% %LineBreak% New Setting: %new%', 'wp-security-audit-log' ), 'woocommerce-store', 'modified' ),
465
- array( 9089, WSAL_HIGH, __( 'User modified exclusive shipping location(s)', 'wp-security-audit-log' ), __( 'Changed the list of specific countries to ship to %LineBreak% Old setting: %old% %LineBreak% New Setting: %new%', 'wp-security-audit-log' ), 'woocommerce-store', 'modified' ),
466
- array( 9090, WSAL_HIGH, __( 'User modified default customer location', 'wp-security-audit-log' ), __( 'The setting Default customer location %LineBreak% Old setting: %old% %LineBreak% New Setting: %new%', 'wp-security-audit-log' ), 'woocommerce-store', 'modified' ),
467
- array( 9091, WSAL_HIGH, __( 'User modified the cart page', 'wp-security-audit-log' ), __( 'Changed the Cart Page %LineBreak% Old page: %old% %LineBreak% New page: %new%', 'wp-security-audit-log' ), 'woocommerce-store', 'modified' ),
468
- array( 9092, WSAL_HIGH, __( 'User modified the checkout page', 'wp-security-audit-log' ), __( 'Changed the Checkout page %LineBreak% Old page: %old% %LineBreak% New page: %new%', 'wp-security-audit-log' ), 'woocommerce-store', 'modified' ),
469
- array( 9093, WSAL_HIGH, __( 'User modified the my account page', 'wp-security-audit-log' ), __( 'Changed the My Account Page %LineBreak% Old page: %old% %LineBreak% New page: %new%', 'wp-security-audit-log' ), 'woocommerce-store', 'modified' ),
470
- array( 9094, WSAL_HIGH, __( 'User modified the terms and conditions page', 'wp-security-audit-log' ), __( 'Changed the Terms and Conditions Page %LineBreak% Old page: %old% %LineBreak% New page: %new%', 'wp-security-audit-log' ), 'woocommerce-store', 'modified' ),
471
- ),
472
-
473
- __( 'Payment Gateways', 'wp-security-audit-log' ) => array(
474
- array( 9074, WSAL_HIGH, __( 'User enabled/disabled a payment gateway', 'wp-security-audit-log' ), __( 'The payment gateway %GatewayName%', 'wp-security-audit-log' ), 'woocommerce-store', 'enabled' ),
475
- array( 9075, E_CRITICAL, __( 'User disabled a payment gateway', 'wp-security-audit-log' ), __( 'Disabled the payment gateway %GatewayName%', 'wp-security-audit-log' ), 'woocommerce-store' ),
476
- array( 9076, WSAL_HIGH, __( 'User modified a payment gateway', 'wp-security-audit-log' ), __( 'The payment gateway %GatewayName%', 'wp-security-audit-log' ), 'woocommerce-store', 'modified' ),
477
- ),
478
-
479
- __( 'Tax Settings', 'wp-security-audit-log' ) => array(
480
- array( 9078, WSAL_LOW, __( 'User modified prices with tax option', 'wp-security-audit-log' ), __( 'Set the option that prices are %TaxStatus% of tax', 'wp-security-audit-log' ), 'woocommerce-store', 'modified' ),
481
- array( 9079, WSAL_LOW, __( 'User modified tax calculation base', 'wp-security-audit-log' ), __( 'Set the setting Calculate tax based on to %Setting%', 'wp-security-audit-log' ), 'woocommerce-store', 'modified' ),
482
- array( 9080, WSAL_MEDIUM, __( 'User modified shipping tax class', 'wp-security-audit-log' ), __( 'Set the Shipping tax class to %Setting%', 'wp-security-audit-log' ), 'woocommerce-store', 'modified' ),
483
- array( 9081, WSAL_MEDIUM, __( 'User enabled/disabled rounding of tax', 'wp-security-audit-log' ), __( 'Rounding of tax at subtotal level', 'wp-security-audit-log' ), 'woocommerce-store', 'enabled' ),
484
- array( 9082, WSAL_MEDIUM, __( 'User modified a shipping zone', 'wp-security-audit-log' ), __( 'The shipping zone %ShippingZoneName%', 'wp-security-audit-log' ), 'woocommerce-store', 'created' ),
485
- ),
486
-
487
- __( 'WC Categories', 'wp-security-audit-log' ) => array(
488
- array( 9002, WSAL_INFORMATIONAL, __( 'User created a new product category', 'wp-security-audit-log' ), __( 'A new product category called %CategoryName% %LineBreak% Category slug is %Slug% %LineBreak% %ProductCatLink%', 'wp-security-audit-log' ), 'woocommerce-category', 'created' ),
489
- array( 9052, WSAL_MEDIUM, __( 'User deleted a product category', 'wp-security-audit-log' ), __( 'The product category called %CategoryName% %LineBreak% Category slug: %CategorySlug%', 'wp-security-audit-log' ), 'woocommerce-category', 'deleted' ),
490
- array( 9053, WSAL_INFORMATIONAL, __( 'User changed the slug of a product category', 'wp-security-audit-log' ), __( 'Changed the slug of the product category called %CategoryName% %LineBreak% Previous category slug: %OldSlug% %LineBreak% New category slug: %NewSlug% %LineBreak% %ProductCatLink%', 'wp-security-audit-log' ), 'woocommerce-category', 'modified' ),
491
- array( 9054, WSAL_MEDIUM, __( 'User changed the parent category of a product category', 'wp-security-audit-log' ), __( 'Changed the parent of the product category %CategoryName% %LineBreak% Category slug: %CategorySlug% %LineBreak% Previous parent: %OldParentCat% %LineBreak% New parent: %NewParentCat% %LineBreak% %ProductCatLink%', 'wp-security-audit-log' ), 'woocommerce-category', 'modified' ),
492
- array( 9055, WSAL_INFORMATIONAL, __( 'User changed the display type of a product category', 'wp-security-audit-log' ), __( 'Changed the display type of the product category %CategoryName% %LineBreak% %CategorySlug% %LineBreak% Previous display type: %OldDisplayType% %LineBreak% New display type: %NewDisplayType% %LineBreak% %ProductCatLink%', 'wp-security-audit-log' ), 'woocommerce-category', 'modified' ),
493
- array( 9056, WSAL_LOW, __( 'User changed the name of a product category', 'wp-security-audit-log' ), __( 'Previous name: %OldName% %LineBreak% New name: %NewName% %LineBreak% Category slug: %CategorySlug% %LineBreak% %ProductCatLink%', 'wp-security-audit-log' ), 'woocommerce-category', 'renamed' ),
494
- ),
495
-
496
- __( 'Attributes', 'wp-security-audit-log' ) => array(
497
- array( 9057, WSAL_MEDIUM, __( 'User created a new attribute', 'wp-security-audit-log' ), __( 'A new attribute in WooCommerce called %AttributeName% %LineBreak% Attribute slug: %AttributeSlug%', 'wp-security-audit-log' ), 'woocommerce-store', 'created' ),
498
- array( 9058, WSAL_LOW, __( 'User deleted an attribute', 'wp-security-audit-log' ), __( 'The WooCommerce attribute called %AttributeName% %LineBreak% Attribute slug: %AttributeSlug%', 'wp-security-audit-log' ), 'woocommerce-store', 'deleted' ),
499
- array( 9059, WSAL_LOW, __( 'User changed the slug of an attribute', 'wp-security-audit-log' ), __( 'Changed the slug of the WooCommerce attribute %AttributeName% %LineBreak% Previous slug: %OldSlug% %LineBreak% New slug: %NewSlug%', 'wp-security-audit-log' ), 'woocommerce-store', 'modified' ),
500
- array( 9060, WSAL_LOW, __( 'User changed the name of an attribute', 'wp-security-audit-log' ), __( 'Changed the name of the WooCommerce attribute %AttributeName% %LineBreak% Attribute slug: %AttributeSlug% %LineBreak% Previous name: %OldName% %LineBreak% New name: %NewName%', 'wp-security-audit-log' ), 'woocommerce-store', 'modified' ),
501
- array( 9061, WSAL_LOW, __( 'User changed the default sort order of an attribute', 'wp-security-audit-log' ), __( 'Changed the Default Sort Order of the attribute %AttributeName% in WooCommerce %LineBreak% Attribute slug: %AttributeSlug% %LineBreak% Previous sorting order: %OldSortOrder% %LineBreak% New sorting order: %NewSortOrder%', 'wp-security-audit-log' ), 'woocommerce-store', 'modified' ),
502
- array( 9062, WSAL_LOW, __( 'User enabled/disabled the option Enable Archives of an attribute', 'wp-security-audit-log' ), __( 'The option Enable Archives in WooCommerce attribute %AttributeName%', 'wp-security-audit-log' ), 'woocommerce-store', 'enabled' ),
503
- ),
504
-
505
- __( 'Coupons', 'wp-security-audit-log' ) => array(
506
- array( 9063, WSAL_LOW, __( 'User published a new coupon', 'wp-security-audit-log' ), __( 'Published a new coupon called %CouponName% %LineBreak% %EditorLinkCoupon%', 'wp-security-audit-log' ), 'woocommerce-coupon', 'published' ),
507
- array( 9064, WSAL_LOW, __( 'User changed the discount type of a coupon', 'wp-security-audit-log' ), __( 'Changed the Discount Type in coupon %CouponName% %LineBreak% Previous discount type: %OldDiscountType% %LineBreak% New discount type: %NewDiscountType% %LineBreak% %EditorLinkCoupon%', 'wp-security-audit-log' ), 'woocommerce-store', 'modified' ),
508
- array( 9065, WSAL_LOW, __( 'User changed the coupon amount of a coupon', 'wp-security-audit-log' ), __( 'Changed the Coupon amount in coupon %CouponName% %LineBreak% Previous amount: %OldAmount% %LineBreak% New amount: %NewAmount% %LineBreak% %EditorLinkCoupon%', 'wp-security-audit-log' ), 'woocommerce-store', 'modified' ),
509
- array( 9066, WSAL_LOW, __( 'User changed the coupon expire date of a coupon', 'wp-security-audit-log' ), __( 'Changed the expire date of the coupon %CouponName% %LineBreak% Previous date: %OldDate% %LineBreak% New date: %NewDate% %LineBreak% %EditorLinkCoupon%', 'wp-security-audit-log' ), 'woocommerce-store', 'modified' ),
510
- array( 9067, WSAL_LOW, __( 'User changed the usage restriction settings of a coupon', 'wp-security-audit-log' ), __( 'Changed the Usage Restriction of the coupon %CouponName% %LineBreak% Previous usage restriction: %OldMetaValue% %LineBreak% New usage restriction: %NewMetaValue% %LineBreak% %EditorLinkCoupon%', 'wp-security-audit-log' ), 'woocommerce-store', 'modified' ),
511
- array( 9068, WSAL_LOW, __( 'User changed the usage limits settings of a coupon', 'wp-security-audit-log' ), __( 'Changed the Usage Limits of the coupon %CouponName% %LineBreak% Previous usage limits: %OldMetaValue% %LineBreak% New usage limits: %NewMetaValue% %LineBreak% %EditorLinkCoupon%', 'wp-security-audit-log' ), 'woocommerce-store', 'modified' ),
512
- array( 9069, WSAL_INFORMATIONAL, __( 'User changed the description of a coupon', 'wp-security-audit-log' ), __( 'Changed the description of the coupon %CouponName% %LineBreak% Previous description: %OldDescription% %LineBreak% New description: %NewDescription% %LineBreak% %EditorLinkCoupon%', 'wp-security-audit-log' ), 'woocommerce-coupon', 'modified' ),
513
- array( 9070, E_WARNING, __( 'User changed the status of a coupon', 'wp-security-audit-log' ), __( 'Changed the Status of the WooCommerce coupon %CouponName% from %OldStatus% to %NewStatus%.', 'wp-security-audit-log' ), 'woocommerce-coupon', 'modified' ),
514
- array( 9071, WSAL_INFORMATIONAL, __( 'User renamed a WooCommerce coupon', 'wp-security-audit-log' ), __( 'Old coupon name: %OldName% %LineBreak% New coupon name: %NewName% %LineBreak% %EditorLinkCoupon%', 'wp-security-audit-log' ), 'woocommerce-coupon', 'renamed' ),
515
- ),
516
-
517
- __( 'Orders', 'wp-security-audit-log' ) => array(
518
- array( 9035, WSAL_LOW, __( 'A WooCommerce order has been placed', 'wp-security-audit-log' ), __( 'A new order has been placed %LineBreak% Order name: %OrderTitle% %LineBreak% %EditorLinkOrder%', 'wp-security-audit-log' ), 'woocommerce-store', 'created' ),
519
- array( 9036, WSAL_INFORMATIONAL, __( 'WooCommerce order status changed', 'wp-security-audit-log' ), __( 'Marked an order %OrderTitle% as %OrderStatus% %LineBreak% %EditorLinkOrder%', 'wp-security-audit-log' ), 'woocommerce-store', 'modified' ),
520
- array( 9037, WSAL_MEDIUM, __( 'User moved a WooCommerce order to trash', 'wp-security-audit-log' ), __( 'Moved the order %OrderTitle% to trash', 'wp-security-audit-log' ), 'woocommerce-store', 'deleted' ),
521
- array( 9038, WSAL_LOW, __( 'User moved a WooCommerce order out of trash', 'wp-security-audit-log' ), __( 'Restored the order %OrderTitle% from the trash %LineBreak% %EditorLinkOrder%', 'wp-security-audit-log' ), 'woocommerce-store', 'restored' ),
522
- array( 9039, WSAL_LOW, __( 'User permanently deleted a WooCommerce order', 'wp-security-audit-log' ), __( 'Permanently deleted the order %OrderTitle%', 'wp-security-audit-log' ), 'woocommerce-store', 'deleted' ),
523
- array( 9040, WSAL_MEDIUM, __( 'User edited a WooCommerce order', 'wp-security-audit-log' ), __( 'Edited the details in order %OrderTitle% %LineBreak% %EditorLinkOrder%', 'wp-security-audit-log' ), 'woocommerce-store', 'modified' ),
524
- array( 9041, WSAL_HIGH, __( 'User refunded a WooCommerce order', 'wp-security-audit-log' ), __( 'Refunded the order %OrderTitle% %LineBreak% %EditorLinkOrder%', 'wp-security-audit-log' ), 'woocommerce-store', 'modified' ),
525
- ),
526
-
527
- __( 'User Profile', 'wp-security-audit-log' ) => array(
528
- array( 9083, WSAL_INFORMATIONAL, __( 'User changed the billing address details', 'wp-security-audit-log' ), __( 'Changed the billing address details of the user %TargetUsername% %LineBreak% Role: %Roles% %LineBreak% New Billing address: %NewValue% %LineBreak% %EditUserLink%', 'wp-security-audit-log' ), 'user', 'modified' ),
529
- array( 9084, WSAL_INFORMATIONAL, __( 'User changed the shipping address details', 'wp-security-audit-log' ), __( 'Changed the shipping address details of the user %TargetUsername% %LineBreak% Role: %Roles% %LineBreak% New Shipping address: %NewValue% %LineBreak% %EditUserLink%', 'wp-security-audit-log' ), 'user', 'modified' ),
530
- ),
531
- ),
532
-
533
  __( 'Yoast SEO', 'wp-security-audit-log' ) => array(
534
  __( 'Post Changes', 'wp-security-audit-log' ) => array(
535
  array( 8801, WSAL_INFORMATIONAL, __( 'User changed title of a SEO post', 'wp-security-audit-log' ), __( 'Changed the Meta title of the post %PostTitle% %LineBreak% ID: %PostID% %LineBreak% Type: %PostType% %LineBreak% Status: %PostStatus% %LineBreak% Previous title: %OldSEOTitle% %LineBreak% New title: %NewSEOTitle% %LineBreak% %EditorLinkPost%', 'wp-security-audit-log' ), 'yoast-seo-metabox', 'modified' ),
21
  defined( 'E_CRITICAL' ) || define( 'E_CRITICAL', 'E_CRITICAL' );
22
 
23
  /**
24
+ * Load Custom Alerts from {plugin working folder}/custom-alerts.php if exists
25
  *
26
  * @param WpSecurityAuditLog $wsal - Instance of main plugin.
27
  */
28
  function load_include_custom_file( $wsal ) {
29
  // Custom alerts can be added via a special file inside the file and dir
30
+ // {plugin working folder}/custom-alerts.php.
31
+ $uploads_dir_path = $wsal->settings()->get_working_dir_path( '', true, true );
 
32
 
33
  /*
34
  * Get an array of directories to loop through to add custom alerts.
87
  __( 'User Activity', 'wp-security-audit-log' ) => array(
88
  array( 1000, WSAL_LOW, __( 'User logged in', 'wp-security-audit-log' ), '', 'user', 'login' ),
89
  array( 1001, WSAL_LOW, __( 'User logged out', 'wp-security-audit-log' ), '', 'user', 'logout' ),
90
+ array( 1002, WSAL_MEDIUM, __( 'Login failed', 'wp-security-audit-log' ), '%Attempts% failed login(s)', 'user', 'failed-login' ),
91
  array( 1003, WSAL_LOW, __( 'Login failed / non existing user', 'wp-security-audit-log' ), __( '%Attempts% failed login(s) %LineBreak% %LogFileText%', 'wp-security-audit-log' ), 'system', 'failed-login' ),
92
  array( 1004, WSAL_MEDIUM, __( 'Login blocked', 'wp-security-audit-log' ), __( 'Login blocked because other session(s) already exist for this user. %LineBreak% IP address: %ClientIP%', 'wp-security-audit-log' ), 'user', 'blocked' ),
93
+ array( 1005, WSAL_LOW, __( 'User logged in with existing session(s)', 'wp-security-audit-log' ), __( 'User logged in. There are other session(s) using the same username logged in from these IP address(es): %IPAddress%', 'wp-security-audit-log' ), 'user', 'login' ),
94
  array( 1006, WSAL_MEDIUM, __( 'User logged out all other sessions with the same username', 'wp-security-audit-log' ), __( 'Logged out all other sessions with the same user.', 'wp-security-audit-log' ), 'user', 'logout' ),
95
  array( 1007, WSAL_MEDIUM, __( 'User session destroyed and logged out', 'wp-security-audit-log' ), __( 'Terminated the session of another user. %LineBreak% User: %TargetUserName% %LineBreak% Session ID: %TargetSessionID%', 'wp-security-audit-log' ), 'user', 'logout' ),
96
  array( 1008, WSAL_MEDIUM, __( 'Switched to another user', 'wp-security-audit-log' ), __( 'Switched to another user. %LineBreak% User: %TargetUserName% %LineBreak% Role: %TargetUserRole%', 'wp-security-audit-log' ), 'user', 'login' ),
153
  array( 2062, WSAL_LOW, __( 'User updated a custom field name for a post', 'wp-security-audit-log' ), __( 'Old custom field name: %MetaKeyOld% %LineBreak% New custom field name: %MetaKeyNew% %LineBreak% Post: %PostTitle% %LineBreak% Post ID: %PostID% %LineBreak% Post Type: %PostType% %LineBreak% Post Status: %PostStatus% %PostUrlIfPlublished% %LineBreak% %EditorLinkPost%', 'wp-security-audit-log' ), 'custom-field', 'renamed' ),
154
  ),
155
 
156
+ __( 'Custom Fields (ACF)', 'wp-security-audit-log' ) => array(
157
+ array( 2131,
158
+ WSAL_LOW,
159
+ __( 'User added relationship to a custom field value for a post', 'mwp-al-ext' ),
160
+ __( 'Modified the value of the custom field %MetaKey% in the post %PostTitle% %LineBreak% Post ID: %PostID% %LineBreak% Post Type: %PostType% %LineBreak% Post Status: %PostStatus% %LineBreak% Added the following relationships: %Relationships% %LineBreak% %LineBreak% %EditorLinkPost% %LineBreak% %MetaLink%.', 'mwp-al-ext' ),
161
+ 'custom-field',
162
+ 'modified'
163
+ ),
164
+ array( 2132,
165
+ WSAL_LOW,
166
+ __( 'User removed relationship from a custom field value for a post', 'mwp-al-ext' ),
167
+ __( 'Modified the value of the custom field %MetaKey% in the post %PostTitle% %LineBreak% Post ID: %PostID% %LineBreak% Post Type: %PostType% %LineBreak% Post Status: %PostStatus% %LineBreak% Removed the following relationships: %Relationships% %LineBreak% %LineBreak% %EditorLinkPost% %LineBreak% %MetaLink%.', 'mwp-al-ext' ),
168
+ 'custom-field',
169
+ 'modified'
170
+ ),
171
+ ),
172
+
173
  /**
174
  * Alerts: Comments
175
  */
185
  array( 2098, WSAL_LOW, __( 'User permanently deleted a comment', 'wp-security-audit-log' ), __( 'Permanently deleted the comment posted by %Author% on the post %PostTitle% %LineBreak% Post ID: %PostID% %LineBreak% Post Type: %PostType% %LineBreak% Post Status: %PostStatus% %PostUrlIfPlublished% %LineBreak% Comment ID: %CommentID%', 'wp-security-audit-log' ), 'comment', 'deleted' ),
186
  array( 2099, WSAL_INFORMATIONAL, __( 'User posted a comment', 'wp-security-audit-log' ), __( 'Posted a comment on the post %PostTitle% %LineBreak% Post ID: %PostID% %LineBreak% Post Type: %PostType% %LineBreak% Post Status: %PostStatus% %LineBreak% Comment ID: %CommentID% %PostUrlIfPlublished% %LineBreak% %CommentLink%', 'wp-security-audit-log' ), 'comment', 'created' ),
187
  /**
188
+ * IMPORTANT: This alert is deprecated but should not be
189
+ * removed from the definitions for backwards compatibility.
190
  */
191
  array( 2126, WSAL_INFORMATIONAL, __( 'Visitor posted a comment', 'wp-security-audit-log' ), __( 'Posted a comment on the post %PostTitle% %LineBreak% Post ID: %PostID% %LineBreak% Post Type: %PostType% %LineBreak% Post Status: %PostStatus% %LineBreak% Comment ID: %CommentID% %PostUrlIfPlublished% %LineBreak% %CommentLink%', 'wp-security-audit-log' ), 'comment', 'created' ),
192
  ),
221
  * Alerts: Custom Post Types
222
  *
223
  * IMPORTANT: These alerts should not be removed from here
224
+ * for backwards compatibility.
225
  *
226
  * @deprecated 3.1.0
227
  */
261
  * Alerts: Pages
262
  *
263
  * IMPORTANT: These alerts should not be removed from here
264
+ * for backwards compatibility.
265
  *
266
  * @deprecated 3.1.0
267
  */
316
  array( 4017, WSAL_INFORMATIONAL, __( 'User changed first name for a user', 'wp-security-audit-log' ), __( 'Changed the first name of the user %TargetUsername% %LineBreak% Previous name: %old_firstname% %LineBreak% New name: %new_firstname% %LineBreak% Role: %Roles% %LineBreak% Last name: %LastName% %LineBreak% %EditUserLink%', 'wp-security-audit-log' ), 'user', 'modified' ),
317
  array( 4018, WSAL_INFORMATIONAL, __( 'User changed last name for a user', 'wp-security-audit-log' ), __( 'Changed the last name of the user %TargetUsername% %LineBreak% Previous last name: %old_lastname% %LineBreak% New last name: %new_lastname% %LineBreak% Role: %Roles% %LineBreak% First name: %FirstName% %LineBreak% %EditUserLink%', 'wp-security-audit-log' ), 'user', 'modified' ),
318
  array( 4019, WSAL_INFORMATIONAL, __( 'User changed nickname for a user', 'wp-security-audit-log' ), __( 'Changed the nickname of the user %TargetUsername% %LineBreak% Previous nickname: %old_nickname% New nickname: %new_nickname% %LineBreak% Role: %Roles% %LineBreak% First name: %FirstName% %LineBreak% Last name: %LastName% %LineBreak% %EditUserLink%', 'wp-security-audit-log' ), 'user', 'modified' ),
319
+ array( 4020, WSAL_LOW, __( 'User changed the display name for a user', 'wp-security-audit-log' ), __( 'Changed the display name of the user %TargetUsername% %LineBreak% Previous display name: %old_displayname% %LineBreak% New display name: %new_displayname% %LineBreak% Role: %Roles% %LineBreak% First name: %FirstName% %LineBreak% Last name: %LastName% %LineBreak% %EditUserLink%', 'wp-security-audit-log' ), 'user', 'modified' ),
320
  ),
321
 
322
  __( 'Multisite User Profiles', 'wp-security-audit-log' ) => array(
335
  array( 5002, WSAL_HIGH, __( 'User deactivated a WordPress plugin', 'wp-security-audit-log' ), __( 'Name: %PluginData->Name% %LineBreak% Install location: %PluginFile%', 'wp-security-audit-log' ), 'plugin', 'deactivated' ),
336
  array( 5003, WSAL_HIGH, __( 'User uninstalled a plugin', 'wp-security-audit-log' ), __( 'Name: %PluginData->Name% %LineBreak% Install location: %PluginFile%', 'wp-security-audit-log' ), 'plugin', 'uninstalled' ),
337
  array( 5004, WSAL_LOW, __( 'User upgraded a plugin', 'wp-security-audit-log' ), __( 'Name: %PluginData->Name% %LineBreak% Install location: %PluginFile%', 'wp-security-audit-log' ), 'plugin', 'updated' ),
338
+ array( 5010, WSAL_LOW, __( 'Plugin created tables', 'wp-security-audit-log' ), __( 'Plugin created this table in the database %LineBreak% Plugin: %Plugin->Name% %LineBreak% Tables: %TableNames%', 'wp-security-audit-log' ), 'database', 'created' ),
339
+ array( 5011, WSAL_LOW, __( 'Plugin modified tables structure', 'wp-security-audit-log' ), __( 'Plugin modified the structure of this table %LineBreak% Plugin: %Plugin->Name% %LineBreak% Tables: %TableNames%', 'wp-security-audit-log' ), 'database', 'modified' ),
340
+ array( 5012, WSAL_MEDIUM, __( 'Plugin deleted tables', 'wp-security-audit-log' ), __( 'Plugin deleted this table from the database %LineBreak% Plugin: %Plugin->Name% %LineBreak% Tables: %TableNames%', 'wp-security-audit-log' ), 'database', 'deleted' ),
341
  array( 5019, WSAL_MEDIUM, __( 'A plugin created a post', 'wp-security-audit-log' ), __( 'Plugin %PluginName% created the post %PostTitle% %LineBreak% Post ID: %PostID% %LineBreak% Type: %PostType% %LineBreak% Status: %PostStatus% %LineBreak% %EditorLinkPage%', 'wp-security-audit-log' ), 'post', 'created' ),
342
  array( 5025, WSAL_LOW, __( 'A plugin deleted a post', 'wp-security-audit-log' ), __( 'Plugin %PluginName% deleted the post %PostTitle% %LineBreak% Post ID: %PostID% %LineBreak% Type: %PostType%', 'wp-security-audit-log' ), 'post', 'deleted' ),
343
  array( 2051, WSAL_HIGH, __( 'User changed a file using the plugin editor', 'wp-security-audit-log' ), __( 'Modified a file with the plugin editor %LineBreak% File: %File%', 'wp-security-audit-log' ), 'file', 'modified' ),
363
  array( 5016, WSAL_HIGH, __( 'Unknown component created tables', 'wp-security-audit-log' ), __( 'An unknown component created these tables in the database %LineBreak% Tables: %TableNames%', 'wp-security-audit-log' ), 'database', 'created' ),
364
  array( 5017, WSAL_HIGH, __( 'Unknown component modified tables structure', 'wp-security-audit-log' ), __( 'An unknown component modified the structure of these database tables %LineBreak% Tables: %TableNames%', 'wp-security-audit-log' ), 'database', 'modified' ),
365
  array( 5018, WSAL_HIGH, __( 'Unknown component deleted tables', 'wp-security-audit-log' ), __( 'An unknown component deleted these tables from the database %LineBreak% Tables: %TableNames%', 'wp-security-audit-log' ), 'database', 'deleted' ),
366
+ array( 5022, WSAL_HIGH, __( 'WordPress created tables', 'wp-security-audit-log' ), __( 'WordPress created these tables in the database %LineBreak% Tables: %TableNames%', 'wp-security-audit-log' ), 'database', 'created' ),
367
+ array( 5023, WSAL_HIGH, __( 'WordPress modified tables structure', 'wp-security-audit-log' ), __( 'WordPress modified the structure of these database tables %LineBreak% Tables: %TableNames%', 'wp-security-audit-log' ), 'database', 'modified' ),
368
+ array( 5024, WSAL_HIGH, __( 'WordPress deleted tables', 'wp-security-audit-log' ), __( 'WordPress deleted these tables from the database %LineBreak% Tables: %TableNames%', 'wp-security-audit-log' ), 'database', 'deleted' ),
369
  ),
370
  ),
371
 
424
  ),
425
  ),
426
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
427
  __( 'Yoast SEO', 'wp-security-audit-log' ) => array(
428
  __( 'Post Changes', 'wp-security-audit-log' ) => array(
429
  array( 8801, WSAL_INFORMATIONAL, __( 'User changed title of a SEO post', 'wp-security-audit-log' ), __( 'Changed the Meta title of the post %PostTitle% %LineBreak% ID: %PostID% %LineBreak% Type: %PostType% %LineBreak% Status: %PostStatus% %LineBreak% Previous title: %OldSEOTitle% %LineBreak% New title: %NewSEOTitle% %LineBreak% %EditorLinkPost%', 'wp-security-audit-log' ), 'yoast-seo-metabox', 'modified' ),
img/addons/woocommerce.png ADDED
Binary file
img/mails/daily-notification/alert-icon.png ADDED
Binary file
img/mails/daily-notification/logo.png CHANGED
Binary file
js/auditlog-pointer.js CHANGED
@@ -7,7 +7,6 @@ jQuery(document).ready( function($) {
7
  wsal_open_pointer(0);
8
  function wsal_open_pointer(i) {
9
  pointer = wsalPointer.pointers[i];
10
- console.log( pointer );
11
  options = $.extend( pointer.options, {
12
  close: function() {
13
  $.post( ajaxurl, {
@@ -17,6 +16,6 @@ jQuery(document).ready( function($) {
17
  }
18
  });
19
 
20
- $(pointer.target).pointer( options ).pointer('open');
21
  }
22
  });
7
  wsal_open_pointer(0);
8
  function wsal_open_pointer(i) {
9
  pointer = wsalPointer.pointers[i];
 
10
  options = $.extend( pointer.options, {
11
  close: function() {
12
  $.post( ajaxurl, {
16
  }
17
  });
18
 
19
+ $(pointer.target).first().pointer( options ).pointer('open');
20
  }
21
  });
js/settings.js CHANGED
@@ -112,340 +112,6 @@ jQuery( document ).ready( function() {
112
  setting.prop( 'disabled', 'disabled' );
113
  }
114
 
115
- // Enable/disable file changes.
116
- var file_changes = jQuery( 'input[name=wsal-file-changes]' );
117
-
118
- // File change settings.
119
- var file_changes_settings = [
120
- jQuery( '#wsal-file-alert-types' ),
121
- jQuery( '#wsal-scan-frequency' ),
122
- jQuery( '#wsal-scan-directories' ),
123
- jQuery( '#wsal-scan-exclude-extensions' ),
124
- jQuery( '#wsal-scan-time fieldset' ),
125
- jQuery( '#wsal_add_file_name' ),
126
- jQuery( '#wsal_add_file' ),
127
- jQuery( '#wsal_remove_exception_file' ),
128
- jQuery( '#wsal_add_file_type_name' ),
129
- jQuery( '#wsal_add_file_type' ),
130
- jQuery( '#wsal_remove_exception_file_type' ),
131
- jQuery( '#wsal_add_dir_name' ),
132
- jQuery( '#wsal_add_dir' ),
133
- jQuery( '#wsal_remove_exception_dir' ),
134
- jQuery( '#wsal_files input[type=checkbox]' ),
135
- jQuery( '#wsal_files_types input[type=checkbox]' ),
136
- jQuery( '#wsal_dirs input[type=checkbox]' ),
137
- jQuery( '#wsal-scan-now' )
138
- ];
139
-
140
- // Update settings of file changes on page load.
141
- if ( file_changes.prop( 'checked' ) ) {
142
- file_changes_settings.forEach( wsal_enable_setting ); // Enable the settings.
143
- } else {
144
- file_changes_settings.forEach( wsal_disable_setting ); // Disable the settings.
145
- }
146
-
147
- // Update settings when file changes is enabled or disabled.
148
- file_changes.on( 'change', function() {
149
- if ( file_changes.prop( 'checked' ) ) {
150
- file_changes_settings.forEach( wsal_enable_setting ); // Enable the settings.
151
- } else {
152
- file_changes_settings.forEach( wsal_disable_setting ); // Disable the settings.
153
- }
154
- });
155
-
156
- // Scan frequency.
157
- var scan_frequency = jQuery( 'select[name=wsal-scan-frequency]' ); // Frequency.
158
- var scan_days = jQuery( 'span#wsal-scan-day' ); // Day of the week.
159
- var scan_date = jQuery( 'span#wsal-scan-date' ); // Date of the month.
160
- wsal_update_scan_time( scan_frequency, scan_days, scan_date ); // Update on page load.
161
-
162
- // Update when frequency is changed.
163
- scan_frequency.change( function() {
164
- wsal_update_scan_time( scan_frequency, scan_days, scan_date );
165
- });
166
-
167
- /**
168
- * Updates the display of days and date option based on
169
- * selected frequency.
170
- *
171
- * @param {object} frequency Frequency selector.
172
- * @param {object} days Days selector.
173
- * @param {object} date Date selector.
174
- */
175
- function wsal_update_scan_time( frequency, days, date ) {
176
- if ( 'weekly' === frequency.val() ) {
177
- date.addClass( 'hide' );
178
- days.removeClass( 'hide' );
179
- } else if ( 'monthly' === frequency.val() ) {
180
- days.addClass( 'hide' );
181
- date.removeClass( 'hide' );
182
- } else {
183
- date.addClass( 'hide' );
184
- days.addClass( 'hide' );
185
- }
186
- }
187
-
188
- // Add directory to scan file exception list.
189
- jQuery( '#wsal_add_dir' ).click( function() {
190
- wsal_add_scan_exception( 'dir' );
191
- });
192
-
193
- // Add file to scan file exception list.
194
- jQuery( '#wsal_add_file' ).click( function() {
195
- wsal_add_scan_exception( 'file' );
196
- });
197
-
198
- // Add file extension to scan extension exception list.
199
- jQuery( '#wsal_add_file_type' ).click( function() {
200
- wsal_add_scan_exception( 'extension' );
201
- });
202
-
203
- /**
204
- * Add exception for file changes scan.
205
- *
206
- * @param {string} type Type of exception added. For example, a `file` or an `extension`.
207
- */
208
- function wsal_add_scan_exception( type ) {
209
- if ( 'file' === type ) {
210
- var setting_input = jQuery( '#wsal_add_file_name' );
211
- var setting_value = setting_input.val();
212
- var setting_container = jQuery( '#wsal_files' );
213
- var setting_nonce = jQuery( '#wsal_scan_exception_file' ).val();
214
- var setting_error = jQuery( '#wsal_file_name_error' );
215
-
216
- // Validate file name.
217
- var pattern = /^\s*[a-z-._\d,\s]+\s*$/i;
218
- } else if ( 'extension' === type ) {
219
- var setting_input = jQuery( '#wsal_add_file_type_name' );
220
- var setting_value = setting_input.val();
221
- var setting_container = jQuery( '#wsal_files_types' );
222
- var setting_nonce = jQuery( '#wsal_scan_exception_file_type' ).val();
223
- var setting_error = jQuery( '#wsal_file_type_error' );
224
-
225
- // Validate file name.
226
- var pattern = /^\s*[a-z-._\d,\s]+\s*$/i;
227
- } else if ( 'dir' === type ) {
228
- var setting_input = jQuery( '#wsal_add_dir_name' );
229
- var setting_value = setting_input.val();
230
- var setting_container = jQuery( '#wsal_dirs' );
231
- var setting_nonce = jQuery( '#wsal_scan_exception_dir' ).val();
232
- var setting_error = jQuery( '#wsal_dir_error' );
233
-
234
- // Validate file name.
235
- var pattern = /^\s*[a-z-._\d,\s/]+\s*$/i;
236
- }
237
- setting_error.addClass( 'hide' );
238
-
239
- if ( setting_value.match( pattern ) ) {
240
-
241
- // Ajax request to add file to scan file exception list.
242
- jQuery.ajax({
243
- type: 'POST',
244
- url: ajaxurl,
245
- async: true,
246
- dataType: 'json',
247
- data: {
248
- action: 'wsal_scan_add_exception',
249
- nonce: setting_nonce,
250
- data_name: setting_value,
251
- data_type: type
252
- },
253
- success: function( data ) {
254
- if ( data.success ) {
255
- var file = jQuery( '<span></span>' );
256
- var file_input = jQuery( '<input />' );
257
- file_input.prop( 'type', 'checkbox' );
258
- file_input.prop( 'id', setting_value );
259
- file_input.prop( 'value', setting_value );
260
-
261
- var file_label = jQuery( '<label></label>' );
262
- file_label.prop( 'for', setting_value );
263
- file_label.text( setting_value );
264
-
265
- file.append( file_input );
266
- file.append( file_label );
267
-
268
- setting_container.append( file );
269
- setting_input.removeAttr( 'value' );
270
- } else {
271
- console.log( data.message );
272
- setting_error.text( data.message );
273
- setting_error.removeClass( 'hide' );
274
- }
275
- },
276
- error: function( xhr, textStatus, error ) {
277
- console.log( xhr.statusText );
278
- console.log( textStatus );
279
- console.log( error );
280
- }
281
- });
282
- } else {
283
- if ( 'file' === type ) {
284
- alert( wsal_data.invalidFile );
285
- } else if ( 'extension' === type ) {
286
- alert( wsal_data.invalidFileExt );
287
- } else if ( 'dir' === type ) {
288
- alert( wsal_data.invalidDir );
289
- }
290
- }
291
- }
292
-
293
- // Remove directories from scan file exception list.
294
- jQuery( '#wsal_remove_exception_dir' ).click( function() {
295
- wsal_remove_scan_exception( 'dir' );
296
- });
297
-
298
- // Remove files from scan file exception list.
299
- jQuery( '#wsal_remove_exception_file' ).click( function() {
300
- wsal_remove_scan_exception( 'file' );
301
- });
302
-
303
- // Remove file extensions from scan file extensions exception list.
304
- jQuery( '#wsal_remove_exception_file_type' ).click( function() {
305
- wsal_remove_scan_exception( 'extension' );
306
- });
307
-
308
- /**
309
- * Remove exception for changes scan.
310
- *
311
- * @param {string} type Type of exception removed. For example, a `file` or an `extension`.
312
- */
313
- function wsal_remove_scan_exception( type ) {
314
- if ( 'file' === type ) {
315
- var setting_values = jQuery( '#wsal_files input[type=checkbox]' ); // Get files.
316
- var setting_nonce = jQuery( '#wsal_scan_remove_exception_file' ).val(); // Nonce.
317
- } else if ( 'extension' === type ) {
318
- var setting_values = jQuery( '#wsal_files_types input[type=checkbox]' ); // Get files.
319
- var setting_nonce = jQuery( '#wsal_scan_remove_exception_file_type' ).val(); // Nonce.
320
- } else if ( 'dir' === type ) {
321
- var setting_values = jQuery( '#wsal_dirs input[type=checkbox]' ); // Get files.
322
- var setting_nonce = jQuery( '#wsal_scan_remove_exception_dir' ).val(); // Nonce.
323
- }
324
-
325
- // Make array of files which are checked.
326
- var removed_values = [];
327
- for ( var index = 0; index < setting_values.length; index++ ) {
328
- if ( jQuery( setting_values[ index ]).is( ':checked' ) ) {
329
- removed_values.push( jQuery( setting_values[ index ]).val() );
330
- }
331
- }
332
-
333
- // Ajax request to remove array of files from file exception list.
334
- jQuery.ajax({
335
- type: 'POST',
336
- url: ajaxurl,
337
- async: true,
338
- dataType: 'json',
339
- data: {
340
- action: 'wsal_scan_remove_exception',
341
- nonce: setting_nonce,
342
- data_type: type,
343
- data_removed: removed_values
344
- },
345
- success: function( data ) {
346
- if ( data.success ) {
347
-
348
- // Remove files from list on the page.
349
- for ( index = 0; index < removed_values.length; index++ ) {
350
- var setting_value = jQuery( 'input[value="' + removed_values[ index ] + '"]' );
351
- if ( setting_value ) {
352
- setting_value.parent().remove();
353
- }
354
- }
355
- } else {
356
- console.log( data.message );
357
- }
358
- },
359
- error: function( xhr, textStatus, error ) {
360
- console.log( xhr.statusText );
361
- console.log( textStatus );
362
- console.log( error );
363
- }
364
- });
365
- }
366
-
367
- // Scan now start button.
368
- jQuery( '#wsal-scan-now' ).click( function( event ) {
369
- event.preventDefault();
370
-
371
- // Change button text.
372
- var scan_btn = jQuery( this );
373
- scan_btn.attr( 'disabled', 'disabled' );
374
- scan_btn.val( wsal_data.scanInProgress );
375
-
376
- // Stop scan button.
377
- var stop_scan_btn = jQuery( '#wsal-stop-scan' );
378
- stop_scan_btn.removeAttr( 'disabled' );
379
-
380
-
381
- // Get start scan nonce.
382
- var manual_scan_nonce = jQuery( '#wsal-scan-now-nonce' ).val();
383
-
384
- // Ajax request to remove array of files from file exception list.
385
- jQuery.ajax({
386
- type: 'POST',
387
- url: ajaxurl,
388
- async: true,
389
- dataType: 'json',
390
- data: {
391
- action: 'wsal_manual_scan_now',
392
- nonce: manual_scan_nonce
393
- },
394
- success: function( data ) {
395
- if ( data.success ) {
396
-
397
- // Change button text.
398
- scan_btn.val( wsal_data.scanNow );
399
- scan_btn.removeAttr( 'disabled' );
400
- stop_scan_btn.attr( 'disabled', 'disabled' );
401
- } else {
402
- scan_btn.val( wsal_data.scanFailed );
403
- console.log( data.message );
404
- }
405
- },
406
- error: function( xhr, textStatus, error ) {
407
- console.log( xhr.statusText );
408
- console.log( textStatus );
409
- console.log( error );
410
- }
411
- });
412
- });
413
-
414
- // Stop scan start button.
415
- jQuery( '#wsal-stop-scan' ).click( function( event ) {
416
- event.preventDefault();
417
-
418
- // Change button attributes.
419
- var stop_scan_btn = jQuery( this );
420
- stop_scan_btn.attr( 'disabled', 'disabled' );
421
-
422
- // Ajax request to remove array of files from file exception list.
423
- jQuery.ajax({
424
- type: 'POST',
425
- url: ajaxurl,
426
- async: true,
427
- dataType: 'json',
428
- data: {
429
- action: 'wsal_stop_file_changes_scan',
430
- nonce: jQuery( '#wsal-stop-scan-nonce' ).val()
431
- },
432
- success: function( data ) {
433
- if ( data.success ) {
434
-
435
- // Change button text.
436
- // stop_scan_btn.removeAttr( 'disabled' );
437
- } else {
438
- console.log( data.message );
439
- }
440
- },
441
- error: function( xhr, textStatus, error ) {
442
- console.log( xhr.statusText );
443
- console.log( textStatus );
444
- console.log( error );
445
- }
446
- });
447
- });
448
-
449
  // Reset settings handler.
450
  var resetSettings = jQuery( '[data-remodal-id=wsal_reset_settings] button[data-remodal-action=confirm]' );
451
  resetSettings.click( function() {
@@ -483,4 +149,48 @@ jQuery( document ).ready( function() {
483
  }
484
  });
485
  }
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
486
  });
112
  setting.prop( 'disabled', 'disabled' );
113
  }
114
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
115
  // Reset settings handler.
116
  var resetSettings = jQuery( '[data-remodal-id=wsal_reset_settings] button[data-remodal-action=confirm]' );
117
  resetSettings.click( function() {
149
  }
150
  });
151
  }
152
+
153
+ if ( 0 < jQuery( 'input[name="restrict-log-viewer"][value="only_me"]' ).length ) {
154
+ jQuery( 'input[name="restrict-plugin-settings"]' ).on( 'change', function() {
155
+ if ( 'only_me' == this.value ) {
156
+
157
+ // re-enable "Only me" option in the log viewer access settings
158
+ jQuery( 'input[name="restrict-log-viewer"][value="only_me"]' ).removeAttr( 'disabled' );
159
+ if ( 'yes' == jQuery( 'input[name="restrict-log-viewer"][value="only_me"]' ).attr( 'data-revert-to-only-me' ) ) {
160
+ jQuery( 'input[name="restrict-log-viewer"][value="only_me"]' ).attr( 'checked', 'checked' );
161
+ jQuery( 'input[name="restrict-log-viewer"][value="only_me"]' ).removeAttr( 'data-revert-to-only-me' );
162
+ }
163
+ } else {
164
+
165
+ // disable "Only me" option in the log viewer access settings and change the selection to
166
+ // "Super administators and site administrators" if "Only me" was selected
167
+ jQuery( 'input[name="restrict-log-viewer"][value="only_me"]' ).attr( 'disabled', 'disabled' );
168
+ if ( 'only_me' == jQuery( 'input[name="restrict-log-viewer"]:checked' ).val() ) {
169
+ jQuery( 'input[name="restrict-log-viewer"][value="only_admins"]' ).attr( 'checked', 'checked' );
170
+ jQuery( 'input[name="restrict-log-viewer"][value="only_me"]' ).attr( 'data-revert-to-only-me', 'yes' );
171
+ }
172
+ }
173
+ });
174
+ }
175
+
176
+ jQuery('input[name="mwp_stealth_mode"]').on('change', function () {
177
+ var admin_blocking_support_input = jQuery('input[name="mwp_admin_blocking_support"]');
178
+ if ('yes' == this.value) {
179
+
180
+ // re-enable the admin blocking support checkbox
181
+ admin_blocking_support_input.removeAttr('disabled');
182
+ if ('yes' == admin_blocking_support_input.attr('data-check-on-revert')) {
183
+ admin_blocking_support_input.attr('checked', 'checked')
184
+ .removeAttr('data-check-on-revert');
185
+ }
186
+ } else {
187
+
188
+ // disable the admin blocking support checkbox and uncheck it as well
189
+ admin_blocking_support_input.attr('disabled', 'disabled');
190
+ if (admin_blocking_support_input.attr('checked')) {
191
+ admin_blocking_support_input.removeAttr('checked', 'checked')
192
+ .attr('data-check-on-revert', 'yes')
193
+ }
194
+ }
195
+ });
196
  });
languages/wp-security-audit-log.pot CHANGED
@@ -3,301 +3,287 @@ msgid ""
3
  msgstr ""
4
  "Plural-Forms: nplurals=INTEGER; plural=EXPRESSION;\n"
5
  "Project-Id-Version: WP Activity Log\n"
6
- "POT-Creation-Date: 2020-06-24 13:40+0100\n"
7
- "PO-Revision-Date: 2020-06-24 13:40+0100\n"
8
  "Last-Translator: \n"
9
  "Language-Team: \n"
10
  "MIME-Version: 1.0\n"
11
  "Content-Type: text/plain; charset=UTF-8\n"
12
  "Content-Transfer-Encoding: 8bit\n"
13
- "X-Generator: Poedit 1.8.13\n"
14
  "X-Poedit-Basepath: ..\n"
 
15
  "X-Poedit-WPHeader: wp-security-audit-log.php\n"
16
  "X-Poedit-SourceCharset: UTF-8\n"
17
  "X-Poedit-KeywordsList: __;_e;_n:1,2;_x:1,2c;_ex:1,2c;_nx:4c,1,2;esc_attr__;"
18
  "esc_attr_e;esc_attr_x:1,2c;esc_html__;esc_html_e;esc_html_x:1,2c;_n_noop:1,2;"
19
  "_nx_noop:3c,1,2;__ngettext_noop:1,2\n"
20
  "X-Poedit-SearchPath-0: .\n"
21
- "X-Poedit-SearchPathExcluded-0: *.js\n"
22
 
23
- #: classes/AlertManager.php:365
 
24
  #, php-format
25
  msgid "Event with code %d has not be registered."
26
  msgstr ""
27
 
28
- #: classes/AlertManager.php:421
29
  #, php-format
30
  msgid "Event %s already registered with WP Activity Log."
31
  msgstr ""
32
 
33
- #: classes/AlertManager.php:494
34
  msgid ""
35
  "You have custom events that are using the same ID or IDs which are already "
36
  "registered in the plugin, so they have been disabled."
37
  msgstr ""
38
 
39
- #: classes/AlertManager.php:497
40
  #, php-format
41
  msgid "%4$s to help you solve this issue."
42
  msgstr ""
43
 
44
- #: classes/AlertManager.php:499
45
  msgid "ERROR:"
46
  msgstr ""
47
 
48
- #: classes/AlertManager.php:501
49
  msgid "Contact us"
50
  msgstr ""
51
 
52
- #: classes/AlertManager.php:1107 classes/AuditLogListView.php:333
53
- #: classes/AuditLogListView.php:367 classes/Views/Settings.php:1150
54
  #: classes/WidgetManager.php:76
55
  msgid "User"
56
  msgstr ""
57
 
58
- #: classes/AlertManager.php:1108 classes/AlertManager.php:1898
59
  #: classes/AuditLogGridView.php:517 classes/AuditLogListView.php:543
60
- #: defaults.php:354
61
  msgid "System"
62
  msgstr ""
63
 
64
- #: classes/AlertManager.php:1109 classes/AuditLogGridView.php:508
65
  #: classes/AuditLogListView.php:531
66
  msgid "Plugin"
67
  msgstr ""
68
 
69
- #: classes/AlertManager.php:1110
70
  msgid "Database"
71
  msgstr ""
72
 
73
- #: classes/AlertManager.php:1111
74
  msgid "Post"
75
  msgstr ""
76
 
77
- #: classes/AlertManager.php:1112 classes/AlertManager.php:1116
78
  msgid "File"
79
  msgstr ""
80
 
81
- #: classes/AlertManager.php:1113
82
  msgid "Tag"
83
  msgstr ""
84
 
85
- #: classes/AlertManager.php:1114
86
  msgid "Comment"
87
  msgstr ""
88
 
89
- #: classes/AlertManager.php:1115
90
  msgid "Setting"
91
  msgstr ""
92
 
93
- #: classes/AlertManager.php:1117
94
  msgid "System Setting"
95
  msgstr ""
96
 
97
- #: classes/AlertManager.php:1118
98
- msgid "WooCommerce Product"
99
- msgstr ""
100
-
101
- #: classes/AlertManager.php:1119
102
- msgid "WooCommerce Store"
103
- msgstr ""
104
-
105
- #: classes/AlertManager.php:1120
106
- msgid "WooCommerce Coupon"
107
- msgstr ""
108
-
109
- #: classes/AlertManager.php:1121
110
- msgid "WooCommerce Category"
111
- msgstr ""
112
-
113
- #: classes/AlertManager.php:1122
114
  msgid "MainWP Network"
115
  msgstr ""
116
 
117
- #: classes/AlertManager.php:1123
118
  msgid "MainWP"
119
  msgstr ""
120
 
121
- #: classes/AlertManager.php:1124 classes/Views/ToggleAlerts.php:222
122
- #: classes/Views/ToggleAlerts.php:352 defaults.php:533
123
  msgid "Yoast SEO"
124
  msgstr ""
125
 
126
- #: classes/AlertManager.php:1125
127
  msgid "Yoast SEO Meta Box"
128
  msgstr ""
129
 
130
- #: classes/AlertManager.php:1126
131
  msgid "Category"
132
  msgstr ""
133
 
134
- #: classes/AlertManager.php:1127
135
  msgid "Custom Field"
136
  msgstr ""
137
 
138
- #: classes/AlertManager.php:1128
139
  msgid "Widget"
140
  msgstr ""
141
 
142
- #: classes/AlertManager.php:1129
143
  msgid "Menu"
144
  msgstr ""
145
 
146
- #: classes/AlertManager.php:1130
147
  msgid "Theme"
148
  msgstr ""
149
 
150
- #: classes/AlertManager.php:1131
151
  msgid "Activity Logs"
152
  msgstr ""
153
 
154
- #: classes/AlertManager.php:1132
155
  msgid "Multisite Network"
156
  msgstr ""
157
 
158
- #: classes/AlertManager.php:1133
159
  msgid "IP Address"
160
  msgstr ""
161
 
162
- #: classes/AlertManager.php:1149
163
  msgid "unknown object"
164
  msgstr ""
165
 
166
- #: classes/AlertManager.php:1186
167
  msgid "Login"
168
  msgstr ""
169
 
170
- #: classes/AlertManager.php:1187
171
  msgid "Logout"
172
  msgstr ""
173
 
174
- #: classes/AlertManager.php:1188
175
  msgid "Installed"
176
  msgstr ""
177
 
178
- #: classes/AlertManager.php:1189
179
  msgid "Activated"
180
  msgstr ""
181
 
182
- #: classes/AlertManager.php:1190
183
  msgid "Deactivated"
184
  msgstr ""
185
 
186
- #: classes/AlertManager.php:1191
187
  msgid "Uninstalled"
188
  msgstr ""
189
 
190
- #: classes/AlertManager.php:1192
191
  msgid "Updated"
192
  msgstr ""
193
 
194
- #: classes/AlertManager.php:1193
195
  msgid "Created"
196
  msgstr ""
197
 
198
- #: classes/AlertManager.php:1194
199
  msgid "Modified"
200
  msgstr ""
201
 
202
- #: classes/AlertManager.php:1195
203
  msgid "Deleted"
204
  msgstr ""
205
 
206
- #: classes/AlertManager.php:1196
207
  msgid "Published"
208
  msgstr ""
209
 
210
- #: classes/AlertManager.php:1197
211
  msgid "Approved"
212
  msgstr ""
213
 
214
- #: classes/AlertManager.php:1198
215
  msgid "Unapproved"
216
  msgstr ""
217
 
218
- #: classes/AlertManager.php:1199
219
  msgid "Enabled"
220
  msgstr ""
221
 
222
- #: classes/AlertManager.php:1200
223
  msgid "Disabled"
224
  msgstr ""
225
 
226
- #: classes/AlertManager.php:1201
227
  msgid "Added"
228
  msgstr ""
229
 
230
- #: classes/AlertManager.php:1202
231
  msgid "Failed Login"
232
  msgstr ""
233
 
234
- #: classes/AlertManager.php:1203
235
  msgid "Blocked"
236
  msgstr ""
237
 
238
- #: classes/AlertManager.php:1204
239
  msgid "Uploaded"
240
  msgstr ""
241
 
242
- #: classes/AlertManager.php:1205
243
  msgid "Restored"
244
  msgstr ""
245
 
246
- #: classes/AlertManager.php:1206
247
  msgid "Opened"
248
  msgstr ""
249
 
250
- #: classes/AlertManager.php:1207
251
  msgid "Viewed"
252
  msgstr ""
253
 
254
- #: classes/AlertManager.php:1208
255
  msgid "Started"
256
  msgstr ""
257
 
258
- #: classes/AlertManager.php:1209
259
  msgid "Stopped"
260
  msgstr ""
261
 
262
- #: classes/AlertManager.php:1210
263
  msgid "Removed"
264
  msgstr ""
265
 
266
- #: classes/AlertManager.php:1211
267
  msgid "Unblocked"
268
  msgstr ""
269
 
270
- #: classes/AlertManager.php:1212
271
  msgid "Renamed"
272
  msgstr ""
273
 
274
- #: classes/AlertManager.php:1213
275
  msgid "Duplicated"
276
  msgstr ""
277
 
278
- #: classes/AlertManager.php:1230
279
  msgid "unknown type"
280
  msgstr ""
281
 
282
- #: classes/AlertManager.php:1475 classes/Views/ToggleAlerts.php:243
283
- #: classes/Views/ToggleAlerts.php:275 defaults.php:252
284
  msgid "Pages"
285
  msgstr ""
286
 
287
- #: classes/AlertManager.php:1475 classes/Views/ToggleAlerts.php:243
288
- #: classes/Views/ToggleAlerts.php:275 defaults.php:212
289
  msgid "Custom Post Types"
290
  msgstr ""
291
 
292
- #: classes/AlertManager.php:1797
293
  msgid "System Activity"
294
  msgstr ""
295
 
296
- #: classes/AlertManager.php:1857 classes/ConstantManager.php:146
297
  msgid "Unknown error code."
298
  msgstr ""
299
 
300
- #: classes/AlertManager.php:1864 classes/AlertManager.php:1876
301
  msgid "Unknown Site"
302
  msgstr ""
303
 
@@ -326,7 +312,7 @@ msgid "— End of Activity Log —"
326
  msgstr ""
327
 
328
  #: classes/AuditLogGridView.php:229 classes/AuditLogListView.php:235
329
- #: classes/Views/AuditLog.php:620
330
  msgid "All Sites"
331
  msgstr ""
332
 
@@ -345,7 +331,7 @@ msgstr ""
345
 
346
  #: classes/AuditLogGridView.php:315 classes/AuditLogGridView.php:341
347
  #: classes/AuditLogListView.php:331 classes/AuditLogListView.php:361
348
- #: classes/Views/Settings.php:1146 classes/Views/ToggleAlerts.php:326
349
  msgid "Severity"
350
  msgstr ""
351
 
@@ -386,7 +372,7 @@ msgid "Show me all activity by this User"
386
  msgstr ""
387
 
388
  #: classes/AuditLogGridView.php:511 classes/AuditLogListView.php:535
389
- #: defaults.php:316
390
  msgid "Plugins"
391
  msgstr ""
392
 
@@ -433,22 +419,23 @@ msgid "Alert Data Inspector"
433
  msgstr ""
434
 
435
  #: classes/AuditLogGridView.php:724 classes/AuditLogListView.php:724
436
- #: classes/Settings.php:1645
437
  msgid "Download the log file"
438
  msgstr ""
439
 
440
  #: classes/AuditLogGridView.php:744 classes/AuditLogListView.php:744
441
- #: classes/Settings.php:1687
442
  msgid "Download the log file."
443
  msgstr ""
444
 
445
  #: classes/AuditLogGridView.php:752 classes/AuditLogListView.php:752
446
- #: classes/Settings.php:1700 classes/Settings.php:1943
447
  msgid "published"
448
  msgstr ""
449
 
 
450
  #: classes/AuditLogGridView.php:780 classes/AuditLogListView.php:780
451
- #: classes/Settings.php:1726 classes/Settings.php:1969
452
  #, php-format
453
  msgid "Contact us on %s for assistance"
454
  msgstr ""
@@ -478,12 +465,10 @@ msgid "Click to toggle."
478
  msgstr ""
479
 
480
  #: classes/AuditLogListView.php:446 classes/Models/Occurrence.php:83
481
- #: classes/ViewManager.php:497
482
  msgid "Alert message not found."
483
  msgstr ""
484
 
485
  #: classes/AuditLogListView.php:447 classes/Models/Occurrence.php:84
486
- #: classes/ViewManager.php:498
487
  msgid "Alert description not found."
488
  msgstr ""
489
 
@@ -493,6 +478,7 @@ msgid ""
493
  "valid."
494
  msgstr ""
495
 
 
496
  #: classes/Connector/MySQLDB.php:69
497
  #, php-format
498
  msgid "Code %1$d: %2$s"
@@ -502,6 +488,7 @@ msgstr ""
502
  msgid "Error establishing a database connection"
503
  msgstr ""
504
 
 
505
  #: classes/Connector/wp-db-custom.php:216
506
  #, php-format
507
  msgid ""
@@ -522,6 +509,7 @@ msgstr ""
522
  msgid "Are you sure that the database server is running?"
523
  msgstr ""
524
 
 
525
  #: classes/Connector/wp-db-custom.php:229
526
  #, php-format
527
  msgid ""
@@ -538,6 +526,7 @@ msgstr ""
538
  msgid "Can&#8217;t select database"
539
  msgstr ""
540
 
 
541
  #: classes/Connector/wp-db-custom.php:287
542
  #, php-format
543
  msgid ""
@@ -549,11 +538,13 @@ msgstr ""
549
  msgid "Are you sure it exists?"
550
  msgstr ""
551
 
 
552
  #: classes/Connector/wp-db-custom.php:296
553
  #, php-format
554
  msgid "Does the user %1$s have permission to use the %2$s database?"
555
  msgstr ""
556
 
 
557
  #: classes/Connector/wp-db-custom.php:303
558
  #, php-format
559
  msgid ""
@@ -561,6 +552,7 @@ msgid ""
561
  "it would be like <code>username_%1$s</code>. Could that be the problem?"
562
  msgstr ""
563
 
 
564
  #: classes/Connector/wp-db-custom.php:311
565
  #, php-format
566
  msgid ""
@@ -574,32 +566,32 @@ msgid "https://wordpress.org/support/forums/"
574
  msgstr ""
575
 
576
  #: classes/ConstantManager.php:152 classes/ConstantManager.php:158
577
- #: classes/Views/ToggleAlerts.php:450 classes/Views/ToggleAlerts.php:456
578
  msgid "Critical"
579
  msgstr ""
580
 
581
- #: classes/ConstantManager.php:154 classes/Views/ToggleAlerts.php:452
582
  msgid "Warning"
583
  msgstr ""
584
 
585
- #: classes/ConstantManager.php:156 classes/Views/ToggleAlerts.php:454
586
- #: classes/Views/ToggleAlerts.php:466
587
  msgid "Notification"
588
  msgstr ""
589
 
590
- #: classes/ConstantManager.php:160 classes/Views/ToggleAlerts.php:458
591
  msgid "High"
592
  msgstr ""
593
 
594
- #: classes/ConstantManager.php:162 classes/Views/ToggleAlerts.php:460
595
  msgid "Medium"
596
  msgstr ""
597
 
598
- #: classes/ConstantManager.php:164 classes/Views/ToggleAlerts.php:462
599
  msgid "Low"
600
  msgstr ""
601
 
602
- #: classes/ConstantManager.php:166 classes/Views/ToggleAlerts.php:464
603
  msgid "Informational"
604
  msgstr ""
605
 
@@ -620,11 +612,15 @@ msgstr ""
620
  msgid "BBPress"
621
  msgstr ""
622
 
623
- #: classes/Models/Occurrence.php:208
 
 
 
 
624
  msgid "WFCM"
625
  msgstr ""
626
 
627
- #: classes/Models/Occurrence.php:230
628
  #, php-format
629
  msgid ""
630
  "Alert message was not available, this may have been a custom alert that no "
@@ -632,127 +628,111 @@ msgid ""
632
  msgstr ""
633
 
634
  #: classes/Sensors/Content.php:996 classes/Sensors/Content.php:1004
635
- #: classes/Sensors/WooCommerce.php:606 classes/Sensors/WooCommerce.php:614
636
  msgid "Password Protected"
637
  msgstr ""
638
 
639
  #: classes/Sensors/Content.php:998 classes/Sensors/Content.php:1006
640
- #: classes/Sensors/WooCommerce.php:610 classes/Sensors/WooCommerce.php:618
641
  msgid "Private"
642
  msgstr ""
643
 
644
  #: classes/Sensors/Content.php:1000 classes/Sensors/Content.php:1008
645
- #: classes/Sensors/WooCommerce.php:608 classes/Sensors/WooCommerce.php:616
646
  msgid "Public"
647
  msgstr ""
648
 
649
- #: classes/Sensors/FrontendWooCommerce.php:209 classes/Sensors/Public.php:394
650
- #: classes/Sensors/WooCommerce.php:2172
651
  msgid "In stock"
652
  msgstr ""
653
 
654
- #: classes/Sensors/FrontendWooCommerce.php:211 classes/Sensors/Public.php:396
655
- #: classes/Sensors/WooCommerce.php:2174
656
  msgid "Out of stock"
657
  msgstr ""
658
 
659
- #: classes/Sensors/FrontendWooCommerce.php:213 classes/Sensors/Public.php:398
660
- #: classes/Sensors/WooCommerce.php:2176
661
  msgid "On backorder"
662
  msgstr ""
663
 
664
- #: classes/Sensors/WooCommerce.php:1805 classes/Sensors/WooCommerce.php:1839
665
- #: classes/Sensors/WooCommerce.php:1885
666
- msgid "None, "
667
- msgstr ""
668
-
669
- #: classes/Sensors/WooCommerce.php:1814 classes/Sensors/WooCommerce.php:1848
670
- #: classes/Sensors/WooCommerce.php:1894
671
- msgid "None"
672
- msgstr ""
673
-
674
- #: classes/Sensors/WooCommerce.php:3083
675
- msgid "Visible"
676
- msgstr ""
677
-
678
- #: classes/Sensors/WooCommerce.php:3083
679
- msgid "Non-Visible"
680
  msgstr ""
681
 
682
- #: classes/Settings.php:473
683
  msgid "This function is deprecated"
684
  msgstr ""
685
 
686
- #: classes/Settings.php:1602
687
  msgid "View the content changes"
688
  msgstr ""
689
 
690
- #: classes/Settings.php:1607 classes/Settings.php:1613
691
  msgid "View post in the editor"
692
  msgstr ""
693
 
694
- #: classes/Settings.php:1610
695
  msgid "View Order"
696
  msgstr ""
697
 
698
- #: classes/Settings.php:1618
699
  msgid "View category"
700
  msgstr ""
701
 
702
- #: classes/Settings.php:1621
703
  msgid "View tag"
704
  msgstr ""
705
 
706
- #: classes/Settings.php:1625
707
  msgid "User profile page"
708
  msgstr ""
709
 
710
- #: classes/Settings.php:1738
711
  msgid "Increase maximum file size limit"
712
  msgstr ""
713
 
714
- #: classes/Settings.php:1741
715
  msgid "Contact Support"
716
  msgstr ""
717
 
718
- #: classes/Settings.php:1981
719
  msgid "plugin settings"
720
  msgstr ""
721
 
722
- #: classes/Settings.php:1984
723
  msgid "contact our support"
724
  msgstr ""
725
 
726
- #: classes/Settings.php:2190
727
  msgid "Root directory of WordPress (excluding sub directories)"
728
  msgstr ""
729
 
730
- #: classes/Settings.php:2191
731
  msgid "WP Admin directory (/wp-admin/)"
732
  msgstr ""
733
 
734
- #: classes/Settings.php:2192
735
  msgid "WP Includes directory (/wp-includes/)"
736
  msgstr ""
737
 
738
- #: classes/Settings.php:2193
739
  msgid ""
740
  "/wp-content/ directory (excluding plugins, themes & uploads directories)"
741
  msgstr ""
742
 
743
- #: classes/Settings.php:2194
744
  msgid "Themes directory (/wp-content/themes/)"
745
  msgstr ""
746
 
747
- #: classes/Settings.php:2195
748
  msgid "Plugins directory (/wp-content/plugins/)"
749
  msgstr ""
750
 
751
- #: classes/Settings.php:2196
752
  msgid "Uploads directory (/wp-content/uploads/)"
753
  msgstr ""
754
 
755
- #: classes/Settings.php:2201
756
  msgid ""
757
  "Uploads directory of all sub sites on this network (/wp-content/sites/*)"
758
  msgstr ""
@@ -781,23 +761,23 @@ msgid ""
781
  msgstr ""
782
 
783
  #: classes/Utilities/PluginInstallAndActivate.php:100
784
- #: classes/Views/SetupWizard.php:870
785
  msgid "Extension for "
786
  msgstr ""
787
 
788
  #: classes/Utilities/PluginInstallAndActivate.php:105
789
- #: classes/Views/SetupWizard.php:875
790
  msgid "Extension installed, activate now?"
791
  msgstr ""
792
 
793
  #: classes/Utilities/PluginInstallAndActivate.php:107
794
- #: classes/Views/SetupWizard.php:274 classes/Views/SetupWizard.php:877
795
- #: wp-security-audit-log.php:1168
796
  msgid "Extension installed"
797
  msgstr ""
798
 
799
  #: classes/Utilities/PluginInstallAndActivate.php:109
800
- #: classes/Views/AuditLog.php:275 classes/Views/SetupWizard.php:879
801
  msgid "Install Extension"
802
  msgstr ""
803
 
@@ -805,35 +785,16 @@ msgstr ""
805
  msgid "Tried to install a zip or slug that was not in the allowed list"
806
  msgstr ""
807
 
808
- #: classes/ViewManager.php:155
809
  msgid ""
810
  "WP Activity Log requires Website File Changes Monitor 1.6.0. Please upgrade "
811
  "that plugin."
812
  msgstr ""
813
 
814
- #: classes/ViewManager.php:292
815
  msgid "Free Premium Trial"
816
  msgstr ""
817
 
818
- #: classes/ViewManager.php:523 classes/Views/Settings.php:226
819
- #: classes/Views/Settings.php:1992 classes/Views/Settings.php:2021
820
- #: classes/Views/SetupWizard.php:83
821
- msgid "Access Denied."
822
- msgstr ""
823
-
824
- #: classes/ViewManager.php:554
825
- msgid "Log count parameter expected."
826
- msgstr ""
827
-
828
- #: classes/ViewManager.php:562 classes/Views/AuditLog.php:808
829
- #: classes/Views/AuditLog.php:885 classes/Views/AuditLog.php:911
830
- #: classes/Views/AuditLog.php:1231 classes/Views/AuditLog.php:1301
831
- #: classes/Views/Settings.php:241 classes/Views/Settings.php:1904
832
- #: classes/Views/Settings.php:1932 classes/Views/Settings.php:1962
833
- #: classes/Views/SetupWizard.php:96
834
- msgid "Nonce verification failed."
835
- msgstr ""
836
-
837
  #: classes/Views/AuditLog.php:99
838
  msgid ""
839
  "Get instantly alerted of critical changes via SMS & email, search the "
@@ -916,115 +877,124 @@ msgstr ""
916
  msgid "No, thank you"
917
  msgstr ""
918
 
919
- #: classes/Views/AuditLog.php:278
920
  msgid "Install Extensions"
921
  msgstr ""
922
 
923
- #: classes/Views/AuditLog.php:290
924
  msgid "You have"
925
  msgstr ""
926
 
927
- #: classes/Views/AuditLog.php:292
928
  msgid "installed. Keep a log of changes in"
929
  msgstr ""
930
 
931
- #: classes/Views/AuditLog.php:352 classes/Views/Settings.php:92
932
  msgid "Activity Log Viewer"
933
  msgstr ""
934
 
935
- #: classes/Views/AuditLog.php:379
936
  msgid "Log Viewer"
937
  msgstr ""
938
 
939
- #: classes/Views/AuditLog.php:534 classes/Views/Settings.php:332
940
- #: classes/Views/ToggleAlerts.php:140
941
  msgid "You do not have sufficient permissions to access this page."
942
  msgstr ""
943
 
944
- #: classes/Views/AuditLog.php:582
945
  msgid ""
946
  "Thank you for installing WP Activity Log. Do you want to run the wizard to "
947
  "configure the basic plugin settings?"
948
  msgstr ""
949
 
950
- #: classes/Views/AuditLog.php:584 classes/Views/Settings.php:535
951
- #: classes/Views/Settings.php:562 classes/Views/Settings.php:628
952
- #: classes/Views/Settings.php:686 classes/Views/Settings.php:1181
953
- #: classes/Views/Settings.php:1607 classes/Views/Settings.php:1668
954
- #: classes/Views/Settings.php:1696 classes/Views/Settings.php:1717
955
- #: classes/Views/Settings.php:1727 classes/Views/SetupWizard.php:565
956
- #: classes/Views/SetupWizard.php:613
957
  msgid "Yes"
958
  msgstr ""
959
 
960
- #: classes/Views/AuditLog.php:585 classes/Views/Settings.php:540
961
- #: classes/Views/Settings.php:567 classes/Views/Settings.php:658
962
- #: classes/Views/Settings.php:696 classes/Views/Settings.php:1186
963
- #: classes/Views/Settings.php:1612 classes/Views/Settings.php:1675
964
- #: classes/Views/Settings.php:1703 classes/Views/Settings.php:1718
965
- #: classes/Views/Settings.php:1728 classes/Views/SetupWizard.php:570
966
- #: classes/Views/SetupWizard.php:618
967
  msgid "No"
968
  msgstr ""
969
 
970
- #: classes/Views/AuditLog.php:619
971
  msgid "Please enter the number of alerts you would like to see on one page:"
972
  msgstr ""
973
 
974
- #: classes/Views/AuditLog.php:621
975
  msgid "No Results"
976
  msgstr ""
977
 
978
- #: classes/Views/AuditLog.php:805
979
  msgid "No users found."
980
  msgstr ""
981
 
982
- #: classes/Views/AuditLog.php:827
 
 
 
 
 
 
 
 
983
  msgid "Log file does not exist."
984
  msgstr ""
985
 
986
- #: classes/Views/AuditLog.php:876
987
  msgid "Request to get log file failed."
988
  msgstr ""
989
 
990
- #: classes/Views/AuditLog.php:951
991
  msgid "Freemius opt choice selected."
992
  msgstr ""
993
 
994
- #: classes/Views/AuditLog.php:958
995
  msgid "Freemius opt choice not found."
996
  msgstr ""
997
 
998
- #: classes/Views/AuditLog.php:1046
 
999
  #, php-format
1000
  msgid ""
1001
- "<br>An error occured when trying to install and activate the plugin. Please "
1002
  "try install it again from the %1$sevent settings%2$s page."
1003
  msgstr ""
1004
 
1005
- #: classes/Views/AuditLog.php:1145
1006
  msgid "WordPress Activity Log"
1007
  msgstr ""
1008
 
1009
- #: classes/Views/AuditLog.php:1146
1010
  msgid ""
1011
  "When a user makes a change on your website the plugin will keep a record of "
1012
  "that event here. Right now there is nothing because this is a new install."
1013
  msgstr ""
1014
 
1015
- #: classes/Views/AuditLog.php:1147
1016
  msgid "Thank you for using WP Activity Log"
1017
  msgstr ""
1018
 
1019
- #: classes/Views/AuditLog.php:1168
1020
  msgid "Error: You do not have sufficient permissions to exclude this URL."
1021
  msgstr ""
1022
 
1023
- #: classes/Views/AuditLog.php:1214
1024
  msgid "You do not have sufficient permissions to dismiss this notice."
1025
  msgstr ""
1026
 
1027
- #: classes/Views/AuditLog.php:1284
1028
  msgid "Access Denied"
1029
  msgstr ""
1030
 
@@ -1112,7 +1082,7 @@ msgid "DB & Integrations &#8682;"
1112
  msgstr ""
1113
 
1114
  #: classes/Views/ExternalDB.php:114
1115
- msgid "Audit Log Database & Integration Tools"
1116
  msgstr ""
1117
 
1118
  #: classes/Views/ExternalDB.php:115
@@ -1217,7 +1187,7 @@ msgstr ""
1217
  msgid ""
1218
  "Refer to the list of WordPress security events for a complete list of Events "
1219
  "and IDs that the plugin uses to keep a log of all the changes in the "
1220
- "WordPress audit log."
1221
  msgstr ""
1222
 
1223
  #: classes/Views/Help.php:198
@@ -1452,8 +1422,8 @@ msgstr ""
1452
  msgid "General"
1453
  msgstr ""
1454
 
1455
- #: classes/Views/Settings.php:99 classes/Views/ToggleAlerts.php:330
1456
- #: classes/Views/ToggleAlerts.php:442 defaults.php:574
1457
  msgid "File Changes"
1458
  msgstr ""
1459
 
@@ -1462,54 +1432,55 @@ msgid "Exclude Objects"
1462
  msgstr ""
1463
 
1464
  #: classes/Views/Settings.php:112
1465
- msgid "Import/Export"
1466
- msgstr ""
1467
-
1468
- #: classes/Views/Settings.php:119
1469
  msgid "Advanced Settings"
1470
  msgstr ""
1471
 
1472
- #: classes/Views/Settings.php:167 classes/Views/Settings.php:181
1473
  msgid "Settings"
1474
  msgstr ""
1475
 
1476
- #: classes/Views/Settings.php:208
1477
  msgid "Current user is not allowed to save settings."
1478
  msgstr ""
1479
 
1480
- #: classes/Views/Settings.php:214
1481
  msgid "Unknown settings tab."
1482
  msgstr ""
1483
 
1484
- #: classes/Views/Settings.php:251 classes/Views/SetupWizard.php:106
 
 
 
 
 
1485
  msgid "Invalid input."
1486
  msgstr ""
1487
 
1488
- #: classes/Views/Settings.php:344
1489
  msgid "Message sent successfully."
1490
  msgstr ""
1491
 
1492
- #: classes/Views/Settings.php:348 classes/Views/ToggleAlerts.php:157
1493
  msgid "Settings have been saved."
1494
  msgstr ""
1495
 
1496
- #: classes/Views/Settings.php:354 classes/Views/ToggleAlerts.php:163
1497
  msgid "Error: "
1498
  msgstr ""
1499
 
1500
- #: classes/Views/Settings.php:366
1501
  msgid "Old data successfully purged."
1502
  msgstr ""
1503
 
1504
- #: classes/Views/Settings.php:372
1505
  msgid "No data is old enough to be purged."
1506
  msgstr ""
1507
 
1508
- #: classes/Views/Settings.php:403
1509
  msgid "Send Message"
1510
  msgstr ""
1511
 
1512
- #: classes/Views/Settings.php:454
1513
  msgid ""
1514
  "Need help with setting up the plugin to meet your requirements? <a href="
1515
  "\"https://wpactivitylog.com/contact/?"
@@ -1518,161 +1489,165 @@ msgid ""
1518
  "call</a> with our experts for just $50."
1519
  msgstr ""
1520
 
1521
- #: classes/Views/Settings.php:456
1522
  msgid "Use infinite scroll or pagination for the event viewer?"
1523
  msgstr ""
1524
 
1525
- #: classes/Views/Settings.php:461
 
1526
  #, php-format
1527
  msgid ""
1528
  "When using infinite scroll the event viewer and search results %s load up "
1529
  "much faster and require less resources."
1530
  msgstr ""
1531
 
1532
- #: classes/Views/Settings.php:462
1533
  msgid "(Premium feature)"
1534
  msgstr ""
1535
 
1536
- #: classes/Views/Settings.php:469
1537
  msgid "Select event viewer view type:"
1538
  msgstr ""
1539
 
1540
- #: classes/Views/Settings.php:474
1541
  msgid "Infinite Scroll (Recommended)"
1542
  msgstr ""
1543
 
1544
- #: classes/Views/Settings.php:479
1545
  msgid "Pagination"
1546
  msgstr ""
1547
 
1548
- #: classes/Views/Settings.php:490
1549
  msgid "Do you want the activity log viewer to auto refresh?"
1550
  msgstr ""
1551
 
1552
- #: classes/Views/Settings.php:491
1553
  msgid ""
1554
  "The activity log viewer auto refreshes every 30 seconds when opened so you "
1555
  "can see the latest events as they happen almost in real time."
1556
  msgstr ""
1557
 
1558
- #: classes/Views/Settings.php:495
1559
- msgid "Refresh Audit Log Viewer"
1560
  msgstr ""
1561
 
1562
- #: classes/Views/Settings.php:501
1563
  msgid "Auto refresh"
1564
  msgstr ""
1565
 
1566
- #: classes/Views/Settings.php:506
1567
  msgid "Do not auto refresh"
1568
  msgstr ""
1569
 
1570
- #: classes/Views/Settings.php:516
1571
  msgid "Display latest events widget in Dashboard & Admin bar"
1572
  msgstr ""
1573
 
1574
- #: classes/Views/Settings.php:521
 
1575
  #, php-format
1576
  msgid ""
1577
  "The events widget displays the latest %d security events in the dashboard "
1578
  "and the admin bar notification displays the latest event."
1579
  msgstr ""
1580
 
1581
- #: classes/Views/Settings.php:529
1582
  msgid "Dashboard Widget"
1583
  msgstr ""
1584
 
1585
- #: classes/Views/Settings.php:550
1586
  msgid "Admin Bar Notification"
1587
  msgstr ""
1588
 
1589
- #: classes/Views/Settings.php:553
1590
  msgid "Admin Bar Notification (Premium)"
1591
  msgstr ""
1592
 
1593
- #: classes/Views/Settings.php:577
1594
  msgid "Admin Bar Notification Updates"
1595
  msgstr ""
1596
 
1597
- #: classes/Views/Settings.php:580
1598
  msgid "Admin Bar Notification Updates (Premium)"
1599
  msgstr ""
1600
 
1601
- #: classes/Views/Settings.php:589
1602
  msgid "Update in near real time"
1603
  msgstr ""
1604
 
1605
- #: classes/Views/Settings.php:594
1606
  msgid "Update only on page refreshes"
1607
  msgstr ""
1608
 
1609
- #: classes/Views/Settings.php:604
1610
  msgid "Add user notification on the WordPress login page"
1611
  msgstr ""
1612
 
1613
- #: classes/Views/Settings.php:605
1614
  msgid ""
1615
  "Many compliance regulations (such as the GDPR) require website "
1616
  "administrators to tell the users of their website that all the changes they "
1617
  "do when logged in are being logged."
1618
  msgstr ""
1619
 
1620
- #: classes/Views/Settings.php:609
1621
  msgid "Login Page Notification"
1622
  msgstr ""
1623
 
1624
- #: classes/Views/Settings.php:634
1625
  msgid ""
1626
  "For security and auditing purposes, a record of all of your logged-in "
1627
  "actions and changes within the WordPress dashboard will be recorded in an "
1628
- "audit log with the <a href=\"https://wpactivitylog.com/?"
1629
  "utm_source=plugin&utm_medium=referral&utm_campaign=WSAL&utm_content=settings"
1630
  "+pages\" target=\"_blank\">WP Activity Log plugin</a>. The audit log also "
1631
  "includes the IP address where you accessed this site from."
1632
  msgstr ""
1633
 
1634
- #: classes/Views/Settings.php:652
1635
  msgid "<strong>Note: </strong>"
1636
  msgstr ""
1637
 
1638
- #: classes/Views/Settings.php:652
1639
  msgid ""
1640
  "The only HTML code allowed in the login page notification is for links ( < a "
1641
  "href >< /a > )."
1642
  msgstr ""
1643
 
1644
- #: classes/Views/Settings.php:668
1645
  msgid "Is your website running behind a firewall or reverse proxy?"
1646
  msgstr ""
1647
 
1648
- #: classes/Views/Settings.php:673
 
1649
  #, php-format
1650
  msgid ""
1651
  "If your website is running behind a firewall set this option to yes so the "
1652
  "plugin retrieves the end user’s IP address from the proxy header - %s."
1653
  msgstr ""
1654
 
1655
- #: classes/Views/Settings.php:674 classes/Views/Settings.php:720
1656
- #: classes/Views/Settings.php:771
1657
  msgid "learn more"
1658
  msgstr ""
1659
 
1660
- #: classes/Views/Settings.php:681
1661
  msgid "Reverse Proxy / Firewall Options"
1662
  msgstr ""
1663
 
1664
- #: classes/Views/Settings.php:691
1665
  msgid ""
1666
  "Filter internal IP addresses from the proxy headers. Enable this option only "
1667
  "if you are\tare still seeing the internal IP addresses of the firewall or "
1668
  "proxy."
1669
  msgstr ""
1670
 
1671
- #: classes/Views/Settings.php:707
1672
  msgid "Who can change the plugin settings?"
1673
  msgstr ""
1674
 
1675
- #: classes/Views/Settings.php:719
 
1676
  #, php-format
1677
  msgid ""
1678
  "By default only users with administrator role (single site) and super "
@@ -1680,80 +1655,104 @@ msgid ""
1680
  "you can restrict the privileges to just your user - %s."
1681
  msgstr ""
1682
 
1683
- #: classes/Views/Settings.php:729
1684
- msgid "Restrict Plugin Access"
1685
  msgstr ""
1686
 
1687
- #: classes/Views/Settings.php:735
1688
  msgid "Only me"
1689
  msgstr ""
1690
 
1691
- #: classes/Views/Settings.php:742
1692
- msgid "Only superadmins"
1693
  msgstr ""
1694
 
1695
- #: classes/Views/Settings.php:744
1696
- msgid "Only administrators"
1697
  msgstr ""
1698
 
1699
- #: classes/Views/Settings.php:758
1700
  msgid "Allow other users to view the activity log"
1701
  msgstr ""
1702
 
1703
- #: classes/Views/Settings.php:770
1704
- #, php-format
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1705
  msgid ""
1706
- "By default only users with administrator and super administrator (multisite) "
1707
- "role can view the WordPress activity log. Though you can allow other users "
1708
- "with no admin role to view the events - %s."
1709
  msgstr ""
1710
 
1711
- #: classes/Views/Settings.php:780
1712
- msgid "Can View Events"
1713
  msgstr ""
1714
 
1715
- #: classes/Views/Settings.php:788
1716
  msgid ""
1717
  "Specify the username or the users which do not have an admin role but can "
1718
  "also see the WordPress activity role. You can also specify roles."
1719
  msgstr ""
1720
 
1721
- #: classes/Views/Settings.php:814
1722
  msgid "Which email address should the plugin use as a from address?"
1723
  msgstr ""
1724
 
1725
- #: classes/Views/Settings.php:815
1726
  msgid ""
1727
  "By default when the plugin sends an email notification it uses the email "
1728
  "address specified in this website’s general settings. Though you can change "
1729
  "the email address and display name from this section."
1730
  msgstr ""
1731
 
1732
- #: classes/Views/Settings.php:819
1733
  msgid "From Email & Name"
1734
  msgstr ""
1735
 
1736
- #: classes/Views/Settings.php:825
1737
  msgid "Use the email address from the WordPress general settings"
1738
  msgstr ""
1739
 
1740
- #: classes/Views/Settings.php:830
1741
  msgid "Use another email address"
1742
  msgstr ""
1743
 
1744
- #: classes/Views/Settings.php:834
1745
  msgid "Email Address"
1746
  msgstr ""
1747
 
1748
- #: classes/Views/Settings.php:839
1749
  msgid "Display Name"
1750
  msgstr ""
1751
 
1752
- #: classes/Views/Settings.php:850
1753
  msgid "Do you want to hide the plugin from the list of installed plugins?"
1754
  msgstr ""
1755
 
1756
- #: classes/Views/Settings.php:851
1757
  msgid ""
1758
  "By default all installed plugins are listed in the plugins page. If you do "
1759
  "not want other administrators to see that you installed this plugin set this "
@@ -1761,32 +1760,32 @@ msgid ""
1761
  "this website."
1762
  msgstr ""
1763
 
1764
- #: classes/Views/Settings.php:855
1765
  msgid "Hide Plugin in Plugins Page"
1766
  msgstr ""
1767
 
1768
- #: classes/Views/Settings.php:860
1769
  msgid "Yes, hide the plugin from the list of installed plugins"
1770
  msgstr ""
1771
 
1772
- #: classes/Views/Settings.php:865
1773
  msgid "No, do not hide the plugin"
1774
  msgstr ""
1775
 
1776
- #: classes/Views/Settings.php:935
1777
  msgid ""
1778
  "For how long do you want to keep the activity log events (Retention "
1779
  "settings) ?"
1780
  msgstr ""
1781
 
1782
- #: classes/Views/Settings.php:938
1783
  msgid ""
1784
  "The plugin uses an efficient way to store the activity log data in the "
1785
  "WordPress database, though the more data you keep the more disk space will "
1786
  "be required. "
1787
  msgstr ""
1788
 
1789
- #: classes/Views/Settings.php:939
1790
  msgid ""
1791
  "<a href=\"https://wpactivitylog.com/pricing/?"
1792
  "utm_source=plugin&utm_medium=referral&utm_campaign=WSAL&utm_content=settings"
@@ -1794,82 +1793,83 @@ msgid ""
1794
  "data in an external database."
1795
  msgstr ""
1796
 
1797
- #: classes/Views/Settings.php:957
 
1798
  #, php-format
1799
  msgid ""
1800
  "Retention settings moved to %1$s archiving settings %2$s because archiving "
1801
  "is enabled"
1802
  msgstr ""
1803
 
1804
- #: classes/Views/Settings.php:964
1805
- msgid "Audit Log Retention"
1806
  msgstr ""
1807
 
1808
- #: classes/Views/Settings.php:970
1809
  msgid "Keep all data"
1810
  msgstr ""
1811
 
1812
- #: classes/Views/Settings.php:997
1813
  msgid "Delete events older than"
1814
  msgstr ""
1815
 
1816
- #: classes/Views/Settings.php:1004
1817
  msgid "Months"
1818
  msgstr ""
1819
 
1820
- #: classes/Views/Settings.php:1005
1821
  msgid "Years"
1822
  msgstr ""
1823
 
1824
- #: classes/Views/Settings.php:1013
1825
  msgid "The next scheduled purging of activity log data that is older than "
1826
  msgstr ""
1827
 
1828
- #: classes/Views/Settings.php:1020
1829
  msgid "You can run the purging process now by clicking the button below."
1830
  msgstr ""
1831
 
1832
- #: classes/Views/Settings.php:1024
1833
  msgid "Purge Old Data"
1834
  msgstr ""
1835
 
1836
- #: classes/Views/Settings.php:1035
1837
  msgid "What timestamp you would like to see in the WordPress activity log?"
1838
  msgstr ""
1839
 
1840
- #: classes/Views/Settings.php:1036
1841
  msgid ""
1842
  "Note that the WordPress' timezone might be different from that configured on "
1843
  "the server so when you switch from UTC to WordPress timezone or vice versa "
1844
  "you might notice a big difference."
1845
  msgstr ""
1846
 
1847
- #: classes/Views/Settings.php:1040
1848
  msgid "Events Timestamp"
1849
  msgstr ""
1850
 
1851
- #: classes/Views/Settings.php:1060
1852
  msgid "UTC"
1853
  msgstr ""
1854
 
1855
- #: classes/Views/Settings.php:1066
1856
  msgid "Timezone configured on this WordPress website"
1857
  msgstr ""
1858
 
1859
- #: classes/Views/Settings.php:1073
1860
  msgid "Show Milliseconds"
1861
  msgstr ""
1862
 
1863
- #: classes/Views/Settings.php:1089
1864
  msgid "Show Milliseconds in list view"
1865
  msgstr ""
1866
 
1867
- #: classes/Views/Settings.php:1099
1868
  msgid ""
1869
  "What user information should be displayed in the WordPress activity log?"
1870
  msgstr ""
1871
 
1872
- #: classes/Views/Settings.php:1100
1873
  msgid ""
1874
  "Usernames might not be the same as a user's first and last name so it can be "
1875
  "difficult to recognize whose user was that did a change. When there is no "
@@ -1877,57 +1877,57 @@ msgid ""
1877
  "back to the WordPress username."
1878
  msgstr ""
1879
 
1880
- #: classes/Views/Settings.php:1104
1881
- msgid "User Information in Audit Log"
1882
  msgstr ""
1883
 
1884
- #: classes/Views/Settings.php:1110
1885
- msgid "WordPress Username"
1886
  msgstr ""
1887
 
1888
- #: classes/Views/Settings.php:1115
1889
- msgid "First Name & Last Name"
1890
  msgstr ""
1891
 
1892
- #: classes/Views/Settings.php:1120
1893
- msgid "Configured Public Display Name"
1894
  msgstr ""
1895
 
1896
- #: classes/Views/Settings.php:1130
1897
  msgid "Select the columns to be displayed in the WordPress activity log"
1898
  msgstr ""
1899
 
1900
- #: classes/Views/Settings.php:1131
1901
  msgid ""
1902
  "When you deselect a column it won’t be shown in the activity log viewer in "
1903
  "both views. The data will still be recorded by the plugin."
1904
  msgstr ""
1905
 
1906
- #: classes/Views/Settings.php:1135
1907
- msgid "Audit Log Columns Selection"
1908
  msgstr ""
1909
 
1910
- #: classes/Views/Settings.php:1144
1911
  msgid "Event ID"
1912
  msgstr ""
1913
 
1914
- #: classes/Views/Settings.php:1148
1915
  msgid "Date & Time"
1916
  msgstr ""
1917
 
1918
- #: classes/Views/Settings.php:1152
1919
  msgid "Source IP Address"
1920
  msgstr ""
1921
 
1922
- #: classes/Views/Settings.php:1154
1923
  msgid "Info (used in Grid view mode only)"
1924
  msgstr ""
1925
 
1926
- #: classes/Views/Settings.php:1169
1927
  msgid "Do you want to keep a log of WordPress background activity?"
1928
  msgstr ""
1929
 
1930
- #: classes/Views/Settings.php:1171
1931
  msgid ""
1932
  "WordPress does a lot of things in the background that you do not necessarily "
1933
  "need to know about, such as; deletion of post revisions, deletion of auto "
@@ -1935,37 +1935,37 @@ msgid ""
1935
  "might be a lot and are irrelevant to the user."
1936
  msgstr ""
1937
 
1938
- #: classes/Views/Settings.php:1176
1939
  msgid "Enable Events for WordPress Background Activity"
1940
  msgstr ""
1941
 
1942
- #: classes/Views/Settings.php:1235 classes/Views/ToggleAlerts.php:563
1943
  msgid "Website File Changes Monitor"
1944
  msgstr ""
1945
 
1946
- #: classes/Views/Settings.php:1236 classes/Views/ToggleAlerts.php:564
1947
  msgid ""
1948
  "To keep a log of file changes please install Website File Changes Monitor, a "
1949
  "plugin which is also developed by us."
1950
  msgstr ""
1951
 
1952
- #: classes/Views/Settings.php:1237 classes/Views/ToggleAlerts.php:565
1953
  msgid "Install plugin now"
1954
  msgstr ""
1955
 
1956
- #: classes/Views/Settings.php:1237 classes/Views/ToggleAlerts.php:565
1957
  msgid "Learn More"
1958
  msgstr ""
1959
 
1960
- #: classes/Views/Settings.php:1251
1961
  msgid "Configure how often file changes scan run and other settings from the"
1962
  msgstr ""
1963
 
1964
- #: classes/Views/Settings.php:1251
1965
  msgid "Website File Changes plugin settings"
1966
  msgstr ""
1967
 
1968
- #: classes/Views/Settings.php:1266
1969
  msgid ""
1970
  "By default the plugin keeps a log of all user changes done on your WordPress "
1971
  "website. Use the setting below to exclude any objects from the activity log. "
@@ -1973,200 +1973,167 @@ msgid ""
1973
  "object is referred will not be logged in the activity log."
1974
  msgstr ""
1975
 
1976
- #: classes/Views/Settings.php:1270
1977
  msgid "Exclude Users:"
1978
  msgstr ""
1979
 
1980
- #: classes/Views/Settings.php:1291
1981
  msgid "Exclude Roles:"
1982
  msgstr ""
1983
 
1984
- #: classes/Views/Settings.php:1312
1985
  msgid "Exclude IP Address(es):"
1986
  msgstr ""
1987
 
1988
- #: classes/Views/Settings.php:1328
1989
  msgid ""
1990
  "You can exclude an individual IP address or a range of IP addresses. To "
1991
  "exclude a range use the following format: [first IP]-[last octet of the last "
1992
  "IP]. Example: 172.16.180.6-127."
1993
  msgstr ""
1994
 
1995
- #: classes/Views/Settings.php:1334
1996
  msgid "Exclude Post Type:"
1997
  msgstr ""
1998
 
1999
- #: classes/Views/Settings.php:1350
2000
  msgid ""
2001
  "WordPress has the post and page post types by default though your website "
2002
  "might use more post types (custom post types). You can exclude all post "
2003
  "types, including the default WordPress ones."
2004
  msgstr ""
2005
 
2006
- #: classes/Views/Settings.php:1356
2007
  msgid "Exclude Custom Fields:"
2008
  msgstr ""
2009
 
2010
- #: classes/Views/Settings.php:1372
2011
  msgid ""
2012
  "You can use the * wildcard to exclude multiple matching custom fields. For "
2013
  "example to exclude all custom fields starting with wp123 enter wp123*"
2014
  msgstr ""
2015
 
2016
- #: classes/Views/Settings.php:1378
2017
  msgid "Exclude Non-Existing URLs:"
2018
  msgstr ""
2019
 
2020
- #: classes/Views/Settings.php:1394
2021
  msgid ""
2022
  "Add the non existing URLs for which you do not want to be alerted of HTTP "
2023
  "404 errors in the activity log by specifying the complete URL.\tExamples "
2024
  "below:"
2025
  msgstr ""
2026
 
2027
- #: classes/Views/Settings.php:1394
2028
  msgid "File: "
2029
  msgstr ""
2030
 
2031
- #: classes/Views/Settings.php:1394
2032
  msgid "Directory: "
2033
  msgstr ""
2034
 
2035
- #: classes/Views/Settings.php:1427
2036
- msgid ""
2037
- "You can export and import the plugin settings from here, which can also be "
2038
- "used as a plugin configuration backup. The plugin settings are exported to a "
2039
- "JSON file."
2040
- msgstr ""
2041
-
2042
- #: classes/Views/Settings.php:1428 classes/Views/Settings.php:1432
2043
- #: classes/Views/Settings.php:1455
2044
- msgid "Export Settings"
2045
- msgstr ""
2046
-
2047
- #: classes/Views/Settings.php:1462 classes/Views/Settings.php:1466
2048
- #: classes/Views/Settings.php:1470
2049
- msgid "Import Settings"
2050
- msgstr ""
2051
-
2052
- #: classes/Views/Settings.php:1522
2053
- msgid "Current user is not allowed to import files."
2054
- msgstr ""
2055
-
2056
- #: classes/Views/Settings.php:1541
2057
- msgid "The plugin settings have been imported successfully."
2058
- msgstr ""
2059
-
2060
- #: classes/Views/Settings.php:1543
2061
- msgid "No settings found to import."
2062
- msgstr ""
2063
-
2064
- #: classes/Views/Settings.php:1546
2065
- msgid "Invalid file or file size is too large."
2066
- msgstr ""
2067
-
2068
- #: classes/Views/Settings.php:1549
2069
- msgid "Error occurred while uploading the file."
2070
- msgstr ""
2071
-
2072
- #: classes/Views/Settings.php:1560
2073
  msgid "These settings are for advanced users."
2074
  msgstr ""
2075
 
2076
- #: classes/Views/Settings.php:1561
2077
  msgid ""
2078
  "If you have any questions <a href=\"https://wpactivitylog.com/contact/?"
2079
  "utm_source=plugin&utm_medium=referral&utm_campaign=WSAL&utm_content=settings"
2080
  "+pages\" target=\"_blank\">contact us</a>."
2081
  msgstr ""
2082
 
2083
- #: classes/Views/Settings.php:1564
2084
- msgid "Where do you want to save the log files?"
 
 
2085
  msgstr ""
2086
 
2087
- #: classes/Views/Settings.php:1565
2088
  msgid ""
2089
- "The plugin uses a number of log files. It uses these log files to keep a log "
2090
- "of 1) requests to non-existing URLs from logged in users (event ID 6007) and "
2091
- "non-logged in users (6023), 2) the request log. Use the below setting to "
2092
- "save the log files in different location. Please specify the relative path."
 
 
2093
  msgstr ""
2094
 
2095
- #: classes/Views/Settings.php:1570
2096
- msgid "Log files location"
2097
  msgstr ""
2098
 
2099
- #: classes/Views/Settings.php:1581
2100
  msgid ""
2101
  "<strong>Note:</strong> Enter a path from the root of your website: eg \"/wp-"
2102
- "content/uploads/wp-security-audit-log/\"."
2103
  msgstr ""
2104
 
2105
- #: classes/Views/Settings.php:1594
2106
  msgid ""
2107
  "Troubleshooting setting: Keep a debug log of all the requests this website "
2108
  "receives"
2109
  msgstr ""
2110
 
2111
- #: classes/Views/Settings.php:1595
2112
  msgid ""
2113
  "Only enable the request log on testing, staging and development website. "
2114
  "Never enable logging on a live website unless instructed to do so. Enabling "
2115
  "request logging on a live website may degrade the performance of the website."
2116
  msgstr ""
2117
 
2118
- #: classes/Views/Settings.php:1599
2119
  msgid "Request Log"
2120
  msgstr ""
2121
 
2122
- #: classes/Views/Settings.php:1617
2123
  msgid ""
2124
  "<strong>Note:</strong> The requests debug log file is saved as request.log."
2125
- "php in the /wp-content/uploads/wp-security-audit-log/ directory."
2126
  msgstr ""
2127
 
2128
- #: classes/Views/Settings.php:1629
2129
  msgid "Reset plugin settings to default"
2130
  msgstr ""
2131
 
2132
- #: classes/Views/Settings.php:1630
2133
  msgid ""
2134
  "Click the RESET button to reset ALL plugin settings to default. Note that "
2135
  "the activity log data will be retained and only the plugin settings will be "
2136
  "reset. To purge the data of the activity log use the setting below."
2137
  msgstr ""
2138
 
2139
- #: classes/Views/Settings.php:1634
2140
  msgid "Reset Settings"
2141
  msgstr ""
2142
 
2143
- #: classes/Views/Settings.php:1636
2144
  msgid "RESET"
2145
  msgstr ""
2146
 
2147
- #: classes/Views/Settings.php:1642
2148
  msgid "Purge the WordPress activity log"
2149
  msgstr ""
2150
 
2151
- #: classes/Views/Settings.php:1643
2152
  msgid ""
2153
  "Click the Purge button below to delete all the data from the WordPress "
2154
  "activity log and start afresh."
2155
  msgstr ""
2156
 
2157
- #: classes/Views/Settings.php:1647
2158
  msgid "Purge Activity Log"
2159
  msgstr ""
2160
 
2161
- #: classes/Views/Settings.php:1649
2162
  msgid "PURGE"
2163
  msgstr ""
2164
 
2165
- #: classes/Views/Settings.php:1655
2166
  msgid "MainWP Child Site Stealth Mode"
2167
  msgstr ""
2168
 
2169
- #: classes/Views/Settings.php:1656
2170
  msgid ""
2171
  "This option is enabled automatically when the plugin detects the MainWP "
2172
  "Child plugin on the site. When this setting is enabled plugin access is "
@@ -2175,15 +2142,23 @@ msgid ""
2175
  "Disable this option to change the plugin to the default setup."
2176
  msgstr ""
2177
 
2178
- #: classes/Views/Settings.php:1660
2179
  msgid "Enable MainWP Child Site Stealth Mode"
2180
  msgstr ""
2181
 
2182
- #: classes/Views/Settings.php:1684
 
 
 
 
 
 
 
 
2183
  msgid "Do you want to delete the plugin data from the database upon uninstall?"
2184
  msgstr ""
2185
 
2186
- #: classes/Views/Settings.php:1685
2187
  msgid ""
2188
  "The plugin saves the activity log data and settings in the WordPress "
2189
  "database. By default upon uninstalling the plugin the data is kept in the "
@@ -2192,59 +2167,65 @@ msgid ""
2192
  "access it again even when you reinstall the plugin."
2193
  msgstr ""
2194
 
2195
- #: classes/Views/Settings.php:1689
2196
  msgid "Remove Data on Uninstall"
2197
  msgstr ""
2198
 
2199
- #: classes/Views/Settings.php:1714
2200
  msgid "Are you sure you want to reset all the plugin settings to default?"
2201
  msgstr ""
2202
 
2203
- #: classes/Views/Settings.php:1724
2204
  msgid "Are you sure you want to purge all the activity log data?"
2205
  msgstr ""
2206
 
2207
- #: classes/Views/Settings.php:1754
2208
  msgid "MainWP Child plugin is not active on this website."
2209
  msgstr ""
2210
 
2211
- #: classes/Views/Settings.php:1864
 
 
 
 
 
 
2212
  msgid "The specified value is not a valid URL!"
2213
  msgstr ""
2214
 
2215
- #: classes/Views/Settings.php:1865
2216
  msgid "The specified value is not a valid post type!"
2217
  msgstr ""
2218
 
2219
- #: classes/Views/Settings.php:1866
2220
  msgid "The specified value is not a valid IP address!"
2221
  msgstr ""
2222
 
2223
- #: classes/Views/Settings.php:1867
2224
  msgid "The specified value is not a user nor a role!"
2225
  msgstr ""
2226
 
2227
- #: classes/Views/Settings.php:1868
2228
  msgid "Filename cannot be added because it contains invalid characters."
2229
  msgstr ""
2230
 
2231
- #: classes/Views/Settings.php:1869
2232
  msgid "File extension cannot be added because it contains invalid characters."
2233
  msgstr ""
2234
 
2235
- #: classes/Views/Settings.php:1870
2236
  msgid "Directory cannot be added because it contains invalid characters."
2237
  msgstr ""
2238
 
2239
- #: classes/Views/Settings.php:2006 classes/Views/Settings.php:2033
2240
  msgid "Tables has been reset."
2241
  msgstr ""
2242
 
2243
- #: classes/Views/Settings.php:2008 classes/Views/Settings.php:2035
2244
  msgid "Reset query failed."
2245
  msgstr ""
2246
 
2247
- #: classes/Views/Settings.php:2011 classes/Views/Settings.php:2038
2248
  msgid "Nonce Verification Failed."
2249
  msgstr ""
2250
 
@@ -2272,8 +2253,8 @@ msgstr ""
2272
  msgid "Log Retention"
2273
  msgstr ""
2274
 
2275
- #: classes/Views/SetupWizard.php:207 classes/Views/SetupWizard.php:796
2276
- #: classes/Views/SetupWizard.php:797
2277
  msgid "Finish"
2278
  msgstr ""
2279
 
@@ -2289,19 +2270,19 @@ msgstr ""
2289
  msgid "Specified value in not an IP address."
2290
  msgstr ""
2291
 
2292
- #: classes/Views/SetupWizard.php:272 wp-security-audit-log.php:1166
2293
  msgid "Installing, please wait"
2294
  msgstr ""
2295
 
2296
- #: classes/Views/SetupWizard.php:273 wp-security-audit-log.php:1167
2297
  msgid "Already installed"
2298
  msgstr ""
2299
 
2300
- #: classes/Views/SetupWizard.php:275 wp-security-audit-log.php:1169
2301
  msgid "Extension activated"
2302
  msgstr ""
2303
 
2304
- #: classes/Views/SetupWizard.php:276 wp-security-audit-log.php:1170
2305
  msgid "Install failed"
2306
  msgstr ""
2307
 
@@ -2309,118 +2290,119 @@ msgstr ""
2309
  msgid "WP Activity Log &rsaquo; Setup Wizard"
2310
  msgstr ""
2311
 
2312
- #: classes/Views/SetupWizard.php:325
2313
  msgid "Close Wizard"
2314
  msgstr ""
2315
 
2316
- #: classes/Views/SetupWizard.php:418
 
2317
  #, php-format
2318
  msgid ""
2319
  "You have reached an invaild step - %1$sreturn to the start of the wizard%2$s."
2320
  msgstr ""
2321
 
2322
- #: classes/Views/SetupWizard.php:435
2323
  msgid ""
2324
  "This wizard helps you configure the basic plugin settings. All these "
2325
  "settings can be changed at a later stage from the plugin settings."
2326
  msgstr ""
2327
 
2328
- #: classes/Views/SetupWizard.php:440
2329
  msgid "Start Configuring the Plugin"
2330
  msgstr ""
2331
 
2332
- #: classes/Views/SetupWizard.php:444
2333
  msgid "Exit Wizard"
2334
  msgstr ""
2335
 
2336
- #: classes/Views/SetupWizard.php:457
2337
  msgid "Please select the level of detail for your WordPress activity logs:"
2338
  msgstr ""
2339
 
2340
- #: classes/Views/SetupWizard.php:461
2341
  msgid ""
2342
  "Basic (I want a high level overview and I am not interested in the detail)"
2343
  msgstr ""
2344
 
2345
- #: classes/Views/SetupWizard.php:466
2346
  msgid "Geek (I want to know everything that is happening on my WordPress)"
2347
  msgstr ""
2348
 
2349
- #: classes/Views/SetupWizard.php:468
2350
  msgid ""
2351
  "Note: You can change the WordPress logging level from the plugin’s settings "
2352
  "anytime."
2353
  msgstr ""
2354
 
2355
- #: classes/Views/SetupWizard.php:471 classes/Views/SetupWizard.php:528
2356
- #: classes/Views/SetupWizard.php:576 classes/Views/SetupWizard.php:625
2357
- #: classes/Views/SetupWizard.php:685 classes/Views/SetupWizard.php:686
2358
- #: classes/Views/SetupWizard.php:892 classes/Views/SetupWizard.php:893
2359
  msgid "Next"
2360
  msgstr ""
2361
 
2362
- #: classes/Views/SetupWizard.php:512
2363
  msgid ""
2364
  "Do you or your users use other pages to log in to WordPress other than the "
2365
  "default login page ( /wp-admin/ )?"
2366
  msgstr ""
2367
 
2368
- #: classes/Views/SetupWizard.php:516
2369
  msgid "Yes, we use other pages to login to WordPress."
2370
  msgstr ""
2371
 
2372
- #: classes/Views/SetupWizard.php:521
2373
  msgid "No, we only use the default WordPress login page."
2374
  msgstr ""
2375
 
2376
- #: classes/Views/SetupWizard.php:523
2377
  msgid ""
2378
  "If your website is a membership or ecommerce website most probably you have "
2379
  "more than one area from where the users can login. If you are not sure, "
2380
  "select Yes."
2381
  msgstr ""
2382
 
2383
- #: classes/Views/SetupWizard.php:526 classes/Views/SetupWizard.php:574
2384
- #: classes/Views/SetupWizard.php:623 classes/Views/SetupWizard.php:677
2385
  msgid ""
2386
  "Note: You can change the WordPress activity log retention settings at any "
2387
  "time from the plugin settings later on."
2388
  msgstr ""
2389
 
2390
- #: classes/Views/SetupWizard.php:561
2391
  msgid ""
2392
  "Do you want to keep a log of (non-logged in) visitors’ requests to non-"
2393
  "existing URLs which generate a HTTP 404 error response?"
2394
  msgstr ""
2395
 
2396
- #: classes/Views/SetupWizard.php:609
2397
  msgid "Can visitors register for a user on your website?"
2398
  msgstr ""
2399
 
2400
- #: classes/Views/SetupWizard.php:620
2401
  msgid ""
2402
  "If you are not sure about this setting, check if the Membership setting in "
2403
  "the WordPress General settings is checked or not. If it is not checked "
2404
  "(default) select No."
2405
  msgstr ""
2406
 
2407
- #: classes/Views/SetupWizard.php:659
2408
  msgid "How long do you want to keep the data in the WordPress activity Log?"
2409
  msgstr ""
2410
 
2411
- #: classes/Views/SetupWizard.php:664
2412
  msgid "6 months (data older than 6 months will be deleted)"
2413
  msgstr ""
2414
 
2415
- #: classes/Views/SetupWizard.php:669
2416
  msgid "12 months (data older than 12 months will be deleted)"
2417
  msgstr ""
2418
 
2419
- #: classes/Views/SetupWizard.php:674
2420
  msgid "Keep all data."
2421
  msgstr ""
2422
 
2423
- #: classes/Views/SetupWizard.php:695
2424
  msgid ""
2425
  "The plugin stores the data in the WordPress database in a very efficient "
2426
  "way, though the more data you keep the more hard disk space it will consume. "
@@ -2431,37 +2413,29 @@ msgid ""
2431
  "Database tools to store the WordPress activity log in an external database."
2432
  msgstr ""
2433
 
2434
- #: classes/Views/SetupWizard.php:699
2435
- msgid ""
2436
- "The plugin stores the data in the WordPress database in a very efficient "
2437
- "way, though the more data you keep the more hard disk space it will consume. "
2438
- "If you need need to retain a lot of data we would recommend you to store the "
2439
- "WordPress activity log in an external database or enable archiving."
2440
- msgstr ""
2441
-
2442
- #: classes/Views/SetupWizard.php:767
2443
  msgid ""
2444
  "Your plugin is all set and it is ready to start keeping a record of "
2445
  "everything that is happening on your WordPress in a WordPress activity log."
2446
  msgstr ""
2447
 
2448
- #: classes/Views/SetupWizard.php:768
2449
  msgid "Below are a few useful links you might need to refer to:"
2450
  msgstr ""
2451
 
2452
- #: classes/Views/SetupWizard.php:773
2453
  msgid "Getting started with the WP Activity Log plugin"
2454
  msgstr ""
2455
 
2456
- #: classes/Views/SetupWizard.php:778
2457
  msgid "Knowledge Base & Support Documents"
2458
  msgstr ""
2459
 
2460
- #: classes/Views/SetupWizard.php:783
2461
  msgid "Benefits of keeping a WordPress activity log"
2462
  msgstr ""
2463
 
2464
- #: classes/Views/SetupWizard.php:788
2465
  msgid ""
2466
  "We trust this plugin meets all your activity log requirements. Should you "
2467
  "encounter any problems, have feature requests or would like to share some "
@@ -2470,15 +2444,15 @@ msgid ""
2470
  "+configuration\" target=\"_blank\">please get in touch!</a>"
2471
  msgstr ""
2472
 
2473
- #: classes/Views/SetupWizard.php:824
2474
  msgid "Third Party Extensions"
2475
  msgstr ""
2476
 
2477
- #: classes/Views/SetupWizard.php:850
2478
  msgid "Monitoring changes done in third party plugins"
2479
  msgstr ""
2480
 
2481
- #: classes/Views/SetupWizard.php:851
2482
  msgid ""
2483
  "We noticed that the below plugins are installed on this website. You can "
2484
  "install our extensions to also keep a log of changes users do on these "
@@ -2489,23 +2463,23 @@ msgstr ""
2489
  msgid "Enable/Disable Events"
2490
  msgstr ""
2491
 
2492
- #: classes/Views/ToggleAlerts.php:197
2493
  msgid "Log Level: "
2494
  msgstr ""
2495
 
2496
- #: classes/Views/ToggleAlerts.php:202
2497
  msgid "Basic"
2498
  msgstr ""
2499
 
2500
- #: classes/Views/ToggleAlerts.php:207
2501
  msgid "Geek"
2502
  msgstr ""
2503
 
2504
- #: classes/Views/ToggleAlerts.php:210
2505
  msgid "Custom"
2506
  msgstr ""
2507
 
2508
- #: classes/Views/ToggleAlerts.php:214
2509
  msgid ""
2510
  "Use the Log level drop down menu above to use one of our preset log levels. "
2511
  "Alternatively you can enable or disable any of the individual events from "
@@ -2515,139 +2489,135 @@ msgid ""
2515
  "plugin can keep a log of."
2516
  msgstr ""
2517
 
2518
- #: classes/Views/ToggleAlerts.php:224
2519
  msgid "Front-end Events"
2520
  msgstr ""
2521
 
2522
- #: classes/Views/ToggleAlerts.php:229
2523
  msgid "Third party plugins"
2524
  msgstr ""
2525
 
2526
- #: classes/Views/ToggleAlerts.php:325
2527
  msgid "Code"
2528
  msgstr ""
2529
 
2530
- #: classes/Views/ToggleAlerts.php:327 classes/WidgetManager.php:77
2531
  msgid "Description"
2532
  msgstr ""
2533
 
2534
- #: classes/Views/ToggleAlerts.php:331 defaults.php:104
2535
  msgid "Content"
2536
  msgstr ""
2537
 
2538
- #: classes/Views/ToggleAlerts.php:334
2539
  msgid ""
2540
  "<strong>Note:</strong> Post refers to any type of content, i.e. blog post, "
2541
  "page or a post with a custom post type."
2542
  msgstr ""
2543
 
2544
- #: classes/Views/ToggleAlerts.php:337 defaults.php:408
2545
- msgid "WooCommerce"
2546
- msgstr ""
2547
-
2548
- #: classes/Views/ToggleAlerts.php:337 classes/Views/ToggleAlerts.php:345
2549
  msgid "WooCommerce Products"
2550
  msgstr ""
2551
 
2552
- #: classes/Views/ToggleAlerts.php:341
2553
  msgid ""
2554
  "The plugin WooCommerce is not installed on your website so these events have "
2555
  "been disabled."
2556
  msgstr ""
2557
 
2558
- #: classes/Views/ToggleAlerts.php:348 defaults.php:409
2559
  msgid "Products"
2560
  msgstr ""
2561
 
2562
- #: classes/Views/ToggleAlerts.php:356
2563
  msgid ""
2564
  "The plugin Yoast SEO is not installed on your website so these events have "
2565
  "been disabled."
2566
  msgstr ""
2567
 
2568
- #: classes/Views/ToggleAlerts.php:362 defaults.php:534
2569
  msgid "Post Changes"
2570
  msgstr ""
2571
 
2572
- #: classes/Views/ToggleAlerts.php:365 defaults.php:398
2573
  msgid "MultiSite"
2574
  msgstr ""
2575
 
2576
- #: classes/Views/ToggleAlerts.php:369
2577
  msgid ""
2578
  "Your website is a single site so the multisite events have been disabled."
2579
  msgstr ""
2580
 
2581
- #: classes/Views/ToggleAlerts.php:373
2582
  msgid "Other User Activity"
2583
  msgstr ""
2584
 
2585
- #: classes/Views/ToggleAlerts.php:376
2586
  msgid "Logins & Logouts"
2587
  msgstr ""
2588
 
2589
- #: classes/Views/ToggleAlerts.php:388 classes/Views/ToggleAlerts.php:547
2590
- #: defaults.php:575
2591
  msgid "Monitor File Changes"
2592
  msgstr ""
2593
 
2594
- #: classes/Views/ToggleAlerts.php:399
2595
  msgid "Not Implemented"
2596
  msgstr ""
2597
 
2598
- #: classes/Views/ToggleAlerts.php:402
2599
  msgid "Not Available"
2600
  msgstr ""
2601
 
2602
- #: classes/Views/ToggleAlerts.php:412
2603
  msgid "User Sessions"
2604
  msgstr ""
2605
 
2606
- #: classes/Views/ToggleAlerts.php:414
2607
  msgid "Files"
2608
  msgstr ""
2609
 
2610
- #: classes/Views/ToggleAlerts.php:416
2611
  msgid "Post Settings"
2612
  msgstr ""
2613
 
2614
- #: classes/Views/ToggleAlerts.php:418
2615
  msgid "Product Admin"
2616
  msgstr ""
2617
 
2618
- #: classes/Views/ToggleAlerts.php:420
2619
  msgid "Product Attributes"
2620
  msgstr ""
2621
 
2622
- #: classes/Views/ToggleAlerts.php:484 classes/Views/ToggleAlerts.php:634
2623
  msgid ""
2624
  "Capture 404 requests to file (the log file are created in the /wp-content/"
2625
- "uploads/wp-security-audit-log/404s/ directory)"
2626
  msgstr ""
2627
 
2628
- #: classes/Views/ToggleAlerts.php:492 classes/Views/ToggleAlerts.php:638
2629
  msgid "Purge log files older than one month"
2630
  msgstr ""
2631
 
2632
- #: classes/Views/ToggleAlerts.php:497
2633
  msgid ""
2634
  "Number of 404 Requests to Log. By default the plugin keeps up to 99 requests "
2635
  "to non-existing pages from the same IP address. Increase the value in this "
2636
  "setting to the desired amount to keep a log of more or less requests."
2637
  msgstr ""
2638
 
2639
- #: classes/Views/ToggleAlerts.php:502 classes/Views/ToggleAlerts.php:646
2640
  msgid "Record the referrer that generated the 404 error."
2641
  msgstr ""
2642
 
2643
- #: classes/Views/ToggleAlerts.php:514 classes/Views/ToggleAlerts.php:527
2644
  msgid ""
2645
  "Number of login attempts to log. Enter 0 to log all failed login attempts. "
2646
  "(By default the plugin only logs up to 10 failed login because the process "
2647
  "can be very resource intensive in case of a brute force attack)"
2648
  msgstr ""
2649
 
2650
- #: classes/Views/ToggleAlerts.php:540
2651
  msgid ""
2652
  "Log all stock changes. Disable this setting to only keep a log of stock "
2653
  "changes done manually via the WooCommerce dashboard. Therefore automated "
@@ -2655,7 +2625,7 @@ msgid ""
2655
  "plugins will not be logged."
2656
  msgstr ""
2657
 
2658
- #: classes/Views/ToggleAlerts.php:591
2659
  msgid ""
2660
  "This plugin keeps a log of what your website users are doing when they are "
2661
  "logged in. On top of that it can also keep a log of some important events of "
@@ -2663,38 +2633,38 @@ msgid ""
2663
  "any of the front-end sensors:"
2664
  msgstr ""
2665
 
2666
- #: classes/Views/ToggleAlerts.php:596
2667
  msgid "Front-end users registrations"
2668
  msgstr ""
2669
 
2670
- #: classes/Views/ToggleAlerts.php:602
2671
  msgid ""
2672
  "Keep a log when a visitor registers a user on the website. Only enable this "
2673
  "if you allow visitors to register as users on your website. User "
2674
  "registration is disabled by default in WordPress."
2675
  msgstr ""
2676
 
2677
- #: classes/Views/ToggleAlerts.php:607
2678
  msgid "Front-end users logins"
2679
  msgstr ""
2680
 
2681
- #: classes/Views/ToggleAlerts.php:613
2682
  msgid ""
2683
  "Keep a log when users login to the website from other login pages / forms "
2684
  "other than the default WordPress login page."
2685
  msgstr ""
2686
 
2687
- #: classes/Views/ToggleAlerts.php:618
2688
  msgid "Website visitors 404 errors"
2689
  msgstr ""
2690
 
2691
- #: classes/Views/ToggleAlerts.php:624
2692
  msgid ""
2693
  "Event ID 6023: Keep a log when a website visitor requests a non-existing URL "
2694
  "(HTTP 404 response error)."
2695
  msgstr ""
2696
 
2697
- #: classes/Views/ToggleAlerts.php:642
2698
  msgid ""
2699
  "Number of 404 Requests to Log. By default the plugin keeps up to 99 requests "
2700
  "to non-existing pages from the same IP address. Increase the value in this "
@@ -2703,49 +2673,39 @@ msgid ""
2703
  "scanned the plugin will consume more resources to log all the requests."
2704
  msgstr ""
2705
 
2706
- #: classes/Views/ToggleAlerts.php:650
2707
- msgid "Front-end WooCommerce activity"
2708
- msgstr ""
2709
-
2710
- #: classes/Views/ToggleAlerts.php:656
2711
- msgid ""
2712
- "Keep a log of product stocks and orders changes done by website visitors "
2713
- "(non-logged in). Regardless of the state of this setting, the plugin always "
2714
- "keeps a log of changes done by logged in users."
2715
- msgstr ""
2716
-
2717
- #: classes/Views/ToggleAlerts.php:666
2718
  msgid "Save Changes"
2719
  msgstr ""
2720
 
2721
- #: classes/Views/ToggleAlerts.php:673
2722
  msgid "Log Level Updated"
2723
  msgstr ""
2724
 
2725
- #: classes/Views/ToggleAlerts.php:677
 
2726
  #, php-format
2727
  msgid "The %s log level has been successfully loaded and applied."
2728
  msgstr ""
2729
 
2730
- #: classes/Views/ToggleAlerts.php:681
2731
  msgid "OK"
2732
  msgstr ""
2733
 
2734
- #: classes/Views/ToggleAlerts.php:696
2735
  msgid "Enable File Integrity Scanner"
2736
  msgstr ""
2737
 
2738
- #: classes/Views/ToggleAlerts.php:698
2739
  msgid ""
2740
  "The file integrity scanner is switched off. To enable this event it has to "
2741
  "be switched on."
2742
  msgstr ""
2743
 
2744
- #: classes/Views/ToggleAlerts.php:702
2745
  msgid "SWITCH ON"
2746
  msgstr ""
2747
 
2748
- #: classes/Views/ToggleAlerts.php:703
2749
  msgid "DISABLE EVENT"
2750
  msgstr ""
2751
 
@@ -2765,197 +2725,197 @@ msgstr ""
2765
  msgid "No events found."
2766
  msgstr ""
2767
 
2768
- #: defaults.php:78
2769
  msgid "Critical severity events."
2770
  msgstr ""
2771
 
2772
- #: defaults.php:79
2773
  msgid "High severity events."
2774
  msgstr ""
2775
 
2776
- #: defaults.php:80
2777
  msgid "Medium severity events."
2778
  msgstr ""
2779
 
2780
- #: defaults.php:81
2781
  msgid "Low severity events."
2782
  msgstr ""
2783
 
2784
- #: defaults.php:82
2785
  msgid "Informational events."
2786
  msgstr ""
2787
 
2788
- #: defaults.php:87
2789
  msgid "Users Logins & Sessions Events"
2790
  msgstr ""
2791
 
2792
- #: defaults.php:88
2793
  msgid "User Activity"
2794
  msgstr ""
2795
 
2796
- #: defaults.php:89
2797
  msgid "User logged in"
2798
  msgstr ""
2799
 
2800
- #: defaults.php:90
2801
  msgid "User logged out"
2802
  msgstr ""
2803
 
2804
- #: defaults.php:91
2805
  msgid "Login failed"
2806
  msgstr ""
2807
 
2808
- #: defaults.php:92
2809
  msgid "Login failed / non existing user"
2810
  msgstr ""
2811
 
2812
- #: defaults.php:92
2813
  msgid "%Attempts% failed login(s) %LineBreak% %LogFileText%"
2814
  msgstr ""
2815
 
2816
- #: defaults.php:93
2817
  msgid "Login blocked"
2818
  msgstr ""
2819
 
2820
- #: defaults.php:93
2821
  msgid ""
2822
  "Login blocked because other session(s) already exist for this user. "
2823
  "%LineBreak% IP address: %ClientIP%"
2824
  msgstr ""
2825
 
2826
- #: defaults.php:94
2827
  msgid "User logged in with existing session(s)"
2828
  msgstr ""
2829
 
2830
- #: defaults.php:94
2831
  msgid ""
2832
- "User logged in however there are other session(s) already exist for this "
2833
- "user. %LineBreak% IP address: %IPAddress%"
2834
  msgstr ""
2835
 
2836
- #: defaults.php:95
2837
  msgid "User logged out all other sessions with the same username"
2838
  msgstr ""
2839
 
2840
- #: defaults.php:95
2841
  msgid "Logged out all other sessions with the same user."
2842
  msgstr ""
2843
 
2844
- #: defaults.php:96
2845
  msgid "User session destroyed and logged out"
2846
  msgstr ""
2847
 
2848
- #: defaults.php:96
2849
  msgid ""
2850
  "Terminated the session of another user. %LineBreak% User: %TargetUserName% "
2851
  "%LineBreak% Session ID: %TargetSessionID%"
2852
  msgstr ""
2853
 
2854
- #: defaults.php:97
2855
  msgid "Switched to another user"
2856
  msgstr ""
2857
 
2858
- #: defaults.php:97
2859
  msgid ""
2860
  "Switched to another user. %LineBreak% User: %TargetUserName% %LineBreak% "
2861
  "Role: %TargetUserRole%"
2862
  msgstr ""
2863
 
2864
- #: defaults.php:98
2865
  msgid "User uploaded file from Uploads directory"
2866
  msgstr ""
2867
 
2868
- #: defaults.php:98 defaults.php:99
2869
  msgid "Filename: %FileName% %LineBreak% Directory: %FilePath%"
2870
  msgstr ""
2871
 
2872
- #: defaults.php:99
2873
  msgid "User deleted file from Uploads directory"
2874
  msgstr ""
2875
 
2876
- #: defaults.php:103
2877
  msgid "Content & Comments"
2878
  msgstr ""
2879
 
2880
- #: defaults.php:105
2881
  msgid "User created a new post and saved it as draft"
2882
  msgstr ""
2883
 
2884
- #: defaults.php:105
2885
  msgid ""
2886
  "Created the post %PostTitle% %LineBreak% ID: %PostID% %LineBreak% Type: "
2887
  "%PostType% %LineBreak% Status: %PostStatus% %PostUrlIfPlublished% %LineBreak"
2888
  "% %EditorLinkPost%"
2889
  msgstr ""
2890
 
2891
- #: defaults.php:106
2892
  msgid "User published a post"
2893
  msgstr ""
2894
 
2895
- #: defaults.php:106
2896
  msgid ""
2897
  "Published the post %PostTitle% %LineBreak% ID: %PostID% %LineBreak% Type: "
2898
  "%PostType% %LineBreak% Status: %PostStatus% %PostUrlIfPlublished% %LineBreak"
2899
  "% %EditorLinkPost%"
2900
  msgstr ""
2901
 
2902
- #: defaults.php:107
2903
  msgid "User modified a post"
2904
  msgstr ""
2905
 
2906
- #: defaults.php:107
2907
  msgid ""
2908
  "Modified the post %PostTitle% %LineBreak% ID: %PostID% %LineBreak% Type: "
2909
  "%PostType% %PostUrlIfPlublished% %LineBreak% %EditorLinkPost%"
2910
  msgstr ""
2911
 
2912
- #: defaults.php:108
2913
  msgid "User permanently deleted a post from the trash"
2914
  msgstr ""
2915
 
2916
- #: defaults.php:108
2917
  msgid ""
2918
  "Permanently deleted the post %PostTitle% %LineBreak% ID: %PostID% %LineBreak"
2919
  "% Type: %PostType%"
2920
  msgstr ""
2921
 
2922
- #: defaults.php:109
2923
  msgid "User moved a post to the trash"
2924
  msgstr ""
2925
 
2926
- #: defaults.php:109
2927
  msgid ""
2928
  "Moved the post %PostTitle% to trash %LineBreak% ID: %PostID% %LineBreak% "
2929
  "Type: %PostType% %LineBreak% Status: %PostStatus% %PostUrlIfPlublished%"
2930
  msgstr ""
2931
 
2932
- #: defaults.php:110
2933
  msgid "User restored a post from trash"
2934
  msgstr ""
2935
 
2936
- #: defaults.php:110
2937
  msgid ""
2938
  "Restored the post %PostTitle% from trash %LineBreak% ID: %PostID% %LineBreak"
2939
  "% Type: %PostType% %LineBreak% Status: %PostStatus% %PostUrlIfPlublished% "
2940
  "%LineBreak% %EditorLinkPost%"
2941
  msgstr ""
2942
 
2943
- #: defaults.php:111
2944
  msgid "User changed post URL"
2945
  msgstr ""
2946
 
2947
- #: defaults.php:111
2948
  msgid ""
2949
  "Changed the URL of the post %PostTitle% %LineBreak% ID: %PostID% %LineBreak% "
2950
  "Type: %PostType% %LineBreak% Status: %PostStatus% %LineBreak% Previous URL: "
2951
  "%OldUrl% %LineBreak% New URL: %NewUrl% %LineBreak% %EditorLinkPost%"
2952
  msgstr ""
2953
 
2954
- #: defaults.php:112
2955
  msgid "User changed post author"
2956
  msgstr ""
2957
 
2958
- #: defaults.php:112
2959
  msgid ""
2960
  "Changed the author of the post %PostTitle% %LineBreak% ID: %PostID% "
2961
  "%LineBreak% Type: %PostType% %LineBreak% Status: %PostStatus% %LineBreak% "
@@ -2963,22 +2923,22 @@ msgid ""
2963
  "%PostUrlIfPlublished% %LineBreak% %EditorLinkPost%."
2964
  msgstr ""
2965
 
2966
- #: defaults.php:113
2967
  msgid "User changed post status"
2968
  msgstr ""
2969
 
2970
- #: defaults.php:113
2971
  msgid ""
2972
  "Changed the status of the post %PostTitle% %LineBreak% ID: %PostID% "
2973
  "%LineBreak% Type: %PostType% %LineBreak% Status was: %OldStatus% %LineBreak% "
2974
  "New status: %NewStatus% %PostUrlIfPlublished% %LineBreak% %EditorLinkPost%"
2975
  msgstr ""
2976
 
2977
- #: defaults.php:114
2978
  msgid "User changed the visibility of a post"
2979
  msgstr ""
2980
 
2981
- #: defaults.php:114
2982
  msgid ""
2983
  "Changed the visibility of the post %PostTitle% %LineBreak% ID: %PostID% "
2984
  "%LineBreak% Type: %PostType% %LineBreak% Status: %PostStatus% %LineBreak% "
@@ -2986,11 +2946,11 @@ msgid ""
2986
  "%PostUrlIfPlublished% %LineBreak% %EditorLinkPost%"
2987
  msgstr ""
2988
 
2989
- #: defaults.php:115
2990
  msgid "User changed the date of a post"
2991
  msgstr ""
2992
 
2993
- #: defaults.php:115
2994
  msgid ""
2995
  "Changed the date of the post %PostTitle% %LineBreak% ID: %PostID% %LineBreak"
2996
  "% Type: %PostType% %LineBreak% Status: %PostStatus% %LineBreak% Previous "
@@ -2998,11 +2958,11 @@ msgid ""
2998
  "%LineBreak% %EditorLinkPost%"
2999
  msgstr ""
3000
 
3001
- #: defaults.php:116
3002
  msgid "User changed the parent of a page"
3003
  msgstr ""
3004
 
3005
- #: defaults.php:116
3006
  msgid ""
3007
  "Changed the parent of the post %PostTitle% %LineBreak% ID: %PostID% "
3008
  "%LineBreak% Type: %PostType% %LineBreak% Status: %PostStatus% %LineBreak% "
@@ -3010,11 +2970,11 @@ msgid ""
3010
  "%PostUrlIfPlublished% %LineBreak% %EditorLinkPost%"
3011
  msgstr ""
3012
 
3013
- #: defaults.php:117
3014
  msgid "User changed the template of a page"
3015
  msgstr ""
3016
 
3017
- #: defaults.php:117
3018
  msgid ""
3019
  "Changed the template of the post %PostTitle% %LineBreak% ID: %PostID% "
3020
  "%LineBreak% Type: %PostType% %LineBreak% Status: %PostStatus% %LineBreak% "
@@ -3022,210 +2982,210 @@ msgid ""
3022
  "%PostUrlIfPlublished% %LineBreak% %EditorLinkPost%"
3023
  msgstr ""
3024
 
3025
- #: defaults.php:118
3026
  msgid "User set a post as sticky"
3027
  msgstr ""
3028
 
3029
- #: defaults.php:118
3030
  msgid ""
3031
  "Set the post %PostTitle% as sticky %LineBreak% ID: %PostID% %LineBreak% "
3032
  "Type: %PostType% %LineBreak% Status: %PostStatus% %PostUrlIfPlublished% "
3033
  "%LineBreak% %EditorLinkPost%"
3034
  msgstr ""
3035
 
3036
- #: defaults.php:119
3037
  msgid "User removed post from sticky"
3038
  msgstr ""
3039
 
3040
- #: defaults.php:119
3041
  msgid ""
3042
  "Removed the post %PostTitle% from sticky %LineBreak% ID: %PostID% %LineBreak"
3043
  "% Type: %PostType% %LineBreak% Status: %PostStatus% %PostUrlIfPlublished% "
3044
  "%LineBreak% %EditorLinkPost%"
3045
  msgstr ""
3046
 
3047
- #: defaults.php:120
3048
  msgid "User modified the content of a post"
3049
  msgstr ""
3050
 
3051
- #: defaults.php:120
3052
  msgid ""
3053
  "Modified the content of the post %PostTitle% %LineBreak% ID: %PostID% "
3054
  "%LineBreak% Type: %PostType% %LineBreak% Status: %PostStatus% %LineBreak% "
3055
  "%RevisionLink% %PostUrlIfPlublished% %LineBreak% %EditorLinkPost%"
3056
  msgstr ""
3057
 
3058
- #: defaults.php:121
3059
  msgid "User submitted a post for review"
3060
  msgstr ""
3061
 
3062
- #: defaults.php:121
3063
  msgid ""
3064
  "Submitted the post %PostTitle% for review %LineBreak% ID: %PostID% %LineBreak"
3065
  "% Type: %PostType% %LineBreak% Status: %PostStatus% %PostUrlIfPlublished% "
3066
  "%LineBreak% %EditorLinkPost%"
3067
  msgstr ""
3068
 
3069
- #: defaults.php:122
3070
  msgid "User scheduled a post"
3071
  msgstr ""
3072
 
3073
- #: defaults.php:122
3074
  msgid ""
3075
  "Scheduled the post %PostTitle% to be published on %PublishingDate% %LineBreak"
3076
  "% ID: %PostID% %LineBreak% Type: %PostType% %LineBreak% Status: %PostStatus% "
3077
  "%LineBreak% %PostUrlIfPlublished% %LineBreak% %EditorLinkPost%"
3078
  msgstr ""
3079
 
3080
- #: defaults.php:123
3081
  msgid "User changed title of a post"
3082
  msgstr ""
3083
 
3084
- #: defaults.php:123
3085
  msgid ""
3086
  "Changed the title of the post %OldTitle% %LineBreak% New title: %NewTitle% "
3087
  "%LineBreak% ID: %PostID% %LineBreak% Type: %PostType% %LineBreak% Status: "
3088
  "%PostStatus% %PostUrlIfPlublished% %LineBreak% %EditorLinkPost%"
3089
  msgstr ""
3090
 
3091
- #: defaults.php:124
3092
  msgid "User opened a post in the editor"
3093
  msgstr ""
3094
 
3095
- #: defaults.php:124
3096
  msgid ""
3097
  "Opened the post %PostTitle% in the editor %LineBreak% ID: %PostID% %LineBreak"
3098
  "% Type: %PostType% %LineBreak% Status: %PostStatus% %PostUrlIfPlublished% "
3099
  "%LineBreak% %EditorLinkPost%"
3100
  msgstr ""
3101
 
3102
- #: defaults.php:125
3103
  msgid "User viewed a post"
3104
  msgstr ""
3105
 
3106
- #: defaults.php:125
3107
  msgid ""
3108
  "Viewed the post %PostTitle% %LineBreak% ID: %PostID% %LineBreak% Type: "
3109
  "%PostType% %LineBreak% Status: %PostStatus% %LineBreak% URL: %PostUrl% "
3110
  "%LineBreak% %EditorLinkPost%"
3111
  msgstr ""
3112
 
3113
- #: defaults.php:126
3114
  msgid "A plugin modified a post"
3115
  msgstr ""
3116
 
3117
- #: defaults.php:126
3118
  msgid ""
3119
  "Plugin modified the post %PostTitle% %LineBreak% ID: %PostID% %LineBreak% "
3120
  "Type: %PostType% %LineBreak% Status: %PostStatus% %PostUrlIfPlublished% "
3121
  "%LineBreak% %EditorLinkPost%"
3122
  msgstr ""
3123
 
3124
- #: defaults.php:127
3125
  msgid "User enabled/disabled comments in a post"
3126
  msgstr ""
3127
 
3128
- #: defaults.php:127
3129
  msgid ""
3130
  "The comments in the post %PostTitle% %LineBreak% ID: %PostID% %LineBreak% "
3131
  "Type: %PostType% %LineBreak% Status: %PostStatus% %PostUrlIfPlublished% "
3132
  "%LineBreak% %EditorLinkPost%"
3133
  msgstr ""
3134
 
3135
- #: defaults.php:128
3136
  msgid "User enabled/disabled trackbacks and pingbacks in a post"
3137
  msgstr ""
3138
 
3139
- #: defaults.php:128
3140
  msgid ""
3141
  "Pingbacks and Trackbacks in the post %PostTitle% %LineBreak% ID: %PostID% "
3142
  "%LineBreak% Type: %PostType% %LineBreak% Status: %PostStatus% "
3143
  "%PostUrlIfPlublished% %LineBreak% %EditorLinkPost%"
3144
  msgstr ""
3145
 
3146
- #: defaults.php:131
3147
  msgid "Tags"
3148
  msgstr ""
3149
 
3150
- #: defaults.php:132
3151
  msgid "User added post tag"
3152
  msgstr ""
3153
 
3154
- #: defaults.php:132
3155
  msgid ""
3156
  "Added tag(s) to the post %PostTitle% %LineBreak% ID: %PostID% %LineBreak% "
3157
  "Type: %PostType% %LineBreak% Status: %PostStatus% %LineBreak% Added tag(s): "
3158
  "%tag% %PostUrlIfPlublished% %LineBreak% %EditorLinkPost%"
3159
  msgstr ""
3160
 
3161
- #: defaults.php:133
3162
  msgid "User removed post tag"
3163
  msgstr ""
3164
 
3165
- #: defaults.php:133
3166
  msgid ""
3167
  "Removed tag(s) from the post %PostTitle% %LineBreak% ID: %PostID% %LineBreak"
3168
  "% Type: %PostType% %LineBreak% Status: %PostStatus% %LineBreak% Removed "
3169
  "tag(s): %tag% %PostUrlIfPlublished% %LineBreak% %EditorLinkPost%"
3170
  msgstr ""
3171
 
3172
- #: defaults.php:134
3173
  msgid "User created new tag"
3174
  msgstr ""
3175
 
3176
- #: defaults.php:134
3177
  msgid ""
3178
  "Created the tag %TagName% %LineBreak% Slug: %Slug% %LineBreak% %TagLink%"
3179
  msgstr ""
3180
 
3181
- #: defaults.php:135
3182
  msgid "User deleted tag"
3183
  msgstr ""
3184
 
3185
- #: defaults.php:135
3186
  msgid "Deleted the tag %TagName% %LineBreak% Slug: %Slug%"
3187
  msgstr ""
3188
 
3189
- #: defaults.php:136
3190
  msgid "User renamed tag"
3191
  msgstr ""
3192
 
3193
- #: defaults.php:136
3194
  msgid ""
3195
  "Old name: %old_name% %LineBreak% New name: %new_name% %LineBreak% Slug: %Slug"
3196
  "% %LineBreak% %TagLink%"
3197
  msgstr ""
3198
 
3199
- #: defaults.php:137
3200
  msgid "User changed tag slug"
3201
  msgstr ""
3202
 
3203
- #: defaults.php:137
3204
  msgid ""
3205
  "Changed the slug of the tag %tag% %LineBreak% Previous slug: %old_slug% "
3206
  "%LineBreak% New slug: %new_slug% %LineBreak% %TagLink%"
3207
  msgstr ""
3208
 
3209
- #: defaults.php:138
3210
  msgid "User changed tag description"
3211
  msgstr ""
3212
 
3213
- #: defaults.php:138
3214
  msgid ""
3215
  "Changed the description of the tag %tag% %LineBreak% Slug: %Slug% %LineBreak"
3216
  "% Previous description: %old_desc% %LineBreak% New description: %new_desc% "
3217
  "%LineBreak% %TagLink%"
3218
  msgstr ""
3219
 
3220
- #: defaults.php:141
3221
  msgid "Categories"
3222
  msgstr ""
3223
 
3224
- #: defaults.php:142
3225
  msgid "User changed post category"
3226
  msgstr ""
3227
 
3228
- #: defaults.php:142
3229
  msgid ""
3230
  "Changed the category of the post %PostTitle% %LineBreak% ID: %PostID% "
3231
  "%LineBreak% Type: %PostType% %LineBreak% Status: %PostStatus% %LineBreak% "
@@ -3233,64 +3193,64 @@ msgid ""
3233
  "%NewCategories% %PostUrlIfPlublished% %LineBreak% %EditorLinkPost%"
3234
  msgstr ""
3235
 
3236
- #: defaults.php:143
3237
  msgid "User created new category"
3238
  msgstr ""
3239
 
3240
- #: defaults.php:143
3241
  msgid ""
3242
  "Created the category %CategoryName% %LineBreak% Slug: %Slug% %LineBreak% "
3243
  "%CategoryLink%"
3244
  msgstr ""
3245
 
3246
- #: defaults.php:144
3247
  msgid "User deleted category"
3248
  msgstr ""
3249
 
3250
- #: defaults.php:144
3251
  msgid "Deleted the category %CategoryName% %LineBreak% Slug: %Slug%"
3252
  msgstr ""
3253
 
3254
- #: defaults.php:145
3255
  msgid "Changed the parent of a category"
3256
  msgstr ""
3257
 
3258
- #: defaults.php:145
3259
  msgid ""
3260
  "Changed the parent of the category %CategoryName% %LineBreak% Slug: %Slug% "
3261
  "%LineBreak% Previous parent: %OldParent% %LineBreak% New parent: %NewParent% "
3262
  "%LineBreak% %CategoryLink%"
3263
  msgstr ""
3264
 
3265
- #: defaults.php:146
3266
  msgid "User changed category name"
3267
  msgstr ""
3268
 
3269
- #: defaults.php:146
3270
  msgid ""
3271
  "Previous name: %old_name% %LineBreak% New name: %new_name% %LineBreak% Slug: "
3272
  "%slug% %LineBreak% %cat_link%"
3273
  msgstr ""
3274
 
3275
- #: defaults.php:147
3276
  msgid "User changed category slug"
3277
  msgstr ""
3278
 
3279
- #: defaults.php:147
3280
  msgid ""
3281
  "Changed the slug of the category: %CategoryName% %LineBreak% Previous slug: "
3282
  "%old_slug% %LineBreak% New slug: %new_slug% %LineBreak% %cat_link%"
3283
  msgstr ""
3284
 
3285
- #: defaults.php:150
3286
  msgid "Custom Fields"
3287
  msgstr ""
3288
 
3289
- #: defaults.php:151
3290
  msgid "User created a custom field for a post"
3291
  msgstr ""
3292
 
3293
- #: defaults.php:151
3294
  msgid ""
3295
  "Created a new custom field called %MetaKey% in the post %PostTitle% "
3296
  "%LineBreak% Post ID: %PostID% %LineBreak% Post Type: %PostType% %LineBreak% "
@@ -3298,11 +3258,11 @@ msgid ""
3298
  "%PostUrlIfPlublished% %LineBreak% %EditorLinkPost% %LineBreak% %MetaLink%"
3299
  msgstr ""
3300
 
3301
- #: defaults.php:152
3302
  msgid "User updated a custom field value for a post"
3303
  msgstr ""
3304
 
3305
- #: defaults.php:152
3306
  msgid ""
3307
  "Modified the value of the custom field %MetaKey% in the post %PostTitle% "
3308
  "%LineBreak% Post ID: %PostID% %LineBreak% Post Type: %PostType% %LineBreak% "
@@ -3311,22 +3271,22 @@ msgid ""
3311
  "%PostUrlIfPlublished% %LineBreak% %EditorLinkPost% %LineBreak% %MetaLink%."
3312
  msgstr ""
3313
 
3314
- #: defaults.php:153
3315
  msgid "User deleted a custom field from a post"
3316
  msgstr ""
3317
 
3318
- #: defaults.php:153
3319
  msgid ""
3320
  "Deleted the custom field %MetaKey% from the post %PostTitle% %LineBreak% "
3321
  "Post ID: %PostID% %LineBreak% Post Type: %PostType% %LineBreak% Post Status: "
3322
  "%PostStatus% %PostUrlIfPlublished% %LineBreak% %EditorLinkPost%"
3323
  msgstr ""
3324
 
3325
- #: defaults.php:154
3326
  msgid "User updated a custom field name for a post"
3327
  msgstr ""
3328
 
3329
- #: defaults.php:154
3330
  msgid ""
3331
  "Old custom field name: %MetaKeyOld% %LineBreak% New custom field name: "
3332
  "%MetaKeyNew% %LineBreak% Post: %PostTitle% %LineBreak% Post ID: %PostID% "
@@ -3334,15 +3294,45 @@ msgid ""
3334
  "%PostUrlIfPlublished% %LineBreak% %EditorLinkPost%"
3335
  msgstr ""
3336
 
 
 
 
 
 
 
 
 
3337
  #: defaults.php:160
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
3338
  msgid "Comments"
3339
  msgstr ""
3340
 
3341
- #: defaults.php:161
3342
  msgid "User approved a comment"
3343
  msgstr ""
3344
 
3345
- #: defaults.php:161
3346
  msgid ""
3347
  "Approved the comment posted by %Author% on the post %PostTitle% %LineBreak% "
3348
  "Post ID: %PostID% %LineBreak% Post Type: %PostType% %LineBreak% Post Status: "
@@ -3350,11 +3340,11 @@ msgid ""
3350
  "%LineBreak% %CommentLink%"
3351
  msgstr ""
3352
 
3353
- #: defaults.php:162
3354
  msgid "User unapproved a comment"
3355
  msgstr ""
3356
 
3357
- #: defaults.php:162
3358
  msgid ""
3359
  "Unapproved the comment posted by %Author% on the post %PostTitle% %LineBreak"
3360
  "% Post ID: %PostID% %LineBreak% Post Type: %PostType% %LineBreak% Post "
@@ -3362,11 +3352,11 @@ msgid ""
3362
  "% %LineBreak% %CommentLink%"
3363
  msgstr ""
3364
 
3365
- #: defaults.php:163
3366
  msgid "User replied to a comment"
3367
  msgstr ""
3368
 
3369
- #: defaults.php:163
3370
  msgid ""
3371
  "Replied to the comment posted by %Author% on the post %PostTitle% %LineBreak"
3372
  "% Post ID: %PostID% %LineBreak% Post Type: %PostType% %LineBreak% Post "
@@ -3374,11 +3364,11 @@ msgid ""
3374
  "% %LineBreak% %CommentLink%"
3375
  msgstr ""
3376
 
3377
- #: defaults.php:164
3378
  msgid "User edited a comment"
3379
  msgstr ""
3380
 
3381
- #: defaults.php:164
3382
  msgid ""
3383
  "Edited the comment posted by %Author% on the post %PostTitle% %LineBreak% "
3384
  "Post ID: %PostID% %LineBreak% Post Type: %PostType% %LineBreak% Post Status: "
@@ -3386,11 +3376,11 @@ msgid ""
3386
  "%LineBreak% %CommentLink%"
3387
  msgstr ""
3388
 
3389
- #: defaults.php:165
3390
  msgid "User marked a comment as Spam"
3391
  msgstr ""
3392
 
3393
- #: defaults.php:165
3394
  msgid ""
3395
  "Marked the comment posted by %Author% on the post %PostTitle% as spam "
3396
  "%LineBreak% Post ID: %PostID% %LineBreak% Post Type: %PostType% %LineBreak% "
@@ -3398,11 +3388,11 @@ msgid ""
3398
  "%PostUrlIfPlublished% %LineBreak% %CommentLink%"
3399
  msgstr ""
3400
 
3401
- #: defaults.php:166
3402
  msgid "User marked a comment as Not Spam"
3403
  msgstr ""
3404
 
3405
- #: defaults.php:166
3406
  msgid ""
3407
  "Marked the comment posted by %Author% on the post %PostTitle% as not spam "
3408
  "%LineBreak% Post ID: %PostID% %LineBreak% Post Type: %PostType% %LineBreak% "
@@ -3410,11 +3400,11 @@ msgid ""
3410
  "%PostUrlIfPlublished% %LineBreak% %CommentLink%"
3411
  msgstr ""
3412
 
3413
- #: defaults.php:167
3414
  msgid "User moved a comment to trash"
3415
  msgstr ""
3416
 
3417
- #: defaults.php:167
3418
  msgid ""
3419
  "Moved the comment posted by %Author% on the post %PostTitle% to trash "
3420
  "%LineBreak% Post ID: %PostID% %LineBreak% Post Type: %PostType% %LineBreak% "
@@ -3422,11 +3412,11 @@ msgid ""
3422
  "%PostUrlIfPlublished% %LineBreak% %CommentLink%"
3423
  msgstr ""
3424
 
3425
- #: defaults.php:168
3426
  msgid "User restored a comment from the trash"
3427
  msgstr ""
3428
 
3429
- #: defaults.php:168
3430
  msgid ""
3431
  "Restored the comment posted by %Author% on the post %PostTitle% from trash "
3432
  "%LineBreak% Post ID: %PostID% %LineBreak% Post Type: %PostType% %LineBreak% "
@@ -3434,11 +3424,11 @@ msgid ""
3434
  "%PostUrlIfPlublished% %LineBreak% %CommentLink%"
3435
  msgstr ""
3436
 
3437
- #: defaults.php:169
3438
  msgid "User permanently deleted a comment"
3439
  msgstr ""
3440
 
3441
- #: defaults.php:169
3442
  msgid ""
3443
  "Permanently deleted the comment posted by %Author% on the post %PostTitle% "
3444
  "%LineBreak% Post ID: %PostID% %LineBreak% Post Type: %PostType% %LineBreak% "
@@ -3446,11 +3436,11 @@ msgid ""
3446
  "%CommentID%"
3447
  msgstr ""
3448
 
3449
- #: defaults.php:170
3450
  msgid "User posted a comment"
3451
  msgstr ""
3452
 
3453
- #: defaults.php:170 defaults.php:175
3454
  msgid ""
3455
  "Posted a comment on the post %PostTitle% %LineBreak% Post ID: %PostID% "
3456
  "%LineBreak% Post Type: %PostType% %LineBreak% Post Status: %PostStatus% "
@@ -3458,755 +3448,755 @@ msgid ""
3458
  "%CommentLink%"
3459
  msgstr ""
3460
 
3461
- #: defaults.php:175
3462
  msgid "Visitor posted a comment"
3463
  msgstr ""
3464
 
3465
- #: defaults.php:181
3466
  msgid "Widgets"
3467
  msgstr ""
3468
 
3469
- #: defaults.php:182
3470
  msgid "User added a new widget"
3471
  msgstr ""
3472
 
3473
- #: defaults.php:182
3474
  msgid "Added a new %WidgetName% widget in %Sidebar%."
3475
  msgstr ""
3476
 
3477
- #: defaults.php:183
3478
  msgid "User modified a widget"
3479
  msgstr ""
3480
 
3481
- #: defaults.php:183
3482
  msgid "Modified the %WidgetName% widget in %Sidebar%."
3483
  msgstr ""
3484
 
3485
- #: defaults.php:184
3486
  msgid "User deleted widget"
3487
  msgstr ""
3488
 
3489
- #: defaults.php:184
3490
  msgid "Deleted the %WidgetName% widget from %Sidebar%."
3491
  msgstr ""
3492
 
3493
- #: defaults.php:185
3494
  msgid "User moved widget"
3495
  msgstr ""
3496
 
3497
- #: defaults.php:185
3498
  msgid ""
3499
  "Moved the %WidgetName% widget %LineBreak% From: %OldSidebar% %LineBreak% To: "
3500
  "%NewSidebar%"
3501
  msgstr ""
3502
 
3503
- #: defaults.php:186
3504
  msgid "User changed widget position"
3505
  msgstr ""
3506
 
3507
- #: defaults.php:186
3508
  msgid "Changed the position of the %WidgetName% widget in %Sidebar%."
3509
  msgstr ""
3510
 
3511
- #: defaults.php:192
3512
  msgid "Menus"
3513
  msgstr ""
3514
 
3515
- #: defaults.php:193
3516
  msgid "User created new menu"
3517
  msgstr ""
3518
 
3519
- #: defaults.php:193
3520
  msgid "New menu called %MenuName%."
3521
  msgstr ""
3522
 
3523
- #: defaults.php:194
3524
  msgid "User added content to a menu"
3525
  msgstr ""
3526
 
3527
- #: defaults.php:194
3528
  msgid ""
3529
  "Added new item to the menu %MenuName% %LineBreak% Item type: %ContentType% "
3530
  "%LineBreak% Item name: %ContentName% "
3531
  msgstr ""
3532
 
3533
- #: defaults.php:195
3534
  msgid "User removed content from a menu"
3535
  msgstr ""
3536
 
3537
- #: defaults.php:195
3538
  msgid ""
3539
  "Removed item from the menu %MenuName% %LineBreak% Item type: %ContentType% "
3540
  "%LineBreak% Item name: %ContentName%"
3541
  msgstr ""
3542
 
3543
- #: defaults.php:196
3544
  msgid "User deleted menu"
3545
  msgstr ""
3546
 
3547
- #: defaults.php:196
3548
  msgid "Deleted the menu %MenuName%"
3549
  msgstr ""
3550
 
3551
- #: defaults.php:197
3552
  msgid "User changed menu setting"
3553
  msgstr ""
3554
 
3555
- #: defaults.php:197
3556
  msgid "The setting in the %MenuName% %LineBreak% Setting: %MenuSetting%"
3557
  msgstr ""
3558
 
3559
- #: defaults.php:198
3560
  msgid "User modified content in a menu"
3561
  msgstr ""
3562
 
3563
- #: defaults.php:198
3564
  msgid ""
3565
  "Modified an item in the menu %MenuName% %LineBreak% Item type: %ContentType% "
3566
  "%LineBreak% Item name: %ContentName%"
3567
  msgstr ""
3568
 
3569
- #: defaults.php:199
3570
  msgid "User changed name of a menu"
3571
  msgstr ""
3572
 
3573
- #: defaults.php:199
3574
  msgid "Old name: %OldMenuName% %LineBreak% New name: %NewMenuName%"
3575
  msgstr ""
3576
 
3577
- #: defaults.php:200
3578
  msgid "User changed order of the objects in a menu"
3579
  msgstr ""
3580
 
3581
- #: defaults.php:200
3582
  msgid "Changed the order of the items in the menu %MenuName%"
3583
  msgstr ""
3584
 
3585
- #: defaults.php:201
3586
  msgid "User moved objects as a sub-item"
3587
  msgstr ""
3588
 
3589
- #: defaults.php:201
3590
  msgid ""
3591
  "Menu name: %MenuName% %LineBreak% Moved item %ItemName% as a sub-item of "
3592
  "%ParentName%"
3593
  msgstr ""
3594
 
3595
- #: defaults.php:213
3596
  msgid "User modified a draft blog post"
3597
  msgstr ""
3598
 
3599
- #: defaults.php:213
3600
  msgid "Modified the draft post with the %PostTitle%. %EditorLinkPost%."
3601
  msgstr ""
3602
 
3603
- #: defaults.php:214
3604
  msgid "User created a new post with custom post type and saved it as draft"
3605
  msgstr ""
3606
 
3607
- #: defaults.php:214
3608
  msgid ""
3609
  "Created a new custom post called %PostTitle% of type %PostType%. "
3610
  "%EditorLinkPost%."
3611
  msgstr ""
3612
 
3613
- #: defaults.php:215
3614
  msgid "User published a post with custom post type"
3615
  msgstr ""
3616
 
3617
- #: defaults.php:215
3618
  msgid ""
3619
  "Published a custom post %PostTitle% of type %PostType%. Post URL is %PostUrl"
3620
  "%. %EditorLinkPost%."
3621
  msgstr ""
3622
 
3623
- #: defaults.php:216
3624
  msgid "User modified a post with custom post type"
3625
  msgstr ""
3626
 
3627
- #: defaults.php:216
3628
  msgid ""
3629
  "Modified the custom post %PostTitle% of type %PostType%. Post URL is %PostUrl"
3630
  "%. %EditorLinkPost%."
3631
  msgstr ""
3632
 
3633
- #: defaults.php:217
3634
  msgid "User modified a draft post with custom post type"
3635
  msgstr ""
3636
 
3637
- #: defaults.php:217
3638
  msgid ""
3639
  "Modified the draft custom post %PostTitle% of type is %PostType%. "
3640
  "%EditorLinkPost%."
3641
  msgstr ""
3642
 
3643
- #: defaults.php:218
3644
  msgid "User permanently deleted post with custom post type"
3645
  msgstr ""
3646
 
3647
- #: defaults.php:218
3648
  msgid "Permanently Deleted the custom post %PostTitle% of type %PostType%."
3649
  msgstr ""
3650
 
3651
- #: defaults.php:219
3652
  msgid "User moved post with custom post type to trash"
3653
  msgstr ""
3654
 
3655
- #: defaults.php:219
3656
  msgid ""
3657
  "Moved the custom post %PostTitle% of type %PostType% to trash. Post URL was "
3658
  "%PostUrl%."
3659
  msgstr ""
3660
 
3661
- #: defaults.php:220
3662
  msgid "User restored post with custom post type from trash"
3663
  msgstr ""
3664
 
3665
- #: defaults.php:220
3666
  msgid ""
3667
  "The custom post %PostTitle% of type %PostType% has been restored from trash. "
3668
  "%EditorLinkPost%."
3669
  msgstr ""
3670
 
3671
- #: defaults.php:221
3672
  msgid "User changed the category of a post with custom post type"
3673
  msgstr ""
3674
 
3675
- #: defaults.php:221
3676
  msgid ""
3677
  "Changed the category(ies) of the custom post %PostTitle% of type %PostType% "
3678
  "from %OldCategories% to %NewCategories%. %EditorLinkPost%."
3679
  msgstr ""
3680
 
3681
- #: defaults.php:222
3682
  msgid "User changed the URL of a post with custom post type"
3683
  msgstr ""
3684
 
3685
- #: defaults.php:222
3686
  msgid ""
3687
  "Changed the URL of the custom post %PostTitle% of type %PostType% from "
3688
  "%OldUrl% to %NewUrl%. %EditorLinkPost%."
3689
  msgstr ""
3690
 
3691
- #: defaults.php:223
3692
  msgid "User changed the author or post with custom post type"
3693
  msgstr ""
3694
 
3695
- #: defaults.php:223
3696
  msgid ""
3697
  "Changed the author of custom post %PostTitle% of type %PostType% from "
3698
  "%OldAuthor% to %NewAuthor%. %EditorLinkPost%."
3699
  msgstr ""
3700
 
3701
- #: defaults.php:224
3702
  msgid "User changed the status of post with custom post type"
3703
  msgstr ""
3704
 
3705
- #: defaults.php:224
3706
  msgid ""
3707
  "Changed the status of custom post %PostTitle% of type %PostType% from "
3708
  "%OldStatus% to %NewStatus%. %EditorLinkPost%."
3709
  msgstr ""
3710
 
3711
- #: defaults.php:225
3712
  msgid "User changed the visibility of a post with custom post type"
3713
  msgstr ""
3714
 
3715
- #: defaults.php:225
3716
  msgid ""
3717
  "Changed the visibility of the custom post %PostTitle% of type %PostType% "
3718
  "from %OldVisibility% to %NewVisibility%. %EditorLinkPost%."
3719
  msgstr ""
3720
 
3721
- #: defaults.php:226
3722
  msgid "User changed the date of post with custom post type"
3723
  msgstr ""
3724
 
3725
- #: defaults.php:226
3726
  msgid ""
3727
  "Changed the date of the custom post %PostTitle% of type %PostType% from "
3728
  "%OldDate% to %NewDate%. %EditorLinkPost%."
3729
  msgstr ""
3730
 
3731
- #: defaults.php:227
3732
  msgid "User created a custom field for a custom post type"
3733
  msgstr ""
3734
 
3735
- #: defaults.php:227
3736
  msgid ""
3737
  "Created a new custom field %MetaKey% with value %MetaValue% in custom post "
3738
  "%PostTitle% of type %PostType%. %EditorLinkPost%.<br>%MetaLink%."
3739
  msgstr ""
3740
 
3741
- #: defaults.php:228
3742
  msgid "User updated a custom field for a custom post type"
3743
  msgstr ""
3744
 
3745
- #: defaults.php:228
3746
  msgid ""
3747
  "Modified the value of the custom field %MetaKey% from %MetaValueOld% to "
3748
  "%MetaValueNew% in custom post %PostTitle% of type %PostType% %EditorLinkPost"
3749
  "%.<br>%MetaLink%."
3750
  msgstr ""
3751
 
3752
- #: defaults.php:229
3753
  msgid "User deleted a custom field from a custom post type"
3754
  msgstr ""
3755
 
3756
- #: defaults.php:229
3757
  msgid ""
3758
  "Deleted the custom field %MetaKey% with id %MetaID% from custom post "
3759
  "%PostTitle% of type %PostType% %EditorLinkPost%.<br>%MetaLink%."
3760
  msgstr ""
3761
 
3762
- #: defaults.php:230
3763
  msgid "User updated a custom field name for a custom post type"
3764
  msgstr ""
3765
 
3766
- #: defaults.php:230
3767
  msgid ""
3768
  "Changed the custom field name from %MetaKeyOld% to %MetaKeyNew% in custom "
3769
  "post %PostTitle% of type %PostType% %EditorLinkPost%.<br>%MetaLink%."
3770
  msgstr ""
3771
 
3772
- #: defaults.php:231
3773
  msgid "User modified content for a published custom post type"
3774
  msgstr ""
3775
 
3776
- #: defaults.php:231
3777
  msgid ""
3778
  "Modified the content of the published custom post type %PostTitle%. Post URL "
3779
  "is %PostUrl%.%EditorLinkPost%."
3780
  msgstr ""
3781
 
3782
- #: defaults.php:232
3783
  msgid "User modified content for a draft post"
3784
  msgstr ""
3785
 
3786
- #: defaults.php:232
3787
  msgid ""
3788
  "Modified the content of the draft post %PostTitle%.%RevisionLink% "
3789
  "%EditorLinkPost%."
3790
  msgstr ""
3791
 
3792
- #: defaults.php:233
3793
  msgid "User modified content for a draft custom post type"
3794
  msgstr ""
3795
 
3796
- #: defaults.php:233
3797
  msgid ""
3798
  "Modified the content of the draft custom post type %PostTitle%."
3799
  "%EditorLinkPost%."
3800
  msgstr ""
3801
 
3802
- #: defaults.php:234
3803
  msgid "User modified content of a post"
3804
  msgstr ""
3805
 
3806
- #: defaults.php:234
3807
  msgid ""
3808
  "Modified the content of post %PostTitle% which is submitted for review."
3809
  "%RevisionLink% %EditorLinkPost%."
3810
  msgstr ""
3811
 
3812
- #: defaults.php:235
3813
  msgid "User scheduled a custom post type"
3814
  msgstr ""
3815
 
3816
- #: defaults.php:235
3817
  msgid ""
3818
  "Scheduled the custom post type %PostTitle% to be published %PublishingDate%. "
3819
  "%EditorLinkPost%."
3820
  msgstr ""
3821
 
3822
- #: defaults.php:236
3823
  msgid "User changed title of a custom post type"
3824
  msgstr ""
3825
 
3826
- #: defaults.php:236
3827
  msgid ""
3828
  "Changed the title of the custom post %OldTitle% to %NewTitle%. "
3829
  "%EditorLinkPost%."
3830
  msgstr ""
3831
 
3832
- #: defaults.php:237
3833
  msgid "User opened a custom post type in the editor"
3834
  msgstr ""
3835
 
3836
- #: defaults.php:237
3837
  msgid ""
3838
  "Opened the custom post %PostTitle% of type %PostType% in the editor. View "
3839
  "the post: %EditorLinkPost%."
3840
  msgstr ""
3841
 
3842
- #: defaults.php:238
3843
  msgid "User viewed a custom post type"
3844
  msgstr ""
3845
 
3846
- #: defaults.php:238
3847
  msgid ""
3848
  "Viewed the custom post %PostTitle% of type %PostType%. View the post: "
3849
  "%PostUrl%."
3850
  msgstr ""
3851
 
3852
- #: defaults.php:239
3853
  msgid "A plugin created a custom post"
3854
  msgstr ""
3855
 
3856
- #: defaults.php:239
3857
  msgid "A plugin automatically created the following custom post: %PostTitle%."
3858
  msgstr ""
3859
 
3860
- #: defaults.php:240
3861
  msgid "A plugin deleted a custom post"
3862
  msgstr ""
3863
 
3864
- #: defaults.php:240
3865
  msgid "A plugin automatically deleted the following custom post: %PostTitle%."
3866
  msgstr ""
3867
 
3868
- #: defaults.php:241
3869
  msgid "A plugin modified a custom post"
3870
  msgstr ""
3871
 
3872
- #: defaults.php:241
3873
  msgid ""
3874
  "Plugin modified the custom post %PostTitle%. View the post: %EditorLinkPost%."
3875
  msgstr ""
3876
 
3877
- #: defaults.php:253
3878
  msgid "User created a new WordPress page and saved it as draft"
3879
  msgstr ""
3880
 
3881
- #: defaults.php:253
3882
  msgid ""
3883
  "Created a new page called %PostTitle% and saved it as draft. %EditorLinkPage"
3884
  "%."
3885
  msgstr ""
3886
 
3887
- #: defaults.php:254
3888
  msgid "User published a WordPress page"
3889
  msgstr ""
3890
 
3891
- #: defaults.php:254
3892
  msgid ""
3893
  "Published a page called %PostTitle%. Page URL is %PostUrl%. %EditorLinkPage%."
3894
  msgstr ""
3895
 
3896
- #: defaults.php:255
3897
  msgid "User modified a published WordPress page"
3898
  msgstr ""
3899
 
3900
- #: defaults.php:255
3901
  msgid ""
3902
  "Modified the published page %PostTitle%. Page URL is %PostUrl%. "
3903
  "%EditorLinkPage%."
3904
  msgstr ""
3905
 
3906
- #: defaults.php:256
3907
  msgid "User modified a draft WordPress page"
3908
  msgstr ""
3909
 
3910
- #: defaults.php:256
3911
  msgid ""
3912
  "Modified the draft page %PostTitle%. Page ID is %PostID%. %EditorLinkPage%."
3913
  msgstr ""
3914
 
3915
- #: defaults.php:257
3916
  msgid "User permanently deleted a page from the trash"
3917
  msgstr ""
3918
 
3919
- #: defaults.php:257
3920
  msgid "Permanently deleted the page %PostTitle%."
3921
  msgstr ""
3922
 
3923
- #: defaults.php:258
3924
  msgid "User moved WordPress page to the trash"
3925
  msgstr ""
3926
 
3927
- #: defaults.php:258
3928
  msgid "Moved the page %PostTitle% to trash. Page URL was %PostUrl%."
3929
  msgstr ""
3930
 
3931
- #: defaults.php:259
3932
  msgid "User restored a WordPress page from trash"
3933
  msgstr ""
3934
 
3935
- #: defaults.php:259
3936
  msgid "Page %PostTitle% has been restored from trash. %EditorLinkPage%."
3937
  msgstr ""
3938
 
3939
- #: defaults.php:260
3940
  msgid "User changed page URL"
3941
  msgstr ""
3942
 
3943
- #: defaults.php:260
3944
  msgid ""
3945
  "Changed the URL of the page %PostTitle% from %OldUrl% to %NewUrl%. "
3946
  "%EditorLinkPage%."
3947
  msgstr ""
3948
 
3949
- #: defaults.php:261
3950
  msgid "User changed page author"
3951
  msgstr ""
3952
 
3953
- #: defaults.php:261
3954
  msgid ""
3955
  "Changed the author of the page %PostTitle% from %OldAuthor% to %NewAuthor%. "
3956
  "%EditorLinkPage%."
3957
  msgstr ""
3958
 
3959
- #: defaults.php:262
3960
  msgid "User changed page status"
3961
  msgstr ""
3962
 
3963
- #: defaults.php:262
3964
  msgid ""
3965
  "Changed the status of the page %PostTitle% from %OldStatus% to %NewStatus%. "
3966
  "%EditorLinkPage%."
3967
  msgstr ""
3968
 
3969
- #: defaults.php:263
3970
  msgid "User changed the visibility of a page post"
3971
  msgstr ""
3972
 
3973
- #: defaults.php:263
3974
  msgid ""
3975
  "Changed the visibility of the page %PostTitle% from %OldVisibility% to "
3976
  "%NewVisibility%. %EditorLinkPage%."
3977
  msgstr ""
3978
 
3979
- #: defaults.php:264
3980
  msgid "User changed the date of a page post"
3981
  msgstr ""
3982
 
3983
- #: defaults.php:264
3984
  msgid ""
3985
  "Changed the date of the page %PostTitle% from %OldDate% to %NewDate%. "
3986
  "%EditorLinkPage%."
3987
  msgstr ""
3988
 
3989
- #: defaults.php:265
3990
  msgid "User created a custom field for a page"
3991
  msgstr ""
3992
 
3993
- #: defaults.php:265
3994
  msgid ""
3995
  "Created a new custom field called %MetaKey% with value %MetaValue% in the "
3996
  "page %PostTitle% %EditorLinkPage%.<br>%MetaLink%."
3997
  msgstr ""
3998
 
3999
- #: defaults.php:266
4000
  msgid "User updated a custom field value for a page"
4001
  msgstr ""
4002
 
4003
- #: defaults.php:266
4004
  msgid ""
4005
  "Modified the value of the custom field %MetaKey% from %MetaValueOld% to "
4006
  "%MetaValueNew% in the page %PostTitle% %EditorLinkPage%.<br>%MetaLink%."
4007
  msgstr ""
4008
 
4009
- #: defaults.php:267
4010
  msgid "User deleted a custom field from a page"
4011
  msgstr ""
4012
 
4013
- #: defaults.php:267
4014
  msgid ""
4015
  "Deleted the custom field %MetaKey% with id %MetaID% from page %PostTitle% "
4016
  "%EditorLinkPage%.<br>%MetaLink%."
4017
  msgstr ""
4018
 
4019
- #: defaults.php:268
4020
  msgid "User updated a custom field name for a page"
4021
  msgstr ""
4022
 
4023
- #: defaults.php:268
4024
  msgid ""
4025
  "Changed the custom field name from %MetaKeyOld% to %MetaKeyNew% in the page "
4026
  "%PostTitle% %EditorLinkPage%.<br>%MetaLink%."
4027
  msgstr ""
4028
 
4029
- #: defaults.php:269
4030
  msgid "User modified content for a published page"
4031
  msgstr ""
4032
 
4033
- #: defaults.php:269
4034
  msgid ""
4035
  "Modified the content of the published page %PostTitle%. Page URL is %PostUrl"
4036
  "%. %RevisionLink% %EditorLinkPage%."
4037
  msgstr ""
4038
 
4039
- #: defaults.php:270
4040
  msgid "User modified content for a draft page"
4041
  msgstr ""
4042
 
4043
- #: defaults.php:270
4044
  msgid ""
4045
  "Modified the content of draft page %PostTitle%.%RevisionLink% %EditorLinkPage"
4046
  "%."
4047
  msgstr ""
4048
 
4049
- #: defaults.php:271
4050
  msgid "User scheduled a page"
4051
  msgstr ""
4052
 
4053
- #: defaults.php:271
4054
  msgid ""
4055
  "Scheduled the page %PostTitle% to be published %PublishingDate%. "
4056
  "%EditorLinkPage%."
4057
  msgstr ""
4058
 
4059
- #: defaults.php:272
4060
  msgid "User changed title of a page"
4061
  msgstr ""
4062
 
4063
- #: defaults.php:272
4064
  msgid ""
4065
  "Changed the title of the page %OldTitle% to %NewTitle%. %EditorLinkPage%."
4066
  msgstr ""
4067
 
4068
- #: defaults.php:273
4069
  msgid "User opened a page in the editor"
4070
  msgstr ""
4071
 
4072
- #: defaults.php:273
4073
  msgid ""
4074
  "Opened the page %PostTitle% in the editor. View the page: %EditorLinkPage%."
4075
  msgstr ""
4076
 
4077
- #: defaults.php:274
4078
  msgid "User viewed a page"
4079
  msgstr ""
4080
 
4081
- #: defaults.php:274
4082
  msgid "Viewed the page %PostTitle%. View the page: %PostUrl%."
4083
  msgstr ""
4084
 
4085
- #: defaults.php:275
4086
  msgid "User disabled Comments/Trackbacks and Pingbacks on a draft post"
4087
  msgstr ""
4088
 
4089
- #: defaults.php:275
4090
  msgid ""
4091
  "Disabled %Type% on the draft post %PostTitle%. View the post: %PostUrl%."
4092
  msgstr ""
4093
 
4094
- #: defaults.php:276
4095
  msgid "User enabled Comments/Trackbacks and Pingbacks on a draft post"
4096
  msgstr ""
4097
 
4098
- #: defaults.php:276
4099
  msgid "Enabled %Type% on the draft post %PostTitle%. View the post: %PostUrl%."
4100
  msgstr ""
4101
 
4102
- #: defaults.php:277
4103
  msgid "User disabled Comments/Trackbacks and Pingbacks on a published page"
4104
  msgstr ""
4105
 
4106
- #: defaults.php:277
4107
  msgid ""
4108
  "Disabled %Type% on the published page %PostTitle%. View the page: %PostUrl%."
4109
  msgstr ""
4110
 
4111
- #: defaults.php:278
4112
  msgid "User enabled Comments/Trackbacks and Pingbacks on a published page"
4113
  msgstr ""
4114
 
4115
- #: defaults.php:278
4116
  msgid ""
4117
  "Enabled %Type% on the published page %PostTitle%. View the page: %PostUrl%."
4118
  msgstr ""
4119
 
4120
- #: defaults.php:279
4121
  msgid "User disabled Comments/Trackbacks and Pingbacks on a draft page"
4122
  msgstr ""
4123
 
4124
- #: defaults.php:279
4125
  msgid ""
4126
  "Disabled %Type% on the draft page %PostTitle%. View the page: %PostUrl%."
4127
  msgstr ""
4128
 
4129
- #: defaults.php:280
4130
  msgid "User enabled Comments/Trackbacks and Pingbacks on a draft page"
4131
  msgstr ""
4132
 
4133
- #: defaults.php:280
4134
  msgid "Enabled %Type% on the draft page %PostTitle%. View the page: %PostUrl%."
4135
  msgstr ""
4136
 
4137
- #: defaults.php:281
4138
  msgid "A plugin created a page"
4139
  msgstr ""
4140
 
4141
- #: defaults.php:281
4142
  msgid "A plugin automatically created the following page: %PostTitle%."
4143
  msgstr ""
4144
 
4145
- #: defaults.php:282
4146
  msgid "A plugin deleted a page"
4147
  msgstr ""
4148
 
4149
- #: defaults.php:282
4150
  msgid "A plugin automatically deleted the following page: %PostTitle%."
4151
  msgstr ""
4152
 
4153
- #: defaults.php:283
4154
  msgid "A plugin modified a page"
4155
  msgstr ""
4156
 
4157
- #: defaults.php:283
4158
  msgid "Plugin modified the page %PostTitle%. View the page: %EditorLinkPage%."
4159
  msgstr ""
4160
 
4161
- #: defaults.php:287
4162
  msgid "User Accounts"
4163
  msgstr ""
4164
 
4165
- #: defaults.php:288
4166
  msgid "User Profiles"
4167
  msgstr ""
4168
 
4169
- #: defaults.php:289
4170
  msgid "New user was created on WordPress"
4171
  msgstr ""
4172
 
4173
- #: defaults.php:289 defaults.php:290
4174
  msgid ""
4175
  "New user: %NewUserData->Username% %LineBreak% Role: %NewUserData->Roles% "
4176
  "%LineBreak% First name: %NewUserData->FirstName% %LineBreak% Last name: "
4177
  "%NewUserData->LastName% %LineBreak% %EditUserLink%"
4178
  msgstr ""
4179
 
4180
- #: defaults.php:290
4181
  msgid "User created another WordPress user"
4182
  msgstr ""
4183
 
4184
- #: defaults.php:291
4185
  msgid "The role of a user was changed by another WordPress user"
4186
  msgstr ""
4187
 
4188
- #: defaults.php:291
4189
  msgid ""
4190
  "Changed the role of the user %TargetUsername% %LineBreak% New role: %NewRole"
4191
  "% %LineBreak% Previous role: %OldRole% %LineBreak% First name: %FirstName% "
4192
  "%LineBreak% Last name: %LastName% %LineBreak% %EditUserLink%"
4193
  msgstr ""
4194
 
4195
- #: defaults.php:292
4196
  msgid "User has changed his or her password"
4197
  msgstr ""
4198
 
4199
- #: defaults.php:292
4200
  msgid ""
4201
  "Changed the password %LineBreak% First name: %TargetUserData->FirstName% "
4202
  "%LineBreak% Last name: %TargetUserData->LastName% %LineBreak% %EditUserLink%"
4203
  msgstr ""
4204
 
4205
- #: defaults.php:293
4206
  msgid "User changed another user's password"
4207
  msgstr ""
4208
 
4209
- #: defaults.php:293
4210
  msgid ""
4211
  "Changed the password of the user %TargetUserData->Username% %LineBreak% "
4212
  "Role: %TargetUserData->Roles% %LineBreak% First name: %TargetUserData-"
@@ -4214,22 +4204,22 @@ msgid ""
4214
  "%EditUserLink%"
4215
  msgstr ""
4216
 
4217
- #: defaults.php:294
4218
  msgid "User changed his or her email address"
4219
  msgstr ""
4220
 
4221
- #: defaults.php:294
4222
  msgid ""
4223
  "Changed the email address to %NewEmail% %LineBreak% Role: %Roles% %LineBreak"
4224
  "% First name: %FirstName% %LineBreak% Last name: %LastName% %LineBreak% "
4225
  "%EditUserLink%"
4226
  msgstr ""
4227
 
4228
- #: defaults.php:295
4229
  msgid "User changed another user's email address"
4230
  msgstr ""
4231
 
4232
- #: defaults.php:295
4233
  msgid ""
4234
  "Changed the email address of the user %TargetUsername% %LineBreak% New email "
4235
  "address: %NewEmail% %LineBreak% Previous email address: %OldEmail% %LineBreak"
@@ -4237,33 +4227,33 @@ msgid ""
4237
  "%LastName% %LineBreak% %EditUserLink%"
4238
  msgstr ""
4239
 
4240
- #: defaults.php:296
4241
  msgid "User was deleted by another user"
4242
  msgstr ""
4243
 
4244
- #: defaults.php:296
4245
  msgid ""
4246
  "User: %TargetUserData->Username% %LineBreak% Role: %TargetUserData->Roles% "
4247
  "%LineBreak% First name: %NewUserData->FirstName% %LineBreak% Last name: "
4248
  "%NewUserData->LastName%"
4249
  msgstr ""
4250
 
4251
- #: defaults.php:297
4252
  msgid "User opened the profile page of another user"
4253
  msgstr ""
4254
 
4255
- #: defaults.php:297
4256
  msgid ""
4257
  "The profile page of the user %TargetUsername% %LineBreak% Role: %Roles% "
4258
  "%LineBreak% First name: %FirstName% %LineBreak% Last name: %LastName% "
4259
  "%LineBreak% %EditUserLink%"
4260
  msgstr ""
4261
 
4262
- #: defaults.php:298
4263
  msgid "User updated a custom field value for a user"
4264
  msgstr ""
4265
 
4266
- #: defaults.php:298
4267
  msgid ""
4268
  "Changed the value of a custom field in the user profile %TargetUsername% "
4269
  "%LineBreak% Custom field: %custom_field_name% %LineBreak% Previous value: "
@@ -4272,11 +4262,11 @@ msgid ""
4272
  "%LineBreak% %EditUserLink%"
4273
  msgstr ""
4274
 
4275
- #: defaults.php:299
4276
  msgid "User created a custom field value for a user"
4277
  msgstr ""
4278
 
4279
- #: defaults.php:299
4280
  msgid ""
4281
  "Created a new custom field in the user profile %TargetUsername% %LineBreak% "
4282
  "Custom field: %custom_field_name% %LineBreak% Custom field value: %new_value"
@@ -4284,33 +4274,33 @@ msgid ""
4284
  "Last name: %LastName% %LineBreak% %EditUserLink%"
4285
  msgstr ""
4286
 
4287
- #: defaults.php:300
4288
  msgid "User changed first name for a user"
4289
  msgstr ""
4290
 
4291
- #: defaults.php:300
4292
  msgid ""
4293
  "Changed the first name of the user %TargetUsername% %LineBreak% Previous "
4294
  "name: %old_firstname% %LineBreak% New name: %new_firstname% %LineBreak% "
4295
  "Role: %Roles% %LineBreak% Last name: %LastName% %LineBreak% %EditUserLink%"
4296
  msgstr ""
4297
 
4298
- #: defaults.php:301
4299
  msgid "User changed last name for a user"
4300
  msgstr ""
4301
 
4302
- #: defaults.php:301
4303
  msgid ""
4304
  "Changed the last name of the user %TargetUsername% %LineBreak% Previous last "
4305
  "name: %old_lastname% %LineBreak% New last name: %new_lastname% %LineBreak% "
4306
  "Role: %Roles% %LineBreak% First name: %FirstName% %LineBreak% %EditUserLink%"
4307
  msgstr ""
4308
 
4309
- #: defaults.php:302
4310
  msgid "User changed nickname for a user"
4311
  msgstr ""
4312
 
4313
- #: defaults.php:302
4314
  msgid ""
4315
  "Changed the nickname of the user %TargetUsername% %LineBreak% Previous "
4316
  "nickname: %old_nickname% New nickname: %new_nickname% %LineBreak% Role: "
@@ -4318,1623 +4308,650 @@ msgid ""
4318
  "% %LineBreak% %EditUserLink%"
4319
  msgstr ""
4320
 
4321
- #: defaults.php:303
4322
  msgid "User changed the display name for a user"
4323
  msgstr ""
4324
 
4325
- #: defaults.php:303
4326
  msgid ""
4327
  "Changed the display name of the user %TargetUsername% %LineBreak% Previous "
4328
- "display name: %old_displayname% New display name: %new_displayname% "
4329
- "%LineBreak% Role: %Roles% %LineBreak% First name: %FirstName% %LineBreak% "
4330
- "Last name: %LastName% %LineBreak% %EditUserLink%"
4331
  msgstr ""
4332
 
4333
- #: defaults.php:306
4334
  msgid "Multisite User Profiles"
4335
  msgstr ""
4336
 
4337
- #: defaults.php:307
4338
  msgid "User granted Super Admin privileges"
4339
  msgstr ""
4340
 
4341
- #: defaults.php:307
4342
  msgid ""
4343
  "Granted Super Admin privileges to %TargetUsername% %LineBreak% First name: "
4344
  "%FirstName% %LineBreak% Last name: %LastName% %LineBreak% %EditUserLink%"
4345
  msgstr ""
4346
 
4347
- #: defaults.php:308
4348
  msgid "User revoked from Super Admin privileges"
4349
  msgstr ""
4350
 
4351
- #: defaults.php:308
4352
  msgid ""
4353
  "Revoked Super Admin privileges from %TargetUsername% %LineBreak% First name: "
4354
  "%FirstName% %LineBreak% Last name: %LastName% %LineBreak% %EditUserLink%"
4355
  msgstr ""
4356
 
4357
- #: defaults.php:309
4358
  msgid "Existing user added to a site"
4359
  msgstr ""
4360
 
4361
- #: defaults.php:309
4362
  msgid ""
4363
  "Added user %TargetUsername% to site: %SiteName% %LineBreak% Role: "
4364
  "%TargetUserRole% %LineBreak% First name: %FirstName% %LineBreak% Last name: "
4365
  "%LastName% %LineBreak% %EditUserLink%"
4366
  msgstr ""
4367
 
4368
- #: defaults.php:310
4369
  msgid "User removed from site"
4370
  msgstr ""
4371
 
4372
- #: defaults.php:310
4373
  msgid ""
4374
  "Removed user %TargetUsername% from site: %SiteName% %LineBreak% Previous "
4375
  "role: %TargetUserRole% %LineBreak% First name: %FirstName% %LineBreak% Last "
4376
  "name: %LastName% %LineBreak% %EditUserLink%"
4377
  msgstr ""
4378
 
4379
- #: defaults.php:311
4380
  msgid "New network user created"
4381
  msgstr ""
4382
 
4383
- #: defaults.php:311
4384
  msgid ""
4385
  "Created a new network user %NewUserData->Username% %LineBreak% First name: "
4386
  "%NewUserData->FirstName% %LineBreak% Last name: %NewUserData->LastName% "
4387
  "%LineBreak% %EditUserLink%"
4388
  msgstr ""
4389
 
4390
- #: defaults.php:315
4391
  msgid "Plugins & Themes"
4392
  msgstr ""
4393
 
4394
- #: defaults.php:317
4395
  msgid "User installed a plugin"
4396
  msgstr ""
4397
 
4398
- #: defaults.php:317
4399
  msgid ""
4400
  "Name: %Plugin->Name% %LineBreak% Install location: %Plugin->plugin_dir_path%"
4401
  msgstr ""
4402
 
4403
- #: defaults.php:318
4404
  msgid "User activated a WordPress plugin"
4405
  msgstr ""
4406
 
4407
- #: defaults.php:318 defaults.php:319 defaults.php:320 defaults.php:321
4408
  msgid "Name: %PluginData->Name% %LineBreak% Install location: %PluginFile%"
4409
  msgstr ""
4410
 
4411
- #: defaults.php:319
4412
  msgid "User deactivated a WordPress plugin"
4413
  msgstr ""
4414
 
4415
- #: defaults.php:320
4416
  msgid "User uninstalled a plugin"
4417
  msgstr ""
4418
 
4419
- #: defaults.php:321
4420
  msgid "User upgraded a plugin"
4421
  msgstr ""
4422
 
4423
- #: defaults.php:322
4424
  msgid "Plugin created tables"
4425
  msgstr ""
4426
 
4427
- #: defaults.php:322
4428
  msgid ""
4429
- "Plugin created these tables in the database %LineBreak% Plugin: %Plugin->Name"
4430
- "% %LineBreak% Tables: %TableNames%"
4431
  msgstr ""
4432
 
4433
- #: defaults.php:323
4434
  msgid "Plugin modified tables structure"
4435
  msgstr ""
4436
 
4437
- #: defaults.php:323
4438
  msgid ""
4439
- "Plugin modified the structure of these database tables %LineBreak% Plugin: "
4440
- "%Plugin->Name% %LineBreak% Tables: %TableNames%"
4441
  msgstr ""
4442
 
4443
- #: defaults.php:324
4444
  msgid "Plugin deleted tables"
4445
  msgstr ""
4446
 
4447
- #: defaults.php:324
4448
  msgid ""
4449
- "Plugin deleted these tables from the database %LineBreak% Plugin: %Plugin-"
4450
- ">Name% %LineBreak% Tables: %TableNames%"
4451
  msgstr ""
4452
 
4453
- #: defaults.php:325
4454
  msgid "A plugin created a post"
4455
  msgstr ""
4456
 
4457
- #: defaults.php:325
4458
  msgid ""
4459
  "Plugin %PluginName% created the post %PostTitle% %LineBreak% Post ID: %PostID"
4460
  "% %LineBreak% Type: %PostType% %LineBreak% Status: %PostStatus% %LineBreak% "
4461
  "%EditorLinkPage%"
4462
  msgstr ""
4463
 
4464
- #: defaults.php:326
4465
  msgid "A plugin deleted a post"
4466
  msgstr ""
4467
 
4468
- #: defaults.php:326
4469
  msgid ""
4470
  "Plugin %PluginName% deleted the post %PostTitle% %LineBreak% Post ID: %PostID"
4471
  "% %LineBreak% Type: %PostType%"
4472
  msgstr ""
4473
 
4474
- #: defaults.php:327
4475
  msgid "User changed a file using the plugin editor"
4476
  msgstr ""
4477
 
4478
- #: defaults.php:327
4479
  msgid "Modified a file with the plugin editor %LineBreak% File: %File%"
4480
  msgstr ""
4481
 
4482
- #: defaults.php:330
4483
  msgid "Themes"
4484
  msgstr ""
4485
 
4486
- #: defaults.php:331
4487
  msgid "User installed a theme"
4488
  msgstr ""
4489
 
4490
- #: defaults.php:331
4491
  msgid ""
4492
  "Theme: \"%Theme->Name%\" %LineBreak% Install location: %Theme-"
4493
  ">get_template_directory%"
4494
  msgstr ""
4495
 
4496
- #: defaults.php:332
4497
  msgid "User activated a theme"
4498
  msgstr ""
4499
 
4500
- #: defaults.php:332 defaults.php:333
4501
  msgid ""
4502
  "Theme \"%Theme->Name%\" %LineBreak% Install location: %Theme-"
4503
  ">get_template_directory%"
4504
  msgstr ""
4505
 
4506
- #: defaults.php:333
4507
  msgid "User uninstalled a theme"
4508
  msgstr ""
4509
 
4510
- #: defaults.php:334
4511
  msgid "Theme created tables"
4512
  msgstr ""
4513
 
4514
- #: defaults.php:334
4515
  msgid ""
4516
  "Theme created these tables in the database %LineBreak% Theme: %Theme->Name% "
4517
  "%LineBreak% Tables: %TableNames%"
4518
  msgstr ""
4519
 
4520
- #: defaults.php:335
4521
  msgid "Theme modified tables structure"
4522
  msgstr ""
4523
 
4524
- #: defaults.php:335
4525
  msgid ""
4526
  "Theme modified the structure of these database tables %LineBreak% Theme: "
4527
  "%Theme->Name% %LineBreak% Tables: %TableNames%"
4528
  msgstr ""
4529
 
4530
- #: defaults.php:336
4531
  msgid "Theme deleted tables"
4532
  msgstr ""
4533
 
4534
- #: defaults.php:336
4535
  msgid ""
4536
  "Theme deleted these tables from the database %LineBreak% Theme: %Theme->Name"
4537
  "% %LineBreak% Tables: %TableNames%"
4538
  msgstr ""
4539
 
4540
- #: defaults.php:337
4541
  msgid "User updated a theme"
4542
  msgstr ""
4543
 
4544
- #: defaults.php:337
4545
  msgid ""
4546
  "Name: %Theme->Name% %LineBreak% Install location: %Theme-"
4547
  ">get_template_directory%"
4548
  msgstr ""
4549
 
4550
- #: defaults.php:338
4551
  msgid "User changed a file using the theme editor"
4552
  msgstr ""
4553
 
4554
- #: defaults.php:338
4555
  msgid "Modified a file with the theme editor %LineBreak% File: %Theme%/%File%"
4556
  msgstr ""
4557
 
4558
- #: defaults.php:341
4559
  msgid "Themes on Multisite"
4560
  msgstr ""
4561
 
4562
- #: defaults.php:342
4563
- msgid "Activated theme on network"
4564
- msgstr ""
4565
-
4566
- #: defaults.php:342
4567
- msgid ""
4568
- "Network activated the theme %Theme->Name% %LineBreak% Install location: "
4569
- "%Theme->get_template_directory%"
4570
- msgstr ""
4571
-
4572
- #: defaults.php:343
4573
- msgid "Deactivated theme from network"
4574
- msgstr ""
4575
-
4576
- #: defaults.php:343
4577
- msgid ""
4578
- "Network deactivated the theme %Theme->Name% %LineBreak% Install location: "
4579
- "%Theme->get_template_directory%"
4580
- msgstr ""
4581
-
4582
- #: defaults.php:346
4583
- msgid "Database Events"
4584
- msgstr ""
4585
-
4586
- #: defaults.php:347
4587
- msgid "Unknown component created tables"
4588
- msgstr ""
4589
-
4590
- #: defaults.php:347
4591
- msgid ""
4592
- "An unknown component created these tables in the database %LineBreak% "
4593
- "Tables: %TableNames%"
4594
- msgstr ""
4595
-
4596
- #: defaults.php:348
4597
- msgid "Unknown component modified tables structure"
4598
- msgstr ""
4599
-
4600
- #: defaults.php:348
4601
- msgid ""
4602
- "An unknown component modified the structure of these database tables "
4603
- "%LineBreak% Tables: %TableNames%"
4604
- msgstr ""
4605
-
4606
- #: defaults.php:349
4607
- msgid "Unknown component deleted tables"
4608
- msgstr ""
4609
-
4610
- #: defaults.php:349
4611
- msgid ""
4612
- "An unknown component deleted these tables from the database %LineBreak% "
4613
- "Tables: %TableNames%"
4614
- msgstr ""
4615
-
4616
- #: defaults.php:353
4617
- msgid "WordPress & System"
4618
- msgstr ""
4619
-
4620
- #: defaults.php:355
4621
- msgid "Unknown Error"
4622
- msgstr ""
4623
-
4624
- #: defaults.php:355
4625
- msgid "An unexpected error has occurred ."
4626
- msgstr ""
4627
-
4628
- #: defaults.php:356
4629
- msgid "PHP error"
4630
- msgstr ""
4631
-
4632
- #: defaults.php:356 defaults.php:357 defaults.php:358 defaults.php:359
4633
- #: defaults.php:360
4634
- msgid "%Message%."
4635
- msgstr ""
4636
-
4637
- #: defaults.php:357
4638
- msgid "PHP warning"
4639
- msgstr ""
4640
-
4641
  #: defaults.php:358
4642
- msgid "PHP notice"
4643
- msgstr ""
4644
-
4645
- #: defaults.php:359
4646
- msgid "PHP exception"
4647
- msgstr ""
4648
-
4649
- #: defaults.php:360
4650
- msgid "PHP shutdown error"
4651
- msgstr ""
4652
-
4653
- #: defaults.php:361
4654
- msgid "WordPress was updated"
4655
- msgstr ""
4656
-
4657
- #: defaults.php:361
4658
- msgid ""
4659
- "Updated WordPress %LineBreak% Previous version: %OldVersion% %LineBreak% New "
4660
- "version: %NewVersion%"
4661
- msgstr ""
4662
-
4663
- #: defaults.php:362
4664
- msgid "Advertising Extensions"
4665
- msgstr ""
4666
-
4667
- #: defaults.php:362
4668
- msgid "%PromoName% %PromoMessage%"
4669
- msgstr ""
4670
-
4671
- #: defaults.php:365
4672
- msgid "Activity log plugin"
4673
- msgstr ""
4674
-
4675
- #: defaults.php:366
4676
- msgid "Events automatically pruned by system"
4677
- msgstr ""
4678
-
4679
- #: defaults.php:366
4680
- msgid "System automatically deleted %EventCount% event(s)"
4681
- msgstr ""
4682
-
4683
- #: defaults.php:367
4684
- msgid "Reset plugin's settings to default"
4685
- msgstr ""
4686
-
4687
- #: defaults.php:367
4688
- msgid "Reset the WP Activity Log plugin settings to default"
4689
- msgstr ""
4690
-
4691
- #: defaults.php:368
4692
- msgid "Purged the activity log"
4693
- msgstr ""
4694
-
4695
- #: defaults.php:371
4696
- msgid "User/Visitor Actions"
4697
- msgstr ""
4698
-
4699
- #: defaults.php:372
4700
- msgid "User requests non-existing pages (404 Error Pages)"
4701
- msgstr ""
4702
-
4703
- #: defaults.php:372
4704
- msgid ""
4705
- "Has requested a non existing page (404 error) %LineBreak% Number of times: "
4706
- "%Attempts%"
4707
- msgstr ""
4708
-
4709
- #: defaults.php:373
4710
- msgid "Website Visitor User requests non-existing pages (404 Error Pages)"
4711
- msgstr ""
4712
-
4713
- #: defaults.php:373
4714
- msgid ""
4715
- "Website visitor has requested a non existing page (404 error) %LineBreak% "
4716
- "Number of times: %Attempts%"
4717
- msgstr ""
4718
-
4719
- #: defaults.php:376
4720
- msgid "WordPress Site Settings"
4721
- msgstr ""
4722
-
4723
- #: defaults.php:377
4724
- msgid "Option Anyone Can Register in WordPress settings changed"
4725
- msgstr ""
4726
-
4727
- #: defaults.php:377
4728
- msgid "The option Anyone can register"
4729
- msgstr ""
4730
-
4731
- #: defaults.php:378
4732
- msgid "New User Default Role changed"
4733
- msgstr ""
4734
-
4735
- #: defaults.php:378
4736
- msgid ""
4737
- "Changed the new user default role %LineBreak% Previous role: %OldRole% "
4738
- "%LineBreak% New role: %NewRole%"
4739
- msgstr ""
4740
-
4741
- #: defaults.php:379
4742
- msgid "WordPress Administrator Notification email changed"
4743
- msgstr ""
4744
-
4745
- #: defaults.php:379
4746
- msgid ""
4747
- "Changed the WordPress administrator notification email address %LineBreak% "
4748
- "Previous address %OldEmail% %LineBreak% New address: %NewEmail%"
4749
- msgstr ""
4750
-
4751
- #: defaults.php:380
4752
- msgid "User changes the WordPress Permalinks"
4753
- msgstr ""
4754
-
4755
- #: defaults.php:380
4756
- msgid ""
4757
- "Changed the WordPress permalinks %LineBreak% Previous permalinks: %OldPattern"
4758
- "% %LineBreak% New permalinks: %NewPattern%"
4759
- msgstr ""
4760
-
4761
- #: defaults.php:381
4762
- msgid ""
4763
- "Enabled/Disabled the option Discourage search engines from indexing this site"
4764
- msgstr ""
4765
-
4766
- #: defaults.php:381
4767
- msgid "Discourage search engines from indexing this site."
4768
- msgstr ""
4769
-
4770
- #: defaults.php:382
4771
- msgid "Enabled/Disabled comments on all the website"
4772
- msgstr ""
4773
-
4774
- #: defaults.php:382
4775
- msgid "Comments on the website"
4776
- msgstr ""
4777
-
4778
- #: defaults.php:383
4779
- msgid "Enabled/Disabled the option Comment author must fill out name and email"
4780
- msgstr ""
4781
-
4782
- #: defaults.php:383
4783
- msgid "The option Comment author must fill out name and email"
4784
- msgstr ""
4785
-
4786
- #: defaults.php:384
4787
- msgid ""
4788
- "Enabled/Disabled the option Users must be logged in and registered to comment"
4789
- msgstr ""
4790
-
4791
- #: defaults.php:384
4792
- msgid "The option Users must be logged in and registered to comment"
4793
- msgstr ""
4794
-
4795
- #: defaults.php:385
4796
- msgid "Enabled/Disabled the option to automatically close comments"
4797
- msgstr ""
4798
-
4799
- #: defaults.php:385
4800
- msgid "The option to Automatically close comments after %Value% days"
4801
- msgstr ""
4802
-
4803
- #: defaults.php:386
4804
- msgid "Changed the value of the option Automatically close comments"
4805
- msgstr ""
4806
-
4807
- #: defaults.php:386
4808
- msgid ""
4809
- "Changed the value of the option to Automatically close comments after a "
4810
- "number of days %LineBreak% Previous value: %OldValue% %LineBreak% New value: "
4811
- "%NewValue%"
4812
- msgstr ""
4813
-
4814
- #: defaults.php:387
4815
- msgid "Enabled/Disabled the option for comments to be manually approved"
4816
- msgstr ""
4817
-
4818
- #: defaults.php:387
4819
- msgid "The option for comments to be manually approved"
4820
- msgstr ""
4821
-
4822
- #: defaults.php:388
4823
- msgid ""
4824
- "Enabled/Disabled the option for an author to have previously approved "
4825
- "comments for the comments to appear"
4826
- msgstr ""
4827
-
4828
- #: defaults.php:388
4829
- msgid ""
4830
- "The option for an author to have previously approved comments for the "
4831
- "comments to appear"
4832
- msgstr ""
4833
-
4834
- #: defaults.php:389
4835
- msgid ""
4836
- "Changed the number of links that a comment must have to be held in the queue"
4837
- msgstr ""
4838
-
4839
- #: defaults.php:389
4840
- msgid ""
4841
- "Changed the minimum number of links a comment must have to be held in the "
4842
- "queue %LineBreak% Previous value: %OldValue% %LineBreak% New value: %NewValue"
4843
- "%"
4844
- msgstr ""
4845
-
4846
- #: defaults.php:390
4847
- msgid "Modified the list of keywords for comments moderation"
4848
- msgstr ""
4849
-
4850
- #: defaults.php:390
4851
- msgid "Modified the list of keywords for comments medoration"
4852
- msgstr ""
4853
-
4854
- #: defaults.php:391
4855
- msgid "Modified the list of keywords for comments blacklisting"
4856
- msgstr ""
4857
-
4858
- #: defaults.php:392
4859
- msgid "Option WordPress Address (URL) in WordPress settings changed"
4860
- msgstr ""
4861
-
4862
- #: defaults.php:392
4863
- msgid ""
4864
- "Changed the WordPress address (URL) %LineBreak% Previous URL: %old_url% "
4865
- "%LineBreak% New URL: %new_url%"
4866
- msgstr ""
4867
-
4868
- #: defaults.php:393
4869
- msgid "Option Site Address (URL) in WordPress settings changed"
4870
- msgstr ""
4871
-
4872
- #: defaults.php:393
4873
- msgid ""
4874
- "Changed the site address (URL) %LineBreak% Previous URL: %old_url% %LineBreak"
4875
- "% New URL: %new_url%"
4876
- msgstr ""
4877
-
4878
- #: defaults.php:397
4879
- msgid "Multisite Network Sites"
4880
- msgstr ""
4881
-
4882
- #: defaults.php:399
4883
- msgid "New site added on the network"
4884
- msgstr ""
4885
-
4886
- #: defaults.php:399
4887
- msgid "New site on the network: %SiteName% %LineBreak% URL: %BlogURL%"
4888
- msgstr ""
4889
-
4890
- #: defaults.php:400
4891
- msgid "Existing site archived"
4892
- msgstr ""
4893
-
4894
- #: defaults.php:400
4895
- msgid "Archived the site: %SiteName% %LineBreak% URL: %BlogURL%"
4896
- msgstr ""
4897
-
4898
- #: defaults.php:401
4899
- msgid "Archived site has been unarchived"
4900
- msgstr ""
4901
-
4902
- #: defaults.php:401
4903
- msgid "Unarchived the site: %SiteName% %LineBreak% URL: %BlogURL%"
4904
- msgstr ""
4905
-
4906
- #: defaults.php:402
4907
- msgid "Deactivated site has been activated"
4908
- msgstr ""
4909
-
4910
- #: defaults.php:402
4911
- msgid "Activated the site: %SiteName% %LineBreak% URL: %BlogURL%"
4912
- msgstr ""
4913
-
4914
- #: defaults.php:403
4915
- msgid "Site has been deactivated"
4916
- msgstr ""
4917
-
4918
- #: defaults.php:403
4919
- msgid "Deactivated the site: %SiteName% %LineBreak% URL: %BlogURL%"
4920
- msgstr ""
4921
-
4922
- #: defaults.php:404
4923
- msgid "Existing site deleted from network"
4924
- msgstr ""
4925
-
4926
- #: defaults.php:404
4927
- msgid "The site: %SiteName% %LineBreak% URL: %BlogURL%"
4928
- msgstr ""
4929
-
4930
- #: defaults.php:410
4931
- msgid "User created a new product"
4932
- msgstr ""
4933
-
4934
- #: defaults.php:410
4935
- msgid ""
4936
- "Created a new product called %ProductTitle% %LineBreak% ID: %PostID% "
4937
- "%LineBreak% Status: %ProductStatus% %LineBreak% %EditorLinkProduct%"
4938
- msgstr ""
4939
-
4940
- #: defaults.php:411
4941
- msgid "User published a product"
4942
- msgstr ""
4943
-
4944
- #: defaults.php:411
4945
- msgid ""
4946
- "Published the product called %ProductTitle% %LineBreak% ID: %PostID% "
4947
- "%LineBreak% Status: %ProductStatus% %LineBreak% %EditorLinkProduct%"
4948
- msgstr ""
4949
-
4950
- #: defaults.php:412
4951
- msgid "User changed the category of a product"
4952
- msgstr ""
4953
-
4954
- #: defaults.php:412
4955
- msgid ""
4956
- "Changed the category of the product %ProductTitle% %LineBreak% ID: %PostID% "
4957
- "%LineBreak% Status: %ProductStatus% %LineBreak% Previous categories: "
4958
- "%OldCategories% %LineBreak% New categories: %NewCategories% %LineBreak% "
4959
- "%EditorLinkProduct%"
4960
- msgstr ""
4961
-
4962
- #: defaults.php:413
4963
- msgid "User modified the short description of a product"
4964
- msgstr ""
4965
-
4966
- #: defaults.php:413
4967
- msgid ""
4968
- "Changed the short description of the product %ProductTitle% %LineBreak% ID: "
4969
- "%PostID% %LineBreak% Status: %ProductStatus% %LineBreak% %EditorLinkProduct%"
4970
- msgstr ""
4971
-
4972
- #: defaults.php:414
4973
- msgid "User modified the text of a product"
4974
- msgstr ""
4975
-
4976
- #: defaults.php:414
4977
- msgid ""
4978
- "Changed the text of the product %ProductTitle% %LineBreak% ID: %PostID% "
4979
- "%LineBreak% Status: %ProductStatus% %LineBreak% %EditorLinkProduct%"
4980
- msgstr ""
4981
-
4982
- #: defaults.php:415
4983
- msgid "User changed the URL of a product"
4984
- msgstr ""
4985
-
4986
- #: defaults.php:415
4987
- msgid ""
4988
- "Changed the URL of the product %ProductTitle% %LineBreak% ID: %PostID% "
4989
- "%LineBreak% Status: %ProductStatus% %LineBreak% Previous URL: %OldUrl% "
4990
- "%LineBreak% New URL: %NewUrl% %LineBreak% %EditorLinkProduct%"
4991
- msgstr ""
4992
-
4993
- #: defaults.php:416
4994
- msgid "User changed the Product Data of a product"
4995
- msgstr ""
4996
-
4997
- #: defaults.php:416
4998
- msgid ""
4999
- "Changed the type of the product %ProductTitle% %LineBreak% ID: %PostID% "
5000
- "%LineBreak% Status: %ProductStatus% %LineBreak% Previous type: %OldType% "
5001
- "%LineBreak% New type: %NewType% %LineBreak% %EditorLinkProduct%"
5002
- msgstr ""
5003
-
5004
- #: defaults.php:417
5005
- msgid "User changed the date of a product"
5006
- msgstr ""
5007
-
5008
- #: defaults.php:417
5009
- msgid ""
5010
- "Changed the date of the product %ProductTitle% %LineBreak% ID: %PostID% "
5011
- "%LineBreak% Status: %ProductStatus% %LineBreak% Previous date: %OldDate% "
5012
- "%LineBreak% New date: %NewDate% %LineBreak% %EditorLinkProduct%"
5013
- msgstr ""
5014
-
5015
- #: defaults.php:418
5016
- msgid "User changed the visibility of a product"
5017
- msgstr ""
5018
-
5019
- #: defaults.php:418
5020
- msgid ""
5021
- "Changed the visibility of the product %ProductTitle% %LineBreak% ID: %PostID"
5022
- "% %LineBreak% Status: %ProductStatus% %LineBreak% Previous visibility: "
5023
- "%OldVisibility% %LineBreak% New visibility: %NewVisibility% %LineBreak% "
5024
- "%EditorLinkProduct%"
5025
- msgstr ""
5026
-
5027
- #: defaults.php:419
5028
- msgid "User modified the product"
5029
- msgstr ""
5030
-
5031
- #: defaults.php:419
5032
- msgid ""
5033
- "Modified the product %ProductTitle% %LineBreak% ID: %PostID% %LineBreak% "
5034
- "Status: %ProductStatus% %LineBreak% %EditorLinkProduct%"
5035
- msgstr ""
5036
-
5037
- #: defaults.php:420
5038
- msgid "User modified the draft product"
5039
- msgstr ""
5040
-
5041
- #: defaults.php:420
5042
- msgid ""
5043
- "Modified the draft product %ProductTitle%. View the product: "
5044
- "%EditorLinkProduct%."
5045
- msgstr ""
5046
-
5047
- #: defaults.php:421
5048
- msgid "User moved a product to trash"
5049
- msgstr ""
5050
-
5051
- #: defaults.php:421
5052
- msgid ""
5053
- "Moved the product %ProductTitle% to trash %LineBreak% ID: %PostID% %LineBreak"
5054
- "% Status: %ProductStatus%"
5055
- msgstr ""
5056
-
5057
- #: defaults.php:422
5058
- msgid "User permanently deleted a product"
5059
- msgstr ""
5060
-
5061
- #: defaults.php:422
5062
- msgid "Permanently deleted the product %ProductTitle% %LineBreak% ID: %PostID%"
5063
- msgstr ""
5064
-
5065
- #: defaults.php:423
5066
- msgid "User restored a product from the trash"
5067
- msgstr ""
5068
-
5069
- #: defaults.php:423
5070
- msgid ""
5071
- "Restored the product %ProductTitle% from trash %LineBreak% ID: %PostID% "
5072
- "%LineBreak% Status: %ProductStatus% %LineBreak% %EditorLinkProduct%"
5073
- msgstr ""
5074
-
5075
- #: defaults.php:424
5076
- msgid "User changed status of a product"
5077
- msgstr ""
5078
-
5079
- #: defaults.php:424
5080
- msgid ""
5081
- "Changed the status of the product %ProductTitle% %LineBreak% ID: %PostID% "
5082
- "%LineBreak% Previous status: %OldStatus% %LineBreak% New status: %NewStatus% "
5083
- "%LineBreak% %EditorLinkProduct%"
5084
- msgstr ""
5085
-
5086
- #: defaults.php:425
5087
- msgid "User opened a product in the editor"
5088
- msgstr ""
5089
-
5090
- #: defaults.php:425
5091
- msgid ""
5092
- "Opened the product %ProductTitle% in the editor %LineBreak% ID: %PostID% "
5093
- "%LineBreak% Status: %ProductStatus% %LineBreak% %EditorLinkProduct%"
5094
- msgstr ""
5095
-
5096
- #: defaults.php:426
5097
- msgid "User viewed a product"
5098
- msgstr ""
5099
-
5100
- #: defaults.php:426
5101
- msgid ""
5102
- "Viewed the product %ProductTitle% page %LineBreak% ID: %PostID% %LineBreak% "
5103
- "Status: %ProductStatus% %LineBreak% %EditorLinkProduct%"
5104
- msgstr ""
5105
-
5106
- #: defaults.php:427
5107
- msgid "User renamed a product"
5108
- msgstr ""
5109
-
5110
- #: defaults.php:427
5111
- msgid ""
5112
- "Old name: %OldTitle% %LineBreak% New name: %NewTitle% %LineBreak% ID: %PostID"
5113
- "% %LineBreak% Status: %ProductStatus% %LineBreak% %EditorLinkProduct%"
5114
- msgstr ""
5115
-
5116
- #: defaults.php:428
5117
- msgid "User changed type of a price"
5118
- msgstr ""
5119
-
5120
- #: defaults.php:428
5121
- msgid ""
5122
- "Changed the %PriceType% of the product %ProductTitle% %LineBreak% ID: %PostID"
5123
- "% %LineBreak% Status: %ProductStatus% %LineBreak% Previous price: %OldPrice% "
5124
- "%LineBreak% New price: %NewPrice% %LineBreak% %EditorLinkProduct%"
5125
- msgstr ""
5126
-
5127
- #: defaults.php:429
5128
- msgid "User changed the SKU of a product"
5129
- msgstr ""
5130
-
5131
- #: defaults.php:429
5132
- msgid ""
5133
- "Changed the SKU of the product %ProductTitle% %LineBreak% ID: %PostID% "
5134
- "%LineBreak% Status: %ProductStatus% %LineBreak% Previous SKU: %OldSku% "
5135
- "%LineBreak% New SKU: %NewSku% %LineBreak% %EditorLinkProduct%"
5136
- msgstr ""
5137
-
5138
- #: defaults.php:430
5139
- msgid "User changed the stock status of a product"
5140
- msgstr ""
5141
-
5142
- #: defaults.php:430
5143
- msgid ""
5144
- "Changed the stock status of the product %ProductTitle% %LineBreak% ID: "
5145
- "%PostID% %LineBreak% Status: %ProductStatus% %LineBreak% Previous stock "
5146
- "status: %OldStatus% %LineBreak% New stock status: %NewStatus% %LineBreak% "
5147
- "%EditorLinkProduct%"
5148
- msgstr ""
5149
-
5150
- #: defaults.php:431
5151
- msgid "User changed the stock quantity"
5152
- msgstr ""
5153
-
5154
- #: defaults.php:431
5155
- msgid ""
5156
- "Changed the stock quantity of the product %ProductTitle% %LineBreak% ID: "
5157
- "%PostID% %LineBreak% Status: %ProductStatus% %LineBreak% Previous quantity: "
5158
- "%OldValue% %LineBreak% New quantity: %NewValue% %LineBreak% "
5159
- "%EditorLinkProduct%"
5160
- msgstr ""
5161
-
5162
- #: defaults.php:432
5163
- msgid "User set a product type"
5164
- msgstr ""
5165
-
5166
- #: defaults.php:432
5167
- msgid ""
5168
- "Changed the type of the %NewType% product %ProductTitle% %LineBreak% ID: "
5169
- "%PostID% %LineBreak% Status: %ProductStatus% %LineBreak% Previous type: "
5170
- "%OldType% %LineBreak% New type: %NewType% %LineBreak% %EditorLinkProduct%"
5171
- msgstr ""
5172
-
5173
- #: defaults.php:433
5174
- msgid "User changed the weight of a product"
5175
- msgstr ""
5176
-
5177
- #: defaults.php:433
5178
- msgid ""
5179
- "Changed the weight of the product %ProductTitle% %LineBreak% ID: %PostID% "
5180
- "%LineBreak% Status: %ProductStatus% %LineBreak% Previous weight: %OldWeight% "
5181
- "%LineBreak% New weight: %NewWeight% %LineBreak% %EditorLinkProduct%"
5182
- msgstr ""
5183
-
5184
- #: defaults.php:434
5185
- msgid "User changed the dimensions of a product"
5186
- msgstr ""
5187
-
5188
- #: defaults.php:434
5189
- msgid ""
5190
- "Changed the %DimensionType% dimensions of the product %ProductTitle% "
5191
- "%LineBreak% ID: %PostID% %LineBreak% Status: %ProductStatus% %LineBreak% "
5192
- "Previous value: %OldDimension% %LineBreak% New value: %NewDimension% "
5193
- "%LineBreak% %EditorLinkProduct%"
5194
- msgstr ""
5195
-
5196
- #: defaults.php:435
5197
- msgid "User added the Downloadable File to a product"
5198
- msgstr ""
5199
-
5200
- #: defaults.php:435
5201
- msgid ""
5202
- "Added a downloadable file to the product %ProductTitle% %LineBreak% ID: "
5203
- "%PostID% %LineBreak% Status: %ProductStatus% %LineBreak% File name: %FileName"
5204
- "% %LineBreak% File URL: %FileUrl% %LineBreak% %EditorLinkProduct%"
5205
- msgstr ""
5206
-
5207
- #: defaults.php:436
5208
- msgid "User Removed the Downloadable File from a product"
5209
- msgstr ""
5210
-
5211
- #: defaults.php:436
5212
- msgid ""
5213
- "Removed the downloadable file from the product %ProductTitle% %LineBreak% "
5214
- "ID: %PostID% %LineBreak% Status: %ProductStatus% %LineBreak% File name: "
5215
- "%FileName% %LineBreak% File URL: %FileUrl% %LineBreak% %EditorLinkProduct%"
5216
- msgstr ""
5217
-
5218
- #: defaults.php:437
5219
- msgid "User changed the name of a Downloadable File in a product"
5220
- msgstr ""
5221
-
5222
- #: defaults.php:437
5223
- msgid ""
5224
- "Changed the name of the downloadable file to the product %ProductTitle% "
5225
- "%LineBreak% ID: %PostID% %LineBreak% Status: %ProductStatus% %LineBreak% "
5226
- "Previous file name: %OldName% %LineBreak% New file name: %NewName% %LineBreak"
5227
- "% %EditorLinkProduct%"
5228
- msgstr ""
5229
-
5230
- #: defaults.php:438
5231
- msgid "User changed the URL of the Downloadable File in a product"
5232
- msgstr ""
5233
-
5234
- #: defaults.php:438
5235
- msgid ""
5236
- "Changed the URL of the downloadable file to the product %ProductTitle% "
5237
- "%LineBreak% ID: %PostID% %LineBreak% Status: %ProductStatus% %LineBreak% "
5238
- "File name: %FileName% %LineBreak% Previous URL: %OldUrl% %LineBreak% New "
5239
- "URL: %NewUrl% %LineBreak% %EditorLinkProduct%"
5240
- msgstr ""
5241
-
5242
- #: defaults.php:439
5243
- msgid "User changed the catalog visibility of a product"
5244
- msgstr ""
5245
-
5246
- #: defaults.php:439
5247
- msgid ""
5248
- "Changed the product visibility of the product %ProductTitle% %LineBreak% ID: "
5249
- "%PostID% %LineBreak% Status: %ProductStatus% %LineBreak% Previous setting: "
5250
- "%OldVisibility% %LineBreak% New setting: %NewVisibility% %LineBreak% "
5251
- "%EditorLinkProduct%"
5252
- msgstr ""
5253
-
5254
- #: defaults.php:440
5255
- msgid "User changed the setting Featured Product of a product"
5256
- msgstr ""
5257
-
5258
- #: defaults.php:440
5259
- msgid ""
5260
- "The setting Featured Product for the product %ProductTitle% %LineBreak% ID: "
5261
- "%PostID% %LineBreak% Status: %ProductStatus% %LineBreak% %EditorLinkProduct%"
5262
- msgstr ""
5263
-
5264
- #: defaults.php:441
5265
- msgid "User changed the Allow Backorders setting of a product"
5266
- msgstr ""
5267
-
5268
- #: defaults.php:441
5269
- msgid ""
5270
- "Changed the Allow Backorders setting for the product %ProductTitle% "
5271
- "%LineBreak% ID: %PostID% %LineBreak% Status: %ProductStatus% %LineBreak% "
5272
- "Previous status: %OldStatus% %LineBreak% New status: %NewStatus% %LineBreak% "
5273
- "%EditorLinkProduct%"
5274
- msgstr ""
5275
-
5276
- #: defaults.php:442
5277
- msgid "User added/removed products to upsell of a product"
5278
- msgstr ""
5279
-
5280
- #: defaults.php:442
5281
- msgid ""
5282
- "Products to Upsell in the product %ProductTitle% %LineBreak% ID: %PostID% "
5283
- "%LineBreak% Status: %ProductStatus% %LineBreak% Product: %UpsellTitle% "
5284
- "%LineBreak% %EditorLinkProduct%"
5285
- msgstr ""
5286
-
5287
- #: defaults.php:443
5288
- msgid "User added/removed products to cross-sells of a product"
5289
- msgstr ""
5290
-
5291
- #: defaults.php:443
5292
- msgid ""
5293
- "Product to Cross-sell in the product %ProductTitle% %LineBreak% ID: %PostID% "
5294
- "%LineBreak% Status: %ProductStatus% %LineBreak% Product: %CrossSellTitle% "
5295
- "%LineBreak% %EditorLinkProduct%"
5296
- msgstr ""
5297
-
5298
- #: defaults.php:444
5299
- msgid "System changed the stock quantity of a product"
5300
- msgstr ""
5301
-
5302
- #: defaults.php:444
5303
- msgid ""
5304
- "The stock quantity of the product %ProductTitle% was changed due to a "
5305
- "purchase. %LineBreak% ID: %PostID% %LineBreak% Status: %ProductStatus% "
5306
- "%LineBreak% Previous quantity: %OldValue% %LineBreak% New quantity: %NewValue"
5307
- "% %LineBreak% %EditorLinkProduct%"
5308
- msgstr ""
5309
-
5310
- #: defaults.php:445
5311
- msgid "Added a new attribute of a product"
5312
- msgstr ""
5313
-
5314
- #: defaults.php:445
5315
- msgid ""
5316
- "A new attribute to the product %ProductTitle% %LineBreak% ID: %ProductID% "
5317
- "%LineBreak% Status: %ProductStatus% %LineBreak% Attribute name: "
5318
- "%AttributeName% %LineBreak% Attribute value: %AttributeValue% %LineBreak% "
5319
- "%EditorLinkProduct%"
5320
- msgstr ""
5321
-
5322
- #: defaults.php:446
5323
- msgid "Modified the value of an attribute of a product"
5324
- msgstr ""
5325
-
5326
- #: defaults.php:446
5327
- msgid ""
5328
- "Modified the value of an attribute in the product %ProductTitle% %LineBreak% "
5329
- "ID: %ProductID% %LineBreak% Status: %ProductStatus% %LineBreak% Attribute "
5330
- "name: %AttributeName% %LineBreak% Previous attribute value: %OldValue% "
5331
- "%LineBreak% New attribute value: %NewValue% %LineBreak% %EditorLinkProduct%"
5332
- msgstr ""
5333
-
5334
- #: defaults.php:447
5335
- msgid "Changed the name of an attribute of a product"
5336
- msgstr ""
5337
-
5338
- #: defaults.php:447
5339
- msgid ""
5340
- "Changed the name of an attribute in the product %ProductTitle% %LineBreak% "
5341
- "ID: %ProductID% %LineBreak% Status: %ProductStatus% %LineBreak% Previous "
5342
- "attribute name: %OldValue% %LineBreak% New attribute name: %NewValue% "
5343
- "%LineBreak% %EditorLinkProduct%"
5344
- msgstr ""
5345
-
5346
- #: defaults.php:448
5347
- msgid "Deleted an attribute of a product"
5348
- msgstr ""
5349
-
5350
- #: defaults.php:448
5351
- msgid ""
5352
- "An attribute from the product %ProductTitle% %LineBreak% ID: %ProductID% "
5353
- "%LineBreak% Status: %ProductStatus% %LineBreak% Attribute name: "
5354
- "%AttributeName% %LineBreak% Attribute value: %AttributeValue% %LineBreak% "
5355
- "%EditorLinkProduct%"
5356
- msgstr ""
5357
-
5358
- #: defaults.php:449
5359
- msgid "Set the attribute visibility of a product"
5360
- msgstr ""
5361
-
5362
- #: defaults.php:449
5363
- msgid ""
5364
- "Changed the visibility of an attribute in the product %ProductTitle% "
5365
- "%LineBreak% ID: %ProductID% %LineBreak% Status: %ProductStatus% %LineBreak% "
5366
- "Attribute name: %AttributeName% %LineBreak% Attribute visibility: "
5367
- "%AttributeVisiblilty% %LineBreak% %EditorLinkProduct%"
5368
- msgstr ""
5369
-
5370
- #: defaults.php:452
5371
- msgid "Store"
5372
- msgstr ""
5373
-
5374
- #: defaults.php:453
5375
- msgid "User changed the Weight Unit"
5376
- msgstr ""
5377
-
5378
- #: defaults.php:453
5379
- msgid ""
5380
- "Changed the weight unit of the store %LineBreak% Previous weight unit: "
5381
- "%OldUnit% %LineBreak% New weight unit: %NewUnit%"
5382
- msgstr ""
5383
-
5384
- #: defaults.php:454
5385
- msgid "User changed the Dimensions Unit"
5386
- msgstr ""
5387
-
5388
- #: defaults.php:454
5389
- msgid ""
5390
- "Changed the dimensions unit of the store %LineBreak% Previous dimensions "
5391
- "unit: %OldUnit% %LineBreak% New dimensions unit: %NewUnit%"
5392
- msgstr ""
5393
-
5394
- #: defaults.php:455
5395
- msgid "User changed the Base Location"
5396
- msgstr ""
5397
-
5398
- #: defaults.php:455
5399
- msgid ""
5400
- "Changed the base location %LineBreak% Previous address: %OldLocation% "
5401
- "%LineBreak% New address: %NewLocation%"
5402
- msgstr ""
5403
-
5404
- #: defaults.php:456
5405
- msgid "User enabled/disabled taxes"
5406
- msgstr ""
5407
-
5408
- #: defaults.php:456
5409
- msgid "Taxes in WooCommerce"
5410
- msgstr ""
5411
-
5412
- #: defaults.php:457
5413
- msgid "User changed the currency"
5414
- msgstr ""
5415
-
5416
- #: defaults.php:457
5417
- msgid ""
5418
- "Changed the currency of the store %LineBreak% Previous currency: %OldCurrency"
5419
- "% %LineBreak% New currency: %NewCurrency%"
5420
- msgstr ""
5421
-
5422
- #: defaults.php:458
5423
- msgid "User enabled/disabled the use of coupons during checkout"
5424
- msgstr ""
5425
-
5426
- #: defaults.php:458
5427
- msgid "The use of coupons during checkout"
5428
- msgstr ""
5429
-
5430
- #: defaults.php:459
5431
- msgid "User enabled/disabled guest checkout"
5432
- msgstr ""
5433
-
5434
- #: defaults.php:459
5435
- msgid "Guest checkout in the store"
5436
- msgstr ""
5437
-
5438
- #: defaults.php:460
5439
- msgid "User enabled/disabled cash on delivery"
5440
- msgstr ""
5441
-
5442
- #: defaults.php:460
5443
- msgid "The option cash on delivery"
5444
- msgstr ""
5445
-
5446
- #: defaults.php:461
5447
- msgid "User modified selling location(s)"
5448
- msgstr ""
5449
-
5450
- #: defaults.php:461
5451
- msgid ""
5452
- "The setting Selling location(s) %LineBreak% Old setting: %old% %LineBreak% "
5453
- "New Setting: %new%"
5454
- msgstr ""
5455
-
5456
- #: defaults.php:462
5457
- msgid "User modified excluded selling location(s)"
5458
- msgstr ""
5459
-
5460
- #: defaults.php:462
5461
- msgid ""
5462
- "Changed the list of excluded countries to sell to %LineBreak% Old setting: "
5463
- "%old% %LineBreak% New Setting: %new%"
5464
- msgstr ""
5465
-
5466
- #: defaults.php:463
5467
- msgid "User modified exclusive selling location(s)"
5468
- msgstr ""
5469
-
5470
- #: defaults.php:463
5471
- msgid ""
5472
- "Changed the list of countries to sell to %LineBreak% Old setting: %old% "
5473
- "%LineBreak% New Setting: %new%"
5474
- msgstr ""
5475
-
5476
- #: defaults.php:464
5477
- msgid "User modified shipping location(s)"
5478
- msgstr ""
5479
-
5480
- #: defaults.php:464
5481
- msgid ""
5482
- "The setting Shipping location(s) %LineBreak% Old setting: %old% %LineBreak% "
5483
- "New Setting: %new%"
5484
- msgstr ""
5485
-
5486
- #: defaults.php:465
5487
- msgid "User modified exclusive shipping location(s)"
5488
  msgstr ""
5489
 
5490
- #: defaults.php:465
5491
  msgid ""
5492
- "Changed the list of specific countries to ship to %LineBreak% Old setting: "
5493
- "%old% %LineBreak% New Setting: %new%"
5494
  msgstr ""
5495
 
5496
- #: defaults.php:466
5497
- msgid "User modified default customer location"
5498
  msgstr ""
5499
 
5500
- #: defaults.php:466
5501
  msgid ""
5502
- "The setting Default customer location %LineBreak% Old setting: %old% "
5503
- "%LineBreak% New Setting: %new%"
5504
- msgstr ""
5505
-
5506
- #: defaults.php:467
5507
- msgid "User modified the cart page"
5508
  msgstr ""
5509
 
5510
- #: defaults.php:467
5511
- msgid ""
5512
- "Changed the Cart Page %LineBreak% Old page: %old% %LineBreak% New page: %new%"
5513
  msgstr ""
5514
 
5515
- #: defaults.php:468
5516
- msgid "User modified the checkout page"
5517
  msgstr ""
5518
 
5519
- #: defaults.php:468
5520
  msgid ""
5521
- "Changed the Checkout page %LineBreak% Old page: %old% %LineBreak% New page: "
5522
- "%new%"
5523
  msgstr ""
5524
 
5525
- #: defaults.php:469
5526
- msgid "User modified the my account page"
5527
  msgstr ""
5528
 
5529
- #: defaults.php:469
5530
  msgid ""
5531
- "Changed the My Account Page %LineBreak% Old page: %old% %LineBreak% New "
5532
- "page: %new%"
5533
  msgstr ""
5534
 
5535
- #: defaults.php:470
5536
- msgid "User modified the terms and conditions page"
5537
  msgstr ""
5538
 
5539
- #: defaults.php:470
5540
  msgid ""
5541
- "Changed the Terms and Conditions Page %LineBreak% Old page: %old% %LineBreak"
5542
- "% New page: %new%"
5543
  msgstr ""
5544
 
5545
- #: defaults.php:473
5546
- msgid "Payment Gateways"
5547
  msgstr ""
5548
 
5549
- #: defaults.php:474
5550
- msgid "User enabled/disabled a payment gateway"
 
 
5551
  msgstr ""
5552
 
5553
- #: defaults.php:474 defaults.php:476
5554
- msgid "The payment gateway %GatewayName%"
5555
  msgstr ""
5556
 
5557
- #: defaults.php:475
5558
- msgid "User disabled a payment gateway"
 
 
5559
  msgstr ""
5560
 
5561
- #: defaults.php:475
5562
- msgid "Disabled the payment gateway %GatewayName%"
5563
  msgstr ""
5564
 
5565
- #: defaults.php:476
5566
- msgid "User modified a payment gateway"
 
 
5567
  msgstr ""
5568
 
5569
- #: defaults.php:479
5570
- msgid "Tax Settings"
5571
  msgstr ""
5572
 
5573
- #: defaults.php:480
5574
- msgid "User modified prices with tax option"
5575
  msgstr ""
5576
 
5577
- #: defaults.php:480
5578
- msgid "Set the option that prices are %TaxStatus% of tax"
5579
  msgstr ""
5580
 
5581
- #: defaults.php:481
5582
- msgid "User modified tax calculation base"
5583
  msgstr ""
5584
 
5585
- #: defaults.php:481
5586
- msgid "Set the setting Calculate tax based on to %Setting%"
 
5587
  msgstr ""
5588
 
5589
- #: defaults.php:482
5590
- msgid "User modified shipping tax class"
5591
  msgstr ""
5592
 
5593
- #: defaults.php:482
5594
- msgid "Set the Shipping tax class to %Setting%"
5595
  msgstr ""
5596
 
5597
- #: defaults.php:483
5598
- msgid "User enabled/disabled rounding of tax"
5599
  msgstr ""
5600
 
5601
- #: defaults.php:483
5602
- msgid "Rounding of tax at subtotal level"
5603
  msgstr ""
5604
 
5605
- #: defaults.php:484
5606
- msgid "User modified a shipping zone"
5607
  msgstr ""
5608
 
5609
- #: defaults.php:484
5610
- msgid "The shipping zone %ShippingZoneName%"
 
 
5611
  msgstr ""
5612
 
5613
- #: defaults.php:487
5614
- msgid "WC Categories"
5615
  msgstr ""
5616
 
5617
- #: defaults.php:488
5618
- msgid "User created a new product category"
5619
  msgstr ""
5620
 
5621
- #: defaults.php:488
5622
- msgid ""
5623
- "A new product category called %CategoryName% %LineBreak% Category slug is "
5624
- "%Slug% %LineBreak% %ProductCatLink%"
5625
  msgstr ""
5626
 
5627
- #: defaults.php:489
5628
- msgid "User deleted a product category"
5629
  msgstr ""
5630
 
5631
- #: defaults.php:489
5632
- msgid ""
5633
- "The product category called %CategoryName% %LineBreak% Category slug: "
5634
- "%CategorySlug%"
5635
  msgstr ""
5636
 
5637
- #: defaults.php:490
5638
- msgid "User changed the slug of a product category"
5639
  msgstr ""
5640
 
5641
- #: defaults.php:490
5642
- msgid ""
5643
- "Changed the slug of the product category called %CategoryName% %LineBreak% "
5644
- "Previous category slug: %OldSlug% %LineBreak% New category slug: %NewSlug% "
5645
- "%LineBreak% %ProductCatLink%"
5646
  msgstr ""
5647
 
5648
- #: defaults.php:491
5649
- msgid "User changed the parent category of a product category"
5650
  msgstr ""
5651
 
5652
- #: defaults.php:491
5653
- msgid ""
5654
- "Changed the parent of the product category %CategoryName% %LineBreak% "
5655
- "Category slug: %CategorySlug% %LineBreak% Previous parent: %OldParentCat% "
5656
- "%LineBreak% New parent: %NewParentCat% %LineBreak% %ProductCatLink%"
5657
  msgstr ""
5658
 
5659
- #: defaults.php:492
5660
- msgid "User changed the display type of a product category"
5661
  msgstr ""
5662
 
5663
- #: defaults.php:492
5664
  msgid ""
5665
- "Changed the display type of the product category %CategoryName% %LineBreak% "
5666
- "%CategorySlug% %LineBreak% Previous display type: %OldDisplayType% %LineBreak"
5667
- "% New display type: %NewDisplayType% %LineBreak% %ProductCatLink%"
5668
  msgstr ""
5669
 
5670
- #: defaults.php:493
5671
- msgid "User changed the name of a product category"
5672
  msgstr ""
5673
 
5674
- #: defaults.php:493
5675
  msgid ""
5676
- "Previous name: %OldName% %LineBreak% New name: %NewName% %LineBreak% "
5677
- "Category slug: %CategorySlug% %LineBreak% %ProductCatLink%"
5678
  msgstr ""
5679
 
5680
- #: defaults.php:496
5681
- msgid "Attributes"
5682
  msgstr ""
5683
 
5684
- #: defaults.php:497
5685
- msgid "User created a new attribute"
5686
  msgstr ""
5687
 
5688
- #: defaults.php:497
5689
- msgid ""
5690
- "A new attribute in WooCommerce called %AttributeName% %LineBreak% Attribute "
5691
- "slug: %AttributeSlug%"
5692
  msgstr ""
5693
 
5694
- #: defaults.php:498
5695
- msgid "User deleted an attribute"
5696
  msgstr ""
5697
 
5698
- #: defaults.php:498
5699
  msgid ""
5700
- "The WooCommerce attribute called %AttributeName% %LineBreak% Attribute slug: "
5701
- "%AttributeSlug%"
5702
  msgstr ""
5703
 
5704
- #: defaults.php:499
5705
- msgid "User changed the slug of an attribute"
5706
  msgstr ""
5707
 
5708
- #: defaults.php:499
5709
  msgid ""
5710
- "Changed the slug of the WooCommerce attribute %AttributeName% %LineBreak% "
5711
- "Previous slug: %OldSlug% %LineBreak% New slug: %NewSlug%"
5712
  msgstr ""
5713
 
5714
- #: defaults.php:500
5715
- msgid "User changed the name of an attribute"
5716
  msgstr ""
5717
 
5718
- #: defaults.php:500
5719
  msgid ""
5720
- "Changed the name of the WooCommerce attribute %AttributeName% %LineBreak% "
5721
- "Attribute slug: %AttributeSlug% %LineBreak% Previous name: %OldName% "
5722
- "%LineBreak% New name: %NewName%"
5723
- msgstr ""
5724
-
5725
- #: defaults.php:501
5726
- msgid "User changed the default sort order of an attribute"
5727
  msgstr ""
5728
 
5729
- #: defaults.php:501
5730
  msgid ""
5731
- "Changed the Default Sort Order of the attribute %AttributeName% in "
5732
- "WooCommerce %LineBreak% Attribute slug: %AttributeSlug% %LineBreak% Previous "
5733
- "sorting order: %OldSortOrder% %LineBreak% New sorting order: %NewSortOrder%"
5734
- msgstr ""
5735
-
5736
- #: defaults.php:502
5737
- msgid "User enabled/disabled the option Enable Archives of an attribute"
5738
  msgstr ""
5739
 
5740
- #: defaults.php:502
5741
- msgid "The option Enable Archives in WooCommerce attribute %AttributeName%"
5742
  msgstr ""
5743
 
5744
- #: defaults.php:505
5745
- msgid "Coupons"
5746
  msgstr ""
5747
 
5748
- #: defaults.php:506
5749
- msgid "User published a new coupon"
5750
  msgstr ""
5751
 
5752
- #: defaults.php:506
5753
- msgid ""
5754
- "Published a new coupon called %CouponName% %LineBreak% %EditorLinkCoupon%"
5755
  msgstr ""
5756
 
5757
- #: defaults.php:507
5758
- msgid "User changed the discount type of a coupon"
5759
  msgstr ""
5760
 
5761
- #: defaults.php:507
5762
  msgid ""
5763
- "Changed the Discount Type in coupon %CouponName% %LineBreak% Previous "
5764
- "discount type: %OldDiscountType% %LineBreak% New discount type: "
5765
- "%NewDiscountType% %LineBreak% %EditorLinkCoupon%"
5766
- msgstr ""
5767
-
5768
- #: defaults.php:508
5769
- msgid "User changed the coupon amount of a coupon"
5770
  msgstr ""
5771
 
5772
- #: defaults.php:508
5773
- msgid ""
5774
- "Changed the Coupon amount in coupon %CouponName% %LineBreak% Previous "
5775
- "amount: %OldAmount% %LineBreak% New amount: %NewAmount% %LineBreak% "
5776
- "%EditorLinkCoupon%"
5777
  msgstr ""
5778
 
5779
- #: defaults.php:509
5780
- msgid "User changed the coupon expire date of a coupon"
5781
  msgstr ""
5782
 
5783
- #: defaults.php:509
5784
- msgid ""
5785
- "Changed the expire date of the coupon %CouponName% %LineBreak% Previous "
5786
- "date: %OldDate% %LineBreak% New date: %NewDate% %LineBreak% %EditorLinkCoupon"
5787
- "%"
5788
  msgstr ""
5789
 
5790
- #: defaults.php:510
5791
- msgid "User changed the usage restriction settings of a coupon"
5792
  msgstr ""
5793
 
5794
- #: defaults.php:510
5795
  msgid ""
5796
- "Changed the Usage Restriction of the coupon %CouponName% %LineBreak% "
5797
- "Previous usage restriction: %OldMetaValue% %LineBreak% New usage "
5798
- "restriction: %NewMetaValue% %LineBreak% %EditorLinkCoupon%"
5799
- msgstr ""
5800
-
5801
- #: defaults.php:511
5802
- msgid "User changed the usage limits settings of a coupon"
5803
  msgstr ""
5804
 
5805
- #: defaults.php:511
5806
- msgid ""
5807
- "Changed the Usage Limits of the coupon %CouponName% %LineBreak% Previous "
5808
- "usage limits: %OldMetaValue% %LineBreak% New usage limits: %NewMetaValue% "
5809
- "%LineBreak% %EditorLinkCoupon%"
5810
  msgstr ""
5811
 
5812
- #: defaults.php:512
5813
- msgid "User changed the description of a coupon"
5814
  msgstr ""
5815
 
5816
- #: defaults.php:512
5817
  msgid ""
5818
- "Changed the description of the coupon %CouponName% %LineBreak% Previous "
5819
- "description: %OldDescription% %LineBreak% New description: %NewDescription% "
5820
- "%LineBreak% %EditorLinkCoupon%"
5821
- msgstr ""
5822
-
5823
- #: defaults.php:513
5824
- msgid "User changed the status of a coupon"
5825
  msgstr ""
5826
 
5827
- #: defaults.php:513
5828
  msgid ""
5829
- "Changed the Status of the WooCommerce coupon %CouponName% from %OldStatus% "
5830
- "to %NewStatus%."
5831
  msgstr ""
5832
 
5833
- #: defaults.php:514
5834
- msgid "User renamed a WooCommerce coupon"
 
5835
  msgstr ""
5836
 
5837
- #: defaults.php:514
5838
  msgid ""
5839
- "Old coupon name: %OldName% %LineBreak% New coupon name: %NewName% %LineBreak"
5840
- "% %EditorLinkCoupon%"
 
5841
  msgstr ""
5842
 
5843
- #: defaults.php:517
5844
- msgid "Orders"
5845
  msgstr ""
5846
 
5847
- #: defaults.php:518
5848
- msgid "A WooCommerce order has been placed"
5849
  msgstr ""
5850
 
5851
- #: defaults.php:518
5852
- msgid ""
5853
- "A new order has been placed %LineBreak% Order name: %OrderTitle% %LineBreak% "
5854
- "%EditorLinkOrder%"
5855
  msgstr ""
5856
 
5857
- #: defaults.php:519
5858
- msgid "WooCommerce order status changed"
5859
  msgstr ""
5860
 
5861
- #: defaults.php:519
5862
  msgid ""
5863
- "Marked an order %OrderTitle% as %OrderStatus% %LineBreak% %EditorLinkOrder%"
 
5864
  msgstr ""
5865
 
5866
- #: defaults.php:520
5867
- msgid "User moved a WooCommerce order to trash"
5868
  msgstr ""
5869
 
5870
- #: defaults.php:520
5871
- msgid "Moved the order %OrderTitle% to trash"
 
 
5872
  msgstr ""
5873
 
5874
- #: defaults.php:521
5875
- msgid "User moved a WooCommerce order out of trash"
5876
  msgstr ""
5877
 
5878
- #: defaults.php:521
5879
- msgid ""
5880
- "Restored the order %OrderTitle% from the trash %LineBreak% %EditorLinkOrder%"
5881
  msgstr ""
5882
 
5883
- #: defaults.php:522
5884
- msgid "User permanently deleted a WooCommerce order"
5885
  msgstr ""
5886
 
5887
- #: defaults.php:522
5888
- msgid "Permanently deleted the order %OrderTitle%"
5889
  msgstr ""
5890
 
5891
- #: defaults.php:523
5892
- msgid "User edited a WooCommerce order"
5893
  msgstr ""
5894
 
5895
- #: defaults.php:523
5896
- msgid "Edited the details in order %OrderTitle% %LineBreak% %EditorLinkOrder%"
5897
  msgstr ""
5898
 
5899
- #: defaults.php:524
5900
- msgid "User refunded a WooCommerce order"
5901
  msgstr ""
5902
 
5903
- #: defaults.php:524
5904
- msgid "Refunded the order %OrderTitle% %LineBreak% %EditorLinkOrder%"
5905
  msgstr ""
5906
 
5907
- #: defaults.php:527
5908
- msgid "User Profile"
5909
  msgstr ""
5910
 
5911
- #: defaults.php:528
5912
- msgid "User changed the billing address details"
5913
  msgstr ""
5914
 
5915
- #: defaults.php:528
5916
- msgid ""
5917
- "Changed the billing address details of the user %TargetUsername% %LineBreak% "
5918
- "Role: %Roles% %LineBreak% New Billing address: %NewValue% %LineBreak% "
5919
- "%EditUserLink%"
5920
  msgstr ""
5921
 
5922
- #: defaults.php:529
5923
- msgid "User changed the shipping address details"
5924
  msgstr ""
5925
 
5926
- #: defaults.php:529
5927
- msgid ""
5928
- "Changed the shipping address details of the user %TargetUsername% %LineBreak"
5929
- "% Role: %Roles% %LineBreak% New Shipping address: %NewValue% %LineBreak% "
5930
- "%EditUserLink%"
5931
  msgstr ""
5932
 
5933
- #: defaults.php:535
5934
  msgid "User changed title of a SEO post"
5935
  msgstr ""
5936
 
5937
- #: defaults.php:535
5938
  msgid ""
5939
  "Changed the Meta title of the post %PostTitle% %LineBreak% ID: %PostID% "
5940
  "%LineBreak% Type: %PostType% %LineBreak% Status: %PostStatus% %LineBreak% "
@@ -5942,11 +4959,11 @@ msgid ""
5942
  "% %EditorLinkPost%"
5943
  msgstr ""
5944
 
5945
- #: defaults.php:536
5946
  msgid "User changed the meta description of a SEO post"
5947
  msgstr ""
5948
 
5949
- #: defaults.php:536
5950
  msgid ""
5951
  "Changed the Meta Description of the post %PostTitle% %LineBreak% ID: %PostID"
5952
  "% %LineBreak% Type: %PostType% %LineBreak% Status: %PostStatus% %LineBreak% "
@@ -5954,13 +4971,13 @@ msgid ""
5954
  "%LineBreak% %EditorLinkPost%"
5955
  msgstr ""
5956
 
5957
- #: defaults.php:537
5958
  msgid ""
5959
  "User changed setting to allow search engines to show post in search results "
5960
  "of a SEO post"
5961
  msgstr ""
5962
 
5963
- #: defaults.php:537
5964
  msgid ""
5965
  "Changed the setting to allow search engines to show post in search results "
5966
  "for the post %PostTitle% %LineBreak% ID: %PostID% %LineBreak% Type: %PostType"
@@ -5968,24 +4985,24 @@ msgid ""
5968
  "%LineBreak% New setting: %NewStatus% %LineBreak% %EditorLinkPost%"
5969
  msgstr ""
5970
 
5971
- #: defaults.php:538
5972
  msgid ""
5973
  "User Enabled/Disabled the option for search engine to follow links of a SEO "
5974
  "post"
5975
  msgstr ""
5976
 
5977
- #: defaults.php:538
5978
  msgid ""
5979
  "The option for search engine to follow links in post %PostTitle% %LineBreak% "
5980
  "ID: %PostID% %LineBreak% Type: %PostType% %LineBreak% Status: %PostStatus% "
5981
  "%LineBreak% %EditorLinkPost%"
5982
  msgstr ""
5983
 
5984
- #: defaults.php:539
5985
  msgid "User set the meta robots advanced setting of a SEO post"
5986
  msgstr ""
5987
 
5988
- #: defaults.php:539
5989
  msgid ""
5990
  "Changed the Meta Robots Advanced setting for the post %PostTitle% %LineBreak"
5991
  "% ID: %PostID% %LineBreak% Type: %PostType% %LineBreak% Status: %PostStatus% "
@@ -5993,11 +5010,11 @@ msgid ""
5993
  "% %LineBreak% %EditorLinkPost%"
5994
  msgstr ""
5995
 
5996
- #: defaults.php:540
5997
  msgid "User changed the canonical URL of a SEO post"
5998
  msgstr ""
5999
 
6000
- #: defaults.php:540
6001
  msgid ""
6002
  "Changed the Canonical URL of the post %PostTitle% %LineBreak% ID: %PostID% "
6003
  "%LineBreak% Type: %PostType% %LineBreak% Status: %PostStatus% %LineBreak% "
@@ -6005,11 +5022,11 @@ msgid ""
6005
  "%LineBreak% %EditorLinkPost%"
6006
  msgstr ""
6007
 
6008
- #: defaults.php:541
6009
  msgid "User changed the focus keyword of a SEO post"
6010
  msgstr ""
6011
 
6012
- #: defaults.php:541
6013
  msgid ""
6014
  "Changed the focus keyword for the post %PostTitle% %LineBreak% ID: %PostID% "
6015
  "%LineBreak% Type: %PostType% %LineBreak% Status: %PostStatus% %LineBreak% "
@@ -6017,212 +5034,214 @@ msgid ""
6017
  "%LineBreak% %EditorLinkPost%"
6018
  msgstr ""
6019
 
6020
- #: defaults.php:542
6021
  msgid "User Enabled/Disabled the option Cornerston Content of a SEO post"
6022
  msgstr ""
6023
 
6024
- #: defaults.php:542
6025
  msgid ""
6026
  "The option Cornerstone Content in the post %PostTitle% %LineBreak% ID: "
6027
  "%PostID% %LineBreak% Type: %PostType% %LineBreak% Status: %PostStatus% "
6028
  "%LineBreak% %EditorLinkPost%"
6029
  msgstr ""
6030
 
6031
- #: defaults.php:545
6032
  msgid "Website Changes"
6033
  msgstr ""
6034
 
6035
- #: defaults.php:546
6036
  msgid "User changed the Title Separator setting"
6037
  msgstr ""
6038
 
6039
- #: defaults.php:546
6040
  msgid ""
6041
  "Changed the default title separator %LineBreak% Previous separator: %old% "
6042
  "%LineBreak% New separator: %new%"
6043
  msgstr ""
6044
 
6045
- #: defaults.php:547
6046
  msgid "User changed the Homepage Title setting"
6047
  msgstr ""
6048
 
6049
- #: defaults.php:547
6050
  msgid ""
6051
  "Changed the homepage Meta title %LineBreak% Previous title: %old% %LineBreak"
6052
  "% New title: %new%"
6053
  msgstr ""
6054
 
6055
- #: defaults.php:548
6056
  msgid "User changed the Homepage Meta description setting"
6057
  msgstr ""
6058
 
6059
- #: defaults.php:548
6060
  msgid ""
6061
  "Changed the homepage Meta description %LineBreak% Previous description: %old"
6062
  "% %LineBreak% New description: %new%"
6063
  msgstr ""
6064
 
6065
- #: defaults.php:549
6066
  msgid "User changed the Company or Person setting"
6067
  msgstr ""
6068
 
6069
- #: defaults.php:549
6070
  msgid ""
6071
  "Changed the Company or Person setting %LineBreak% Previous setting: %old% "
6072
  "%LineBreak% New setting: %new%"
6073
  msgstr ""
6074
 
6075
- #: defaults.php:552
6076
  msgid "Plugin Settings Changes"
6077
  msgstr ""
6078
 
6079
- #: defaults.php:553
6080
  msgid ""
6081
  "User Enabled/Disabled the option Show Posts/Pages in Search Results in the "
6082
  "Yoast SEO plugin settings"
6083
  msgstr ""
6084
 
6085
- #: defaults.php:553
6086
  msgid "The option to show %SEOPostType% in search results"
6087
  msgstr ""
6088
 
6089
- #: defaults.php:554
6090
  msgid ""
6091
  "User changed the Posts/Pages title template in the Yoast SEO plugin settings"
6092
  msgstr ""
6093
 
6094
- #: defaults.php:554
6095
  msgid ""
6096
  "Changed the %SEOPostType% Meta (SEO) title template %LineBreak% Previous "
6097
  "template: %old% %LineBreak% New template: %new%"
6098
  msgstr ""
6099
 
6100
- #: defaults.php:555
6101
  msgid "User Enabled/Disabled SEO analysis in the Yoast SEO plugin settings"
6102
  msgstr ""
6103
 
6104
- #: defaults.php:555
6105
  msgid "The SEO Analysis feature"
6106
  msgstr ""
6107
 
6108
- #: defaults.php:556
6109
  msgid ""
6110
  "User Enabled/Disabled readability analysis in the Yoast SEO plugin settings"
6111
  msgstr ""
6112
 
6113
- #: defaults.php:556
6114
  msgid "The Readability Analysis feature"
6115
  msgstr ""
6116
 
6117
- #: defaults.php:557
6118
  msgid ""
6119
  "User Enabled/Disabled cornerstone content in the Yoast SEO plugin settings"
6120
  msgstr ""
6121
 
6122
- #: defaults.php:557
6123
  msgid "The Cornerstone content feature"
6124
  msgstr ""
6125
 
6126
- #: defaults.php:558
6127
  msgid ""
6128
  "User Enabled/Disabled the text link counter in the Yoast SEO plugin settings"
6129
  msgstr ""
6130
 
6131
- #: defaults.php:558
6132
  msgid "The Text link counter feature"
6133
  msgstr ""
6134
 
6135
- #: defaults.php:559
6136
  msgid "User Enabled/Disabled XML sitemaps in the Yoast SEO plugin settings"
6137
  msgstr ""
6138
 
6139
- #: defaults.php:559
6140
  msgid "The XML sitemap feature"
6141
  msgstr ""
6142
 
6143
- #: defaults.php:560
6144
  msgid "User Enabled/Disabled ryte integration in the Yoast SEO plugin settings"
6145
  msgstr ""
6146
 
6147
- #: defaults.php:560
6148
  msgid "The Ryte integration feature"
6149
  msgstr ""
6150
 
6151
- #: defaults.php:561
6152
  msgid ""
6153
  "User Enabled/Disabled the admin bar menu in the Yoast SEO plugin settings"
6154
  msgstr ""
6155
 
6156
- #: defaults.php:561
6157
  msgid "The Admin bar menu feature"
6158
  msgstr ""
6159
 
6160
- #: defaults.php:562
6161
  msgid ""
6162
  "User changed the Posts/Pages meta description template in the Yoast SEO "
6163
  "plugin settings"
6164
  msgstr ""
6165
 
6166
- #: defaults.php:562
6167
  msgid ""
6168
  "Changed the %SEOPostType% Meta description template %LineBreak% Previous "
6169
  "template: %old% New template: %new%"
6170
  msgstr ""
6171
 
6172
- #: defaults.php:563
6173
  msgid ""
6174
  "User set the option Date in Snippet Preview for Posts/Pages in the Yoast SEO "
6175
  "plugin settings"
6176
  msgstr ""
6177
 
6178
- #: defaults.php:563
6179
  msgid "The option Date in Snippet Preview for %SEOPostType%"
6180
  msgstr ""
6181
 
6182
- #: defaults.php:564
6183
  msgid ""
6184
  "User set the option Yoast SEO Meta Box for Posts/Pages in the Yoast SEO "
6185
  "plugin settings"
6186
  msgstr ""
6187
 
6188
- #: defaults.php:564
6189
  msgid "The option Yoast SEO Meta Box for %SEOPostType%"
6190
  msgstr ""
6191
 
6192
- #: defaults.php:565
6193
  msgid ""
6194
  "User Enabled/Disabled the advanced settings for authors in the Yoast SEO "
6195
  "plugin settings"
6196
  msgstr ""
6197
 
6198
- #: defaults.php:565
6199
  msgid "The Security: no advanced settings for authors feature"
6200
  msgstr ""
6201
 
6202
- #: defaults.php:576
6203
  msgid "Dummy"
6204
  msgstr ""
6205
 
6206
- #: wp-security-audit-log.php:818 wp-security-audit-log.php:845
 
6207
  #, php-format
6208
  msgid "Hey %1$s"
6209
  msgstr ""
6210
 
6211
- #: wp-security-audit-log.php:819
6212
  msgid ""
6213
  "Never miss an important update! Opt-in to our security and feature updates "
6214
  "notifications, and non-sensitive diagnostic tracking with freemius.com."
6215
  msgstr ""
6216
 
6217
- #: wp-security-audit-log.php:820 wp-security-audit-log.php:848
6218
  msgid "Note: "
6219
  msgstr ""
6220
 
6221
- #: wp-security-audit-log.php:821 wp-security-audit-log.php:849
6222
- msgid "NO AUDIT LOG ACTIVITY & DATA IS SENT BACK TO OUR SERVERS."
6223
  msgstr ""
6224
 
6225
- #: wp-security-audit-log.php:847
 
6226
  #, php-format
6227
  msgid ""
6228
  "Please help us improve %2$s! If you opt-in, some non-sensitive data about "
@@ -6230,7 +5249,8 @@ msgid ""
6230
  "use. If you skip this, that's okay! %2$s will still work just fine."
6231
  msgstr ""
6232
 
6233
- #: wp-security-audit-log.php:869
 
6234
  #, php-format
6235
  msgid ""
6236
  "Get a free 7-day trial of the premium edition of %s. No credit card "
@@ -6238,169 +5258,169 @@ msgid ""
6238
  msgstr ""
6239
 
6240
  #. Plugin Name of the plugin/theme
6241
- #: wp-security-audit-log.php:870
6242
  msgid "WP Activity Log"
6243
  msgstr ""
6244
 
6245
- #: wp-security-audit-log.php:874
6246
  msgid "Start free trial"
6247
  msgstr ""
6248
 
6249
- #: wp-security-audit-log.php:942
6250
  #, php-format
6251
  msgid ""
6252
- "You need to activate the licence key to use WP Securitity Audit Log Premium. "
6253
- "%2$s"
6254
  msgstr ""
6255
 
6256
- #: wp-security-audit-log.php:943
6257
  msgid "Activate the licence key now"
6258
  msgstr ""
6259
 
6260
- #: wp-security-audit-log.php:960
6261
  #, php-format
6262
  msgid ""
6263
  "The license is limited to %s sub-sites. You need to upgrade your license to "
6264
  "cover all the sub-sites on this network."
6265
  msgstr ""
6266
 
6267
- #: wp-security-audit-log.php:1070
6268
  msgid ""
6269
  "Error: You do not have sufficient permissions to disable this custom field."
6270
  msgstr ""
6271
 
6272
- #: wp-security-audit-log.php:1103
6273
  #, php-format
6274
  msgid ""
6275
  "Custom Field %1$s is no longer being monitored.<br />Enable the monitoring "
6276
  "of this custom field again from the"
6277
  msgstr ""
6278
 
6279
- #: wp-security-audit-log.php:1103
6280
  msgid "Excluded Objects"
6281
  msgstr ""
6282
 
6283
- #: wp-security-audit-log.php:1103
6284
  msgid " tab in the plugin settings"
6285
  msgstr ""
6286
 
6287
- #: wp-security-audit-log.php:1115
6288
  msgid "Error: You do not have sufficient permissions to disable this alert."
6289
  msgstr ""
6290
 
6291
- #: wp-security-audit-log.php:1139
6292
  #, php-format
6293
  msgid "Alert %1$s is no longer being monitored.<br /> %2$s"
6294
  msgstr ""
6295
 
6296
- #: wp-security-audit-log.php:1139
6297
  msgid ""
6298
  "You can enable this alert again from the Enable/Disable Alerts node in the "
6299
  "plugin menu."
6300
  msgstr ""
6301
 
6302
- #: wp-security-audit-log.php:1240
6303
  #, php-format
6304
  msgid ""
6305
  "You are using a version of PHP that is older than %s, which is no longer "
6306
  "supported."
6307
  msgstr ""
6308
 
6309
- #: wp-security-audit-log.php:1242
6310
  msgid ""
6311
  "Contact us on <a href=\"mailto:plugins@wpwhitesecurity.com"
6312
  "\">plugins@wpwhitesecurity.com</a> to help you switch the version of PHP you "
6313
  "are using."
6314
  msgstr ""
6315
 
6316
- #: wp-security-audit-log.php:1244
6317
  msgid ""
6318
  "The WP Activity Log plugin is a multisite network tool, so it has to be "
6319
  "activated at network level."
6320
  msgstr ""
6321
 
6322
- #: wp-security-audit-log.php:1246
6323
  msgid "Redirect me to the network dashboard"
6324
  msgstr ""
6325
 
6326
- #: wp-security-audit-log.php:1251
6327
  #, php-format
6328
  msgid "Please install the %s plugin on the MainWP dashboard."
6329
  msgstr ""
6330
 
6331
- #: wp-security-audit-log.php:1251
6332
  msgid "Activity Log for MainWP"
6333
  msgstr ""
6334
 
6335
- #: wp-security-audit-log.php:1253
6336
  #, php-format
6337
  msgid ""
6338
  "The WP Activity Log should be installed on the child sites only. Refer to "
6339
  "the %s for more information."
6340
  msgstr ""
6341
 
6342
- #: wp-security-audit-log.php:1253
6343
  msgid "getting started guide"
6344
  msgstr ""
6345
 
6346
- #: wp-security-audit-log.php:1339
6347
  msgid ""
6348
  "This plugin uses 3 tables in the WordPress database to store the activity "
6349
  "log and settings. It seems that these tables were not created."
6350
  msgstr ""
6351
 
6352
- #: wp-security-audit-log.php:1341
6353
  msgid ""
6354
  "This could happen because the database user does not have the right "
6355
  "privileges to create the tables in the database. We recommend you to update "
6356
  "the privileges and try enabling the plugin again."
6357
  msgstr ""
6358
 
6359
- #: wp-security-audit-log.php:1343
6360
  #, php-format
6361
  msgid ""
6362
  "If after doing so you still have issues, please send us an email on %s for "
6363
  "assistance."
6364
  msgstr ""
6365
 
6366
- #: wp-security-audit-log.php:1343
6367
  msgid "support@wpsecurityauditlog.com"
6368
  msgstr ""
6369
 
6370
- #: wp-security-audit-log.php:1925
6371
  msgid ""
6372
  "For security and auditing purposes, a record of all of your logged-in "
6373
  "actions and changes within the WordPress dashboard will be recorded in an "
6374
- "audit log with the <a href=\"https://wpactivitylog.com/\" target=\"_blank"
6375
  "\">WP Activity Log plugin</a>. The audit log also includes the IP address "
6376
  "where you accessed this site from."
6377
  msgstr ""
6378
 
6379
- #: wp-security-audit-log.php:1944
6380
  msgid "Every 6 hours"
6381
  msgstr ""
6382
 
6383
- #: wp-security-audit-log.php:1948
6384
  msgid "Every 45 minutes"
6385
  msgstr ""
6386
 
6387
- #: wp-security-audit-log.php:1952
6388
  msgid "Every 30 minutes"
6389
  msgstr ""
6390
 
6391
- #: wp-security-audit-log.php:1956
6392
  msgid "Every 15 minutes"
6393
  msgstr ""
6394
 
6395
- #: wp-security-audit-log.php:1960
6396
  msgid "Every 10 minutes"
6397
  msgstr ""
6398
 
6399
- #: wp-security-audit-log.php:1964
6400
  msgid "Every 1 minute"
6401
  msgstr ""
6402
 
6403
- #: wp-security-audit-log.php:1978
 
6404
  #, php-format
6405
  msgid "Method %1$s is deprecated since version %2$s!"
6406
  msgstr ""
@@ -6415,8 +5435,8 @@ msgid ""
6415
  "of everything happening on your WordPress including WordPress users "
6416
  "activity. Similar to Windows Event Log and Linux Syslog, WP Activity Log "
6417
  "generates a security alert for everything that happens on your WordPress "
6418
- "blogs and websites. Use the Audit Log Viewer included in the plugin to see "
6419
- "all the security alerts."
6420
  msgstr ""
6421
 
6422
  #. Author of the plugin/theme
3
  msgstr ""
4
  "Plural-Forms: nplurals=INTEGER; plural=EXPRESSION;\n"
5
  "Project-Id-Version: WP Activity Log\n"
6
+ "POT-Creation-Date: 2020-08-12 06:14+0200\n"
7
+ "PO-Revision-Date: 2020-08-12 06:14+0200\n"
8
  "Last-Translator: \n"
9
  "Language-Team: \n"
10
  "MIME-Version: 1.0\n"
11
  "Content-Type: text/plain; charset=UTF-8\n"
12
  "Content-Transfer-Encoding: 8bit\n"
13
+ "X-Generator: Poedit 2.3.1\n"
14
  "X-Poedit-Basepath: ..\n"
15
+ "X-Poedit-Flags-xgettext: --add-comments=translators:\n"
16
  "X-Poedit-WPHeader: wp-security-audit-log.php\n"
17
  "X-Poedit-SourceCharset: UTF-8\n"
18
  "X-Poedit-KeywordsList: __;_e;_n:1,2;_x:1,2c;_ex:1,2c;_nx:4c,1,2;esc_attr__;"
19
  "esc_attr_e;esc_attr_x:1,2c;esc_html__;esc_html_e;esc_html_x:1,2c;_n_noop:1,2;"
20
  "_nx_noop:3c,1,2;__ngettext_noop:1,2\n"
21
  "X-Poedit-SearchPath-0: .\n"
22
+ "X-Poedit-SearchPathExcluded-0: *.min.js\n"
23
 
24
+ #. translators: Event ID
25
+ #: classes/AlertManager.php:363
26
  #, php-format
27
  msgid "Event with code %d has not be registered."
28
  msgstr ""
29
 
30
+ #: classes/AlertManager.php:419
31
  #, php-format
32
  msgid "Event %s already registered with WP Activity Log."
33
  msgstr ""
34
 
35
+ #: classes/AlertManager.php:492
36
  msgid ""
37
  "You have custom events that are using the same ID or IDs which are already "
38
  "registered in the plugin, so they have been disabled."
39
  msgstr ""
40
 
41
+ #: classes/AlertManager.php:495
42
  #, php-format
43
  msgid "%4$s to help you solve this issue."
44
  msgstr ""
45
 
46
+ #: classes/AlertManager.php:497
47
  msgid "ERROR:"
48
  msgstr ""
49
 
50
+ #: classes/AlertManager.php:499
51
  msgid "Contact us"
52
  msgstr ""
53
 
54
+ #: classes/AlertManager.php:1106 classes/AuditLogListView.php:333
55
+ #: classes/AuditLogListView.php:367 classes/Views/Settings.php:1162
56
  #: classes/WidgetManager.php:76
57
  msgid "User"
58
  msgstr ""
59
 
60
+ #: classes/AlertManager.php:1107 classes/AlertManager.php:1893
61
  #: classes/AuditLogGridView.php:517 classes/AuditLogListView.php:543
62
+ #: defaults.php:373
63
  msgid "System"
64
  msgstr ""
65
 
66
+ #: classes/AlertManager.php:1108 classes/AuditLogGridView.php:508
67
  #: classes/AuditLogListView.php:531
68
  msgid "Plugin"
69
  msgstr ""
70
 
71
+ #: classes/AlertManager.php:1109
72
  msgid "Database"
73
  msgstr ""
74
 
75
+ #: classes/AlertManager.php:1110
76
  msgid "Post"
77
  msgstr ""
78
 
79
+ #: classes/AlertManager.php:1111 classes/AlertManager.php:1115
80
  msgid "File"
81
  msgstr ""
82
 
83
+ #: classes/AlertManager.php:1112
84
  msgid "Tag"
85
  msgstr ""
86
 
87
+ #: classes/AlertManager.php:1113
88
  msgid "Comment"
89
  msgstr ""
90
 
91
+ #: classes/AlertManager.php:1114
92
  msgid "Setting"
93
  msgstr ""
94
 
95
+ #: classes/AlertManager.php:1116
96
  msgid "System Setting"
97
  msgstr ""
98
 
99
+ #: classes/AlertManager.php:1117
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
100
  msgid "MainWP Network"
101
  msgstr ""
102
 
103
+ #: classes/AlertManager.php:1118
104
  msgid "MainWP"
105
  msgstr ""
106
 
107
+ #: classes/AlertManager.php:1119 classes/Views/ToggleAlerts.php:214
108
+ #: classes/Views/ToggleAlerts.php:344 defaults.php:427
109
  msgid "Yoast SEO"
110
  msgstr ""
111
 
112
+ #: classes/AlertManager.php:1120
113
  msgid "Yoast SEO Meta Box"
114
  msgstr ""
115
 
116
+ #: classes/AlertManager.php:1121
117
  msgid "Category"
118
  msgstr ""
119
 
120
+ #: classes/AlertManager.php:1122
121
  msgid "Custom Field"
122
  msgstr ""
123
 
124
+ #: classes/AlertManager.php:1123
125
  msgid "Widget"
126
  msgstr ""
127
 
128
+ #: classes/AlertManager.php:1124
129
  msgid "Menu"
130
  msgstr ""
131
 
132
+ #: classes/AlertManager.php:1125
133
  msgid "Theme"
134
  msgstr ""
135
 
136
+ #: classes/AlertManager.php:1126
137
  msgid "Activity Logs"
138
  msgstr ""
139
 
140
+ #: classes/AlertManager.php:1127
141
  msgid "Multisite Network"
142
  msgstr ""
143
 
144
+ #: classes/AlertManager.php:1128
145
  msgid "IP Address"
146
  msgstr ""
147
 
148
+ #: classes/AlertManager.php:1144
149
  msgid "unknown object"
150
  msgstr ""
151
 
152
+ #: classes/AlertManager.php:1181
153
  msgid "Login"
154
  msgstr ""
155
 
156
+ #: classes/AlertManager.php:1182
157
  msgid "Logout"
158
  msgstr ""
159
 
160
+ #: classes/AlertManager.php:1183
161
  msgid "Installed"
162
  msgstr ""
163
 
164
+ #: classes/AlertManager.php:1184
165
  msgid "Activated"
166
  msgstr ""
167
 
168
+ #: classes/AlertManager.php:1185
169
  msgid "Deactivated"
170
  msgstr ""
171
 
172
+ #: classes/AlertManager.php:1186
173
  msgid "Uninstalled"
174
  msgstr ""
175
 
176
+ #: classes/AlertManager.php:1187
177
  msgid "Updated"
178
  msgstr ""
179
 
180
+ #: classes/AlertManager.php:1188
181
  msgid "Created"
182
  msgstr ""
183
 
184
+ #: classes/AlertManager.php:1189
185
  msgid "Modified"
186
  msgstr ""
187
 
188
+ #: classes/AlertManager.php:1190
189
  msgid "Deleted"
190
  msgstr ""
191
 
192
+ #: classes/AlertManager.php:1191
193
  msgid "Published"
194
  msgstr ""
195
 
196
+ #: classes/AlertManager.php:1192
197
  msgid "Approved"
198
  msgstr ""
199
 
200
+ #: classes/AlertManager.php:1193
201
  msgid "Unapproved"
202
  msgstr ""
203
 
204
+ #: classes/AlertManager.php:1194
205
  msgid "Enabled"
206
  msgstr ""
207
 
208
+ #: classes/AlertManager.php:1195
209
  msgid "Disabled"
210
  msgstr ""
211
 
212
+ #: classes/AlertManager.php:1196
213
  msgid "Added"
214
  msgstr ""
215
 
216
+ #: classes/AlertManager.php:1197
217
  msgid "Failed Login"
218
  msgstr ""
219
 
220
+ #: classes/AlertManager.php:1198
221
  msgid "Blocked"
222
  msgstr ""
223
 
224
+ #: classes/AlertManager.php:1199
225
  msgid "Uploaded"
226
  msgstr ""
227
 
228
+ #: classes/AlertManager.php:1200
229
  msgid "Restored"
230
  msgstr ""
231
 
232
+ #: classes/AlertManager.php:1201
233
  msgid "Opened"
234
  msgstr ""
235
 
236
+ #: classes/AlertManager.php:1202
237
  msgid "Viewed"
238
  msgstr ""
239
 
240
+ #: classes/AlertManager.php:1203
241
  msgid "Started"
242
  msgstr ""
243
 
244
+ #: classes/AlertManager.php:1204
245
  msgid "Stopped"
246
  msgstr ""
247
 
248
+ #: classes/AlertManager.php:1205
249
  msgid "Removed"
250
  msgstr ""
251
 
252
+ #: classes/AlertManager.php:1206
253
  msgid "Unblocked"
254
  msgstr ""
255
 
256
+ #: classes/AlertManager.php:1207
257
  msgid "Renamed"
258
  msgstr ""
259
 
260
+ #: classes/AlertManager.php:1208
261
  msgid "Duplicated"
262
  msgstr ""
263
 
264
+ #: classes/AlertManager.php:1225
265
  msgid "unknown type"
266
  msgstr ""
267
 
268
+ #: classes/AlertManager.php:1470 classes/Views/ToggleAlerts.php:235
269
+ #: classes/Views/ToggleAlerts.php:267 defaults.php:268
270
  msgid "Pages"
271
  msgstr ""
272
 
273
+ #: classes/AlertManager.php:1470 classes/Views/ToggleAlerts.php:235
274
+ #: classes/Views/ToggleAlerts.php:267 defaults.php:228
275
  msgid "Custom Post Types"
276
  msgstr ""
277
 
278
+ #: classes/AlertManager.php:1792
279
  msgid "System Activity"
280
  msgstr ""
281
 
282
+ #: classes/AlertManager.php:1852 classes/ConstantManager.php:146
283
  msgid "Unknown error code."
284
  msgstr ""
285
 
286
+ #: classes/AlertManager.php:1859 classes/AlertManager.php:1871
287
  msgid "Unknown Site"
288
  msgstr ""
289
 
312
  msgstr ""
313
 
314
  #: classes/AuditLogGridView.php:229 classes/AuditLogListView.php:235
315
+ #: classes/Views/AuditLog.php:628
316
  msgid "All Sites"
317
  msgstr ""
318
 
331
 
332
  #: classes/AuditLogGridView.php:315 classes/AuditLogGridView.php:341
333
  #: classes/AuditLogListView.php:331 classes/AuditLogListView.php:361
334
+ #: classes/Views/Settings.php:1158 classes/Views/ToggleAlerts.php:318
335
  msgid "Severity"
336
  msgstr ""
337
 
372
  msgstr ""
373
 
374
  #: classes/AuditLogGridView.php:511 classes/AuditLogListView.php:535
375
+ #: defaults.php:332
376
  msgid "Plugins"
377
  msgstr ""
378
 
419
  msgstr ""
420
 
421
  #: classes/AuditLogGridView.php:724 classes/AuditLogListView.php:724
422
+ #: classes/Settings.php:1794
423
  msgid "Download the log file"
424
  msgstr ""
425
 
426
  #: classes/AuditLogGridView.php:744 classes/AuditLogListView.php:744
427
+ #: classes/Settings.php:1836
428
  msgid "Download the log file."
429
  msgstr ""
430
 
431
  #: classes/AuditLogGridView.php:752 classes/AuditLogListView.php:752
432
+ #: classes/Settings.php:1849 classes/Settings.php:2089
433
  msgid "published"
434
  msgstr ""
435
 
436
+ #. translators: Mailto link for support.
437
  #: classes/AuditLogGridView.php:780 classes/AuditLogListView.php:780
438
+ #: classes/Settings.php:1875 classes/Settings.php:2115
439
  #, php-format
440
  msgid "Contact us on %s for assistance"
441
  msgstr ""
465
  msgstr ""
466
 
467
  #: classes/AuditLogListView.php:446 classes/Models/Occurrence.php:83
 
468
  msgid "Alert message not found."
469
  msgstr ""
470
 
471
  #: classes/AuditLogListView.php:447 classes/Models/Occurrence.php:84
 
472
  msgid "Alert description not found."
473
  msgstr ""
474
 
478
  "valid."
479
  msgstr ""
480
 
481
+ #. translators: 1 - mysqli error code, 2 - mysqli error message
482
  #: classes/Connector/MySQLDB.php:69
483
  #, php-format
484
  msgid "Code %1$d: %2$s"
488
  msgid "Error establishing a database connection"
489
  msgstr ""
490
 
491
+ #. translators: 1: wp-config.php. 2: database host
492
  #: classes/Connector/wp-db-custom.php:216
493
  #, php-format
494
  msgid ""
509
  msgid "Are you sure that the database server is running?"
510
  msgstr ""
511
 
512
+ #. translators: %s: support forums URL
513
  #: classes/Connector/wp-db-custom.php:229
514
  #, php-format
515
  msgid ""
526
  msgid "Can&#8217;t select database"
527
  msgstr ""
528
 
529
+ #. translators: %s: database name
530
  #: classes/Connector/wp-db-custom.php:287
531
  #, php-format
532
  msgid ""
538
  msgid "Are you sure it exists?"
539
  msgstr ""
540
 
541
+ #. translators: 1: database user, 2: database name
542
  #: classes/Connector/wp-db-custom.php:296
543
  #, php-format
544
  msgid "Does the user %1$s have permission to use the %2$s database?"
545
  msgstr ""
546
 
547
+ #. translators: %s: database name
548
  #: classes/Connector/wp-db-custom.php:303
549
  #, php-format
550
  msgid ""
552
  "it would be like <code>username_%1$s</code>. Could that be the problem?"
553
  msgstr ""
554
 
555
+ #. translators: %s: support forums URL
556
  #: classes/Connector/wp-db-custom.php:311
557
  #, php-format
558
  msgid ""
566
  msgstr ""
567
 
568
  #: classes/ConstantManager.php:152 classes/ConstantManager.php:158
569
+ #: classes/Views/ToggleAlerts.php:442 classes/Views/ToggleAlerts.php:448
570
  msgid "Critical"
571
  msgstr ""
572
 
573
+ #: classes/ConstantManager.php:154 classes/Views/ToggleAlerts.php:444
574
  msgid "Warning"
575
  msgstr ""
576
 
577
+ #: classes/ConstantManager.php:156 classes/Views/ToggleAlerts.php:446
578
+ #: classes/Views/ToggleAlerts.php:458
579
  msgid "Notification"
580
  msgstr ""
581
 
582
+ #: classes/ConstantManager.php:160 classes/Views/ToggleAlerts.php:450
583
  msgid "High"
584
  msgstr ""
585
 
586
+ #: classes/ConstantManager.php:162 classes/Views/ToggleAlerts.php:452
587
  msgid "Medium"
588
  msgstr ""
589
 
590
+ #: classes/ConstantManager.php:164 classes/Views/ToggleAlerts.php:454
591
  msgid "Low"
592
  msgstr ""
593
 
594
+ #: classes/ConstantManager.php:166 classes/Views/ToggleAlerts.php:456
595
  msgid "Informational"
596
  msgstr ""
597
 
612
  msgid "BBPress"
613
  msgstr ""
614
 
615
+ #: classes/Models/Occurrence.php:208 classes/Views/ToggleAlerts.php:329
616
+ msgid "WooCommerce"
617
+ msgstr ""
618
+
619
+ #: classes/Models/Occurrence.php:212
620
  msgid "WFCM"
621
  msgstr ""
622
 
623
+ #: classes/Models/Occurrence.php:234
624
  #, php-format
625
  msgid ""
626
  "Alert message was not available, this may have been a custom alert that no "
628
  msgstr ""
629
 
630
  #: classes/Sensors/Content.php:996 classes/Sensors/Content.php:1004
 
631
  msgid "Password Protected"
632
  msgstr ""
633
 
634
  #: classes/Sensors/Content.php:998 classes/Sensors/Content.php:1006
 
635
  msgid "Private"
636
  msgstr ""
637
 
638
  #: classes/Sensors/Content.php:1000 classes/Sensors/Content.php:1008
 
639
  msgid "Public"
640
  msgstr ""
641
 
642
+ #: classes/Sensors/FrontendWooCommerce.php:228 classes/Sensors/Public.php:413
 
643
  msgid "In stock"
644
  msgstr ""
645
 
646
+ #: classes/Sensors/FrontendWooCommerce.php:230 classes/Sensors/Public.php:415
 
647
  msgid "Out of stock"
648
  msgstr ""
649
 
650
+ #: classes/Sensors/FrontendWooCommerce.php:232 classes/Sensors/Public.php:417
 
651
  msgid "On backorder"
652
  msgstr ""
653
 
654
+ #. translators: %s: Directory path.
655
+ #: classes/Settings.php:272
656
+ #, php-format
657
+ msgid ""
658
+ "Unable to create directory %s. Is its parent directory writable by the "
659
+ "server?"
 
 
 
 
 
 
 
 
 
 
660
  msgstr ""
661
 
662
+ #: classes/Settings.php:593
663
  msgid "This function is deprecated"
664
  msgstr ""
665
 
666
+ #: classes/Settings.php:1753
667
  msgid "View the content changes"
668
  msgstr ""
669
 
670
+ #: classes/Settings.php:1758
671
  msgid "View post in the editor"
672
  msgstr ""
673
 
674
+ #: classes/Settings.php:1761
675
  msgid "View Order"
676
  msgstr ""
677
 
678
+ #: classes/Settings.php:1766
679
  msgid "View category"
680
  msgstr ""
681
 
682
+ #: classes/Settings.php:1769
683
  msgid "View tag"
684
  msgstr ""
685
 
686
+ #: classes/Settings.php:1773
687
  msgid "User profile page"
688
  msgstr ""
689
 
690
+ #: classes/Settings.php:1887
691
  msgid "Increase maximum file size limit"
692
  msgstr ""
693
 
694
+ #: classes/Settings.php:1890
695
  msgid "Contact Support"
696
  msgstr ""
697
 
698
+ #: classes/Settings.php:2127
699
  msgid "plugin settings"
700
  msgstr ""
701
 
702
+ #: classes/Settings.php:2130
703
  msgid "contact our support"
704
  msgstr ""
705
 
706
+ #: classes/Settings.php:2336
707
  msgid "Root directory of WordPress (excluding sub directories)"
708
  msgstr ""
709
 
710
+ #: classes/Settings.php:2337
711
  msgid "WP Admin directory (/wp-admin/)"
712
  msgstr ""
713
 
714
+ #: classes/Settings.php:2338
715
  msgid "WP Includes directory (/wp-includes/)"
716
  msgstr ""
717
 
718
+ #: classes/Settings.php:2339
719
  msgid ""
720
  "/wp-content/ directory (excluding plugins, themes & uploads directories)"
721
  msgstr ""
722
 
723
+ #: classes/Settings.php:2340
724
  msgid "Themes directory (/wp-content/themes/)"
725
  msgstr ""
726
 
727
+ #: classes/Settings.php:2341
728
  msgid "Plugins directory (/wp-content/plugins/)"
729
  msgstr ""
730
 
731
+ #: classes/Settings.php:2342
732
  msgid "Uploads directory (/wp-content/uploads/)"
733
  msgstr ""
734
 
735
+ #: classes/Settings.php:2347
736
  msgid ""
737
  "Uploads directory of all sub sites on this network (/wp-content/sites/*)"
738
  msgstr ""
761
  msgstr ""
762
 
763
  #: classes/Utilities/PluginInstallAndActivate.php:100
764
+ #: classes/Views/SetupWizard.php:884
765
  msgid "Extension for "
766
  msgstr ""
767
 
768
  #: classes/Utilities/PluginInstallAndActivate.php:105
769
+ #: classes/Views/SetupWizard.php:889
770
  msgid "Extension installed, activate now?"
771
  msgstr ""
772
 
773
  #: classes/Utilities/PluginInstallAndActivate.php:107
774
+ #: classes/Views/SetupWizard.php:274 classes/Views/SetupWizard.php:891
775
+ #: wp-security-audit-log.php:1247
776
  msgid "Extension installed"
777
  msgstr ""
778
 
779
  #: classes/Utilities/PluginInstallAndActivate.php:109
780
+ #: classes/Views/AuditLog.php:283 classes/Views/SetupWizard.php:893
781
  msgid "Install Extension"
782
  msgstr ""
783
 
785
  msgid "Tried to install a zip or slug that was not in the allowed list"
786
  msgstr ""
787
 
788
+ #: classes/ViewManager.php:140
789
  msgid ""
790
  "WP Activity Log requires Website File Changes Monitor 1.6.0. Please upgrade "
791
  "that plugin."
792
  msgstr ""
793
 
794
+ #: classes/ViewManager.php:281
795
  msgid "Free Premium Trial"
796
  msgstr ""
797
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
798
  #: classes/Views/AuditLog.php:99
799
  msgid ""
800
  "Get instantly alerted of critical changes via SMS & email, search the "
877
  msgid "No, thank you"
878
  msgstr ""
879
 
880
+ #: classes/Views/AuditLog.php:286
881
  msgid "Install Extensions"
882
  msgstr ""
883
 
884
+ #: classes/Views/AuditLog.php:298
885
  msgid "You have"
886
  msgstr ""
887
 
888
+ #: classes/Views/AuditLog.php:300
889
  msgid "installed. Keep a log of changes in"
890
  msgstr ""
891
 
892
+ #: classes/Views/AuditLog.php:360 classes/Views/Settings.php:92
893
  msgid "Activity Log Viewer"
894
  msgstr ""
895
 
896
+ #: classes/Views/AuditLog.php:387
897
  msgid "Log Viewer"
898
  msgstr ""
899
 
900
+ #: classes/Views/AuditLog.php:542 classes/Views/Settings.php:325
901
+ #: classes/Views/ToggleAlerts.php:132
902
  msgid "You do not have sufficient permissions to access this page."
903
  msgstr ""
904
 
905
+ #: classes/Views/AuditLog.php:590
906
  msgid ""
907
  "Thank you for installing WP Activity Log. Do you want to run the wizard to "
908
  "configure the basic plugin settings?"
909
  msgstr ""
910
 
911
+ #: classes/Views/AuditLog.php:592 classes/Views/Settings.php:528
912
+ #: classes/Views/Settings.php:555 classes/Views/Settings.php:621
913
+ #: classes/Views/Settings.php:679 classes/Views/Settings.php:1194
914
+ #: classes/Views/Settings.php:1485 classes/Views/Settings.php:1544
915
+ #: classes/Views/Settings.php:1585 classes/Views/Settings.php:1606
916
+ #: classes/Views/Settings.php:1616 classes/Views/SetupWizard.php:564
917
+ #: classes/Views/SetupWizard.php:612
918
  msgid "Yes"
919
  msgstr ""
920
 
921
+ #: classes/Views/AuditLog.php:593 classes/Views/Settings.php:533
922
+ #: classes/Views/Settings.php:560 classes/Views/Settings.php:651
923
+ #: classes/Views/Settings.php:689 classes/Views/Settings.php:1199
924
+ #: classes/Views/Settings.php:1490 classes/Views/Settings.php:1551
925
+ #: classes/Views/Settings.php:1592 classes/Views/Settings.php:1607
926
+ #: classes/Views/Settings.php:1617 classes/Views/SetupWizard.php:569
927
+ #: classes/Views/SetupWizard.php:617
928
  msgid "No"
929
  msgstr ""
930
 
931
+ #: classes/Views/AuditLog.php:627
932
  msgid "Please enter the number of alerts you would like to see on one page:"
933
  msgstr ""
934
 
935
+ #: classes/Views/AuditLog.php:629
936
  msgid "No Results"
937
  msgstr ""
938
 
939
+ #: classes/Views/AuditLog.php:813
940
  msgid "No users found."
941
  msgstr ""
942
 
943
+ #: classes/Views/AuditLog.php:816 classes/Views/AuditLog.php:877
944
+ #: classes/Views/AuditLog.php:903 classes/Views/AuditLog.php:1223
945
+ #: classes/Views/AuditLog.php:1293 classes/Views/Settings.php:234
946
+ #: classes/Views/Settings.php:1793 classes/Views/Settings.php:1821
947
+ #: classes/Views/Settings.php:1851 classes/Views/SetupWizard.php:96
948
+ msgid "Nonce verification failed."
949
+ msgstr ""
950
+
951
+ #: classes/Views/AuditLog.php:835
952
  msgid "Log file does not exist."
953
  msgstr ""
954
 
955
+ #: classes/Views/AuditLog.php:868
956
  msgid "Request to get log file failed."
957
  msgstr ""
958
 
959
+ #: classes/Views/AuditLog.php:943
960
  msgid "Freemius opt choice selected."
961
  msgstr ""
962
 
963
+ #: classes/Views/AuditLog.php:950
964
  msgid "Freemius opt choice not found."
965
  msgstr ""
966
 
967
+ #. translators: 1 - an opening link tag, 2 - the closing tag.
968
+ #: classes/Views/AuditLog.php:1038
969
  #, php-format
970
  msgid ""
971
+ "<br>An error occurred when trying to install and activate the plugin. Please "
972
  "try install it again from the %1$sevent settings%2$s page."
973
  msgstr ""
974
 
975
+ #: classes/Views/AuditLog.php:1137
976
  msgid "WordPress Activity Log"
977
  msgstr ""
978
 
979
+ #: classes/Views/AuditLog.php:1138
980
  msgid ""
981
  "When a user makes a change on your website the plugin will keep a record of "
982
  "that event here. Right now there is nothing because this is a new install."
983
  msgstr ""
984
 
985
+ #: classes/Views/AuditLog.php:1139
986
  msgid "Thank you for using WP Activity Log"
987
  msgstr ""
988
 
989
+ #: classes/Views/AuditLog.php:1160
990
  msgid "Error: You do not have sufficient permissions to exclude this URL."
991
  msgstr ""
992
 
993
+ #: classes/Views/AuditLog.php:1206
994
  msgid "You do not have sufficient permissions to dismiss this notice."
995
  msgstr ""
996
 
997
+ #: classes/Views/AuditLog.php:1276
998
  msgid "Access Denied"
999
  msgstr ""
1000
 
1082
  msgstr ""
1083
 
1084
  #: classes/Views/ExternalDB.php:114
1085
+ msgid "Activity log database & integration tools"
1086
  msgstr ""
1087
 
1088
  #: classes/Views/ExternalDB.php:115
1187
  msgid ""
1188
  "Refer to the list of WordPress security events for a complete list of Events "
1189
  "and IDs that the plugin uses to keep a log of all the changes in the "
1190
+ "WordPress activity log."
1191
  msgstr ""
1192
 
1193
  #: classes/Views/Help.php:198
1422
  msgid "General"
1423
  msgstr ""
1424
 
1425
+ #: classes/Views/Settings.php:99 classes/Views/ToggleAlerts.php:434
1426
+ #: defaults.php:468
1427
  msgid "File Changes"
1428
  msgstr ""
1429
 
1432
  msgstr ""
1433
 
1434
  #: classes/Views/Settings.php:112
 
 
 
 
1435
  msgid "Advanced Settings"
1436
  msgstr ""
1437
 
1438
+ #: classes/Views/Settings.php:160 classes/Views/Settings.php:174
1439
  msgid "Settings"
1440
  msgstr ""
1441
 
1442
+ #: classes/Views/Settings.php:201
1443
  msgid "Current user is not allowed to save settings."
1444
  msgstr ""
1445
 
1446
+ #: classes/Views/Settings.php:207
1447
  msgid "Unknown settings tab."
1448
  msgstr ""
1449
 
1450
+ #: classes/Views/Settings.php:219 classes/Views/Settings.php:1881
1451
+ #: classes/Views/Settings.php:1910 classes/Views/SetupWizard.php:83
1452
+ msgid "Access Denied."
1453
+ msgstr ""
1454
+
1455
+ #: classes/Views/Settings.php:244 classes/Views/SetupWizard.php:106
1456
  msgid "Invalid input."
1457
  msgstr ""
1458
 
1459
+ #: classes/Views/Settings.php:337
1460
  msgid "Message sent successfully."
1461
  msgstr ""
1462
 
1463
+ #: classes/Views/Settings.php:341 classes/Views/ToggleAlerts.php:149
1464
  msgid "Settings have been saved."
1465
  msgstr ""
1466
 
1467
+ #: classes/Views/Settings.php:347 classes/Views/ToggleAlerts.php:155
1468
  msgid "Error: "
1469
  msgstr ""
1470
 
1471
+ #: classes/Views/Settings.php:359
1472
  msgid "Old data successfully purged."
1473
  msgstr ""
1474
 
1475
+ #: classes/Views/Settings.php:365
1476
  msgid "No data is old enough to be purged."
1477
  msgstr ""
1478
 
1479
+ #: classes/Views/Settings.php:396
1480
  msgid "Send Message"
1481
  msgstr ""
1482
 
1483
+ #: classes/Views/Settings.php:447
1484
  msgid ""
1485
  "Need help with setting up the plugin to meet your requirements? <a href="
1486
  "\"https://wpactivitylog.com/contact/?"
1489
  "call</a> with our experts for just $50."
1490
  msgstr ""
1491
 
1492
+ #: classes/Views/Settings.php:449
1493
  msgid "Use infinite scroll or pagination for the event viewer?"
1494
  msgstr ""
1495
 
1496
+ #. translators: Learn more link.
1497
+ #: classes/Views/Settings.php:454
1498
  #, php-format
1499
  msgid ""
1500
  "When using infinite scroll the event viewer and search results %s load up "
1501
  "much faster and require less resources."
1502
  msgstr ""
1503
 
1504
+ #: classes/Views/Settings.php:455
1505
  msgid "(Premium feature)"
1506
  msgstr ""
1507
 
1508
+ #: classes/Views/Settings.php:462
1509
  msgid "Select event viewer view type:"
1510
  msgstr ""
1511
 
1512
+ #: classes/Views/Settings.php:467
1513
  msgid "Infinite Scroll (Recommended)"
1514
  msgstr ""
1515
 
1516
+ #: classes/Views/Settings.php:472
1517
  msgid "Pagination"
1518
  msgstr ""
1519
 
1520
+ #: classes/Views/Settings.php:483
1521
  msgid "Do you want the activity log viewer to auto refresh?"
1522
  msgstr ""
1523
 
1524
+ #: classes/Views/Settings.php:484
1525
  msgid ""
1526
  "The activity log viewer auto refreshes every 30 seconds when opened so you "
1527
  "can see the latest events as they happen almost in real time."
1528
  msgstr ""
1529
 
1530
+ #: classes/Views/Settings.php:488
1531
+ msgid "Refresh activity log viewer"
1532
  msgstr ""
1533
 
1534
+ #: classes/Views/Settings.php:494
1535
  msgid "Auto refresh"
1536
  msgstr ""
1537
 
1538
+ #: classes/Views/Settings.php:499
1539
  msgid "Do not auto refresh"
1540
  msgstr ""
1541
 
1542
+ #: classes/Views/Settings.php:509
1543
  msgid "Display latest events widget in Dashboard & Admin bar"
1544
  msgstr ""
1545
 
1546
+ #. translators: Max number of dashboard widget alerts.
1547
+ #: classes/Views/Settings.php:514
1548
  #, php-format
1549
  msgid ""
1550
  "The events widget displays the latest %d security events in the dashboard "
1551
  "and the admin bar notification displays the latest event."
1552
  msgstr ""
1553
 
1554
+ #: classes/Views/Settings.php:522
1555
  msgid "Dashboard Widget"
1556
  msgstr ""
1557
 
1558
+ #: classes/Views/Settings.php:543
1559
  msgid "Admin Bar Notification"
1560
  msgstr ""
1561
 
1562
+ #: classes/Views/Settings.php:546
1563
  msgid "Admin Bar Notification (Premium)"
1564
  msgstr ""
1565
 
1566
+ #: classes/Views/Settings.php:570
1567
  msgid "Admin Bar Notification Updates"
1568
  msgstr ""
1569
 
1570
+ #: classes/Views/Settings.php:573
1571
  msgid "Admin Bar Notification Updates (Premium)"
1572
  msgstr ""
1573
 
1574
+ #: classes/Views/Settings.php:582
1575
  msgid "Update in near real time"
1576
  msgstr ""
1577
 
1578
+ #: classes/Views/Settings.php:587
1579
  msgid "Update only on page refreshes"
1580
  msgstr ""
1581
 
1582
+ #: classes/Views/Settings.php:597
1583
  msgid "Add user notification on the WordPress login page"
1584
  msgstr ""
1585
 
1586
+ #: classes/Views/Settings.php:598
1587
  msgid ""
1588
  "Many compliance regulations (such as the GDPR) require website "
1589
  "administrators to tell the users of their website that all the changes they "
1590
  "do when logged in are being logged."
1591
  msgstr ""
1592
 
1593
+ #: classes/Views/Settings.php:602
1594
  msgid "Login Page Notification"
1595
  msgstr ""
1596
 
1597
+ #: classes/Views/Settings.php:627
1598
  msgid ""
1599
  "For security and auditing purposes, a record of all of your logged-in "
1600
  "actions and changes within the WordPress dashboard will be recorded in an "
1601
+ "activity log with the <a href=\"https://wpactivitylog.com/?"
1602
  "utm_source=plugin&utm_medium=referral&utm_campaign=WSAL&utm_content=settings"
1603
  "+pages\" target=\"_blank\">WP Activity Log plugin</a>. The audit log also "
1604
  "includes the IP address where you accessed this site from."
1605
  msgstr ""
1606
 
1607
+ #: classes/Views/Settings.php:645
1608
  msgid "<strong>Note: </strong>"
1609
  msgstr ""
1610
 
1611
+ #: classes/Views/Settings.php:645
1612
  msgid ""
1613
  "The only HTML code allowed in the login page notification is for links ( < a "
1614
  "href >< /a > )."
1615
  msgstr ""
1616
 
1617
+ #: classes/Views/Settings.php:661
1618
  msgid "Is your website running behind a firewall or reverse proxy?"
1619
  msgstr ""
1620
 
1621
+ #. translators: Learn more link.
1622
+ #: classes/Views/Settings.php:666
1623
  #, php-format
1624
  msgid ""
1625
  "If your website is running behind a firewall set this option to yes so the "
1626
  "plugin retrieves the end user’s IP address from the proxy header - %s."
1627
  msgstr ""
1628
 
1629
+ #: classes/Views/Settings.php:667 classes/Views/Settings.php:713
1630
+ #: classes/Views/Settings.php:769
1631
  msgid "learn more"
1632
  msgstr ""
1633
 
1634
+ #: classes/Views/Settings.php:674
1635
  msgid "Reverse Proxy / Firewall Options"
1636
  msgstr ""
1637
 
1638
+ #: classes/Views/Settings.php:684
1639
  msgid ""
1640
  "Filter internal IP addresses from the proxy headers. Enable this option only "
1641
  "if you are\tare still seeing the internal IP addresses of the firewall or "
1642
  "proxy."
1643
  msgstr ""
1644
 
1645
+ #: classes/Views/Settings.php:700
1646
  msgid "Who can change the plugin settings?"
1647
  msgstr ""
1648
 
1649
+ #. translators: Learn more link.
1650
+ #: classes/Views/Settings.php:712
1651
  #, php-format
1652
  msgid ""
1653
  "By default only users with administrator role (single site) and super "
1655
  "you can restrict the privileges to just your user - %s."
1656
  msgstr ""
1657
 
1658
+ #: classes/Views/Settings.php:723
1659
+ msgid "Restrict plugin access"
1660
  msgstr ""
1661
 
1662
+ #: classes/Views/Settings.php:728 classes/Views/Settings.php:784
1663
  msgid "Only me"
1664
  msgstr ""
1665
 
1666
+ #: classes/Views/Settings.php:735
1667
+ msgid "All superadmins"
1668
  msgstr ""
1669
 
1670
+ #: classes/Views/Settings.php:737
1671
+ msgid "All administrators"
1672
  msgstr ""
1673
 
1674
+ #: classes/Views/Settings.php:751
1675
  msgid "Allow other users to view the activity log"
1676
  msgstr ""
1677
 
1678
+ #: classes/Views/Settings.php:763
1679
+ msgid ""
1680
+ "By default only super administrators and the child sites' administrators can "
1681
+ "view the WordPress activity log. Though you can change this by using the "
1682
+ "setting below."
1683
+ msgstr ""
1684
+
1685
+ #: classes/Views/Settings.php:765
1686
+ msgid ""
1687
+ "By default only users with administrator role can view the WordPress "
1688
+ "activity log. To allow someone who does not have an admin role to view the "
1689
+ "activity log, specify them in the below setting."
1690
+ msgstr ""
1691
+
1692
+ #: classes/Views/Settings.php:778 classes/Views/Settings.php:808
1693
+ msgid "Can view events"
1694
+ msgstr ""
1695
+
1696
+ #: classes/Views/Settings.php:785
1697
+ msgid "Super administators only"
1698
+ msgstr ""
1699
+
1700
+ #: classes/Views/Settings.php:786
1701
+ msgid "Super administators and site administrators"
1702
+ msgstr ""
1703
+
1704
+ #: classes/Views/Settings.php:802
1705
  msgid ""
1706
+ "To allow someone who does not have an admin role to view the activity log, "
1707
+ "specify them in the below setting."
 
1708
  msgstr ""
1709
 
1710
+ #: classes/Views/Settings.php:808
1711
+ msgid "Can also view events"
1712
  msgstr ""
1713
 
1714
+ #: classes/Views/Settings.php:817
1715
  msgid ""
1716
  "Specify the username or the users which do not have an admin role but can "
1717
  "also see the WordPress activity role. You can also specify roles."
1718
  msgstr ""
1719
 
1720
+ #: classes/Views/Settings.php:843
1721
  msgid "Which email address should the plugin use as a from address?"
1722
  msgstr ""
1723
 
1724
+ #: classes/Views/Settings.php:844
1725
  msgid ""
1726
  "By default when the plugin sends an email notification it uses the email "
1727
  "address specified in this website’s general settings. Though you can change "
1728
  "the email address and display name from this section."
1729
  msgstr ""
1730
 
1731
+ #: classes/Views/Settings.php:848
1732
  msgid "From Email & Name"
1733
  msgstr ""
1734
 
1735
+ #: classes/Views/Settings.php:854
1736
  msgid "Use the email address from the WordPress general settings"
1737
  msgstr ""
1738
 
1739
+ #: classes/Views/Settings.php:859
1740
  msgid "Use another email address"
1741
  msgstr ""
1742
 
1743
+ #: classes/Views/Settings.php:863
1744
  msgid "Email Address"
1745
  msgstr ""
1746
 
1747
+ #: classes/Views/Settings.php:868
1748
  msgid "Display Name"
1749
  msgstr ""
1750
 
1751
+ #: classes/Views/Settings.php:879
1752
  msgid "Do you want to hide the plugin from the list of installed plugins?"
1753
  msgstr ""
1754
 
1755
+ #: classes/Views/Settings.php:880
1756
  msgid ""
1757
  "By default all installed plugins are listed in the plugins page. If you do "
1758
  "not want other administrators to see that you installed this plugin set this "
1760
  "this website."
1761
  msgstr ""
1762
 
1763
+ #: classes/Views/Settings.php:884
1764
  msgid "Hide Plugin in Plugins Page"
1765
  msgstr ""
1766
 
1767
+ #: classes/Views/Settings.php:889
1768
  msgid "Yes, hide the plugin from the list of installed plugins"
1769
  msgstr ""
1770
 
1771
+ #: classes/Views/Settings.php:894
1772
  msgid "No, do not hide the plugin"
1773
  msgstr ""
1774
 
1775
+ #: classes/Views/Settings.php:960
1776
  msgid ""
1777
  "For how long do you want to keep the activity log events (Retention "
1778
  "settings) ?"
1779
  msgstr ""
1780
 
1781
+ #: classes/Views/Settings.php:963
1782
  msgid ""
1783
  "The plugin uses an efficient way to store the activity log data in the "
1784
  "WordPress database, though the more data you keep the more disk space will "
1785
  "be required. "
1786
  msgstr ""
1787
 
1788
+ #: classes/Views/Settings.php:964
1789
  msgid ""
1790
  "<a href=\"https://wpactivitylog.com/pricing/?"
1791
  "utm_source=plugin&utm_medium=referral&utm_campaign=WSAL&utm_content=settings"
1793
  "data in an external database."
1794
  msgstr ""
1795
 
1796
+ #. translators: 1: Archive page link tag. 2: Link closing tag.
1797
+ #: classes/Views/Settings.php:978
1798
  #, php-format
1799
  msgid ""
1800
  "Retention settings moved to %1$s archiving settings %2$s because archiving "
1801
  "is enabled"
1802
  msgstr ""
1803
 
1804
+ #: classes/Views/Settings.php:985
1805
+ msgid "Activity log retention"
1806
  msgstr ""
1807
 
1808
+ #: classes/Views/Settings.php:991
1809
  msgid "Keep all data"
1810
  msgstr ""
1811
 
1812
+ #: classes/Views/Settings.php:1018
1813
  msgid "Delete events older than"
1814
  msgstr ""
1815
 
1816
+ #: classes/Views/Settings.php:1025
1817
  msgid "Months"
1818
  msgstr ""
1819
 
1820
+ #: classes/Views/Settings.php:1026
1821
  msgid "Years"
1822
  msgstr ""
1823
 
1824
+ #: classes/Views/Settings.php:1034
1825
  msgid "The next scheduled purging of activity log data that is older than "
1826
  msgstr ""
1827
 
1828
+ #: classes/Views/Settings.php:1041
1829
  msgid "You can run the purging process now by clicking the button below."
1830
  msgstr ""
1831
 
1832
+ #: classes/Views/Settings.php:1045
1833
  msgid "Purge Old Data"
1834
  msgstr ""
1835
 
1836
+ #: classes/Views/Settings.php:1056
1837
  msgid "What timestamp you would like to see in the WordPress activity log?"
1838
  msgstr ""
1839
 
1840
+ #: classes/Views/Settings.php:1057
1841
  msgid ""
1842
  "Note that the WordPress' timezone might be different from that configured on "
1843
  "the server so when you switch from UTC to WordPress timezone or vice versa "
1844
  "you might notice a big difference."
1845
  msgstr ""
1846
 
1847
+ #: classes/Views/Settings.php:1061
1848
  msgid "Events Timestamp"
1849
  msgstr ""
1850
 
1851
+ #: classes/Views/Settings.php:1081
1852
  msgid "UTC"
1853
  msgstr ""
1854
 
1855
+ #: classes/Views/Settings.php:1087
1856
  msgid "Timezone configured on this WordPress website"
1857
  msgstr ""
1858
 
1859
+ #: classes/Views/Settings.php:1094
1860
  msgid "Show Milliseconds"
1861
  msgstr ""
1862
 
1863
+ #: classes/Views/Settings.php:1101
1864
  msgid "Show Milliseconds in list view"
1865
  msgstr ""
1866
 
1867
+ #: classes/Views/Settings.php:1111
1868
  msgid ""
1869
  "What user information should be displayed in the WordPress activity log?"
1870
  msgstr ""
1871
 
1872
+ #: classes/Views/Settings.php:1112
1873
  msgid ""
1874
  "Usernames might not be the same as a user's first and last name so it can be "
1875
  "difficult to recognize whose user was that did a change. When there is no "
1877
  "back to the WordPress username."
1878
  msgstr ""
1879
 
1880
+ #: classes/Views/Settings.php:1116
1881
+ msgid "User information in Activity log"
1882
  msgstr ""
1883
 
1884
+ #: classes/Views/Settings.php:1122
1885
+ msgid "WordPress username"
1886
  msgstr ""
1887
 
1888
+ #: classes/Views/Settings.php:1127
1889
+ msgid "First name & last name"
1890
  msgstr ""
1891
 
1892
+ #: classes/Views/Settings.php:1132
1893
+ msgid "Configured public display name"
1894
  msgstr ""
1895
 
1896
+ #: classes/Views/Settings.php:1142
1897
  msgid "Select the columns to be displayed in the WordPress activity log"
1898
  msgstr ""
1899
 
1900
+ #: classes/Views/Settings.php:1143
1901
  msgid ""
1902
  "When you deselect a column it won’t be shown in the activity log viewer in "
1903
  "both views. The data will still be recorded by the plugin."
1904
  msgstr ""
1905
 
1906
+ #: classes/Views/Settings.php:1147
1907
+ msgid "Activity log columns selection"
1908
  msgstr ""
1909
 
1910
+ #: classes/Views/Settings.php:1156
1911
  msgid "Event ID"
1912
  msgstr ""
1913
 
1914
+ #: classes/Views/Settings.php:1160
1915
  msgid "Date & Time"
1916
  msgstr ""
1917
 
1918
+ #: classes/Views/Settings.php:1164
1919
  msgid "Source IP Address"
1920
  msgstr ""
1921
 
1922
+ #: classes/Views/Settings.php:1166
1923
  msgid "Info (used in Grid view mode only)"
1924
  msgstr ""
1925
 
1926
+ #: classes/Views/Settings.php:1182
1927
  msgid "Do you want to keep a log of WordPress background activity?"
1928
  msgstr ""
1929
 
1930
+ #: classes/Views/Settings.php:1184
1931
  msgid ""
1932
  "WordPress does a lot of things in the background that you do not necessarily "
1933
  "need to know about, such as; deletion of post revisions, deletion of auto "
1935
  "might be a lot and are irrelevant to the user."
1936
  msgstr ""
1937
 
1938
+ #: classes/Views/Settings.php:1189
1939
  msgid "Enable Events for WordPress Background Activity"
1940
  msgstr ""
1941
 
1942
+ #: classes/Views/Settings.php:1248 classes/Views/ToggleAlerts.php:555
1943
  msgid "Website File Changes Monitor"
1944
  msgstr ""
1945
 
1946
+ #: classes/Views/Settings.php:1249 classes/Views/ToggleAlerts.php:556
1947
  msgid ""
1948
  "To keep a log of file changes please install Website File Changes Monitor, a "
1949
  "plugin which is also developed by us."
1950
  msgstr ""
1951
 
1952
+ #: classes/Views/Settings.php:1250 classes/Views/ToggleAlerts.php:557
1953
  msgid "Install plugin now"
1954
  msgstr ""
1955
 
1956
+ #: classes/Views/Settings.php:1250 classes/Views/ToggleAlerts.php:557
1957
  msgid "Learn More"
1958
  msgstr ""
1959
 
1960
+ #: classes/Views/Settings.php:1264
1961
  msgid "Configure how often file changes scan run and other settings from the"
1962
  msgstr ""
1963
 
1964
+ #: classes/Views/Settings.php:1264
1965
  msgid "Website File Changes plugin settings"
1966
  msgstr ""
1967
 
1968
+ #: classes/Views/Settings.php:1279
1969
  msgid ""
1970
  "By default the plugin keeps a log of all user changes done on your WordPress "
1971
  "website. Use the setting below to exclude any objects from the activity log. "
1973
  "object is referred will not be logged in the activity log."
1974
  msgstr ""
1975
 
1976
+ #: classes/Views/Settings.php:1283
1977
  msgid "Exclude Users:"
1978
  msgstr ""
1979
 
1980
+ #: classes/Views/Settings.php:1304
1981
  msgid "Exclude Roles:"
1982
  msgstr ""
1983
 
1984
+ #: classes/Views/Settings.php:1325
1985
  msgid "Exclude IP Address(es):"
1986
  msgstr ""
1987
 
1988
+ #: classes/Views/Settings.php:1341
1989
  msgid ""
1990
  "You can exclude an individual IP address or a range of IP addresses. To "
1991
  "exclude a range use the following format: [first IP]-[last octet of the last "
1992
  "IP]. Example: 172.16.180.6-127."
1993
  msgstr ""
1994
 
1995
+ #: classes/Views/Settings.php:1347
1996
  msgid "Exclude Post Type:"
1997
  msgstr ""
1998
 
1999
+ #: classes/Views/Settings.php:1363
2000
  msgid ""
2001
  "WordPress has the post and page post types by default though your website "
2002
  "might use more post types (custom post types). You can exclude all post "
2003
  "types, including the default WordPress ones."
2004
  msgstr ""
2005
 
2006
+ #: classes/Views/Settings.php:1369
2007
  msgid "Exclude Custom Fields:"
2008
  msgstr ""
2009
 
2010
+ #: classes/Views/Settings.php:1385
2011
  msgid ""
2012
  "You can use the * wildcard to exclude multiple matching custom fields. For "
2013
  "example to exclude all custom fields starting with wp123 enter wp123*"
2014
  msgstr ""
2015
 
2016
+ #: classes/Views/Settings.php:1391
2017
  msgid "Exclude Non-Existing URLs:"
2018
  msgstr ""
2019
 
2020
+ #: classes/Views/Settings.php:1407
2021
  msgid ""
2022
  "Add the non existing URLs for which you do not want to be alerted of HTTP "
2023
  "404 errors in the activity log by specifying the complete URL.\tExamples "
2024
  "below:"
2025
  msgstr ""
2026
 
2027
+ #: classes/Views/Settings.php:1407
2028
  msgid "File: "
2029
  msgstr ""
2030
 
2031
+ #: classes/Views/Settings.php:1407
2032
  msgid "Directory: "
2033
  msgstr ""
2034
 
2035
+ #: classes/Views/Settings.php:1439
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
2036
  msgid "These settings are for advanced users."
2037
  msgstr ""
2038
 
2039
+ #: classes/Views/Settings.php:1440
2040
  msgid ""
2041
  "If you have any questions <a href=\"https://wpactivitylog.com/contact/?"
2042
  "utm_source=plugin&utm_medium=referral&utm_campaign=WSAL&utm_content=settings"
2043
  "+pages\" target=\"_blank\">contact us</a>."
2044
  msgstr ""
2045
 
2046
+ #: classes/Views/Settings.php:1443
2047
+ msgid ""
2048
+ "Where do you want the plugin's working directory for log files, reports and "
2049
+ "other files?"
2050
  msgstr ""
2051
 
2052
+ #: classes/Views/Settings.php:1444
2053
  msgid ""
2054
+ "The plugin stores the reports it generates, a number of log files ( for "
2055
+ "example to keep a log of 404 errors), and the request log in this working "
2056
+ "directory. By default the directory is in the default WordPress uploads "
2057
+ "directory. Use the below setting to create the working directory in a "
2058
+ "different location. Note that the plugin requires write permissions to this "
2059
+ "directory. Please specify the relative path of the directory."
2060
  msgstr ""
2061
 
2062
+ #: classes/Views/Settings.php:1449
2063
+ msgid "Working directory location"
2064
  msgstr ""
2065
 
2066
+ #: classes/Views/Settings.php:1459
2067
  msgid ""
2068
  "<strong>Note:</strong> Enter a path from the root of your website: eg \"/wp-"
2069
+ "content/uploads/wp-activity-log/\"."
2070
  msgstr ""
2071
 
2072
+ #: classes/Views/Settings.php:1472
2073
  msgid ""
2074
  "Troubleshooting setting: Keep a debug log of all the requests this website "
2075
  "receives"
2076
  msgstr ""
2077
 
2078
+ #: classes/Views/Settings.php:1473
2079
  msgid ""
2080
  "Only enable the request log on testing, staging and development website. "
2081
  "Never enable logging on a live website unless instructed to do so. Enabling "
2082
  "request logging on a live website may degrade the performance of the website."
2083
  msgstr ""
2084
 
2085
+ #: classes/Views/Settings.php:1477
2086
  msgid "Request Log"
2087
  msgstr ""
2088
 
2089
+ #: classes/Views/Settings.php:1495
2090
  msgid ""
2091
  "<strong>Note:</strong> The requests debug log file is saved as request.log."
2092
+ "php in the /wp-content/uploads/wp-activity-log/ directory."
2093
  msgstr ""
2094
 
2095
+ #: classes/Views/Settings.php:1507
2096
  msgid "Reset plugin settings to default"
2097
  msgstr ""
2098
 
2099
+ #: classes/Views/Settings.php:1508
2100
  msgid ""
2101
  "Click the RESET button to reset ALL plugin settings to default. Note that "
2102
  "the activity log data will be retained and only the plugin settings will be "
2103
  "reset. To purge the data of the activity log use the setting below."
2104
  msgstr ""
2105
 
2106
+ #: classes/Views/Settings.php:1512
2107
  msgid "Reset Settings"
2108
  msgstr ""
2109
 
2110
+ #: classes/Views/Settings.php:1514
2111
  msgid "RESET"
2112
  msgstr ""
2113
 
2114
+ #: classes/Views/Settings.php:1520
2115
  msgid "Purge the WordPress activity log"
2116
  msgstr ""
2117
 
2118
+ #: classes/Views/Settings.php:1521
2119
  msgid ""
2120
  "Click the Purge button below to delete all the data from the WordPress "
2121
  "activity log and start afresh."
2122
  msgstr ""
2123
 
2124
+ #: classes/Views/Settings.php:1525
2125
  msgid "Purge Activity Log"
2126
  msgstr ""
2127
 
2128
+ #: classes/Views/Settings.php:1527
2129
  msgid "PURGE"
2130
  msgstr ""
2131
 
2132
+ #: classes/Views/Settings.php:1534
2133
  msgid "MainWP Child Site Stealth Mode"
2134
  msgstr ""
2135
 
2136
+ #: classes/Views/Settings.php:1535
2137
  msgid ""
2138
  "This option is enabled automatically when the plugin detects the MainWP "
2139
  "Child plugin on the site. When this setting is enabled plugin access is "
2142
  "Disable this option to change the plugin to the default setup."
2143
  msgstr ""
2144
 
2145
+ #: classes/Views/Settings.php:1539
2146
  msgid "Enable MainWP Child Site Stealth Mode"
2147
  msgstr ""
2148
 
2149
+ #: classes/Views/Settings.php:1559
2150
+ msgid "Admin blocking plugins support"
2151
+ msgstr ""
2152
+
2153
+ #: classes/Views/Settings.php:1564
2154
+ msgid "Enable early plugin loading on sites that use admin blocking plugins"
2155
+ msgstr ""
2156
+
2157
+ #: classes/Views/Settings.php:1573
2158
  msgid "Do you want to delete the plugin data from the database upon uninstall?"
2159
  msgstr ""
2160
 
2161
+ #: classes/Views/Settings.php:1574
2162
  msgid ""
2163
  "The plugin saves the activity log data and settings in the WordPress "
2164
  "database. By default upon uninstalling the plugin the data is kept in the "
2167
  "access it again even when you reinstall the plugin."
2168
  msgstr ""
2169
 
2170
+ #: classes/Views/Settings.php:1578
2171
  msgid "Remove Data on Uninstall"
2172
  msgstr ""
2173
 
2174
+ #: classes/Views/Settings.php:1603
2175
  msgid "Are you sure you want to reset all the plugin settings to default?"
2176
  msgstr ""
2177
 
2178
+ #: classes/Views/Settings.php:1613
2179
  msgid "Are you sure you want to purge all the activity log data?"
2180
  msgstr ""
2181
 
2182
+ #: classes/Views/Settings.php:1644
2183
  msgid "MainWP Child plugin is not active on this website."
2184
  msgstr ""
2185
 
2186
+ #: classes/Views/Settings.php:1677
2187
+ msgid ""
2188
+ "The plugin cannot create the directory for the log files. Please check "
2189
+ "permissions and configure it again."
2190
+ msgstr ""
2191
+
2192
+ #: classes/Views/Settings.php:1753
2193
  msgid "The specified value is not a valid URL!"
2194
  msgstr ""
2195
 
2196
+ #: classes/Views/Settings.php:1754
2197
  msgid "The specified value is not a valid post type!"
2198
  msgstr ""
2199
 
2200
+ #: classes/Views/Settings.php:1755
2201
  msgid "The specified value is not a valid IP address!"
2202
  msgstr ""
2203
 
2204
+ #: classes/Views/Settings.php:1756
2205
  msgid "The specified value is not a user nor a role!"
2206
  msgstr ""
2207
 
2208
+ #: classes/Views/Settings.php:1757
2209
  msgid "Filename cannot be added because it contains invalid characters."
2210
  msgstr ""
2211
 
2212
+ #: classes/Views/Settings.php:1758
2213
  msgid "File extension cannot be added because it contains invalid characters."
2214
  msgstr ""
2215
 
2216
+ #: classes/Views/Settings.php:1759
2217
  msgid "Directory cannot be added because it contains invalid characters."
2218
  msgstr ""
2219
 
2220
+ #: classes/Views/Settings.php:1895 classes/Views/Settings.php:1922
2221
  msgid "Tables has been reset."
2222
  msgstr ""
2223
 
2224
+ #: classes/Views/Settings.php:1897 classes/Views/Settings.php:1924
2225
  msgid "Reset query failed."
2226
  msgstr ""
2227
 
2228
+ #: classes/Views/Settings.php:1900 classes/Views/Settings.php:1927
2229
  msgid "Nonce Verification Failed."
2230
  msgstr ""
2231
 
2253
  msgid "Log Retention"
2254
  msgstr ""
2255
 
2256
+ #: classes/Views/SetupWizard.php:207 classes/Views/SetupWizard.php:791
2257
+ #: classes/Views/SetupWizard.php:792
2258
  msgid "Finish"
2259
  msgstr ""
2260
 
2270
  msgid "Specified value in not an IP address."
2271
  msgstr ""
2272
 
2273
+ #: classes/Views/SetupWizard.php:272 wp-security-audit-log.php:1245
2274
  msgid "Installing, please wait"
2275
  msgstr ""
2276
 
2277
+ #: classes/Views/SetupWizard.php:273 wp-security-audit-log.php:1246
2278
  msgid "Already installed"
2279
  msgstr ""
2280
 
2281
+ #: classes/Views/SetupWizard.php:275 wp-security-audit-log.php:1248
2282
  msgid "Extension activated"
2283
  msgstr ""
2284
 
2285
+ #: classes/Views/SetupWizard.php:276 wp-security-audit-log.php:1249
2286
  msgid "Install failed"
2287
  msgstr ""
2288
 
2290
  msgid "WP Activity Log &rsaquo; Setup Wizard"
2291
  msgstr ""
2292
 
2293
+ #: classes/Views/SetupWizard.php:324
2294
  msgid "Close Wizard"
2295
  msgstr ""
2296
 
2297
+ #. translators: 1 - an opening link tag, 2 - a closing link tag.
2298
+ #: classes/Views/SetupWizard.php:417
2299
  #, php-format
2300
  msgid ""
2301
  "You have reached an invaild step - %1$sreturn to the start of the wizard%2$s."
2302
  msgstr ""
2303
 
2304
+ #: classes/Views/SetupWizard.php:434
2305
  msgid ""
2306
  "This wizard helps you configure the basic plugin settings. All these "
2307
  "settings can be changed at a later stage from the plugin settings."
2308
  msgstr ""
2309
 
2310
+ #: classes/Views/SetupWizard.php:439
2311
  msgid "Start Configuring the Plugin"
2312
  msgstr ""
2313
 
2314
+ #: classes/Views/SetupWizard.php:443
2315
  msgid "Exit Wizard"
2316
  msgstr ""
2317
 
2318
+ #: classes/Views/SetupWizard.php:456
2319
  msgid "Please select the level of detail for your WordPress activity logs:"
2320
  msgstr ""
2321
 
2322
+ #: classes/Views/SetupWizard.php:460
2323
  msgid ""
2324
  "Basic (I want a high level overview and I am not interested in the detail)"
2325
  msgstr ""
2326
 
2327
+ #: classes/Views/SetupWizard.php:465
2328
  msgid "Geek (I want to know everything that is happening on my WordPress)"
2329
  msgstr ""
2330
 
2331
+ #: classes/Views/SetupWizard.php:467
2332
  msgid ""
2333
  "Note: You can change the WordPress logging level from the plugin’s settings "
2334
  "anytime."
2335
  msgstr ""
2336
 
2337
+ #: classes/Views/SetupWizard.php:470 classes/Views/SetupWizard.php:527
2338
+ #: classes/Views/SetupWizard.php:575 classes/Views/SetupWizard.php:624
2339
+ #: classes/Views/SetupWizard.php:684 classes/Views/SetupWizard.php:685
2340
+ #: classes/Views/SetupWizard.php:906 classes/Views/SetupWizard.php:907
2341
  msgid "Next"
2342
  msgstr ""
2343
 
2344
+ #: classes/Views/SetupWizard.php:511
2345
  msgid ""
2346
  "Do you or your users use other pages to log in to WordPress other than the "
2347
  "default login page ( /wp-admin/ )?"
2348
  msgstr ""
2349
 
2350
+ #: classes/Views/SetupWizard.php:515
2351
  msgid "Yes, we use other pages to login to WordPress."
2352
  msgstr ""
2353
 
2354
+ #: classes/Views/SetupWizard.php:520
2355
  msgid "No, we only use the default WordPress login page."
2356
  msgstr ""
2357
 
2358
+ #: classes/Views/SetupWizard.php:522
2359
  msgid ""
2360
  "If your website is a membership or ecommerce website most probably you have "
2361
  "more than one area from where the users can login. If you are not sure, "
2362
  "select Yes."
2363
  msgstr ""
2364
 
2365
+ #: classes/Views/SetupWizard.php:525 classes/Views/SetupWizard.php:573
2366
+ #: classes/Views/SetupWizard.php:622 classes/Views/SetupWizard.php:676
2367
  msgid ""
2368
  "Note: You can change the WordPress activity log retention settings at any "
2369
  "time from the plugin settings later on."
2370
  msgstr ""
2371
 
2372
+ #: classes/Views/SetupWizard.php:560
2373
  msgid ""
2374
  "Do you want to keep a log of (non-logged in) visitors’ requests to non-"
2375
  "existing URLs which generate a HTTP 404 error response?"
2376
  msgstr ""
2377
 
2378
+ #: classes/Views/SetupWizard.php:608
2379
  msgid "Can visitors register for a user on your website?"
2380
  msgstr ""
2381
 
2382
+ #: classes/Views/SetupWizard.php:619
2383
  msgid ""
2384
  "If you are not sure about this setting, check if the Membership setting in "
2385
  "the WordPress General settings is checked or not. If it is not checked "
2386
  "(default) select No."
2387
  msgstr ""
2388
 
2389
+ #: classes/Views/SetupWizard.php:658
2390
  msgid "How long do you want to keep the data in the WordPress activity Log?"
2391
  msgstr ""
2392
 
2393
+ #: classes/Views/SetupWizard.php:663
2394
  msgid "6 months (data older than 6 months will be deleted)"
2395
  msgstr ""
2396
 
2397
+ #: classes/Views/SetupWizard.php:668
2398
  msgid "12 months (data older than 12 months will be deleted)"
2399
  msgstr ""
2400
 
2401
+ #: classes/Views/SetupWizard.php:673
2402
  msgid "Keep all data."
2403
  msgstr ""
2404
 
2405
+ #: classes/Views/SetupWizard.php:694
2406
  msgid ""
2407
  "The plugin stores the data in the WordPress database in a very efficient "
2408
  "way, though the more data you keep the more hard disk space it will consume. "
2413
  "Database tools to store the WordPress activity log in an external database."
2414
  msgstr ""
2415
 
2416
+ #: classes/Views/SetupWizard.php:762
 
 
 
 
 
 
 
 
2417
  msgid ""
2418
  "Your plugin is all set and it is ready to start keeping a record of "
2419
  "everything that is happening on your WordPress in a WordPress activity log."
2420
  msgstr ""
2421
 
2422
+ #: classes/Views/SetupWizard.php:763
2423
  msgid "Below are a few useful links you might need to refer to:"
2424
  msgstr ""
2425
 
2426
+ #: classes/Views/SetupWizard.php:768
2427
  msgid "Getting started with the WP Activity Log plugin"
2428
  msgstr ""
2429
 
2430
+ #: classes/Views/SetupWizard.php:773
2431
  msgid "Knowledge Base & Support Documents"
2432
  msgstr ""
2433
 
2434
+ #: classes/Views/SetupWizard.php:778
2435
  msgid "Benefits of keeping a WordPress activity log"
2436
  msgstr ""
2437
 
2438
+ #: classes/Views/SetupWizard.php:783
2439
  msgid ""
2440
  "We trust this plugin meets all your activity log requirements. Should you "
2441
  "encounter any problems, have feature requests or would like to share some "
2444
  "+configuration\" target=\"_blank\">please get in touch!</a>"
2445
  msgstr ""
2446
 
2447
+ #: classes/Views/SetupWizard.php:819
2448
  msgid "Third Party Extensions"
2449
  msgstr ""
2450
 
2451
+ #: classes/Views/SetupWizard.php:860
2452
  msgid "Monitoring changes done in third party plugins"
2453
  msgstr ""
2454
 
2455
+ #: classes/Views/SetupWizard.php:861
2456
  msgid ""
2457
  "We noticed that the below plugins are installed on this website. You can "
2458
  "install our extensions to also keep a log of changes users do on these "
2463
  msgid "Enable/Disable Events"
2464
  msgstr ""
2465
 
2466
+ #: classes/Views/ToggleAlerts.php:189
2467
  msgid "Log Level: "
2468
  msgstr ""
2469
 
2470
+ #: classes/Views/ToggleAlerts.php:194
2471
  msgid "Basic"
2472
  msgstr ""
2473
 
2474
+ #: classes/Views/ToggleAlerts.php:199
2475
  msgid "Geek"
2476
  msgstr ""
2477
 
2478
+ #: classes/Views/ToggleAlerts.php:202
2479
  msgid "Custom"
2480
  msgstr ""
2481
 
2482
+ #: classes/Views/ToggleAlerts.php:206
2483
  msgid ""
2484
  "Use the Log level drop down menu above to use one of our preset log levels. "
2485
  "Alternatively you can enable or disable any of the individual events from "
2489
  "plugin can keep a log of."
2490
  msgstr ""
2491
 
2492
+ #: classes/Views/ToggleAlerts.php:216
2493
  msgid "Front-end Events"
2494
  msgstr ""
2495
 
2496
+ #: classes/Views/ToggleAlerts.php:221
2497
  msgid "Third party plugins"
2498
  msgstr ""
2499
 
2500
+ #: classes/Views/ToggleAlerts.php:317
2501
  msgid "Code"
2502
  msgstr ""
2503
 
2504
+ #: classes/Views/ToggleAlerts.php:319 classes/WidgetManager.php:77
2505
  msgid "Description"
2506
  msgstr ""
2507
 
2508
+ #: classes/Views/ToggleAlerts.php:323 defaults.php:103
2509
  msgid "Content"
2510
  msgstr ""
2511
 
2512
+ #: classes/Views/ToggleAlerts.php:326
2513
  msgid ""
2514
  "<strong>Note:</strong> Post refers to any type of content, i.e. blog post, "
2515
  "page or a post with a custom post type."
2516
  msgstr ""
2517
 
2518
+ #: classes/Views/ToggleAlerts.php:329 classes/Views/ToggleAlerts.php:337
 
 
 
 
2519
  msgid "WooCommerce Products"
2520
  msgstr ""
2521
 
2522
+ #: classes/Views/ToggleAlerts.php:333
2523
  msgid ""
2524
  "The plugin WooCommerce is not installed on your website so these events have "
2525
  "been disabled."
2526
  msgstr ""
2527
 
2528
+ #: classes/Views/ToggleAlerts.php:340
2529
  msgid "Products"
2530
  msgstr ""
2531
 
2532
+ #: classes/Views/ToggleAlerts.php:348
2533
  msgid ""
2534
  "The plugin Yoast SEO is not installed on your website so these events have "
2535
  "been disabled."
2536
  msgstr ""
2537
 
2538
+ #: classes/Views/ToggleAlerts.php:354 defaults.php:428
2539
  msgid "Post Changes"
2540
  msgstr ""
2541
 
2542
+ #: classes/Views/ToggleAlerts.php:357 defaults.php:417
2543
  msgid "MultiSite"
2544
  msgstr ""
2545
 
2546
+ #: classes/Views/ToggleAlerts.php:361
2547
  msgid ""
2548
  "Your website is a single site so the multisite events have been disabled."
2549
  msgstr ""
2550
 
2551
+ #: classes/Views/ToggleAlerts.php:365
2552
  msgid "Other User Activity"
2553
  msgstr ""
2554
 
2555
+ #: classes/Views/ToggleAlerts.php:368
2556
  msgid "Logins & Logouts"
2557
  msgstr ""
2558
 
2559
+ #: classes/Views/ToggleAlerts.php:380 classes/Views/ToggleAlerts.php:539
2560
+ #: defaults.php:469
2561
  msgid "Monitor File Changes"
2562
  msgstr ""
2563
 
2564
+ #: classes/Views/ToggleAlerts.php:391
2565
  msgid "Not Implemented"
2566
  msgstr ""
2567
 
2568
+ #: classes/Views/ToggleAlerts.php:394
2569
  msgid "Not Available"
2570
  msgstr ""
2571
 
2572
+ #: classes/Views/ToggleAlerts.php:404
2573
  msgid "User Sessions"
2574
  msgstr ""
2575
 
2576
+ #: classes/Views/ToggleAlerts.php:406
2577
  msgid "Files"
2578
  msgstr ""
2579
 
2580
+ #: classes/Views/ToggleAlerts.php:408
2581
  msgid "Post Settings"
2582
  msgstr ""
2583
 
2584
+ #: classes/Views/ToggleAlerts.php:410
2585
  msgid "Product Admin"
2586
  msgstr ""
2587
 
2588
+ #: classes/Views/ToggleAlerts.php:412
2589
  msgid "Product Attributes"
2590
  msgstr ""
2591
 
2592
+ #: classes/Views/ToggleAlerts.php:476 classes/Views/ToggleAlerts.php:626
2593
  msgid ""
2594
  "Capture 404 requests to file (the log file are created in the /wp-content/"
2595
+ "uploads/wp-activity-log/404s/ directory)"
2596
  msgstr ""
2597
 
2598
+ #: classes/Views/ToggleAlerts.php:484 classes/Views/ToggleAlerts.php:630
2599
  msgid "Purge log files older than one month"
2600
  msgstr ""
2601
 
2602
+ #: classes/Views/ToggleAlerts.php:489
2603
  msgid ""
2604
  "Number of 404 Requests to Log. By default the plugin keeps up to 99 requests "
2605
  "to non-existing pages from the same IP address. Increase the value in this "
2606
  "setting to the desired amount to keep a log of more or less requests."
2607
  msgstr ""
2608
 
2609
+ #: classes/Views/ToggleAlerts.php:494 classes/Views/ToggleAlerts.php:638
2610
  msgid "Record the referrer that generated the 404 error."
2611
  msgstr ""
2612
 
2613
+ #: classes/Views/ToggleAlerts.php:506 classes/Views/ToggleAlerts.php:519
2614
  msgid ""
2615
  "Number of login attempts to log. Enter 0 to log all failed login attempts. "
2616
  "(By default the plugin only logs up to 10 failed login because the process "
2617
  "can be very resource intensive in case of a brute force attack)"
2618
  msgstr ""
2619
 
2620
+ #: classes/Views/ToggleAlerts.php:532
2621
  msgid ""
2622
  "Log all stock changes. Disable this setting to only keep a log of stock "
2623
  "changes done manually via the WooCommerce dashboard. Therefore automated "
2625
  "plugins will not be logged."
2626
  msgstr ""
2627
 
2628
+ #: classes/Views/ToggleAlerts.php:583
2629
  msgid ""
2630
  "This plugin keeps a log of what your website users are doing when they are "
2631
  "logged in. On top of that it can also keep a log of some important events of "
2633
  "any of the front-end sensors:"
2634
  msgstr ""
2635
 
2636
+ #: classes/Views/ToggleAlerts.php:588
2637
  msgid "Front-end users registrations"
2638
  msgstr ""
2639
 
2640
+ #: classes/Views/ToggleAlerts.php:594
2641
  msgid ""
2642
  "Keep a log when a visitor registers a user on the website. Only enable this "
2643
  "if you allow visitors to register as users on your website. User "
2644
  "registration is disabled by default in WordPress."
2645
  msgstr ""
2646
 
2647
+ #: classes/Views/ToggleAlerts.php:599
2648
  msgid "Front-end users logins"
2649
  msgstr ""
2650
 
2651
+ #: classes/Views/ToggleAlerts.php:605
2652
  msgid ""
2653
  "Keep a log when users login to the website from other login pages / forms "
2654
  "other than the default WordPress login page."
2655
  msgstr ""
2656
 
2657
+ #: classes/Views/ToggleAlerts.php:610
2658
  msgid "Website visitors 404 errors"
2659
  msgstr ""
2660
 
2661
+ #: classes/Views/ToggleAlerts.php:616
2662
  msgid ""
2663
  "Event ID 6023: Keep a log when a website visitor requests a non-existing URL "
2664
  "(HTTP 404 response error)."
2665
  msgstr ""
2666
 
2667
+ #: classes/Views/ToggleAlerts.php:634
2668
  msgid ""
2669
  "Number of 404 Requests to Log. By default the plugin keeps up to 99 requests "
2670
  "to non-existing pages from the same IP address. Increase the value in this "
2673
  "scanned the plugin will consume more resources to log all the requests."
2674
  msgstr ""
2675
 
2676
+ #: classes/Views/ToggleAlerts.php:647
 
 
 
 
 
 
 
 
 
 
 
2677
  msgid "Save Changes"
2678
  msgstr ""
2679
 
2680
+ #: classes/Views/ToggleAlerts.php:654
2681
  msgid "Log Level Updated"
2682
  msgstr ""
2683
 
2684
+ #. translators: Alerts log level.
2685
+ #: classes/Views/ToggleAlerts.php:658
2686
  #, php-format
2687
  msgid "The %s log level has been successfully loaded and applied."
2688
  msgstr ""
2689
 
2690
+ #: classes/Views/ToggleAlerts.php:662
2691
  msgid "OK"
2692
  msgstr ""
2693
 
2694
+ #: classes/Views/ToggleAlerts.php:677
2695
  msgid "Enable File Integrity Scanner"
2696
  msgstr ""
2697
 
2698
+ #: classes/Views/ToggleAlerts.php:679
2699
  msgid ""
2700
  "The file integrity scanner is switched off. To enable this event it has to "
2701
  "be switched on."
2702
  msgstr ""
2703
 
2704
+ #: classes/Views/ToggleAlerts.php:683
2705
  msgid "SWITCH ON"
2706
  msgstr ""
2707
 
2708
+ #: classes/Views/ToggleAlerts.php:684
2709
  msgid "DISABLE EVENT"
2710
  msgstr ""
2711
 
2725
  msgid "No events found."
2726
  msgstr ""
2727
 
2728
+ #: defaults.php:77
2729
  msgid "Critical severity events."
2730
  msgstr ""
2731
 
2732
+ #: defaults.php:78
2733
  msgid "High severity events."
2734
  msgstr ""
2735
 
2736
+ #: defaults.php:79
2737
  msgid "Medium severity events."
2738
  msgstr ""
2739
 
2740
+ #: defaults.php:80
2741
  msgid "Low severity events."
2742
  msgstr ""
2743
 
2744
+ #: defaults.php:81
2745
  msgid "Informational events."
2746
  msgstr ""
2747
 
2748
+ #: defaults.php:86
2749
  msgid "Users Logins & Sessions Events"
2750
  msgstr ""
2751
 
2752
+ #: defaults.php:87
2753
  msgid "User Activity"
2754
  msgstr ""
2755
 
2756
+ #: defaults.php:88
2757
  msgid "User logged in"
2758
  msgstr ""
2759
 
2760
+ #: defaults.php:89
2761
  msgid "User logged out"
2762
  msgstr ""
2763
 
2764
+ #: defaults.php:90
2765
  msgid "Login failed"
2766
  msgstr ""
2767
 
2768
+ #: defaults.php:91
2769
  msgid "Login failed / non existing user"
2770
  msgstr ""
2771
 
2772
+ #: defaults.php:91
2773
  msgid "%Attempts% failed login(s) %LineBreak% %LogFileText%"
2774
  msgstr ""
2775
 
2776
+ #: defaults.php:92
2777
  msgid "Login blocked"
2778
  msgstr ""
2779
 
2780
+ #: defaults.php:92
2781
  msgid ""
2782
  "Login blocked because other session(s) already exist for this user. "
2783
  "%LineBreak% IP address: %ClientIP%"
2784
  msgstr ""
2785
 
2786
+ #: defaults.php:93
2787
  msgid "User logged in with existing session(s)"
2788
  msgstr ""
2789
 
2790
+ #: defaults.php:93
2791
  msgid ""
2792
+ "User logged in. There are other session(s) using the same username logged in "
2793
+ "from these IP address(es): %IPAddress%"
2794
  msgstr ""
2795
 
2796
+ #: defaults.php:94
2797
  msgid "User logged out all other sessions with the same username"
2798
  msgstr ""
2799
 
2800
+ #: defaults.php:94
2801
  msgid "Logged out all other sessions with the same user."
2802
  msgstr ""
2803
 
2804
+ #: defaults.php:95
2805
  msgid "User session destroyed and logged out"
2806
  msgstr ""
2807
 
2808
+ #: defaults.php:95
2809
  msgid ""
2810
  "Terminated the session of another user. %LineBreak% User: %TargetUserName% "
2811
  "%LineBreak% Session ID: %TargetSessionID%"
2812
  msgstr ""
2813
 
2814
+ #: defaults.php:96
2815
  msgid "Switched to another user"
2816
  msgstr ""
2817
 
2818
+ #: defaults.php:96
2819
  msgid ""
2820
  "Switched to another user. %LineBreak% User: %TargetUserName% %LineBreak% "
2821
  "Role: %TargetUserRole%"
2822
  msgstr ""
2823
 
2824
+ #: defaults.php:97
2825
  msgid "User uploaded file from Uploads directory"
2826
  msgstr ""
2827
 
2828
+ #: defaults.php:97 defaults.php:98
2829
  msgid "Filename: %FileName% %LineBreak% Directory: %FilePath%"
2830
  msgstr ""
2831
 
2832
+ #: defaults.php:98
2833
  msgid "User deleted file from Uploads directory"
2834
  msgstr ""
2835
 
2836
+ #: defaults.php:102
2837
  msgid "Content & Comments"
2838
  msgstr ""
2839
 
2840
+ #: defaults.php:104
2841
  msgid "User created a new post and saved it as draft"
2842
  msgstr ""
2843
 
2844
+ #: defaults.php:104
2845
  msgid ""
2846
  "Created the post %PostTitle% %LineBreak% ID: %PostID% %LineBreak% Type: "
2847
  "%PostType% %LineBreak% Status: %PostStatus% %PostUrlIfPlublished% %LineBreak"
2848
  "% %EditorLinkPost%"
2849
  msgstr ""
2850
 
2851
+ #: defaults.php:105
2852
  msgid "User published a post"
2853
  msgstr ""
2854
 
2855
+ #: defaults.php:105
2856
  msgid ""
2857
  "Published the post %PostTitle% %LineBreak% ID: %PostID% %LineBreak% Type: "
2858
  "%PostType% %LineBreak% Status: %PostStatus% %PostUrlIfPlublished% %LineBreak"
2859
  "% %EditorLinkPost%"
2860
  msgstr ""
2861
 
2862
+ #: defaults.php:106
2863
  msgid "User modified a post"
2864
  msgstr ""
2865
 
2866
+ #: defaults.php:106
2867
  msgid ""
2868
  "Modified the post %PostTitle% %LineBreak% ID: %PostID% %LineBreak% Type: "
2869
  "%PostType% %PostUrlIfPlublished% %LineBreak% %EditorLinkPost%"
2870
  msgstr ""
2871
 
2872
+ #: defaults.php:107
2873
  msgid "User permanently deleted a post from the trash"
2874
  msgstr ""
2875
 
2876
+ #: defaults.php:107
2877
  msgid ""
2878
  "Permanently deleted the post %PostTitle% %LineBreak% ID: %PostID% %LineBreak"
2879
  "% Type: %PostType%"
2880
  msgstr ""
2881
 
2882
+ #: defaults.php:108
2883
  msgid "User moved a post to the trash"
2884
  msgstr ""
2885
 
2886
+ #: defaults.php:108
2887
  msgid ""
2888
  "Moved the post %PostTitle% to trash %LineBreak% ID: %PostID% %LineBreak% "
2889
  "Type: %PostType% %LineBreak% Status: %PostStatus% %PostUrlIfPlublished%"
2890
  msgstr ""
2891
 
2892
+ #: defaults.php:109
2893
  msgid "User restored a post from trash"
2894
  msgstr ""
2895
 
2896
+ #: defaults.php:109
2897
  msgid ""
2898
  "Restored the post %PostTitle% from trash %LineBreak% ID: %PostID% %LineBreak"
2899
  "% Type: %PostType% %LineBreak% Status: %PostStatus% %PostUrlIfPlublished% "
2900
  "%LineBreak% %EditorLinkPost%"
2901
  msgstr ""
2902
 
2903
+ #: defaults.php:110
2904
  msgid "User changed post URL"
2905
  msgstr ""
2906
 
2907
+ #: defaults.php:110
2908
  msgid ""
2909
  "Changed the URL of the post %PostTitle% %LineBreak% ID: %PostID% %LineBreak% "
2910
  "Type: %PostType% %LineBreak% Status: %PostStatus% %LineBreak% Previous URL: "
2911
  "%OldUrl% %LineBreak% New URL: %NewUrl% %LineBreak% %EditorLinkPost%"
2912
  msgstr ""
2913
 
2914
+ #: defaults.php:111
2915
  msgid "User changed post author"
2916
  msgstr ""
2917
 
2918
+ #: defaults.php:111
2919
  msgid ""
2920
  "Changed the author of the post %PostTitle% %LineBreak% ID: %PostID% "
2921
  "%LineBreak% Type: %PostType% %LineBreak% Status: %PostStatus% %LineBreak% "
2923
  "%PostUrlIfPlublished% %LineBreak% %EditorLinkPost%."
2924
  msgstr ""
2925
 
2926
+ #: defaults.php:112
2927
  msgid "User changed post status"
2928
  msgstr ""
2929
 
2930
+ #: defaults.php:112
2931
  msgid ""
2932
  "Changed the status of the post %PostTitle% %LineBreak% ID: %PostID% "
2933
  "%LineBreak% Type: %PostType% %LineBreak% Status was: %OldStatus% %LineBreak% "
2934
  "New status: %NewStatus% %PostUrlIfPlublished% %LineBreak% %EditorLinkPost%"
2935
  msgstr ""
2936
 
2937
+ #: defaults.php:113
2938
  msgid "User changed the visibility of a post"
2939
  msgstr ""
2940
 
2941
+ #: defaults.php:113
2942
  msgid ""
2943
  "Changed the visibility of the post %PostTitle% %LineBreak% ID: %PostID% "
2944
  "%LineBreak% Type: %PostType% %LineBreak% Status: %PostStatus% %LineBreak% "
2946
  "%PostUrlIfPlublished% %LineBreak% %EditorLinkPost%"
2947
  msgstr ""
2948
 
2949
+ #: defaults.php:114
2950
  msgid "User changed the date of a post"
2951
  msgstr ""
2952
 
2953
+ #: defaults.php:114
2954
  msgid ""
2955
  "Changed the date of the post %PostTitle% %LineBreak% ID: %PostID% %LineBreak"
2956
  "% Type: %PostType% %LineBreak% Status: %PostStatus% %LineBreak% Previous "
2958
  "%LineBreak% %EditorLinkPost%"
2959
  msgstr ""
2960
 
2961
+ #: defaults.php:115
2962
  msgid "User changed the parent of a page"
2963
  msgstr ""
2964
 
2965
+ #: defaults.php:115
2966
  msgid ""
2967
  "Changed the parent of the post %PostTitle% %LineBreak% ID: %PostID% "
2968
  "%LineBreak% Type: %PostType% %LineBreak% Status: %PostStatus% %LineBreak% "
2970
  "%PostUrlIfPlublished% %LineBreak% %EditorLinkPost%"
2971
  msgstr ""
2972
 
2973
+ #: defaults.php:116
2974
  msgid "User changed the template of a page"
2975
  msgstr ""
2976
 
2977
+ #: defaults.php:116
2978
  msgid ""
2979
  "Changed the template of the post %PostTitle% %LineBreak% ID: %PostID% "
2980
  "%LineBreak% Type: %PostType% %LineBreak% Status: %PostStatus% %LineBreak% "
2982
  "%PostUrlIfPlublished% %LineBreak% %EditorLinkPost%"
2983
  msgstr ""
2984
 
2985
+ #: defaults.php:117
2986
  msgid "User set a post as sticky"
2987
  msgstr ""
2988
 
2989
+ #: defaults.php:117
2990
  msgid ""
2991
  "Set the post %PostTitle% as sticky %LineBreak% ID: %PostID% %LineBreak% "
2992
  "Type: %PostType% %LineBreak% Status: %PostStatus% %PostUrlIfPlublished% "
2993
  "%LineBreak% %EditorLinkPost%"
2994
  msgstr ""
2995
 
2996
+ #: defaults.php:118
2997
  msgid "User removed post from sticky"
2998
  msgstr ""
2999
 
3000
+ #: defaults.php:118
3001
  msgid ""
3002
  "Removed the post %PostTitle% from sticky %LineBreak% ID: %PostID% %LineBreak"
3003
  "% Type: %PostType% %LineBreak% Status: %PostStatus% %PostUrlIfPlublished% "
3004
  "%LineBreak% %EditorLinkPost%"
3005
  msgstr ""
3006
 
3007
+ #: defaults.php:119
3008
  msgid "User modified the content of a post"
3009
  msgstr ""
3010
 
3011
+ #: defaults.php:119
3012
  msgid ""
3013
  "Modified the content of the post %PostTitle% %LineBreak% ID: %PostID% "
3014
  "%LineBreak% Type: %PostType% %LineBreak% Status: %PostStatus% %LineBreak% "
3015
  "%RevisionLink% %PostUrlIfPlublished% %LineBreak% %EditorLinkPost%"
3016
  msgstr ""
3017
 
3018
+ #: defaults.php:120
3019
  msgid "User submitted a post for review"
3020
  msgstr ""
3021
 
3022
+ #: defaults.php:120
3023
  msgid ""
3024
  "Submitted the post %PostTitle% for review %LineBreak% ID: %PostID% %LineBreak"
3025
  "% Type: %PostType% %LineBreak% Status: %PostStatus% %PostUrlIfPlublished% "
3026
  "%LineBreak% %EditorLinkPost%"
3027
  msgstr ""
3028
 
3029
+ #: defaults.php:121
3030
  msgid "User scheduled a post"
3031
  msgstr ""
3032
 
3033
+ #: defaults.php:121
3034
  msgid ""
3035
  "Scheduled the post %PostTitle% to be published on %PublishingDate% %LineBreak"
3036
  "% ID: %PostID% %LineBreak% Type: %PostType% %LineBreak% Status: %PostStatus% "
3037
  "%LineBreak% %PostUrlIfPlublished% %LineBreak% %EditorLinkPost%"
3038
  msgstr ""
3039
 
3040
+ #: defaults.php:122
3041
  msgid "User changed title of a post"
3042
  msgstr ""
3043
 
3044
+ #: defaults.php:122
3045
  msgid ""
3046
  "Changed the title of the post %OldTitle% %LineBreak% New title: %NewTitle% "
3047
  "%LineBreak% ID: %PostID% %LineBreak% Type: %PostType% %LineBreak% Status: "
3048
  "%PostStatus% %PostUrlIfPlublished% %LineBreak% %EditorLinkPost%"
3049
  msgstr ""
3050
 
3051
+ #: defaults.php:123
3052
  msgid "User opened a post in the editor"
3053
  msgstr ""
3054
 
3055
+ #: defaults.php:123
3056
  msgid ""
3057
  "Opened the post %PostTitle% in the editor %LineBreak% ID: %PostID% %LineBreak"
3058
  "% Type: %PostType% %LineBreak% Status: %PostStatus% %PostUrlIfPlublished% "
3059
  "%LineBreak% %EditorLinkPost%"
3060
  msgstr ""
3061
 
3062
+ #: defaults.php:124
3063
  msgid "User viewed a post"
3064
  msgstr ""
3065
 
3066
+ #: defaults.php:124
3067
  msgid ""
3068
  "Viewed the post %PostTitle% %LineBreak% ID: %PostID% %LineBreak% Type: "
3069
  "%PostType% %LineBreak% Status: %PostStatus% %LineBreak% URL: %PostUrl% "
3070
  "%LineBreak% %EditorLinkPost%"
3071
  msgstr ""
3072
 
3073
+ #: defaults.php:125
3074
  msgid "A plugin modified a post"
3075
  msgstr ""
3076
 
3077
+ #: defaults.php:125
3078
  msgid ""
3079
  "Plugin modified the post %PostTitle% %LineBreak% ID: %PostID% %LineBreak% "
3080
  "Type: %PostType% %LineBreak% Status: %PostStatus% %PostUrlIfPlublished% "
3081
  "%LineBreak% %EditorLinkPost%"
3082
  msgstr ""
3083
 
3084
+ #: defaults.php:126
3085
  msgid "User enabled/disabled comments in a post"
3086
  msgstr ""
3087
 
3088
+ #: defaults.php:126
3089
  msgid ""
3090
  "The comments in the post %PostTitle% %LineBreak% ID: %PostID% %LineBreak% "
3091
  "Type: %PostType% %LineBreak% Status: %PostStatus% %PostUrlIfPlublished% "
3092
  "%LineBreak% %EditorLinkPost%"
3093
  msgstr ""
3094
 
3095
+ #: defaults.php:127
3096
  msgid "User enabled/disabled trackbacks and pingbacks in a post"
3097
  msgstr ""
3098
 
3099
+ #: defaults.php:127
3100
  msgid ""
3101
  "Pingbacks and Trackbacks in the post %PostTitle% %LineBreak% ID: %PostID% "
3102
  "%LineBreak% Type: %PostType% %LineBreak% Status: %PostStatus% "
3103
  "%PostUrlIfPlublished% %LineBreak% %EditorLinkPost%"
3104
  msgstr ""
3105
 
3106
+ #: defaults.php:130
3107
  msgid "Tags"
3108
  msgstr ""
3109
 
3110
+ #: defaults.php:131
3111
  msgid "User added post tag"
3112
  msgstr ""
3113
 
3114
+ #: defaults.php:131
3115
  msgid ""
3116
  "Added tag(s) to the post %PostTitle% %LineBreak% ID: %PostID% %LineBreak% "
3117
  "Type: %PostType% %LineBreak% Status: %PostStatus% %LineBreak% Added tag(s): "
3118
  "%tag% %PostUrlIfPlublished% %LineBreak% %EditorLinkPost%"
3119
  msgstr ""
3120
 
3121
+ #: defaults.php:132
3122
  msgid "User removed post tag"
3123
  msgstr ""
3124
 
3125
+ #: defaults.php:132
3126
  msgid ""
3127
  "Removed tag(s) from the post %PostTitle% %LineBreak% ID: %PostID% %LineBreak"
3128
  "% Type: %PostType% %LineBreak% Status: %PostStatus% %LineBreak% Removed "
3129
  "tag(s): %tag% %PostUrlIfPlublished% %LineBreak% %EditorLinkPost%"
3130
  msgstr ""
3131
 
3132
+ #: defaults.php:133
3133
  msgid "User created new tag"
3134
  msgstr ""
3135
 
3136
+ #: defaults.php:133
3137
  msgid ""
3138
  "Created the tag %TagName% %LineBreak% Slug: %Slug% %LineBreak% %TagLink%"
3139
  msgstr ""
3140
 
3141
+ #: defaults.php:134
3142
  msgid "User deleted tag"
3143
  msgstr ""
3144
 
3145
+ #: defaults.php:134
3146
  msgid "Deleted the tag %TagName% %LineBreak% Slug: %Slug%"
3147
  msgstr ""
3148
 
3149
+ #: defaults.php:135
3150
  msgid "User renamed tag"
3151
  msgstr ""
3152
 
3153
+ #: defaults.php:135
3154
  msgid ""
3155
  "Old name: %old_name% %LineBreak% New name: %new_name% %LineBreak% Slug: %Slug"
3156
  "% %LineBreak% %TagLink%"
3157
  msgstr ""
3158
 
3159
+ #: defaults.php:136
3160
  msgid "User changed tag slug"
3161
  msgstr ""
3162
 
3163
+ #: defaults.php:136
3164
  msgid ""
3165
  "Changed the slug of the tag %tag% %LineBreak% Previous slug: %old_slug% "
3166
  "%LineBreak% New slug: %new_slug% %LineBreak% %TagLink%"
3167
  msgstr ""
3168
 
3169
+ #: defaults.php:137
3170
  msgid "User changed tag description"
3171
  msgstr ""
3172
 
3173
+ #: defaults.php:137
3174
  msgid ""
3175
  "Changed the description of the tag %tag% %LineBreak% Slug: %Slug% %LineBreak"
3176
  "% Previous description: %old_desc% %LineBreak% New description: %new_desc% "
3177
  "%LineBreak% %TagLink%"
3178
  msgstr ""
3179
 
3180
+ #: defaults.php:140
3181
  msgid "Categories"
3182
  msgstr ""
3183
 
3184
+ #: defaults.php:141
3185
  msgid "User changed post category"
3186
  msgstr ""
3187
 
3188
+ #: defaults.php:141
3189
  msgid ""
3190
  "Changed the category of the post %PostTitle% %LineBreak% ID: %PostID% "
3191
  "%LineBreak% Type: %PostType% %LineBreak% Status: %PostStatus% %LineBreak% "
3193
  "%NewCategories% %PostUrlIfPlublished% %LineBreak% %EditorLinkPost%"
3194
  msgstr ""
3195
 
3196
+ #: defaults.php:142
3197
  msgid "User created new category"
3198
  msgstr ""
3199
 
3200
+ #: defaults.php:142
3201
  msgid ""
3202
  "Created the category %CategoryName% %LineBreak% Slug: %Slug% %LineBreak% "
3203
  "%CategoryLink%"
3204
  msgstr ""
3205
 
3206
+ #: defaults.php:143
3207
  msgid "User deleted category"
3208
  msgstr ""
3209
 
3210
+ #: defaults.php:143
3211
  msgid "Deleted the category %CategoryName% %LineBreak% Slug: %Slug%"
3212
  msgstr ""
3213
 
3214
+ #: defaults.php:144
3215
  msgid "Changed the parent of a category"
3216
  msgstr ""
3217
 
3218
+ #: defaults.php:144
3219
  msgid ""
3220
  "Changed the parent of the category %CategoryName% %LineBreak% Slug: %Slug% "
3221
  "%LineBreak% Previous parent: %OldParent% %LineBreak% New parent: %NewParent% "
3222
  "%LineBreak% %CategoryLink%"
3223
  msgstr ""
3224
 
3225
+ #: defaults.php:145
3226
  msgid "User changed category name"
3227
  msgstr ""
3228
 
3229
+ #: defaults.php:145
3230
  msgid ""
3231
  "Previous name: %old_name% %LineBreak% New name: %new_name% %LineBreak% Slug: "
3232
  "%slug% %LineBreak% %cat_link%"
3233
  msgstr ""
3234
 
3235
+ #: defaults.php:146
3236
  msgid "User changed category slug"
3237
  msgstr ""
3238
 
3239
+ #: defaults.php:146
3240
  msgid ""
3241
  "Changed the slug of the category: %CategoryName% %LineBreak% Previous slug: "
3242
  "%old_slug% %LineBreak% New slug: %new_slug% %LineBreak% %cat_link%"
3243
  msgstr ""
3244
 
3245
+ #: defaults.php:149
3246
  msgid "Custom Fields"
3247
  msgstr ""
3248
 
3249
+ #: defaults.php:150
3250
  msgid "User created a custom field for a post"
3251
  msgstr ""
3252
 
3253
+ #: defaults.php:150
3254
  msgid ""
3255
  "Created a new custom field called %MetaKey% in the post %PostTitle% "
3256
  "%LineBreak% Post ID: %PostID% %LineBreak% Post Type: %PostType% %LineBreak% "
3258
  "%PostUrlIfPlublished% %LineBreak% %EditorLinkPost% %LineBreak% %MetaLink%"
3259
  msgstr ""
3260
 
3261
+ #: defaults.php:151
3262
  msgid "User updated a custom field value for a post"
3263
  msgstr ""
3264
 
3265
+ #: defaults.php:151
3266
  msgid ""
3267
  "Modified the value of the custom field %MetaKey% in the post %PostTitle% "
3268
  "%LineBreak% Post ID: %PostID% %LineBreak% Post Type: %PostType% %LineBreak% "
3271
  "%PostUrlIfPlublished% %LineBreak% %EditorLinkPost% %LineBreak% %MetaLink%."
3272
  msgstr ""
3273
 
3274
+ #: defaults.php:152
3275
  msgid "User deleted a custom field from a post"
3276
  msgstr ""
3277
 
3278
+ #: defaults.php:152
3279
  msgid ""
3280
  "Deleted the custom field %MetaKey% from the post %PostTitle% %LineBreak% "
3281
  "Post ID: %PostID% %LineBreak% Post Type: %PostType% %LineBreak% Post Status: "
3282
  "%PostStatus% %PostUrlIfPlublished% %LineBreak% %EditorLinkPost%"
3283
  msgstr ""
3284
 
3285
+ #: defaults.php:153
3286
  msgid "User updated a custom field name for a post"
3287
  msgstr ""
3288
 
3289
+ #: defaults.php:153
3290
  msgid ""
3291
  "Old custom field name: %MetaKeyOld% %LineBreak% New custom field name: "
3292
  "%MetaKeyNew% %LineBreak% Post: %PostTitle% %LineBreak% Post ID: %PostID% "
3294
  "%PostUrlIfPlublished% %LineBreak% %EditorLinkPost%"
3295
  msgstr ""
3296
 
3297
+ #: defaults.php:156
3298
+ msgid "Custom Fields (ACF)"
3299
+ msgstr ""
3300
+
3301
+ #: defaults.php:159
3302
+ msgid "User added relationship to a custom field value for a post"
3303
+ msgstr ""
3304
+
3305
  #: defaults.php:160
3306
+ msgid ""
3307
+ "Modified the value of the custom field %MetaKey% in the post %PostTitle% "
3308
+ "%LineBreak% Post ID: %PostID% %LineBreak% Post Type: %PostType% %LineBreak% "
3309
+ "Post Status: %PostStatus% %LineBreak% Added the following relationships: "
3310
+ "%Relationships% %LineBreak% %LineBreak% %EditorLinkPost% %LineBreak% "
3311
+ "%MetaLink%."
3312
+ msgstr ""
3313
+
3314
+ #: defaults.php:166
3315
+ msgid "User removed relationship from a custom field value for a post"
3316
+ msgstr ""
3317
+
3318
+ #: defaults.php:167
3319
+ msgid ""
3320
+ "Modified the value of the custom field %MetaKey% in the post %PostTitle% "
3321
+ "%LineBreak% Post ID: %PostID% %LineBreak% Post Type: %PostType% %LineBreak% "
3322
+ "Post Status: %PostStatus% %LineBreak% Removed the following relationships: "
3323
+ "%Relationships% %LineBreak% %LineBreak% %EditorLinkPost% %LineBreak% "
3324
+ "%MetaLink%."
3325
+ msgstr ""
3326
+
3327
+ #: defaults.php:176
3328
  msgid "Comments"
3329
  msgstr ""
3330
 
3331
+ #: defaults.php:177
3332
  msgid "User approved a comment"
3333
  msgstr ""
3334
 
3335
+ #: defaults.php:177
3336
  msgid ""
3337
  "Approved the comment posted by %Author% on the post %PostTitle% %LineBreak% "
3338
  "Post ID: %PostID% %LineBreak% Post Type: %PostType% %LineBreak% Post Status: "
3340
  "%LineBreak% %CommentLink%"
3341
  msgstr ""
3342
 
3343
+ #: defaults.php:178
3344
  msgid "User unapproved a comment"
3345
  msgstr ""
3346
 
3347
+ #: defaults.php:178
3348
  msgid ""
3349
  "Unapproved the comment posted by %Author% on the post %PostTitle% %LineBreak"
3350
  "% Post ID: %PostID% %LineBreak% Post Type: %PostType% %LineBreak% Post "
3352
  "% %LineBreak% %CommentLink%"
3353
  msgstr ""
3354
 
3355
+ #: defaults.php:179
3356
  msgid "User replied to a comment"
3357
  msgstr ""
3358
 
3359
+ #: defaults.php:179
3360
  msgid ""
3361
  "Replied to the comment posted by %Author% on the post %PostTitle% %LineBreak"
3362
  "% Post ID: %PostID% %LineBreak% Post Type: %PostType% %LineBreak% Post "
3364
  "% %LineBreak% %CommentLink%"
3365
  msgstr ""
3366
 
3367
+ #: defaults.php:180
3368
  msgid "User edited a comment"
3369
  msgstr ""
3370
 
3371
+ #: defaults.php:180
3372
  msgid ""
3373
  "Edited the comment posted by %Author% on the post %PostTitle% %LineBreak% "
3374
  "Post ID: %PostID% %LineBreak% Post Type: %PostType% %LineBreak% Post Status: "
3376
  "%LineBreak% %CommentLink%"
3377
  msgstr ""
3378
 
3379
+ #: defaults.php:181
3380
  msgid "User marked a comment as Spam"
3381
  msgstr ""
3382
 
3383
+ #: defaults.php:181
3384
  msgid ""
3385
  "Marked the comment posted by %Author% on the post %PostTitle% as spam "
3386
  "%LineBreak% Post ID: %PostID% %LineBreak% Post Type: %PostType% %LineBreak% "
3388
  "%PostUrlIfPlublished% %LineBreak% %CommentLink%"
3389
  msgstr ""
3390
 
3391
+ #: defaults.php:182
3392
  msgid "User marked a comment as Not Spam"
3393
  msgstr ""
3394
 
3395
+ #: defaults.php:182
3396
  msgid ""
3397
  "Marked the comment posted by %Author% on the post %PostTitle% as not spam "
3398
  "%LineBreak% Post ID: %PostID% %LineBreak% Post Type: %PostType% %LineBreak% "
3400
  "%PostUrlIfPlublished% %LineBreak% %CommentLink%"
3401
  msgstr ""
3402
 
3403
+ #: defaults.php:183
3404
  msgid "User moved a comment to trash"
3405
  msgstr ""
3406
 
3407
+ #: defaults.php:183
3408
  msgid ""
3409
  "Moved the comment posted by %Author% on the post %PostTitle% to trash "
3410
  "%LineBreak% Post ID: %PostID% %LineBreak% Post Type: %PostType% %LineBreak% "
3412
  "%PostUrlIfPlublished% %LineBreak% %CommentLink%"
3413
  msgstr ""
3414
 
3415
+ #: defaults.php:184
3416
  msgid "User restored a comment from the trash"
3417
  msgstr ""
3418
 
3419
+ #: defaults.php:184
3420
  msgid ""
3421
  "Restored the comment posted by %Author% on the post %PostTitle% from trash "
3422
  "%LineBreak% Post ID: %PostID% %LineBreak% Post Type: %PostType% %LineBreak% "
3424
  "%PostUrlIfPlublished% %LineBreak% %CommentLink%"
3425
  msgstr ""
3426
 
3427
+ #: defaults.php:185
3428
  msgid "User permanently deleted a comment"
3429
  msgstr ""
3430
 
3431
+ #: defaults.php:185
3432
  msgid ""
3433
  "Permanently deleted the comment posted by %Author% on the post %PostTitle% "
3434
  "%LineBreak% Post ID: %PostID% %LineBreak% Post Type: %PostType% %LineBreak% "
3436
  "%CommentID%"
3437
  msgstr ""
3438
 
3439
+ #: defaults.php:186
3440
  msgid "User posted a comment"
3441
  msgstr ""
3442
 
3443
+ #: defaults.php:186 defaults.php:191
3444
  msgid ""
3445
  "Posted a comment on the post %PostTitle% %LineBreak% Post ID: %PostID% "
3446
  "%LineBreak% Post Type: %PostType% %LineBreak% Post Status: %PostStatus% "
3448
  "%CommentLink%"
3449
  msgstr ""
3450
 
3451
+ #: defaults.php:191
3452
  msgid "Visitor posted a comment"
3453
  msgstr ""
3454
 
3455
+ #: defaults.php:197
3456
  msgid "Widgets"
3457
  msgstr ""
3458
 
3459
+ #: defaults.php:198
3460
  msgid "User added a new widget"
3461
  msgstr ""
3462
 
3463
+ #: defaults.php:198
3464
  msgid "Added a new %WidgetName% widget in %Sidebar%."
3465
  msgstr ""
3466
 
3467
+ #: defaults.php:199
3468
  msgid "User modified a widget"
3469
  msgstr ""
3470
 
3471
+ #: defaults.php:199
3472
  msgid "Modified the %WidgetName% widget in %Sidebar%."
3473
  msgstr ""
3474
 
3475
+ #: defaults.php:200
3476
  msgid "User deleted widget"
3477
  msgstr ""
3478
 
3479
+ #: defaults.php:200
3480
  msgid "Deleted the %WidgetName% widget from %Sidebar%."
3481
  msgstr ""
3482
 
3483
+ #: defaults.php:201
3484
  msgid "User moved widget"
3485
  msgstr ""
3486
 
3487
+ #: defaults.php:201
3488
  msgid ""
3489
  "Moved the %WidgetName% widget %LineBreak% From: %OldSidebar% %LineBreak% To: "
3490
  "%NewSidebar%"
3491
  msgstr ""
3492
 
3493
+ #: defaults.php:202
3494
  msgid "User changed widget position"
3495
  msgstr ""
3496
 
3497
+ #: defaults.php:202
3498
  msgid "Changed the position of the %WidgetName% widget in %Sidebar%."
3499
  msgstr ""
3500
 
3501
+ #: defaults.php:208
3502
  msgid "Menus"
3503
  msgstr ""
3504
 
3505
+ #: defaults.php:209
3506
  msgid "User created new menu"
3507
  msgstr ""
3508
 
3509
+ #: defaults.php:209
3510
  msgid "New menu called %MenuName%."
3511
  msgstr ""
3512
 
3513
+ #: defaults.php:210
3514
  msgid "User added content to a menu"
3515
  msgstr ""
3516
 
3517
+ #: defaults.php:210
3518
  msgid ""
3519
  "Added new item to the menu %MenuName% %LineBreak% Item type: %ContentType% "
3520
  "%LineBreak% Item name: %ContentName% "
3521
  msgstr ""
3522
 
3523
+ #: defaults.php:211
3524
  msgid "User removed content from a menu"
3525
  msgstr ""
3526
 
3527
+ #: defaults.php:211
3528
  msgid ""
3529
  "Removed item from the menu %MenuName% %LineBreak% Item type: %ContentType% "
3530
  "%LineBreak% Item name: %ContentName%"
3531
  msgstr ""
3532
 
3533
+ #: defaults.php:212
3534
  msgid "User deleted menu"
3535
  msgstr ""
3536
 
3537
+ #: defaults.php:212
3538
  msgid "Deleted the menu %MenuName%"
3539
  msgstr ""
3540
 
3541
+ #: defaults.php:213
3542
  msgid "User changed menu setting"
3543
  msgstr ""
3544
 
3545
+ #: defaults.php:213
3546
  msgid "The setting in the %MenuName% %LineBreak% Setting: %MenuSetting%"
3547
  msgstr ""
3548
 
3549
+ #: defaults.php:214
3550
  msgid "User modified content in a menu"
3551
  msgstr ""
3552
 
3553
+ #: defaults.php:214
3554
  msgid ""
3555
  "Modified an item in the menu %MenuName% %LineBreak% Item type: %ContentType% "
3556
  "%LineBreak% Item name: %ContentName%"
3557
  msgstr ""
3558
 
3559
+ #: defaults.php:215
3560
  msgid "User changed name of a menu"
3561
  msgstr ""
3562
 
3563
+ #: defaults.php:215
3564
  msgid "Old name: %OldMenuName% %LineBreak% New name: %NewMenuName%"
3565
  msgstr ""
3566
 
3567
+ #: defaults.php:216
3568
  msgid "User changed order of the objects in a menu"
3569
  msgstr ""
3570
 
3571
+ #: defaults.php:216
3572
  msgid "Changed the order of the items in the menu %MenuName%"
3573
  msgstr ""
3574
 
3575
+ #: defaults.php:217
3576
  msgid "User moved objects as a sub-item"
3577
  msgstr ""
3578
 
3579
+ #: defaults.php:217
3580
  msgid ""
3581
  "Menu name: %MenuName% %LineBreak% Moved item %ItemName% as a sub-item of "
3582
  "%ParentName%"
3583
  msgstr ""
3584
 
3585
+ #: defaults.php:229
3586
  msgid "User modified a draft blog post"
3587
  msgstr ""
3588
 
3589
+ #: defaults.php:229
3590
  msgid "Modified the draft post with the %PostTitle%. %EditorLinkPost%."
3591
  msgstr ""
3592
 
3593
+ #: defaults.php:230
3594
  msgid "User created a new post with custom post type and saved it as draft"
3595
  msgstr ""
3596
 
3597
+ #: defaults.php:230
3598
  msgid ""
3599
  "Created a new custom post called %PostTitle% of type %PostType%. "
3600
  "%EditorLinkPost%."
3601
  msgstr ""
3602
 
3603
+ #: defaults.php:231
3604
  msgid "User published a post with custom post type"
3605
  msgstr ""
3606
 
3607
+ #: defaults.php:231
3608
  msgid ""
3609
  "Published a custom post %PostTitle% of type %PostType%. Post URL is %PostUrl"
3610
  "%. %EditorLinkPost%."
3611
  msgstr ""
3612
 
3613
+ #: defaults.php:232
3614
  msgid "User modified a post with custom post type"
3615
  msgstr ""
3616
 
3617
+ #: defaults.php:232
3618
  msgid ""
3619
  "Modified the custom post %PostTitle% of type %PostType%. Post URL is %PostUrl"
3620
  "%. %EditorLinkPost%."
3621
  msgstr ""
3622
 
3623
+ #: defaults.php:233
3624
  msgid "User modified a draft post with custom post type"
3625
  msgstr ""
3626
 
3627
+ #: defaults.php:233
3628
  msgid ""
3629
  "Modified the draft custom post %PostTitle% of type is %PostType%. "
3630
  "%EditorLinkPost%."
3631
  msgstr ""
3632
 
3633
+ #: defaults.php:234
3634
  msgid "User permanently deleted post with custom post type"
3635
  msgstr ""
3636
 
3637
+ #: defaults.php:234
3638
  msgid "Permanently Deleted the custom post %PostTitle% of type %PostType%."
3639
  msgstr ""
3640
 
3641
+ #: defaults.php:235
3642
  msgid "User moved post with custom post type to trash"
3643
  msgstr ""
3644
 
3645
+ #: defaults.php:235
3646
  msgid ""
3647
  "Moved the custom post %PostTitle% of type %PostType% to trash. Post URL was "
3648
  "%PostUrl%."
3649
  msgstr ""
3650
 
3651
+ #: defaults.php:236
3652
  msgid "User restored post with custom post type from trash"
3653
  msgstr ""
3654
 
3655
+ #: defaults.php:236
3656
  msgid ""
3657
  "The custom post %PostTitle% of type %PostType% has been restored from trash. "
3658
  "%EditorLinkPost%."
3659
  msgstr ""
3660
 
3661
+ #: defaults.php:237
3662
  msgid "User changed the category of a post with custom post type"
3663
  msgstr ""
3664
 
3665
+ #: defaults.php:237
3666
  msgid ""
3667
  "Changed the category(ies) of the custom post %PostTitle% of type %PostType% "
3668
  "from %OldCategories% to %NewCategories%. %EditorLinkPost%."
3669
  msgstr ""
3670
 
3671
+ #: defaults.php:238
3672
  msgid "User changed the URL of a post with custom post type"
3673
  msgstr ""
3674
 
3675
+ #: defaults.php:238
3676
  msgid ""
3677
  "Changed the URL of the custom post %PostTitle% of type %PostType% from "
3678
  "%OldUrl% to %NewUrl%. %EditorLinkPost%."
3679
  msgstr ""
3680
 
3681
+ #: defaults.php:239
3682
  msgid "User changed the author or post with custom post type"
3683
  msgstr ""
3684
 
3685
+ #: defaults.php:239
3686
  msgid ""
3687
  "Changed the author of custom post %PostTitle% of type %PostType% from "
3688
  "%OldAuthor% to %NewAuthor%. %EditorLinkPost%."
3689
  msgstr ""
3690
 
3691
+ #: defaults.php:240
3692
  msgid "User changed the status of post with custom post type"
3693
  msgstr ""
3694
 
3695
+ #: defaults.php:240
3696
  msgid ""
3697
  "Changed the status of custom post %PostTitle% of type %PostType% from "
3698
  "%OldStatus% to %NewStatus%. %EditorLinkPost%."
3699
  msgstr ""
3700
 
3701
+ #: defaults.php:241
3702
  msgid "User changed the visibility of a post with custom post type"
3703
  msgstr ""
3704
 
3705
+ #: defaults.php:241
3706
  msgid ""
3707
  "Changed the visibility of the custom post %PostTitle% of type %PostType% "
3708
  "from %OldVisibility% to %NewVisibility%. %EditorLinkPost%."
3709
  msgstr ""
3710
 
3711
+ #: defaults.php:242
3712
  msgid "User changed the date of post with custom post type"
3713
  msgstr ""
3714
 
3715
+ #: defaults.php:242
3716
  msgid ""
3717
  "Changed the date of the custom post %PostTitle% of type %PostType% from "
3718
  "%OldDate% to %NewDate%. %EditorLinkPost%."
3719
  msgstr ""
3720
 
3721
+ #: defaults.php:243
3722
  msgid "User created a custom field for a custom post type"
3723
  msgstr ""
3724
 
3725
+ #: defaults.php:243
3726
  msgid ""
3727
  "Created a new custom field %MetaKey% with value %MetaValue% in custom post "
3728
  "%PostTitle% of type %PostType%. %EditorLinkPost%.<br>%MetaLink%."
3729
  msgstr ""
3730
 
3731
+ #: defaults.php:244
3732
  msgid "User updated a custom field for a custom post type"
3733
  msgstr ""
3734
 
3735
+ #: defaults.php:244
3736
  msgid ""
3737
  "Modified the value of the custom field %MetaKey% from %MetaValueOld% to "
3738
  "%MetaValueNew% in custom post %PostTitle% of type %PostType% %EditorLinkPost"
3739
  "%.<br>%MetaLink%."
3740
  msgstr ""
3741
 
3742
+ #: defaults.php:245
3743
  msgid "User deleted a custom field from a custom post type"
3744
  msgstr ""
3745
 
3746
+ #: defaults.php:245
3747
  msgid ""
3748
  "Deleted the custom field %MetaKey% with id %MetaID% from custom post "
3749
  "%PostTitle% of type %PostType% %EditorLinkPost%.<br>%MetaLink%."
3750
  msgstr ""
3751
 
3752
+ #: defaults.php:246
3753
  msgid "User updated a custom field name for a custom post type"
3754
  msgstr ""
3755
 
3756
+ #: defaults.php:246
3757
  msgid ""
3758
  "Changed the custom field name from %MetaKeyOld% to %MetaKeyNew% in custom "
3759
  "post %PostTitle% of type %PostType% %EditorLinkPost%.<br>%MetaLink%."
3760
  msgstr ""
3761
 
3762
+ #: defaults.php:247
3763
  msgid "User modified content for a published custom post type"
3764
  msgstr ""
3765
 
3766
+ #: defaults.php:247
3767
  msgid ""
3768
  "Modified the content of the published custom post type %PostTitle%. Post URL "
3769
  "is %PostUrl%.%EditorLinkPost%."
3770
  msgstr ""
3771
 
3772
+ #: defaults.php:248
3773
  msgid "User modified content for a draft post"
3774
  msgstr ""
3775
 
3776
+ #: defaults.php:248
3777
  msgid ""
3778
  "Modified the content of the draft post %PostTitle%.%RevisionLink% "
3779
  "%EditorLinkPost%."
3780
  msgstr ""
3781
 
3782
+ #: defaults.php:249
3783
  msgid "User modified content for a draft custom post type"
3784
  msgstr ""
3785
 
3786
+ #: defaults.php:249
3787
  msgid ""
3788
  "Modified the content of the draft custom post type %PostTitle%."
3789
  "%EditorLinkPost%."
3790
  msgstr ""
3791
 
3792
+ #: defaults.php:250
3793
  msgid "User modified content of a post"
3794
  msgstr ""
3795
 
3796
+ #: defaults.php:250
3797
  msgid ""
3798
  "Modified the content of post %PostTitle% which is submitted for review."
3799
  "%RevisionLink% %EditorLinkPost%."
3800
  msgstr ""
3801
 
3802
+ #: defaults.php:251
3803
  msgid "User scheduled a custom post type"
3804
  msgstr ""
3805
 
3806
+ #: defaults.php:251
3807
  msgid ""
3808
  "Scheduled the custom post type %PostTitle% to be published %PublishingDate%. "
3809
  "%EditorLinkPost%."
3810
  msgstr ""
3811
 
3812
+ #: defaults.php:252
3813
  msgid "User changed title of a custom post type"
3814
  msgstr ""
3815
 
3816
+ #: defaults.php:252
3817
  msgid ""
3818
  "Changed the title of the custom post %OldTitle% to %NewTitle%. "
3819
  "%EditorLinkPost%."
3820
  msgstr ""
3821
 
3822
+ #: defaults.php:253
3823
  msgid "User opened a custom post type in the editor"
3824
  msgstr ""
3825
 
3826
+ #: defaults.php:253
3827
  msgid ""
3828
  "Opened the custom post %PostTitle% of type %PostType% in the editor. View "
3829
  "the post: %EditorLinkPost%."
3830
  msgstr ""
3831
 
3832
+ #: defaults.php:254
3833
  msgid "User viewed a custom post type"
3834
  msgstr ""
3835
 
3836
+ #: defaults.php:254
3837
  msgid ""
3838
  "Viewed the custom post %PostTitle% of type %PostType%. View the post: "
3839
  "%PostUrl%."
3840
  msgstr ""
3841
 
3842
+ #: defaults.php:255
3843
  msgid "A plugin created a custom post"
3844
  msgstr ""
3845
 
3846
+ #: defaults.php:255
3847
  msgid "A plugin automatically created the following custom post: %PostTitle%."
3848
  msgstr ""
3849
 
3850
+ #: defaults.php:256
3851
  msgid "A plugin deleted a custom post"
3852
  msgstr ""
3853
 
3854
+ #: defaults.php:256
3855
  msgid "A plugin automatically deleted the following custom post: %PostTitle%."
3856
  msgstr ""
3857
 
3858
+ #: defaults.php:257
3859
  msgid "A plugin modified a custom post"
3860
  msgstr ""
3861
 
3862
+ #: defaults.php:257
3863
  msgid ""
3864
  "Plugin modified the custom post %PostTitle%. View the post: %EditorLinkPost%."
3865
  msgstr ""
3866
 
3867
+ #: defaults.php:269
3868
  msgid "User created a new WordPress page and saved it as draft"
3869
  msgstr ""
3870
 
3871
+ #: defaults.php:269
3872
  msgid ""
3873
  "Created a new page called %PostTitle% and saved it as draft. %EditorLinkPage"
3874
  "%."
3875
  msgstr ""
3876
 
3877
+ #: defaults.php:270
3878
  msgid "User published a WordPress page"
3879
  msgstr ""
3880
 
3881
+ #: defaults.php:270
3882
  msgid ""
3883
  "Published a page called %PostTitle%. Page URL is %PostUrl%. %EditorLinkPage%."
3884
  msgstr ""
3885
 
3886
+ #: defaults.php:271
3887
  msgid "User modified a published WordPress page"
3888
  msgstr ""
3889
 
3890
+ #: defaults.php:271
3891
  msgid ""
3892
  "Modified the published page %PostTitle%. Page URL is %PostUrl%. "
3893
  "%EditorLinkPage%."
3894
  msgstr ""
3895
 
3896
+ #: defaults.php:272
3897
  msgid "User modified a draft WordPress page"
3898
  msgstr ""
3899
 
3900
+ #: defaults.php:272
3901
  msgid ""
3902
  "Modified the draft page %PostTitle%. Page ID is %PostID%. %EditorLinkPage%."
3903
  msgstr ""
3904
 
3905
+ #: defaults.php:273
3906
  msgid "User permanently deleted a page from the trash"
3907
  msgstr ""
3908
 
3909
+ #: defaults.php:273
3910
  msgid "Permanently deleted the page %PostTitle%."
3911
  msgstr ""
3912
 
3913
+ #: defaults.php:274
3914
  msgid "User moved WordPress page to the trash"
3915
  msgstr ""
3916
 
3917
+ #: defaults.php:274
3918
  msgid "Moved the page %PostTitle% to trash. Page URL was %PostUrl%."
3919
  msgstr ""
3920
 
3921
+ #: defaults.php:275
3922
  msgid "User restored a WordPress page from trash"
3923
  msgstr ""
3924
 
3925
+ #: defaults.php:275
3926
  msgid "Page %PostTitle% has been restored from trash. %EditorLinkPage%."
3927
  msgstr ""
3928
 
3929
+ #: defaults.php:276
3930
  msgid "User changed page URL"
3931
  msgstr ""
3932
 
3933
+ #: defaults.php:276
3934
  msgid ""
3935
  "Changed the URL of the page %PostTitle% from %OldUrl% to %NewUrl%. "
3936
  "%EditorLinkPage%."
3937
  msgstr ""
3938
 
3939
+ #: defaults.php:277
3940
  msgid "User changed page author"
3941
  msgstr ""
3942
 
3943
+ #: defaults.php:277
3944
  msgid ""
3945
  "Changed the author of the page %PostTitle% from %OldAuthor% to %NewAuthor%. "
3946
  "%EditorLinkPage%."
3947
  msgstr ""
3948
 
3949
+ #: defaults.php:278
3950
  msgid "User changed page status"
3951
  msgstr ""
3952
 
3953
+ #: defaults.php:278
3954
  msgid ""
3955
  "Changed the status of the page %PostTitle% from %OldStatus% to %NewStatus%. "
3956
  "%EditorLinkPage%."
3957
  msgstr ""
3958
 
3959
+ #: defaults.php:279
3960
  msgid "User changed the visibility of a page post"
3961
  msgstr ""
3962
 
3963
+ #: defaults.php:279
3964
  msgid ""
3965
  "Changed the visibility of the page %PostTitle% from %OldVisibility% to "
3966
  "%NewVisibility%. %EditorLinkPage%."
3967
  msgstr ""
3968
 
3969
+ #: defaults.php:280
3970
  msgid "User changed the date of a page post"
3971
  msgstr ""
3972
 
3973
+ #: defaults.php:280
3974
  msgid ""
3975
  "Changed the date of the page %PostTitle% from %OldDate% to %NewDate%. "
3976
  "%EditorLinkPage%."
3977
  msgstr ""
3978
 
3979
+ #: defaults.php:281
3980
  msgid "User created a custom field for a page"
3981
  msgstr ""
3982
 
3983
+ #: defaults.php:281
3984
  msgid ""
3985
  "Created a new custom field called %MetaKey% with value %MetaValue% in the "
3986
  "page %PostTitle% %EditorLinkPage%.<br>%MetaLink%."
3987
  msgstr ""
3988
 
3989
+ #: defaults.php:282
3990
  msgid "User updated a custom field value for a page"
3991
  msgstr ""
3992
 
3993
+ #: defaults.php:282
3994
  msgid ""
3995
  "Modified the value of the custom field %MetaKey% from %MetaValueOld% to "
3996
  "%MetaValueNew% in the page %PostTitle% %EditorLinkPage%.<br>%MetaLink%."
3997
  msgstr ""
3998
 
3999
+ #: defaults.php:283
4000
  msgid "User deleted a custom field from a page"
4001
  msgstr ""
4002
 
4003
+ #: defaults.php:283
4004
  msgid ""
4005
  "Deleted the custom field %MetaKey% with id %MetaID% from page %PostTitle% "
4006
  "%EditorLinkPage%.<br>%MetaLink%."
4007
  msgstr ""
4008
 
4009
+ #: defaults.php:284
4010
  msgid "User updated a custom field name for a page"
4011
  msgstr ""
4012
 
4013
+ #: defaults.php:284
4014
  msgid ""
4015
  "Changed the custom field name from %MetaKeyOld% to %MetaKeyNew% in the page "
4016
  "%PostTitle% %EditorLinkPage%.<br>%MetaLink%."
4017
  msgstr ""
4018
 
4019
+ #: defaults.php:285
4020
  msgid "User modified content for a published page"
4021
  msgstr ""
4022
 
4023
+ #: defaults.php:285
4024
  msgid ""
4025
  "Modified the content of the published page %PostTitle%. Page URL is %PostUrl"
4026
  "%. %RevisionLink% %EditorLinkPage%."
4027
  msgstr ""
4028
 
4029
+ #: defaults.php:286
4030
  msgid "User modified content for a draft page"
4031
  msgstr ""
4032
 
4033
+ #: defaults.php:286
4034
  msgid ""
4035
  "Modified the content of draft page %PostTitle%.%RevisionLink% %EditorLinkPage"
4036
  "%."
4037
  msgstr ""
4038
 
4039
+ #: defaults.php:287
4040
  msgid "User scheduled a page"
4041
  msgstr ""
4042
 
4043
+ #: defaults.php:287
4044
  msgid ""
4045
  "Scheduled the page %PostTitle% to be published %PublishingDate%. "
4046
  "%EditorLinkPage%."
4047
  msgstr ""
4048
 
4049
+ #: defaults.php:288
4050
  msgid "User changed title of a page"
4051
  msgstr ""
4052
 
4053
+ #: defaults.php:288
4054
  msgid ""
4055
  "Changed the title of the page %OldTitle% to %NewTitle%. %EditorLinkPage%."
4056
  msgstr ""
4057
 
4058
+ #: defaults.php:289
4059
  msgid "User opened a page in the editor"
4060
  msgstr ""
4061
 
4062
+ #: defaults.php:289
4063
  msgid ""
4064
  "Opened the page %PostTitle% in the editor. View the page: %EditorLinkPage%."
4065
  msgstr ""
4066
 
4067
+ #: defaults.php:290
4068
  msgid "User viewed a page"
4069
  msgstr ""
4070
 
4071
+ #: defaults.php:290
4072
  msgid "Viewed the page %PostTitle%. View the page: %PostUrl%."
4073
  msgstr ""
4074
 
4075
+ #: defaults.php:291
4076
  msgid "User disabled Comments/Trackbacks and Pingbacks on a draft post"
4077
  msgstr ""
4078
 
4079
+ #: defaults.php:291
4080
  msgid ""
4081
  "Disabled %Type% on the draft post %PostTitle%. View the post: %PostUrl%."
4082
  msgstr ""
4083
 
4084
+ #: defaults.php:292
4085
  msgid "User enabled Comments/Trackbacks and Pingbacks on a draft post"
4086
  msgstr ""
4087
 
4088
+ #: defaults.php:292
4089
  msgid "Enabled %Type% on the draft post %PostTitle%. View the post: %PostUrl%."
4090
  msgstr ""
4091
 
4092
+ #: defaults.php:293
4093
  msgid "User disabled Comments/Trackbacks and Pingbacks on a published page"
4094
  msgstr ""
4095
 
4096
+ #: defaults.php:293
4097
  msgid ""
4098
  "Disabled %Type% on the published page %PostTitle%. View the page: %PostUrl%."
4099
  msgstr ""
4100
 
4101
+ #: defaults.php:294
4102
  msgid "User enabled Comments/Trackbacks and Pingbacks on a published page"
4103
  msgstr ""
4104
 
4105
+ #: defaults.php:294
4106
  msgid ""
4107
  "Enabled %Type% on the published page %PostTitle%. View the page: %PostUrl%."
4108
  msgstr ""
4109
 
4110
+ #: defaults.php:295
4111
  msgid "User disabled Comments/Trackbacks and Pingbacks on a draft page"
4112
  msgstr ""
4113
 
4114
+ #: defaults.php:295
4115
  msgid ""
4116
  "Disabled %Type% on the draft page %PostTitle%. View the page: %PostUrl%."
4117
  msgstr ""
4118
 
4119
+ #: defaults.php:296
4120
  msgid "User enabled Comments/Trackbacks and Pingbacks on a draft page"
4121
  msgstr ""
4122
 
4123
+ #: defaults.php:296
4124
  msgid "Enabled %Type% on the draft page %PostTitle%. View the page: %PostUrl%."
4125
  msgstr ""
4126
 
4127
+ #: defaults.php:297
4128
  msgid "A plugin created a page"
4129
  msgstr ""
4130
 
4131
+ #: defaults.php:297
4132
  msgid "A plugin automatically created the following page: %PostTitle%."
4133
  msgstr ""
4134
 
4135
+ #: defaults.php:298
4136
  msgid "A plugin deleted a page"
4137
  msgstr ""
4138
 
4139
+ #: defaults.php:298
4140
  msgid "A plugin automatically deleted the following page: %PostTitle%."
4141
  msgstr ""
4142
 
4143
+ #: defaults.php:299
4144
  msgid "A plugin modified a page"
4145
  msgstr ""
4146
 
4147
+ #: defaults.php:299
4148
  msgid "Plugin modified the page %PostTitle%. View the page: %EditorLinkPage%."
4149
  msgstr ""
4150
 
4151
+ #: defaults.php:303
4152
  msgid "User Accounts"
4153
  msgstr ""
4154
 
4155
+ #: defaults.php:304
4156
  msgid "User Profiles"
4157
  msgstr ""
4158
 
4159
+ #: defaults.php:305
4160
  msgid "New user was created on WordPress"
4161
  msgstr ""
4162
 
4163
+ #: defaults.php:305 defaults.php:306
4164
  msgid ""
4165
  "New user: %NewUserData->Username% %LineBreak% Role: %NewUserData->Roles% "
4166
  "%LineBreak% First name: %NewUserData->FirstName% %LineBreak% Last name: "
4167
  "%NewUserData->LastName% %LineBreak% %EditUserLink%"
4168
  msgstr ""
4169
 
4170
+ #: defaults.php:306
4171
  msgid "User created another WordPress user"
4172
  msgstr ""
4173
 
4174
+ #: defaults.php:307
4175
  msgid "The role of a user was changed by another WordPress user"
4176
  msgstr ""
4177
 
4178
+ #: defaults.php:307
4179
  msgid ""
4180
  "Changed the role of the user %TargetUsername% %LineBreak% New role: %NewRole"
4181
  "% %LineBreak% Previous role: %OldRole% %LineBreak% First name: %FirstName% "
4182
  "%LineBreak% Last name: %LastName% %LineBreak% %EditUserLink%"
4183
  msgstr ""
4184
 
4185
+ #: defaults.php:308
4186
  msgid "User has changed his or her password"
4187
  msgstr ""
4188
 
4189
+ #: defaults.php:308
4190
  msgid ""
4191
  "Changed the password %LineBreak% First name: %TargetUserData->FirstName% "
4192
  "%LineBreak% Last name: %TargetUserData->LastName% %LineBreak% %EditUserLink%"
4193
  msgstr ""
4194
 
4195
+ #: defaults.php:309
4196
  msgid "User changed another user's password"
4197
  msgstr ""
4198
 
4199
+ #: defaults.php:309
4200
  msgid ""
4201
  "Changed the password of the user %TargetUserData->Username% %LineBreak% "
4202
  "Role: %TargetUserData->Roles% %LineBreak% First name: %TargetUserData-"
4204
  "%EditUserLink%"
4205
  msgstr ""
4206
 
4207
+ #: defaults.php:310
4208
  msgid "User changed his or her email address"
4209
  msgstr ""
4210
 
4211
+ #: defaults.php:310
4212
  msgid ""
4213
  "Changed the email address to %NewEmail% %LineBreak% Role: %Roles% %LineBreak"
4214
  "% First name: %FirstName% %LineBreak% Last name: %LastName% %LineBreak% "
4215
  "%EditUserLink%"
4216
  msgstr ""
4217
 
4218
+ #: defaults.php:311
4219
  msgid "User changed another user's email address"
4220
  msgstr ""
4221
 
4222
+ #: defaults.php:311
4223
  msgid ""
4224
  "Changed the email address of the user %TargetUsername% %LineBreak% New email "
4225
  "address: %NewEmail% %LineBreak% Previous email address: %OldEmail% %LineBreak"
4227
  "%LastName% %LineBreak% %EditUserLink%"
4228
  msgstr ""
4229
 
4230
+ #: defaults.php:312
4231
  msgid "User was deleted by another user"
4232
  msgstr ""
4233
 
4234
+ #: defaults.php:312
4235
  msgid ""
4236
  "User: %TargetUserData->Username% %LineBreak% Role: %TargetUserData->Roles% "
4237
  "%LineBreak% First name: %NewUserData->FirstName% %LineBreak% Last name: "
4238
  "%NewUserData->LastName%"
4239
  msgstr ""
4240
 
4241
+ #: defaults.php:313
4242
  msgid "User opened the profile page of another user"
4243
  msgstr ""
4244
 
4245
+ #: defaults.php:313
4246
  msgid ""
4247
  "The profile page of the user %TargetUsername% %LineBreak% Role: %Roles% "
4248
  "%LineBreak% First name: %FirstName% %LineBreak% Last name: %LastName% "
4249
  "%LineBreak% %EditUserLink%"
4250
  msgstr ""
4251
 
4252
+ #: defaults.php:314
4253
  msgid "User updated a custom field value for a user"
4254
  msgstr ""
4255
 
4256
+ #: defaults.php:314
4257
  msgid ""
4258
  "Changed the value of a custom field in the user profile %TargetUsername% "
4259
  "%LineBreak% Custom field: %custom_field_name% %LineBreak% Previous value: "
4262
  "%LineBreak% %EditUserLink%"
4263
  msgstr ""
4264
 
4265
+ #: defaults.php:315
4266
  msgid "User created a custom field value for a user"
4267
  msgstr ""
4268
 
4269
+ #: defaults.php:315
4270
  msgid ""
4271
  "Created a new custom field in the user profile %TargetUsername% %LineBreak% "
4272
  "Custom field: %custom_field_name% %LineBreak% Custom field value: %new_value"
4274
  "Last name: %LastName% %LineBreak% %EditUserLink%"
4275
  msgstr ""
4276
 
4277
+ #: defaults.php:316
4278
  msgid "User changed first name for a user"
4279
  msgstr ""
4280
 
4281
+ #: defaults.php:316
4282
  msgid ""
4283
  "Changed the first name of the user %TargetUsername% %LineBreak% Previous "
4284
  "name: %old_firstname% %LineBreak% New name: %new_firstname% %LineBreak% "
4285
  "Role: %Roles% %LineBreak% Last name: %LastName% %LineBreak% %EditUserLink%"
4286
  msgstr ""
4287
 
4288
+ #: defaults.php:317
4289
  msgid "User changed last name for a user"
4290
  msgstr ""
4291
 
4292
+ #: defaults.php:317
4293
  msgid ""
4294
  "Changed the last name of the user %TargetUsername% %LineBreak% Previous last "
4295
  "name: %old_lastname% %LineBreak% New last name: %new_lastname% %LineBreak% "
4296
  "Role: %Roles% %LineBreak% First name: %FirstName% %LineBreak% %EditUserLink%"
4297
  msgstr ""
4298
 
4299
+ #: defaults.php:318
4300
  msgid "User changed nickname for a user"
4301
  msgstr ""
4302
 
4303
+ #: defaults.php:318
4304
  msgid ""
4305
  "Changed the nickname of the user %TargetUsername% %LineBreak% Previous "
4306
  "nickname: %old_nickname% New nickname: %new_nickname% %LineBreak% Role: "
4308
  "% %LineBreak% %EditUserLink%"
4309
  msgstr ""
4310
 
4311
+ #: defaults.php:319
4312
  msgid "User changed the display name for a user"
4313
  msgstr ""
4314
 
4315
+ #: defaults.php:319
4316
  msgid ""
4317
  "Changed the display name of the user %TargetUsername% %LineBreak% Previous "
4318
+ "display name: %old_displayname% %LineBreak% New display name: "
4319
+ "%new_displayname% %LineBreak% Role: %Roles% %LineBreak% First name: "
4320
+ "%FirstName% %LineBreak% Last name: %LastName% %LineBreak% %EditUserLink%"
4321
  msgstr ""
4322
 
4323
+ #: defaults.php:322
4324
  msgid "Multisite User Profiles"
4325
  msgstr ""
4326
 
4327
+ #: defaults.php:323
4328
  msgid "User granted Super Admin privileges"
4329
  msgstr ""
4330
 
4331
+ #: defaults.php:323
4332
  msgid ""
4333
  "Granted Super Admin privileges to %TargetUsername% %LineBreak% First name: "
4334
  "%FirstName% %LineBreak% Last name: %LastName% %LineBreak% %EditUserLink%"
4335
  msgstr ""
4336
 
4337
+ #: defaults.php:324
4338
  msgid "User revoked from Super Admin privileges"
4339
  msgstr ""
4340
 
4341
+ #: defaults.php:324
4342
  msgid ""
4343
  "Revoked Super Admin privileges from %TargetUsername% %LineBreak% First name: "
4344
  "%FirstName% %LineBreak% Last name: %LastName% %LineBreak% %EditUserLink%"
4345
  msgstr ""
4346
 
4347
+ #: defaults.php:325
4348
  msgid "Existing user added to a site"
4349
  msgstr ""
4350
 
4351
+ #: defaults.php:325
4352
  msgid ""
4353
  "Added user %TargetUsername% to site: %SiteName% %LineBreak% Role: "
4354
  "%TargetUserRole% %LineBreak% First name: %FirstName% %LineBreak% Last name: "
4355
  "%LastName% %LineBreak% %EditUserLink%"
4356
  msgstr ""
4357
 
4358
+ #: defaults.php:326
4359
  msgid "User removed from site"
4360
  msgstr ""
4361
 
4362
+ #: defaults.php:326
4363
  msgid ""
4364
  "Removed user %TargetUsername% from site: %SiteName% %LineBreak% Previous "
4365
  "role: %TargetUserRole% %LineBreak% First name: %FirstName% %LineBreak% Last "
4366
  "name: %LastName% %LineBreak% %EditUserLink%"
4367
  msgstr ""
4368
 
4369
+ #: defaults.php:327
4370
  msgid "New network user created"
4371
  msgstr ""
4372
 
4373
+ #: defaults.php:327
4374
  msgid ""
4375
  "Created a new network user %NewUserData->Username% %LineBreak% First name: "
4376
  "%NewUserData->FirstName% %LineBreak% Last name: %NewUserData->LastName% "
4377
  "%LineBreak% %EditUserLink%"
4378
  msgstr ""
4379
 
4380
+ #: defaults.php:331
4381
  msgid "Plugins & Themes"
4382
  msgstr ""
4383
 
4384
+ #: defaults.php:333
4385
  msgid "User installed a plugin"
4386
  msgstr ""
4387
 
4388
+ #: defaults.php:333
4389
  msgid ""
4390
  "Name: %Plugin->Name% %LineBreak% Install location: %Plugin->plugin_dir_path%"
4391
  msgstr ""
4392
 
4393
+ #: defaults.php:334
4394
  msgid "User activated a WordPress plugin"
4395
  msgstr ""
4396
 
4397
+ #: defaults.php:334 defaults.php:335 defaults.php:336 defaults.php:337
4398
  msgid "Name: %PluginData->Name% %LineBreak% Install location: %PluginFile%"
4399
  msgstr ""
4400
 
4401
+ #: defaults.php:335
4402
  msgid "User deactivated a WordPress plugin"
4403
  msgstr ""
4404
 
4405
+ #: defaults.php:336
4406
  msgid "User uninstalled a plugin"
4407
  msgstr ""
4408
 
4409
+ #: defaults.php:337
4410
  msgid "User upgraded a plugin"
4411
  msgstr ""
4412
 
4413
+ #: defaults.php:338
4414
  msgid "Plugin created tables"
4415
  msgstr ""
4416
 
4417
+ #: defaults.php:338
4418
  msgid ""
4419
+ "Plugin created this table in the database %LineBreak% Plugin: %Plugin->Name% "
4420
+ "%LineBreak% Tables: %TableNames%"
4421
  msgstr ""
4422
 
4423
+ #: defaults.php:339
4424
  msgid "Plugin modified tables structure"
4425
  msgstr ""
4426
 
4427
+ #: defaults.php:339
4428
  msgid ""
4429
+ "Plugin modified the structure of this table %LineBreak% Plugin: %Plugin->Name"
4430
+ "% %LineBreak% Tables: %TableNames%"
4431
  msgstr ""
4432
 
4433
+ #: defaults.php:340
4434
  msgid "Plugin deleted tables"
4435
  msgstr ""
4436
 
4437
+ #: defaults.php:340
4438
  msgid ""
4439
+ "Plugin deleted this table from the database %LineBreak% Plugin: %Plugin->Name"
4440
+ "% %LineBreak% Tables: %TableNames%"
4441
  msgstr ""
4442
 
4443
+ #: defaults.php:341
4444
  msgid "A plugin created a post"
4445
  msgstr ""
4446
 
4447
+ #: defaults.php:341
4448
  msgid ""
4449
  "Plugin %PluginName% created the post %PostTitle% %LineBreak% Post ID: %PostID"
4450
  "% %LineBreak% Type: %PostType% %LineBreak% Status: %PostStatus% %LineBreak% "
4451
  "%EditorLinkPage%"
4452
  msgstr ""
4453
 
4454
+ #: defaults.php:342
4455
  msgid "A plugin deleted a post"
4456
  msgstr ""
4457
 
4458
+ #: defaults.php:342
4459
  msgid ""
4460
  "Plugin %PluginName% deleted the post %PostTitle% %LineBreak% Post ID: %PostID"
4461
  "% %LineBreak% Type: %PostType%"
4462
  msgstr ""
4463
 
4464
+ #: defaults.php:343
4465
  msgid "User changed a file using the plugin editor"
4466
  msgstr ""
4467
 
4468
+ #: defaults.php:343
4469
  msgid "Modified a file with the plugin editor %LineBreak% File: %File%"
4470
  msgstr ""
4471
 
4472
+ #: defaults.php:346
4473
  msgid "Themes"
4474
  msgstr ""
4475
 
4476
+ #: defaults.php:347
4477
  msgid "User installed a theme"
4478
  msgstr ""
4479
 
4480
+ #: defaults.php:347
4481
  msgid ""
4482
  "Theme: \"%Theme->Name%\" %LineBreak% Install location: %Theme-"
4483
  ">get_template_directory%"
4484
  msgstr ""
4485
 
4486
+ #: defaults.php:348
4487
  msgid "User activated a theme"
4488
  msgstr ""
4489
 
4490
+ #: defaults.php:348 defaults.php:349
4491
  msgid ""
4492
  "Theme \"%Theme->Name%\" %LineBreak% Install location: %Theme-"
4493
  ">get_template_directory%"
4494
  msgstr ""
4495
 
4496
+ #: defaults.php:349
4497
  msgid "User uninstalled a theme"
4498
  msgstr ""
4499
 
4500
+ #: defaults.php:350
4501
  msgid "Theme created tables"
4502
  msgstr ""
4503
 
4504
+ #: defaults.php:350
4505
  msgid ""
4506
  "Theme created these tables in the database %LineBreak% Theme: %Theme->Name% "
4507
  "%LineBreak% Tables: %TableNames%"
4508
  msgstr ""
4509
 
4510
+ #: defaults.php:351
4511
  msgid "Theme modified tables structure"
4512
  msgstr ""
4513
 
4514
+ #: defaults.php:351
4515
  msgid ""
4516
  "Theme modified the structure of these database tables %LineBreak% Theme: "
4517
  "%Theme->Name% %LineBreak% Tables: %TableNames%"
4518
  msgstr ""
4519
 
4520
+ #: defaults.php:352
4521
  msgid "Theme deleted tables"
4522
  msgstr ""
4523
 
4524
+ #: defaults.php:352
4525
  msgid ""
4526
  "Theme deleted these tables from the database %LineBreak% Theme: %Theme->Name"
4527
  "% %LineBreak% Tables: %TableNames%"
4528
  msgstr ""
4529
 
4530
+ #: defaults.php:353
4531
  msgid "User updated a theme"
4532
  msgstr ""
4533
 
4534
+ #: defaults.php:353
4535
  msgid ""
4536
  "Name: %Theme->Name% %LineBreak% Install location: %Theme-"
4537
  ">get_template_directory%"
4538
  msgstr ""
4539
 
4540
+ #: defaults.php:354
4541
  msgid "User changed a file using the theme editor"
4542
  msgstr ""
4543
 
4544
+ #: defaults.php:354
4545
  msgid "Modified a file with the theme editor %LineBreak% File: %Theme%/%File%"
4546
  msgstr ""
4547
 
4548
+ #: defaults.php:357
4549
  msgid "Themes on Multisite"
4550
  msgstr ""
4551
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
4552
  #: defaults.php:358
4553
+ msgid "Activated theme on network"
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
4554
  msgstr ""
4555
 
4556
+ #: defaults.php:358
4557
  msgid ""
4558
+ "Network activated the theme %Theme->Name% %LineBreak% Install location: "
4559
+ "%Theme->get_template_directory%"
4560
  msgstr ""
4561
 
4562
+ #: defaults.php:359
4563
+ msgid "Deactivated theme from network"
4564
  msgstr ""
4565
 
4566
+ #: defaults.php:359
4567
  msgid ""
4568
+ "Network deactivated the theme %Theme->Name% %LineBreak% Install location: "
4569
+ "%Theme->get_template_directory%"
 
 
 
 
4570
  msgstr ""
4571
 
4572
+ #: defaults.php:362
4573
+ msgid "Database Events"
 
4574
  msgstr ""
4575
 
4576
+ #: defaults.php:363
4577
+ msgid "Unknown component created tables"
4578
  msgstr ""
4579
 
4580
+ #: defaults.php:363
4581
  msgid ""
4582
+ "An unknown component created these tables in the database %LineBreak% "
4583
+ "Tables: %TableNames%"
4584
  msgstr ""
4585
 
4586
+ #: defaults.php:364
4587
+ msgid "Unknown component modified tables structure"
4588
  msgstr ""
4589
 
4590
+ #: defaults.php:364
4591
  msgid ""
4592
+ "An unknown component modified the structure of these database tables "
4593
+ "%LineBreak% Tables: %TableNames%"
4594
  msgstr ""
4595
 
4596
+ #: defaults.php:365
4597
+ msgid "Unknown component deleted tables"
4598
  msgstr ""
4599
 
4600
+ #: defaults.php:365
4601
  msgid ""
4602
+ "An unknown component deleted these tables from the database %LineBreak% "
4603
+ "Tables: %TableNames%"
4604
  msgstr ""
4605
 
4606
+ #: defaults.php:366
4607
+ msgid "WordPress created tables"
4608
  msgstr ""
4609
 
4610
+ #: defaults.php:366
4611
+ msgid ""
4612
+ "WordPress created these tables in the database %LineBreak% Tables: "
4613
+ "%TableNames%"
4614
  msgstr ""
4615
 
4616
+ #: defaults.php:367
4617
+ msgid "WordPress modified tables structure"
4618
  msgstr ""
4619
 
4620
+ #: defaults.php:367
4621
+ msgid ""
4622
+ "WordPress modified the structure of these database tables %LineBreak% "
4623
+ "Tables: %TableNames%"
4624
  msgstr ""
4625
 
4626
+ #: defaults.php:368
4627
+ msgid "WordPress deleted tables"
4628
  msgstr ""
4629
 
4630
+ #: defaults.php:368
4631
+ msgid ""
4632
+ "WordPress deleted these tables from the database %LineBreak% Tables: "
4633
+ "%TableNames%"
4634
  msgstr ""
4635
 
4636
+ #: defaults.php:372
4637
+ msgid "WordPress & System"
4638
  msgstr ""
4639
 
4640
+ #: defaults.php:374
4641
+ msgid "Unknown Error"
4642
  msgstr ""
4643
 
4644
+ #: defaults.php:374
4645
+ msgid "An unexpected error has occurred ."
4646
  msgstr ""
4647
 
4648
+ #: defaults.php:375
4649
+ msgid "PHP error"
4650
  msgstr ""
4651
 
4652
+ #: defaults.php:375 defaults.php:376 defaults.php:377 defaults.php:378
4653
+ #: defaults.php:379
4654
+ msgid "%Message%."
4655
  msgstr ""
4656
 
4657
+ #: defaults.php:376
4658
+ msgid "PHP warning"
4659
  msgstr ""
4660
 
4661
+ #: defaults.php:377
4662
+ msgid "PHP notice"
4663
  msgstr ""
4664
 
4665
+ #: defaults.php:378
4666
+ msgid "PHP exception"
4667
  msgstr ""
4668
 
4669
+ #: defaults.php:379
4670
+ msgid "PHP shutdown error"
4671
  msgstr ""
4672
 
4673
+ #: defaults.php:380
4674
+ msgid "WordPress was updated"
4675
  msgstr ""
4676
 
4677
+ #: defaults.php:380
4678
+ msgid ""
4679
+ "Updated WordPress %LineBreak% Previous version: %OldVersion% %LineBreak% New "
4680
+ "version: %NewVersion%"
4681
  msgstr ""
4682
 
4683
+ #: defaults.php:381
4684
+ msgid "Advertising Extensions"
4685
  msgstr ""
4686
 
4687
+ #: defaults.php:381
4688
+ msgid "%PromoName% %PromoMessage%"
4689
  msgstr ""
4690
 
4691
+ #: defaults.php:384
4692
+ msgid "Activity log plugin"
 
 
4693
  msgstr ""
4694
 
4695
+ #: defaults.php:385
4696
+ msgid "Events automatically pruned by system"
4697
  msgstr ""
4698
 
4699
+ #: defaults.php:385
4700
+ msgid "System automatically deleted %EventCount% event(s)"
 
 
4701
  msgstr ""
4702
 
4703
+ #: defaults.php:386
4704
+ msgid "Reset plugin's settings to default"
4705
  msgstr ""
4706
 
4707
+ #: defaults.php:386
4708
+ msgid "Reset the WP Activity Log plugin settings to default"
 
 
 
4709
  msgstr ""
4710
 
4711
+ #: defaults.php:387
4712
+ msgid "Purged the activity log"
4713
  msgstr ""
4714
 
4715
+ #: defaults.php:390
4716
+ msgid "User/Visitor Actions"
 
 
 
4717
  msgstr ""
4718
 
4719
+ #: defaults.php:391
4720
+ msgid "User requests non-existing pages (404 Error Pages)"
4721
  msgstr ""
4722
 
4723
+ #: defaults.php:391
4724
  msgid ""
4725
+ "Has requested a non existing page (404 error) %LineBreak% Number of times: "
4726
+ "%Attempts%"
 
4727
  msgstr ""
4728
 
4729
+ #: defaults.php:392
4730
+ msgid "Website Visitor User requests non-existing pages (404 Error Pages)"
4731
  msgstr ""
4732
 
4733
+ #: defaults.php:392
4734
  msgid ""
4735
+ "Website visitor has requested a non existing page (404 error) %LineBreak% "
4736
+ "Number of times: %Attempts%"
4737
  msgstr ""
4738
 
4739
+ #: defaults.php:395
4740
+ msgid "WordPress Site Settings"
4741
  msgstr ""
4742
 
4743
+ #: defaults.php:396
4744
+ msgid "Option Anyone Can Register in WordPress settings changed"
4745
  msgstr ""
4746
 
4747
+ #: defaults.php:396
4748
+ msgid "The option Anyone can register"
 
 
4749
  msgstr ""
4750
 
4751
+ #: defaults.php:397
4752
+ msgid "New User Default Role changed"
4753
  msgstr ""
4754
 
4755
+ #: defaults.php:397
4756
  msgid ""
4757
+ "Changed the new user default role %LineBreak% Previous role: %OldRole% "
4758
+ "%LineBreak% New role: %NewRole%"
4759
  msgstr ""
4760
 
4761
+ #: defaults.php:398
4762
+ msgid "WordPress Administrator Notification email changed"
4763
  msgstr ""
4764
 
4765
+ #: defaults.php:398
4766
  msgid ""
4767
+ "Changed the WordPress administrator notification email address %LineBreak% "
4768
+ "Previous address %OldEmail% %LineBreak% New address: %NewEmail%"
4769
  msgstr ""
4770
 
4771
+ #: defaults.php:399
4772
+ msgid "User changes the WordPress Permalinks"
4773
  msgstr ""
4774
 
4775
+ #: defaults.php:399
4776
  msgid ""
4777
+ "Changed the WordPress permalinks %LineBreak% Previous permalinks: %OldPattern"
4778
+ "% %LineBreak% New permalinks: %NewPattern%"
 
 
 
 
 
4779
  msgstr ""
4780
 
4781
+ #: defaults.php:400
4782
  msgid ""
4783
+ "Enabled/Disabled the option Discourage search engines from indexing this site"
 
 
 
 
 
 
4784
  msgstr ""
4785
 
4786
+ #: defaults.php:400
4787
+ msgid "Discourage search engines from indexing this site."
4788
  msgstr ""
4789
 
4790
+ #: defaults.php:401
4791
+ msgid "Enabled/Disabled comments on all the website"
4792
  msgstr ""
4793
 
4794
+ #: defaults.php:401
4795
+ msgid "Comments on the website"
4796
  msgstr ""
4797
 
4798
+ #: defaults.php:402
4799
+ msgid "Enabled/Disabled the option Comment author must fill out name and email"
 
4800
  msgstr ""
4801
 
4802
+ #: defaults.php:402
4803
+ msgid "The option Comment author must fill out name and email"
4804
  msgstr ""
4805
 
4806
+ #: defaults.php:403
4807
  msgid ""
4808
+ "Enabled/Disabled the option Users must be logged in and registered to comment"
 
 
 
 
 
 
4809
  msgstr ""
4810
 
4811
+ #: defaults.php:403
4812
+ msgid "The option Users must be logged in and registered to comment"
 
 
 
4813
  msgstr ""
4814
 
4815
+ #: defaults.php:404
4816
+ msgid "Enabled/Disabled the option to automatically close comments"
4817
  msgstr ""
4818
 
4819
+ #: defaults.php:404
4820
+ msgid "The option to Automatically close comments after %Value% days"
 
 
 
4821
  msgstr ""
4822
 
4823
+ #: defaults.php:405
4824
+ msgid "Changed the value of the option Automatically close comments"
4825
  msgstr ""
4826
 
4827
+ #: defaults.php:405
4828
  msgid ""
4829
+ "Changed the value of the option to Automatically close comments after a "
4830
+ "number of days %LineBreak% Previous value: %OldValue% %LineBreak% New value: "
4831
+ "%NewValue%"
 
 
 
 
4832
  msgstr ""
4833
 
4834
+ #: defaults.php:406
4835
+ msgid "Enabled/Disabled the option for comments to be manually approved"
 
 
 
4836
  msgstr ""
4837
 
4838
+ #: defaults.php:406
4839
+ msgid "The option for comments to be manually approved"
4840
  msgstr ""
4841
 
4842
+ #: defaults.php:407
4843
  msgid ""
4844
+ "Enabled/Disabled the option for an author to have previously approved "
4845
+ "comments for the comments to appear"
 
 
 
 
 
4846
  msgstr ""
4847
 
4848
+ #: defaults.php:407
4849
  msgid ""
4850
+ "The option for an author to have previously approved comments for the "
4851
+ "comments to appear"
4852
  msgstr ""
4853
 
4854
+ #: defaults.php:408
4855
+ msgid ""
4856
+ "Changed the number of links that a comment must have to be held in the queue"
4857
  msgstr ""
4858
 
4859
+ #: defaults.php:408
4860
  msgid ""
4861
+ "Changed the minimum number of links a comment must have to be held in the "
4862
+ "queue %LineBreak% Previous value: %OldValue% %LineBreak% New value: %NewValue"
4863
+ "%"
4864
  msgstr ""
4865
 
4866
+ #: defaults.php:409
4867
+ msgid "Modified the list of keywords for comments moderation"
4868
  msgstr ""
4869
 
4870
+ #: defaults.php:409
4871
+ msgid "Modified the list of keywords for comments medoration"
4872
  msgstr ""
4873
 
4874
+ #: defaults.php:410
4875
+ msgid "Modified the list of keywords for comments blacklisting"
 
 
4876
  msgstr ""
4877
 
4878
+ #: defaults.php:411
4879
+ msgid "Option WordPress Address (URL) in WordPress settings changed"
4880
  msgstr ""
4881
 
4882
+ #: defaults.php:411
4883
  msgid ""
4884
+ "Changed the WordPress address (URL) %LineBreak% Previous URL: %old_url% "
4885
+ "%LineBreak% New URL: %new_url%"
4886
  msgstr ""
4887
 
4888
+ #: defaults.php:412
4889
+ msgid "Option Site Address (URL) in WordPress settings changed"
4890
  msgstr ""
4891
 
4892
+ #: defaults.php:412
4893
+ msgid ""
4894
+ "Changed the site address (URL) %LineBreak% Previous URL: %old_url% %LineBreak"
4895
+ "% New URL: %new_url%"
4896
  msgstr ""
4897
 
4898
+ #: defaults.php:416
4899
+ msgid "Multisite Network Sites"
4900
  msgstr ""
4901
 
4902
+ #: defaults.php:418
4903
+ msgid "New site added on the network"
 
4904
  msgstr ""
4905
 
4906
+ #: defaults.php:418
4907
+ msgid "New site on the network: %SiteName% %LineBreak% URL: %BlogURL%"
4908
  msgstr ""
4909
 
4910
+ #: defaults.php:419
4911
+ msgid "Existing site archived"
4912
  msgstr ""
4913
 
4914
+ #: defaults.php:419
4915
+ msgid "Archived the site: %SiteName% %LineBreak% URL: %BlogURL%"
4916
  msgstr ""
4917
 
4918
+ #: defaults.php:420
4919
+ msgid "Archived site has been unarchived"
4920
  msgstr ""
4921
 
4922
+ #: defaults.php:420
4923
+ msgid "Unarchived the site: %SiteName% %LineBreak% URL: %BlogURL%"
4924
  msgstr ""
4925
 
4926
+ #: defaults.php:421
4927
+ msgid "Deactivated site has been activated"
4928
  msgstr ""
4929
 
4930
+ #: defaults.php:421
4931
+ msgid "Activated the site: %SiteName% %LineBreak% URL: %BlogURL%"
4932
  msgstr ""
4933
 
4934
+ #: defaults.php:422
4935
+ msgid "Site has been deactivated"
4936
  msgstr ""
4937
 
4938
+ #: defaults.php:422
4939
+ msgid "Deactivated the site: %SiteName% %LineBreak% URL: %BlogURL%"
 
 
 
4940
  msgstr ""
4941
 
4942
+ #: defaults.php:423
4943
+ msgid "Existing site deleted from network"
4944
  msgstr ""
4945
 
4946
+ #: defaults.php:423
4947
+ msgid "The site: %SiteName% %LineBreak% URL: %BlogURL%"
 
 
 
4948
  msgstr ""
4949
 
4950
+ #: defaults.php:429
4951
  msgid "User changed title of a SEO post"
4952
  msgstr ""
4953
 
4954
+ #: defaults.php:429
4955
  msgid ""
4956
  "Changed the Meta title of the post %PostTitle% %LineBreak% ID: %PostID% "
4957
  "%LineBreak% Type: %PostType% %LineBreak% Status: %PostStatus% %LineBreak% "
4959
  "% %EditorLinkPost%"
4960
  msgstr ""
4961
 
4962
+ #: defaults.php:430
4963
  msgid "User changed the meta description of a SEO post"
4964
  msgstr ""
4965
 
4966
+ #: defaults.php:430
4967
  msgid ""
4968
  "Changed the Meta Description of the post %PostTitle% %LineBreak% ID: %PostID"
4969
  "% %LineBreak% Type: %PostType% %LineBreak% Status: %PostStatus% %LineBreak% "
4971
  "%LineBreak% %EditorLinkPost%"
4972
  msgstr ""
4973
 
4974
+ #: defaults.php:431
4975
  msgid ""
4976
  "User changed setting to allow search engines to show post in search results "
4977
  "of a SEO post"
4978
  msgstr ""
4979
 
4980
+ #: defaults.php:431
4981
  msgid ""
4982
  "Changed the setting to allow search engines to show post in search results "
4983
  "for the post %PostTitle% %LineBreak% ID: %PostID% %LineBreak% Type: %PostType"
4985
  "%LineBreak% New setting: %NewStatus% %LineBreak% %EditorLinkPost%"
4986
  msgstr ""
4987
 
4988
+ #: defaults.php:432
4989
  msgid ""
4990
  "User Enabled/Disabled the option for search engine to follow links of a SEO "
4991
  "post"
4992
  msgstr ""
4993
 
4994
+ #: defaults.php:432
4995
  msgid ""
4996
  "The option for search engine to follow links in post %PostTitle% %LineBreak% "
4997
  "ID: %PostID% %LineBreak% Type: %PostType% %LineBreak% Status: %PostStatus% "
4998
  "%LineBreak% %EditorLinkPost%"
4999
  msgstr ""
5000
 
5001
+ #: defaults.php:433
5002
  msgid "User set the meta robots advanced setting of a SEO post"
5003
  msgstr ""
5004
 
5005
+ #: defaults.php:433
5006
  msgid ""
5007
  "Changed the Meta Robots Advanced setting for the post %PostTitle% %LineBreak"
5008
  "% ID: %PostID% %LineBreak% Type: %PostType% %LineBreak% Status: %PostStatus% "
5010
  "% %LineBreak% %EditorLinkPost%"
5011
  msgstr ""
5012
 
5013
+ #: defaults.php:434
5014
  msgid "User changed the canonical URL of a SEO post"
5015
  msgstr ""
5016
 
5017
+ #: defaults.php:434
5018
  msgid ""
5019
  "Changed the Canonical URL of the post %PostTitle% %LineBreak% ID: %PostID% "
5020
  "%LineBreak% Type: %PostType% %LineBreak% Status: %PostStatus% %LineBreak% "
5022
  "%LineBreak% %EditorLinkPost%"
5023
  msgstr ""
5024
 
5025
+ #: defaults.php:435
5026
  msgid "User changed the focus keyword of a SEO post"
5027
  msgstr ""
5028
 
5029
+ #: defaults.php:435
5030
  msgid ""
5031
  "Changed the focus keyword for the post %PostTitle% %LineBreak% ID: %PostID% "
5032
  "%LineBreak% Type: %PostType% %LineBreak% Status: %PostStatus% %LineBreak% "
5034
  "%LineBreak% %EditorLinkPost%"
5035
  msgstr ""
5036
 
5037
+ #: defaults.php:436
5038
  msgid "User Enabled/Disabled the option Cornerston Content of a SEO post"
5039
  msgstr ""
5040
 
5041
+ #: defaults.php:436
5042
  msgid ""
5043
  "The option Cornerstone Content in the post %PostTitle% %LineBreak% ID: "
5044
  "%PostID% %LineBreak% Type: %PostType% %LineBreak% Status: %PostStatus% "
5045
  "%LineBreak% %EditorLinkPost%"
5046
  msgstr ""
5047
 
5048
+ #: defaults.php:439
5049
  msgid "Website Changes"
5050
  msgstr ""
5051
 
5052
+ #: defaults.php:440
5053
  msgid "User changed the Title Separator setting"
5054
  msgstr ""
5055
 
5056
+ #: defaults.php:440
5057
  msgid ""
5058
  "Changed the default title separator %LineBreak% Previous separator: %old% "
5059
  "%LineBreak% New separator: %new%"
5060
  msgstr ""
5061
 
5062
+ #: defaults.php:441
5063
  msgid "User changed the Homepage Title setting"
5064
  msgstr ""
5065
 
5066
+ #: defaults.php:441
5067
  msgid ""
5068
  "Changed the homepage Meta title %LineBreak% Previous title: %old% %LineBreak"
5069
  "% New title: %new%"
5070
  msgstr ""
5071
 
5072
+ #: defaults.php:442
5073
  msgid "User changed the Homepage Meta description setting"
5074
  msgstr ""
5075
 
5076
+ #: defaults.php:442
5077
  msgid ""
5078
  "Changed the homepage Meta description %LineBreak% Previous description: %old"
5079
  "% %LineBreak% New description: %new%"
5080
  msgstr ""
5081
 
5082
+ #: defaults.php:443
5083
  msgid "User changed the Company or Person setting"
5084
  msgstr ""
5085
 
5086
+ #: defaults.php:443
5087
  msgid ""
5088
  "Changed the Company or Person setting %LineBreak% Previous setting: %old% "
5089
  "%LineBreak% New setting: %new%"
5090
  msgstr ""
5091
 
5092
+ #: defaults.php:446
5093
  msgid "Plugin Settings Changes"
5094
  msgstr ""
5095
 
5096
+ #: defaults.php:447
5097
  msgid ""
5098
  "User Enabled/Disabled the option Show Posts/Pages in Search Results in the "
5099
  "Yoast SEO plugin settings"
5100
  msgstr ""
5101
 
5102
+ #: defaults.php:447
5103
  msgid "The option to show %SEOPostType% in search results"
5104
  msgstr ""
5105
 
5106
+ #: defaults.php:448
5107
  msgid ""
5108
  "User changed the Posts/Pages title template in the Yoast SEO plugin settings"
5109
  msgstr ""
5110
 
5111
+ #: defaults.php:448
5112
  msgid ""
5113
  "Changed the %SEOPostType% Meta (SEO) title template %LineBreak% Previous "
5114
  "template: %old% %LineBreak% New template: %new%"
5115
  msgstr ""
5116
 
5117
+ #: defaults.php:449
5118
  msgid "User Enabled/Disabled SEO analysis in the Yoast SEO plugin settings"
5119
  msgstr ""
5120
 
5121
+ #: defaults.php:449
5122
  msgid "The SEO Analysis feature"
5123
  msgstr ""
5124
 
5125
+ #: defaults.php:450
5126
  msgid ""
5127
  "User Enabled/Disabled readability analysis in the Yoast SEO plugin settings"
5128
  msgstr ""
5129
 
5130
+ #: defaults.php:450
5131
  msgid "The Readability Analysis feature"
5132
  msgstr ""
5133
 
5134
+ #: defaults.php:451
5135
  msgid ""
5136
  "User Enabled/Disabled cornerstone content in the Yoast SEO plugin settings"
5137
  msgstr ""
5138
 
5139
+ #: defaults.php:451
5140
  msgid "The Cornerstone content feature"
5141
  msgstr ""
5142
 
5143
+ #: defaults.php:452
5144
  msgid ""
5145
  "User Enabled/Disabled the text link counter in the Yoast SEO plugin settings"
5146
  msgstr ""
5147
 
5148
+ #: defaults.php:452
5149
  msgid "The Text link counter feature"
5150
  msgstr ""
5151
 
5152
+ #: defaults.php:453
5153
  msgid "User Enabled/Disabled XML sitemaps in the Yoast SEO plugin settings"
5154
  msgstr ""
5155
 
5156
+ #: defaults.php:453
5157
  msgid "The XML sitemap feature"
5158
  msgstr ""
5159
 
5160
+ #: defaults.php:454
5161
  msgid "User Enabled/Disabled ryte integration in the Yoast SEO plugin settings"
5162
  msgstr ""
5163
 
5164
+ #: defaults.php:454
5165
  msgid "The Ryte integration feature"
5166
  msgstr ""
5167
 
5168
+ #: defaults.php:455
5169
  msgid ""
5170
  "User Enabled/Disabled the admin bar menu in the Yoast SEO plugin settings"
5171
  msgstr ""
5172
 
5173
+ #: defaults.php:455
5174
  msgid "The Admin bar menu feature"
5175
  msgstr ""
5176
 
5177
+ #: defaults.php:456
5178
  msgid ""
5179
  "User changed the Posts/Pages meta description template in the Yoast SEO "
5180
  "plugin settings"
5181
  msgstr ""
5182
 
5183
+ #: defaults.php:456
5184
  msgid ""
5185
  "Changed the %SEOPostType% Meta description template %LineBreak% Previous "
5186
  "template: %old% New template: %new%"
5187
  msgstr ""
5188
 
5189
+ #: defaults.php:457
5190
  msgid ""
5191
  "User set the option Date in Snippet Preview for Posts/Pages in the Yoast SEO "
5192
  "plugin settings"
5193
  msgstr ""
5194
 
5195
+ #: defaults.php:457
5196
  msgid "The option Date in Snippet Preview for %SEOPostType%"
5197
  msgstr ""
5198
 
5199
+ #: defaults.php:458
5200
  msgid ""
5201
  "User set the option Yoast SEO Meta Box for Posts/Pages in the Yoast SEO "
5202
  "plugin settings"
5203
  msgstr ""
5204
 
5205
+ #: defaults.php:458
5206
  msgid "The option Yoast SEO Meta Box for %SEOPostType%"
5207
  msgstr ""
5208
 
5209
+ #: defaults.php:459
5210
  msgid ""
5211
  "User Enabled/Disabled the advanced settings for authors in the Yoast SEO "
5212
  "plugin settings"
5213
  msgstr ""
5214
 
5215
+ #: defaults.php:459
5216
  msgid "The Security: no advanced settings for authors feature"
5217
  msgstr ""
5218
 
5219
+ #: defaults.php:470
5220
  msgid "Dummy"
5221
  msgstr ""
5222
 
5223
+ #. translators: Username
5224
+ #: wp-security-audit-log.php:899 wp-security-audit-log.php:926
5225
  #, php-format
5226
  msgid "Hey %1$s"
5227
  msgstr ""
5228
 
5229
+ #: wp-security-audit-log.php:900
5230
  msgid ""
5231
  "Never miss an important update! Opt-in to our security and feature updates "
5232
  "notifications, and non-sensitive diagnostic tracking with freemius.com."
5233
  msgstr ""
5234
 
5235
+ #: wp-security-audit-log.php:901 wp-security-audit-log.php:929
5236
  msgid "Note: "
5237
  msgstr ""
5238
 
5239
+ #: wp-security-audit-log.php:902 wp-security-audit-log.php:930
5240
+ msgid "NO ACTIVITY LOG ACTIVITY & DATA IS SENT BACK TO OUR SERVERS."
5241
  msgstr ""
5242
 
5243
+ #. translators: 1: Plugin name. 2: Freemius link.
5244
+ #: wp-security-audit-log.php:928
5245
  #, php-format
5246
  msgid ""
5247
  "Please help us improve %2$s! If you opt-in, some non-sensitive data about "
5249
  "use. If you skip this, that's okay! %2$s will still work just fine."
5250
  msgstr ""
5251
 
5252
+ #. translators: Plugin name
5253
+ #: wp-security-audit-log.php:950
5254
  #, php-format
5255
  msgid ""
5256
  "Get a free 7-day trial of the premium edition of %s. No credit card "
5258
  msgstr ""
5259
 
5260
  #. Plugin Name of the plugin/theme
5261
+ #: wp-security-audit-log.php:951
5262
  msgid "WP Activity Log"
5263
  msgstr ""
5264
 
5265
+ #: wp-security-audit-log.php:955
5266
  msgid "Start free trial"
5267
  msgstr ""
5268
 
5269
+ #: wp-security-audit-log.php:1023
5270
  #, php-format
5271
  msgid ""
5272
+ "You need to activate the licence key to use WP Activity Log Premium. %2$s"
 
5273
  msgstr ""
5274
 
5275
+ #: wp-security-audit-log.php:1024
5276
  msgid "Activate the licence key now"
5277
  msgstr ""
5278
 
5279
+ #: wp-security-audit-log.php:1041
5280
  #, php-format
5281
  msgid ""
5282
  "The license is limited to %s sub-sites. You need to upgrade your license to "
5283
  "cover all the sub-sites on this network."
5284
  msgstr ""
5285
 
5286
+ #: wp-security-audit-log.php:1151
5287
  msgid ""
5288
  "Error: You do not have sufficient permissions to disable this custom field."
5289
  msgstr ""
5290
 
5291
+ #: wp-security-audit-log.php:1184
5292
  #, php-format
5293
  msgid ""
5294
  "Custom Field %1$s is no longer being monitored.<br />Enable the monitoring "
5295
  "of this custom field again from the"
5296
  msgstr ""
5297
 
5298
+ #: wp-security-audit-log.php:1184
5299
  msgid "Excluded Objects"
5300
  msgstr ""
5301
 
5302
+ #: wp-security-audit-log.php:1184
5303
  msgid " tab in the plugin settings"
5304
  msgstr ""
5305
 
5306
+ #: wp-security-audit-log.php:1196
5307
  msgid "Error: You do not have sufficient permissions to disable this alert."
5308
  msgstr ""
5309
 
5310
+ #: wp-security-audit-log.php:1220
5311
  #, php-format
5312
  msgid "Alert %1$s is no longer being monitored.<br /> %2$s"
5313
  msgstr ""
5314
 
5315
+ #: wp-security-audit-log.php:1220
5316
  msgid ""
5317
  "You can enable this alert again from the Enable/Disable Alerts node in the "
5318
  "plugin menu."
5319
  msgstr ""
5320
 
5321
+ #: wp-security-audit-log.php:1317
5322
  #, php-format
5323
  msgid ""
5324
  "You are using a version of PHP that is older than %s, which is no longer "
5325
  "supported."
5326
  msgstr ""
5327
 
5328
+ #: wp-security-audit-log.php:1319
5329
  msgid ""
5330
  "Contact us on <a href=\"mailto:plugins@wpwhitesecurity.com"
5331
  "\">plugins@wpwhitesecurity.com</a> to help you switch the version of PHP you "
5332
  "are using."
5333
  msgstr ""
5334
 
5335
+ #: wp-security-audit-log.php:1321
5336
  msgid ""
5337
  "The WP Activity Log plugin is a multisite network tool, so it has to be "
5338
  "activated at network level."
5339
  msgstr ""
5340
 
5341
+ #: wp-security-audit-log.php:1323
5342
  msgid "Redirect me to the network dashboard"
5343
  msgstr ""
5344
 
5345
+ #: wp-security-audit-log.php:1328
5346
  #, php-format
5347
  msgid "Please install the %s plugin on the MainWP dashboard."
5348
  msgstr ""
5349
 
5350
+ #: wp-security-audit-log.php:1328
5351
  msgid "Activity Log for MainWP"
5352
  msgstr ""
5353
 
5354
+ #: wp-security-audit-log.php:1330
5355
  #, php-format
5356
  msgid ""
5357
  "The WP Activity Log should be installed on the child sites only. Refer to "
5358
  "the %s for more information."
5359
  msgstr ""
5360
 
5361
+ #: wp-security-audit-log.php:1330
5362
  msgid "getting started guide"
5363
  msgstr ""
5364
 
5365
+ #: wp-security-audit-log.php:1427
5366
  msgid ""
5367
  "This plugin uses 3 tables in the WordPress database to store the activity "
5368
  "log and settings. It seems that these tables were not created."
5369
  msgstr ""
5370
 
5371
+ #: wp-security-audit-log.php:1429
5372
  msgid ""
5373
  "This could happen because the database user does not have the right "
5374
  "privileges to create the tables in the database. We recommend you to update "
5375
  "the privileges and try enabling the plugin again."
5376
  msgstr ""
5377
 
5378
+ #: wp-security-audit-log.php:1431
5379
  #, php-format
5380
  msgid ""
5381
  "If after doing so you still have issues, please send us an email on %s for "
5382
  "assistance."
5383
  msgstr ""
5384
 
5385
+ #: wp-security-audit-log.php:1431
5386
  msgid "support@wpsecurityauditlog.com"
5387
  msgstr ""
5388
 
5389
+ #: wp-security-audit-log.php:2248
5390
  msgid ""
5391
  "For security and auditing purposes, a record of all of your logged-in "
5392
  "actions and changes within the WordPress dashboard will be recorded in an "
5393
+ "activity log with the <a href=\"https://wpactivitylog.com/\" target=\"_blank"
5394
  "\">WP Activity Log plugin</a>. The audit log also includes the IP address "
5395
  "where you accessed this site from."
5396
  msgstr ""
5397
 
5398
+ #: wp-security-audit-log.php:2267
5399
  msgid "Every 6 hours"
5400
  msgstr ""
5401
 
5402
+ #: wp-security-audit-log.php:2271
5403
  msgid "Every 45 minutes"
5404
  msgstr ""
5405
 
5406
+ #: wp-security-audit-log.php:2275
5407
  msgid "Every 30 minutes"
5408
  msgstr ""
5409
 
5410
+ #: wp-security-audit-log.php:2279
5411
  msgid "Every 15 minutes"
5412
  msgstr ""
5413
 
5414
+ #: wp-security-audit-log.php:2283
5415
  msgid "Every 10 minutes"
5416
  msgstr ""
5417
 
5418
+ #: wp-security-audit-log.php:2287
5419
  msgid "Every 1 minute"
5420
  msgstr ""
5421
 
5422
+ #. translators: 1. Deprecated method name 2. Version since deprecated
5423
+ #: wp-security-audit-log.php:2301
5424
  #, php-format
5425
  msgid "Method %1$s is deprecated since version %2$s!"
5426
  msgstr ""
5435
  "of everything happening on your WordPress including WordPress users "
5436
  "activity. Similar to Windows Event Log and Linux Syslog, WP Activity Log "
5437
  "generates a security alert for everything that happens on your WordPress "
5438
+ "blogs and websites. Use the Activity log viewer included in the plugin to "
5439
+ "see all the security alerts."
5440
  msgstr ""
5441
 
5442
  #. Author of the plugin/theme
readme.txt CHANGED
@@ -1,222 +1,274 @@
1
- === WP Activity Log (formerly WP Security Audit Log) ===
2
- Contributors: WPWhiteSecurity, robert681
3
- Plugin URI: https://wpactivitylog.com
4
- License: GPLv3
5
- License URI: https://www.gnu.org/licenses/gpl.html
6
- Tags: activity log, wordpress activity logs, security audit log, audit log, user tracking, security event log, audit trail, wordpress security monitor, wordpress admin, wordpress admin monitoring, user activity, admin, multisite, SMS alerts, wordpress monitoring, email notification, wordpress email alerts, tracking, user tracking, user activity report, wordpress audit trail
7
- Requires at least: 3.6
8
- Tested up to: 5.4.1
9
- Stable tag: 4.1.2
10
- Requires PHP: 5.5
11
-
12
- The #1 user-rated activity log plugin. Keep a comprehensive log of the changes that happen on your site with this easy to use plugin.
13
-
14
- == Description ==
15
-
16
- <strong>THE MOST COMPREHENSIVE & EASY TO USE WORDPRESS ACTIVITY LOG PLUGIN</strong><br />
17
-
18
- Keep an [activity log](https://wpactivitylog.com/wordpress-activity-log/?utm_source=wordpress.org&utm_medium=referral&utm_campaign=WSAL&utm_content=plugin+repos+description) of everything that happens on your WordPress sites and multisite networks with the WP Activity Log plugin to:
19
-
20
- * Ensure user productivity
21
- * Improve user accountability
22
- * Ease troubleshooting
23
- * Know exactly what all your users are doing
24
- * Better manage & organize your WordPress site & users
25
- * Easily spot suspicious behavior before there are security problems.
26
-
27
- [WP Activity Log](https://wpactivitylog.com/?utm_source=wordpress.org&utm_medium=referral&utm_campaign=WSAL&utm_content=plugin+repos+description) is the most comprehensive real time user activity and monitoring log plugin. It helps thousands of WordPress administrators and security professionals keep an eye on what is happening on their websites. It is also the most highly rated WordPress activity log plugin and have been featured on popular sites such as GoDaddy, Kinsta and WPBeginner.
28
-
29
- [youtube https://www.youtube.com/watch?v=1nopATCS-CQ]
30
-
31
- > <strong>Note</strong>: The WordPress activity log is FREE. Features such as reports, email notifications, SMS alerts, search and many others are available in the <Strong>[Premium Edition](https://wpactivitylog.com/features/?utm_source=wordpress.org&utm_medium=referral&utm_campaign=WSAL&utm_content=plugin+repos+description)</strong>.
32
- >
33
-
34
- #### Maintained & Supported by WP White Security
35
-
36
- WP White Security builds high-quality niche WordPress security & management plugins such as [Password Policy Manager for WordPress](https://www.wpwhitesecurity.com/wordpress-plugins/password-policy-manager-wordpress/?utm_source=wordpress.org&utm_medium=referral&utm_campaign=PPMWP&utm_content=plugin+repos+description), a plugin with which you can ensure all your users use strong passwords.
37
-
38
- Browse our list of [WordPress plugins](https://www.wpwhitesecurity.com/wordpress-plugins/?utm_source=wordpress.org&utm_medium=referral&utm_campaign=all+plugins&utm_content=plugin+repos+description) that can help you better manage and improve the security of your WordPress websites and users.
39
-
40
- ### WordPress Changes & Details the Plugin Keeps a Log Of
41
- As a comprehensive & complete WordPress activity log solution WP Activity Log does not just tell you that a post, a user profile, or an object was updated. It tells you exactly what was changed within the post, the user profile, or the object.
42
-
43
- Below is a summary of the changes that the plugin can keep a record of:
44
-
45
- * **Post, Page and Custom Post Type changes** such as status, [content changes](https://wpactivitylog.com/support/kb/how-keep-record-of-content-changes/?utm_source=wordpress.org&utm_medium=referral&utm_campaign=WSAL&utm_content=plugin+repos+description), title, URL, custom field & other metadata changes
46
-
47
- * **Tags and Categories changes** such as creating, modifying or deleting them, and adding or removing them from posts
48
-
49
- * **Widgets and Menus changes** such as creating, modifying or deleting them
50
-
51
- * **User changes** such as user created or registered, deleted or added to a site on multisite network
52
-
53
- * **User profile changes** such as password, email, display name and role changes
54
-
55
- * **User activity** such as login, logout, failed logins and terminating other sessions
56
-
57
- * **WordPress core and settings changes** such as installed updates, permalinks, default role, URL and other site-wide changes
58
-
59
- * **WordPress multisite network changes** such as adding, deleting or archiving sites, adding or removing users from sites etc ([activity logs for multisite networks](https://wpactivitylog.com/support/kb/activity-log-multisite-network-features/?utm_source=wordpress.org&utm_medium=referral&utm_campaign=WSAL&utm_content=plugin+repos+description)).
60
-
61
- * **Plugins and Themes changes** such as installing, activating, deactivating, uninstalling and updating them
62
-
63
- * **WordPress database changes** such as when a plugin adds or removes a table
64
-
65
- * Changes on **WooCommerce Stores & Products**, **Yoast SEO**, **Advanced Custom Fields (ACF)**, **MainWP** and other popular WordPress plugins.
66
-
67
- * **[WordPress site file changes](https://wpactivitylog.com/support/kb/wordpress-files-changes-warning-activity-logs/?utm_source=wordpress.org&utm_medium=referral&utm_campaign=WSAL&utm_content=plugin+repos+description)** such as new files are added, or existing ones are modified or deleted.
68
-
69
- For every event that the plugin keeps a log of it also reports the:
70
-
71
- * Date & time (and milliseconds) of when it happened,
72
- * User & role of the user who did the change,
73
- * Source IP address from where the change happened.
74
-
75
- Refer to [WordPress activity log event IDs](https://wpactivitylog.com/support/kb/list-wordpress-activity-log-event-ids/?utm_source=wordpress.org&utm_medium=referral&utm_campaign=WSAL&utm_content=plugin+repos+description) for a complete list of all the changes WP Activity Log can keep a record of.
76
-
77
- ### Extend the Functionality of WP Activity Log
78
- <strong>[Upgrade to WP Activity Log Premium](https://wpactivitylog.com/pricing/?utm_source=wordpress.org&utm_medium=referral&utm_campaign=WSAL&utm_content=plugin+repos+description)</strong> to:
79
-
80
- * See who is logged,
81
- * See what everyone is doing in real time,
82
- * Log off any user with just a click,
83
- * Generate HTML and CSV reports,
84
- * Export the activity log in CSV (ideal for integrations),
85
- * Get notified via email of important changes,
86
- * Get instant SMS message notifications of critical site changes,
87
- * Search the activity log using text-based searches,
88
- * Use built-in filters to fine tune the searches,
89
- * Store activity log in an external database to improve security,
90
- * Mirror the WordPress activity logs to Slack, Papertrail, Syslog and other central log management and collaboration solutions,
91
- * Configure archiving and mirroring of logs.
92
-
93
- Refer to the [features page](https://wpactivitylog.com/features/?utm_source=wordpress.org&utm_medium=referral&utm_campaign=WSAL&utm_content=plugin+repos+description) for more detailed information on the plugin's features.
94
-
95
- ### Free and Premium Support
96
-
97
- Support for WP Activity Log is free on the WordPress support forums.
98
-
99
- Premium world-class support is available via email to all [WP Activity Log Premium](https://wpactivitylog.com/features/?utm_source=wordpress.org&utm_medium=referral&utm_campaign=WSAL&utm_content=plugin+repos+description) customers.
100
-
101
- > <strong>Note</strong>: paid customers support is given priority and is provided via one-to-one email and over the phone. [Upgrade to Premium](https://wpactivitylog.com/pricing/?utm_source=wordpress.org&utm_medium=referral&utm_campaign=WSAL&utm_content=plugin+repos+description) to benefit from priority support.
102
- >
103
-
104
- #### Other Noteworthy Features
105
- Apart from the activity logs and the already mentioned features, WP Activity Log has a number of non-logging specific features that make it a complete WordPress logging solution, such as:
106
-
107
- * Built-in [support for reverse proxies and web application firewalls](https://wpactivitylog.com/support/kb/support-reverse-proxies-web-application-firewalls/?utm_source=wordpress.org&utm_medium=referral&utm_campaign=WSAL&utm_content=plugin+repos+description)
108
- * Full [WordPress multisite support](https://www.wpsecurityauditlog.com/documentation/wordpress-multisite-plugin-features-support/?utm_source=wordpress.org&utm_medium=referral&utm_campaign=WSAL&utm_content=plugin+repos+description)
109
- * Easily [create your custom alerts](https://wpactivitylog.com/support/kb/activity-log-multisite-network-features/?utm_source=wordpress.org&utm_medium=referral&utm_campaign=WSAL&utm_content=plugin+repos+description) to monitor additional functionality
110
- * Developer tools including the logging of all HTTP GET and POST requests
111
- * Integration with WhatIsMyIpAddress.com so you can get all information about an IP address with just a mouse click
112
- * Limit who can view the WordPress activity log by either users or roles
113
- * Limit who can manage the plugin
114
- * Settings to enable or [disable individual event IDs from the activity log](https://wpactivitylog.com/support/kb/exclude-logging-specific-change-activity-log/?utm_source=wordpress.org&utm_medium=referral&utm_campaign=WSAL&utm_content=plugin+repos+description)
115
- * Configurable dashboard widget highlighting the most recent critical activity
116
- * Configurable [WordPress activity log retention policies](https://wpactivitylog.com/support/kb/activity-log-retention-policies/?utm_source=wordpress.org&utm_medium=referral&utm_campaign=WSAL&utm_content=plugin+repos+description)
117
- * User avatar is shown in the events for better recognizability
118
- * and much more...
119
-
120
- Refer to the <strong>[WordPress activity log plugin datasheet](https://wpactivitylog.com/activity-log-plugin-datasheet/?utm_source=wordpress.org&utm_medium=referral&utm_campaign=WSAL&utm_content=plugin+repos+description)</strong> for a complete list of features.
121
-
122
- ### As Featured On:
123
-
124
- * [GoDaddy](https://www.godaddy.com/garage/decode-security-logs-wordpress/)
125
- * [Kinsta](https://kinsta.com/blog/wordpress-activity-log/)
126
- * [Pagely](https://pagely.com/blog/2015/01/log-wordpress-dashboard-activity-improved-security-auditing/)
127
- * [Shout Me Loud](https://www.shoutmeloud.com/wordpress-security-audit-log.html)
128
- * [The Dev Couple](https://thedevcouple.com/wp-security-audit-log-review/)
129
- * [WPKube](http://www.wpkube.com/improve-wordpress-security-wp-security-audit-log/)
130
- * [WPLift](http://wplift.com/audit-wordpress-security-logs)
131
- * [WP SmackDown](https://wpsmackdown.com/wp-plugins/wp-security-audit-log/)
132
- * [SourceWP](https://www.sourcewp.com/wp-security-audit-log-plugin-review/)
133
- * [Techwibe](https://www.techwibe.com/wp-security-audit-log-wordpress-plugin/)
134
- * [KevinMuldoon.com](https://www.kevinmuldoon.com/wp-security-audit-log-review/)
135
- * [Cloudways](https://www.cloudways.com/blog/monitor-wordpress-with-wp-security-audit-log-plugin/)
136
- * [Collective Ray](https://www.collectiveray.com/wp/plugins/wordpress-security-audit-log)
137
- * [BlogVault](https://blogvault.net/wp-security-audit-log-plugin-review/)
138
- * [Firewall.cx](http://www.firewall.cx/general-topics-reviews/security-articles/1146-wordpress-audit-monitor-log-site-security-alerts.html)
139
- * [Design Wall](http://www.designwall.com/blog/10-wordpress-multisite-plugins-you-shouldnt-live-without/)
140
- * [Tidy Repo](https://tidyrepo.com/wp-security-audit-log-wordpress-activity-log/)
141
- * [Monster Post](http://blog.templatemonster.com/2015/12/15/wp-security-audit-log-plugin-review/)
142
- * [The Darknet](http://www.darknet.org.uk/2015/10/wp-security-audit-log-a-complete-audit-log-plugin-for-wordpress/)
143
- * [WebEmpresa](https://www.webempresa.com/blog/auditando-cambios-en-wordpress.html)
144
- * [KitPloit](http://www.kitploit.com/2016/10/wp-security-audit-log-ultimate.html)
145
- * [EHacking](https://www.ehacking.net/2018/10/how-activity-log-wordpress-plugin.html)
146
-
147
- #### WP Activity Log in your language!
148
- We need help translating the plugin and the activity log events. Please visit the [WordPress Translate Project](https://translate.wordpress.org/projects/wp-plugins/wp-security-audit-log/) to translate the plugin. Drop us an email on support@wpwhitesecurity.com to get mentioned in the list of translators below.
149
-
150
- * Italian translation by [Leonardo Musumeci](http://leonardomusumeci.net/)
151
- * German translation by [Mourad Louha](http://excel-translator.de)
152
- * Brazilian Portuguese translation by [Hudson Santos](https://www.smallbee.com.br/)
153
- * Spanish translation by the [WP Body team](https://wpbody.com/)
154
- * French translations by Denis Moscato
155
-
156
- #### WP Activity Log extensions for third party plugins
157
-
158
- * <strong>[Activity Log for MainWP](https://wpactivitylog.com/extensions/mainwp-activity-log/?utm_source=wordpress.org&utm_medium=referral&utm_campaign=WSAL&utm_content=plugin+repos+description)</strong>: With this MainWP extension you keep a log of the MainWP network changes and can see the activity logs of all child sites from one central location - the MainWP dashboard.
159
- * <strong>[WP Activity Log for WPForms](https://wpactivitylog.com/extensions/wpforms-activity-log/?utm_source=wordpress.org&utm_medium=referral&utm_campaign=WSAL&utm_content=plugin+repos+description)</strong>: When you install this extension you keep a log of changes your team does in the WPForms plugin, forms, form files, entries (leads) and more.
160
- * <strong>[WP Activity Log for bbPress](https://wordpress.org/plugins/wp-security-audit-log-add-on-for-bbpress/)</strong>: With this extension you can keep a log of changes in bbPress forums, topics, bbPress settings and more.
161
-
162
- #### Related Links and Documentation
163
-
164
- * [What is the WordPress activity log?](https://wpactivitylog.com/wordpress-activity-log/?utm_source=wordpress.org&utm_medium=referral&utm_campaign=WSAL&utm_content=plugin+repos+description)
165
- * [List of WordPress activity log event IDs](https://wpactivitylog.com/support/kb/list-wordpress-activity-log-event-ids/?utm_source=wordpress.org&utm_medium=referral&utm_campaign=WSAL&utm_content=plugin+repos+description)
166
- * [WordPress Multisite Features](https://wpactivitylog.com/support/kb/activity-log-multisite-network-features/?utm_source=wordpress.org&utm_medium=referral&utm_campaign=WSAL&utm_content=plugin+repos+description)
167
- * [WP Activity Log support for reverse proxies & WAFs](https://wpactivitylog.com/support/kb/support-reverse-proxies-web-application-firewalls/?utm_source=wordpress.org&utm_medium=referral&utm_campaign=WSAL&utm_content=plugin+repos+description)
168
- * [WP Activity Log database documentation](https://wpactivitylog.com/support/kb/plugin-database-documentation/?utm_source=wordpress.org&utm_medium=referral&utm_campaign=WSAL&utm_content=plugin+repos+description)
169
- * [The WP Activity Log plugin website](https://wpactivitylog.com/?utm_source=wordpress.org&utm_medium=referral&utm_campaign=WSAL&utm_content=plugin+repos+description)
170
- * [Activity logs for MainWP](https://wpactivitylog.com/extensions/mainwp-activity-log/?utm_source=wordpress.org&utm_medium=referral&utm_campaign=WSAL&utm_content=plugin+repos+description)
171
-
172
- == Installation ==
173
-
174
- === Install WP Activity Log from within WordPress ===
175
-
176
- 1. Visit 'Plugins > Add New'
177
- 1. Search for 'WP Activity Log'
178
- 1. Install and activate the WP Activity Log plugin
179
- 1. Allow or skip diagnostic tracking
180
-
181
- === Install WP Activity Log manually ===
182
-
183
- 1. Upload the `wp-security-audit-log` directory to the `/wp-content/plugins/` directory
184
- 1. Activate the WP Activity Log plugin from the 'Plugins' menu in WordPress
185
- 1. Allow or skip diagnostic tracking
186
-
187
- == Frequently Asked Questions ==
188
-
189
- = Support and Documentation =
190
- Please refer to our [support pages](https://wpactivitylog.com/support/?utm_source=wordpress.org&utm_medium=referral&utm_campaign=WSAL&utm_content=plugin+repos+description) for all the technical information and product documentation.
191
-
192
- == Screenshots ==
193
-
194
- 1. The WordPress activity logs from where the site administrator can see all the user and site changes.
195
- 2. See who is logged in to your WordPress and manage users sessions with [Users Sessions Management](https://www.wpsecurityauditlog.com/premium-features/wordpress-users-sessions-management-tools/?utm_source=wordpress.org&utm_medium=referral&utm_campaign=WSAL&utm_content=plugin+repos+description)
196
- 3. The plugin settings from where site administrator can configure generic plugin settings such as [reverse proxy support](https://www.wpsecurityauditlog.com/support-documentation/support-reverse-proxies-web-application-firewalls/?utm_source=wordpress.org&utm_medium=referral&utm_campaign=WSAL&utm_content=plugin+repos+description), who can manage the plugin etc.
197
- 4. The WordPress audit trail settings from where you can configure automatic pruning of alerts, which timestamp should be used, how many 404 requests should be logged and more.
198
- 5. Configuring WordPress email and SMS alerts with the [Email & SMS Notifications module](https://www.wpsecurityauditlog.com/premium-features/email-notifications-wordpress-activity-log/?utm_source=wordpress.org&utm_medium=referral&utm_campaign=WSAL&utm_content=plugin+repos+description)
199
- 6. Search in the WordPress activity log with the use filters to fine tune the search results.
200
- 7. The Enable/Disable events section from where Administrators can disable or enable activity log events.
201
- 8. The Log Viewer of a Super Admin in a WordPress multisite network installation with the Site selection drop down menu.
202
- 9. WP Activity Log is integrated with the built-in revision system of WordPress, thus allowing you to see what content changes users make on your WordPress posts, pages and custom post types. For more information read [Keep Record of All WordPress Content Changes](https://www.wpsecurityauditlog.com/support-documentation/how-keep-record-of-content-changes/?utm_source=wordpress.org&utm_medium=referral&utm_campaign=WSAL&utm_content=plugin+repos+description)
203
- 10. Mirror the WordPress activity log to an external solution such as Syslog or Papertrail to centralize logging, ensure logs are always available and cannot be tampered with in the unfortunate case of a hack attack.
204
-
205
- == Changelog ==
206
-
207
- = 4.1.2 (2020-06-24) =
208
-
209
- Release notes: [WP Activity Log fully integrated with Website File Changes Monitor](https://www.wpwhitesecurity.com/wfcm-1-6/)
210
-
211
- * **New**
212
- * Plugin now uses the [Website File Changes Monitor](https://www.wpwhitesecurity.com/wordpress-plugins/website-file-changes-monitor/) plugin for file integrity monitor scans.
213
-
214
- * **Improvements**
215
- * Event ID 6033 now reports when [file integrity monitoring](https://www.wpwhitesecurity.com/wordpress-file-integrity-scanning-site/) scans start and stop.
216
- * File changes events in the activity log link directly to the changes reported in Website File Changes Monitor.
217
- * Log files custom path setting reverts to default path if left empty.
218
-
219
- * **Bug fix**
220
- * Plugin creating the log files outside website directory if Website URL is different than WordPress URL.
221
-
222
- Refer to the [complete plugin changelog](https://wpactivitylog.com/support/kb/plugin-changelog/?utm_source=wordpress.org&utm_medium=referral&utm_campaign=WSAL&utm_content=plugin+repos+description) for more detailed information about what was new, improved and fixed in previous versions of the WP Activity Log plugin.
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ === WP Activity Log ===
2
+ Contributors: WPWhiteSecurity, robert681
3
+ Plugin URI: https://wpactivitylog.com
4
+ License: GPLv3
5
+ License URI: https://www.gnu.org/licenses/gpl.html
6
+ Tags: activity log, wordpress activity logs, security audit log, audit log, user tracking, security event log, audit trail, wordpress security monitor, wordpress admin, wordpress admin monitoring, user activity, admin, multisite, SMS alerts, wordpress monitoring, email notification, wordpress email alerts, tracking, user tracking, user activity report, wordpress audit trail
7
+ Requires at least: 3.6
8
+ Tested up to: 5.5
9
+ Stable tag: 4.1.3
10
+ Requires PHP: 5.5
11
+
12
+ The #1 user-rated activity log plugin. Keep a comprehensive log of the changes that happen on your site with this easy to use plugin.
13
+
14
+ == Description ==
15
+
16
+ <strong>THE MOST COMPREHENSIVE & EASY TO USE WORDPRESS ACTIVITY LOG PLUGIN</strong><br />
17
+
18
+ Keep an [activity log](https://wpactivitylog.com/wordpress-activity-log/?utm_source=wordpress.org&utm_medium=referral&utm_campaign=WSAL&utm_content=plugin+repos+description) of everything that happens on your WordPress sites and multisite networks with the WP Activity Log plugin to:
19
+
20
+ * Ensure user productivity
21
+ * Improve user accountability
22
+ * Ease troubleshooting
23
+ * Know exactly what all your users are doing
24
+ * Better manage & organize your WordPress site & users
25
+ * Easily spot suspicious behavior before there are security problems.
26
+
27
+ [WP Activity Log](https://wpactivitylog.com/?utm_source=wordpress.org&utm_medium=referral&utm_campaign=WSAL&utm_content=plugin+repos+description) is the most comprehensive real time user activity and monitoring log plugin. It helps thousands of WordPress administrators and security professionals keep an eye on what is happening on their websites. It is also the most highly rated WordPress activity log plugin and have been featured on popular sites such as GoDaddy, Kinsta and WPBeginner.
28
+
29
+ [youtube https://www.youtube.com/watch?v=1nopATCS-CQ]
30
+
31
+ > <strong>Note</strong>: The WordPress activity log is FREE. Features such as reports, email notifications, SMS alerts, search and many others are available in the <Strong>[Premium Edition](https://wpactivitylog.com/features/?utm_source=wordpress.org&utm_medium=referral&utm_campaign=WSAL&utm_content=plugin+repos+description)</strong>.
32
+ >
33
+
34
+ #### Maintained & Supported by WP White Security
35
+
36
+ WP White Security builds high-quality niche WordPress security & management plugins such as [Password Policy Manager for WordPress](https://www.wpwhitesecurity.com/wordpress-plugins/password-policy-manager-wordpress/?utm_source=wordpress.org&utm_medium=referral&utm_campaign=PPMWP&utm_content=plugin+repos+description), a plugin with which you can ensure all your users use strong passwords.
37
+
38
+ Browse our list of [WordPress plugins](https://www.wpwhitesecurity.com/wordpress-plugins/?utm_source=wordpress.org&utm_medium=referral&utm_campaign=all+plugins&utm_content=plugin+repos+description) that can help you better manage and improve the security of your WordPress websites and users.
39
+
40
+ ### WordPress Changes & Details the Plugin Keeps a Log Of
41
+ As a comprehensive & complete WordPress activity log solution WP Activity Log does not just tell you that a post, a user profile, or an object was updated. It tells you exactly what was changed within the post, the user profile, or the object.
42
+
43
+ Below is a summary of the changes that the plugin can keep a record of:
44
+
45
+ * **Post, Page and Custom Post Type changes** such as status, [content changes](https://wpactivitylog.com/support/kb/how-keep-record-of-content-changes/?utm_source=wordpress.org&utm_medium=referral&utm_campaign=WSAL&utm_content=plugin+repos+description), title, URL, custom field & other metadata changes
46
+
47
+ * **Tags and Categories changes** such as creating, modifying or deleting them, and adding or removing them from posts
48
+
49
+ * **Widgets and Menus changes** such as creating, modifying or deleting them
50
+
51
+ * **User changes** such as user created or registered, deleted or added to a site on multisite network
52
+
53
+ * **User profile changes** such as password, email, display name and role changes
54
+
55
+ * **User activity** such as login, logout, failed logins and terminating other sessions
56
+
57
+ * **WordPress core and settings changes** such as installed updates, permalinks, default role, URL and other site-wide changes
58
+
59
+ * **WordPress multisite network changes** such as adding, deleting or archiving sites, adding or removing users from sites etc ([activity logs for multisite networks](https://wpactivitylog.com/support/kb/activity-log-multisite-network-features/?utm_source=wordpress.org&utm_medium=referral&utm_campaign=WSAL&utm_content=plugin+repos+description)).
60
+
61
+ * **Plugins and Themes changes** such as installing, activating, deactivating, uninstalling and updating them
62
+
63
+ * **WordPress database changes** such as when a plugin adds or removes a table
64
+
65
+ * Changes on **WooCommerce Stores & Products**, **Yoast SEO**, **Advanced Custom Fields (ACF)**, **MainWP** and other popular WordPress plugins.
66
+
67
+ * **[WordPress site file changes](https://wpactivitylog.com/support/kb/wordpress-files-changes-warning-activity-logs/?utm_source=wordpress.org&utm_medium=referral&utm_campaign=WSAL&utm_content=plugin+repos+description)** such as new files are added, or existing ones are modified or deleted.
68
+
69
+ For every event that the plugin keeps a log of it also reports the:
70
+
71
+ * Date & time (and milliseconds) of when it happened,
72
+ * User & role of the user who did the change,
73
+ * Source IP address from where the change happened.
74
+
75
+ Refer to [WordPress activity log event IDs](https://wpactivitylog.com/support/kb/list-wordpress-activity-log-event-ids/?utm_source=wordpress.org&utm_medium=referral&utm_campaign=WSAL&utm_content=plugin+repos+description) for a complete list of all the changes WP Activity Log can keep a record of.
76
+
77
+ ### Extend the Functionality of WP Activity Log
78
+ <strong>[Upgrade to WP Activity Log Premium](https://wpactivitylog.com/pricing/?utm_source=wordpress.org&utm_medium=referral&utm_campaign=WSAL&utm_content=plugin+repos+description)</strong> to:
79
+
80
+ * See who is logged,
81
+ * See what everyone is doing in real time,
82
+ * Log off any user with just a click,
83
+ * Generate HTML and CSV reports,
84
+ * Export the activity log in CSV (ideal for integrations),
85
+ * Get notified via email of important changes,
86
+ * Get instant SMS message notifications of critical site changes,
87
+ * Search the activity log using text-based searches,
88
+ * Use built-in filters to fine tune the searches,
89
+ * Store activity log in an external database to improve security,
90
+ * Mirror the WordPress activity logs to Slack, Papertrail, Syslog and other central log management and collaboration solutions,
91
+ * Configure archiving and mirroring of logs.
92
+
93
+ Refer to the [features page](https://wpactivitylog.com/features/?utm_source=wordpress.org&utm_medium=referral&utm_campaign=WSAL&utm_content=plugin+repos+description) for more detailed information on the plugin's features.
94
+
95
+ ### Free and Premium Support
96
+
97
+ Support for WP Activity Log is free on the WordPress support forums.
98
+
99
+ Premium world-class support is available via email to all [WP Activity Log Premium](https://wpactivitylog.com/features/?utm_source=wordpress.org&utm_medium=referral&utm_campaign=WSAL&utm_content=plugin+repos+description) customers.
100
+
101
+ > <strong>Note</strong>: paid customers support is given priority and is provided via one-to-one email and over the phone. [Upgrade to Premium](https://wpactivitylog.com/pricing/?utm_source=wordpress.org&utm_medium=referral&utm_campaign=WSAL&utm_content=plugin+repos+description) to benefit from priority support.
102
+ >
103
+
104
+ #### Other Noteworthy Features
105
+ Apart from the activity logs and the already mentioned features, WP Activity Log has a number of non-logging specific features that make it a complete WordPress logging solution, such as:
106
+
107
+ * Built-in [support for reverse proxies and web application firewalls](https://wpactivitylog.com/support/kb/support-reverse-proxies-web-application-firewalls/?utm_source=wordpress.org&utm_medium=referral&utm_campaign=WSAL&utm_content=plugin+repos+description)
108
+ * Full [WordPress multisite support](https://www.wpsecurityauditlog.com/documentation/wordpress-multisite-plugin-features-support/?utm_source=wordpress.org&utm_medium=referral&utm_campaign=WSAL&utm_content=plugin+repos+description)
109
+ * Easily [create your custom alerts](https://wpactivitylog.com/support/kb/activity-log-multisite-network-features/?utm_source=wordpress.org&utm_medium=referral&utm_campaign=WSAL&utm_content=plugin+repos+description) to monitor additional functionality
110
+ * Developer tools including the logging of all HTTP GET and POST requests
111
+ * Integration with WhatIsMyIpAddress.com so you can get all information about an IP address with just a mouse click
112
+ * Limit who can view the WordPress activity log by either users or roles
113
+ * Limit who can manage the plugin
114
+ * Settings to enable or [disable individual event IDs from the activity log](https://wpactivitylog.com/support/kb/exclude-logging-specific-change-activity-log/?utm_source=wordpress.org&utm_medium=referral&utm_campaign=WSAL&utm_content=plugin+repos+description)
115
+ * Configurable dashboard widget highlighting the most recent critical activity
116
+ * Configurable [WordPress activity log retention policies](https://wpactivitylog.com/support/kb/activity-log-retention-policies/?utm_source=wordpress.org&utm_medium=referral&utm_campaign=WSAL&utm_content=plugin+repos+description)
117
+ * User avatar is shown in the events for better recognizability
118
+ * and much more...
119
+
120
+ Refer to the <strong>[WordPress activity log plugin datasheet](https://wpactivitylog.com/activity-log-plugin-datasheet/?utm_source=wordpress.org&utm_medium=referral&utm_campaign=WSAL&utm_content=plugin+repos+description)</strong> for a complete list of features.
121
+
122
+ ### As Featured On:
123
+
124
+ * [GoDaddy](https://www.godaddy.com/garage/decode-security-logs-wordpress/)
125
+ * [Kinsta](https://kinsta.com/blog/wordpress-activity-log/)
126
+ * [Pagely](https://pagely.com/blog/2015/01/log-wordpress-dashboard-activity-improved-security-auditing/)
127
+ * [Shout Me Loud](https://www.shoutmeloud.com/wordpress-security-audit-log.html)
128
+ * [The Dev Couple](https://thedevcouple.com/wp-security-audit-log-review/)
129
+ * [WPKube](http://www.wpkube.com/improve-wordpress-security-wp-security-audit-log/)
130
+ * [WPLift](http://wplift.com/audit-wordpress-security-logs)
131
+ * [WP SmackDown](https://wpsmackdown.com/wp-plugins/wp-security-audit-log/)
132
+ * [SourceWP](https://www.sourcewp.com/wp-security-audit-log-plugin-review/)
133
+ * [Techwibe](https://www.techwibe.com/wp-security-audit-log-wordpress-plugin/)
134
+ * [KevinMuldoon.com](https://www.kevinmuldoon.com/wp-security-audit-log-review/)
135
+ * [Cloudways](https://www.cloudways.com/blog/monitor-wordpress-with-wp-security-audit-log-plugin/)
136
+ * [Collective Ray](https://www.collectiveray.com/wp/plugins/wordpress-security-audit-log)
137
+ * [BlogVault](https://blogvault.net/wp-security-audit-log-plugin-review/)
138
+ * [Firewall.cx](http://www.firewall.cx/general-topics-reviews/security-articles/1146-wordpress-audit-monitor-log-site-security-alerts.html)
139
+ * [Design Wall](http://www.designwall.com/blog/10-wordpress-multisite-plugins-you-shouldnt-live-without/)
140
+ * [Tidy Repo](https://tidyrepo.com/wp-security-audit-log-wordpress-activity-log/)
141
+ * [Monster Post](http://blog.templatemonster.com/2015/12/15/wp-security-audit-log-plugin-review/)
142
+ * [The Darknet](http://www.darknet.org.uk/2015/10/wp-security-audit-log-a-complete-audit-log-plugin-for-wordpress/)
143
+ * [WebEmpresa](https://www.webempresa.com/blog/auditando-cambios-en-wordpress.html)
144
+ * [KitPloit](http://www.kitploit.com/2016/10/wp-security-audit-log-ultimate.html)
145
+ * [EHacking](https://www.ehacking.net/2018/10/how-activity-log-wordpress-plugin.html)
146
+
147
+ #### WP Activity Log in your language!
148
+ We need help translating the plugin and the activity log events. Please visit the [WordPress Translate Project](https://translate.wordpress.org/projects/wp-plugins/wp-security-audit-log/) to translate the plugin. Drop us an email on support@wpwhitesecurity.com to get mentioned in the list of translators below.
149
+
150
+ * Italian translation by [Leonardo Musumeci](http://leonardomusumeci.net/)
151
+ * German translation by [Mourad Louha](http://excel-translator.de)
152
+ * Brazilian Portuguese translation by [Hudson Santos](https://www.smallbee.com.br/)
153
+ * Spanish translation by the [WP Body team](https://wpbody.com/)
154
+ * French translations by Denis Moscato
155
+
156
+ #### WP Activity Log extensions for third party plugins
157
+
158
+ * <strong>[WP Activity Log for WooCommerce](https://wpactivitylog.com/extensions/woocommerce-activity-log/?utm_source=wordpress.org&utm_medium=referral&utm_campaign=WSAL&utm_content=plugin+repos+description)</strong>: When you install this extension you keep a log of changes your team does to the WooCommerce store settings, orders, products, coupons _ much more.
159
+ * <strong>[WP Activity Log for WPForms](https://wpactivitylog.com/extensions/wpforms-activity-log/?utm_source=wordpress.org&utm_medium=referral&utm_campaign=WSAL&utm_content=plugin+repos+description)</strong>: When you install this extension you keep a log of changes your team does in the WPForms plugin, forms, form files, entries (leads) and more.
160
+ * <strong>[Activity Log for MainWP](https://wpactivitylog.com/extensions/mainwp-activity-log/?utm_source=wordpress.org&utm_medium=referral&utm_campaign=WSAL&utm_content=plugin+repos+description)</strong>: With this MainWP extension you keep a log of the MainWP network changes and can see the activity logs of all child sites from one central location - the MainWP dashboard.
161
+ * <strong>[WP Activity Log for bbPress](https://wordpress.org/plugins/wp-security-audit-log-add-on-for-bbpress/)</strong>: With this extension you can keep a log of changes in bbPress forums, topics, bbPress settings and more.
162
+
163
+ #### Related Links and Documentation
164
+
165
+ * [What is the WordPress activity log?](https://wpactivitylog.com/wordpress-activity-log/?utm_source=wordpress.org&utm_medium=referral&utm_campaign=WSAL&utm_content=plugin+repos+description)
166
+ * [List of WordPress activity log event IDs](https://wpactivitylog.com/support/kb/list-wordpress-activity-log-event-ids/?utm_source=wordpress.org&utm_medium=referral&utm_campaign=WSAL&utm_content=plugin+repos+description)
167
+ * [WordPress Multisite Features](https://wpactivitylog.com/support/kb/activity-log-multisite-network-features/?utm_source=wordpress.org&utm_medium=referral&utm_campaign=WSAL&utm_content=plugin+repos+description)
168
+ * [WP Activity Log support for reverse proxies & WAFs](https://wpactivitylog.com/support/kb/support-reverse-proxies-web-application-firewalls/?utm_source=wordpress.org&utm_medium=referral&utm_campaign=WSAL&utm_content=plugin+repos+description)
169
+ * [WP Activity Log database documentation](https://wpactivitylog.com/support/kb/plugin-database-documentation/?utm_source=wordpress.org&utm_medium=referral&utm_campaign=WSAL&utm_content=plugin+repos+description)
170
+ * [The WP Activity Log plugin website](https://wpactivitylog.com/?utm_source=wordpress.org&utm_medium=referral&utm_campaign=WSAL&utm_content=plugin+repos+description)
171
+ * [Activity logs for MainWP](https://wpactivitylog.com/extensions/mainwp-activity-log/?utm_source=wordpress.org&utm_medium=referral&utm_campaign=WSAL&utm_content=plugin+repos+description)
172
+
173
+ == Installation ==
174
+
175
+ === Install WP Activity Log from within WordPress ===
176
+
177
+ 1. Visit 'Plugins > Add New'
178
+ 1. Search for 'WP Activity Log'
179
+ 1. Install and activate the WP Activity Log plugin
180
+ 1. Allow or skip diagnostic tracking
181
+
182
+ === Install WP Activity Log manually ===
183
+
184
+ 1. Upload the `wp-security-audit-log` directory to the `/wp-content/plugins/` directory
185
+ 1. Activate the WP Activity Log plugin from the 'Plugins' menu in WordPress
186
+ 1. Allow or skip diagnostic tracking
187
+
188
+ == Frequently Asked Questions ==
189
+
190
+ = Support and Documentation =
191
+ Please refer to our [support pages](https://wpactivitylog.com/support/?utm_source=wordpress.org&utm_medium=referral&utm_campaign=WSAL&utm_content=plugin+repos+description) for all the technical information and product documentation.
192
+
193
+ == Screenshots ==
194
+
195
+ 1. The WordPress activity logs from where the site administrator can see all the user and site changes.
196
+ 2. See who is logged in to your WordPress and manage users sessions with [Users Sessions Management](https://www.wpsecurityauditlog.com/premium-features/wordpress-users-sessions-management-tools/?utm_source=wordpress.org&utm_medium=referral&utm_campaign=WSAL&utm_content=plugin+repos+description)
197
+ 3. The plugin settings from where site administrator can configure generic plugin settings such as [reverse proxy support](https://www.wpsecurityauditlog.com/support-documentation/support-reverse-proxies-web-application-firewalls/?utm_source=wordpress.org&utm_medium=referral&utm_campaign=WSAL&utm_content=plugin+repos+description), who can manage the plugin etc.
198
+ 4. The WordPress audit trail settings from where you can configure automatic pruning of alerts, which timestamp should be used, how many 404 requests should be logged and more.
199
+ 5. Configuring WordPress email and SMS alerts with the [Email & SMS Notifications module](https://www.wpsecurityauditlog.com/premium-features/email-notifications-wordpress-activity-log/?utm_source=wordpress.org&utm_medium=referral&utm_campaign=WSAL&utm_content=plugin+repos+description)
200
+ 6. Search in the WordPress activity log with the use filters to fine tune the search results.
201
+ 7. The Enable/Disable events section from where Administrators can disable or enable activity log events.
202
+ 8. The Log Viewer of a Super Admin in a WordPress multisite network installation with the Site selection drop down menu.
203
+ 9. WP Activity Log is integrated with the built-in revision system of WordPress, thus allowing you to see what content changes users make on your WordPress posts, pages and custom post types. For more information read [Keep Record of All WordPress Content Changes](https://www.wpsecurityauditlog.com/support-documentation/how-keep-record-of-content-changes/?utm_source=wordpress.org&utm_medium=referral&utm_campaign=WSAL&utm_content=plugin+repos+description)
204
+ 10. Mirror the WordPress activity log to an external solution such as Syslog or Papertrail to centralize logging, ensure logs are always available and cannot be tampered with in the unfortunate case of a hack attack.
205
+
206
+ == Changelog ==
207
+
208
+ = 4.1.3 (2020-08-11) =
209
+
210
+ Release notes: [WP Activity Log 4.1.3: New extension for WooCommerce & other updates](https://wpactivitylog.com/wsal-4-1-3/)
211
+
212
+ * **IMPORTANT**
213
+ * Only update from 4.1.2 to 4.1.3. If you are using an older version, first update to 4.1.2 before updating to 4.1.3.
214
+
215
+ * **New features**
216
+ * The all new [WP Activity Log for WooCommerce](https://wordpress.org/plugins/wp-activity-log-for-woocommerce/) extension (needed to keep a log of changes on WooCommerce store, products, orders & much more).
217
+ * New [plugin and activity log privileges](https://wpactivitylog.com/support/kb/managing-wordpress-activity-log-plugin-privileges/) that allow super admins on a multisite network to restrict activity log access to site admins and other super admins.
218
+ * Coverage for changes done to relationship custom fields created with ACF.
219
+
220
+ * **New activity log events**
221
+ * ID 2131: Added relationships in a custom field.
222
+ * ID 2132: Removed relationships from a custom field.
223
+ * ID 9101: Created new product tag in WooCommerce.
224
+ * ID 9102: Deleted a product tag in WooCommerce.
225
+ * ID 9103: Renamed a product tag in WooCommerce.
226
+ * ID 9104: Changed the slug of a product tag in WooCommerce.
227
+
228
+ Refer to the [complete list of activity log event IDs](https://wpactivitylog.com/support/kb/list-wordpress-activity-log-event-ids/) for more detailed information.
229
+
230
+ * **Improvements**
231
+ * Improved the plugin's coverage of WooCommerce stores, products, orders etc by adding new events, and updating the current sensor.
232
+ * Plugin now uses the default WordPress options table to store settings (performance enhancement).
233
+ * Refactored all settings in the database so they all use yes/no values.
234
+ * Restricted the plugin's and activity log settings to the network dashboard only on a multisite network.
235
+ * Change in wp_wsal_sessions table structure: now plugin uses session ID as unique identifier in table.
236
+ * Plugin keeps the ID of the sites a user is logged in to on a multisite network.
237
+ * Removed the Import/Export plugin settings functionality (a much better utility will be designed and launched as a replacement).
238
+ * File changes detected by the Website File Changes Monitor plugin are now reported in the daily summary email.
239
+ * Log files working directory in uploads directory renamed to wp-activity-log.
240
+ * If no path is specified for the log files working directory, the default path is used.
241
+ * Improved activity log privileges - on multisite super admin can restrict site admins from seeing their own site's activity logs.
242
+ * WooCommerce front end sensor is automatically enabled if admin enables events to track purchases of non-logged in users.
243
+ * Improved the text of the third party plugins extensions notifications.
244
+ * Updated the format of event IDs 9070 and 4020 to matches the standard template.
245
+ * Coverage of WooCommerce coupon changes has been improved andplugin can now keep a log of usage restriction changes in coupons.
246
+ * IP address in list of logged in users is now linked to WhatIsMyIPAddress.com.
247
+ * Added a message for when no sessions are shown in the Logged In users section.
248
+ * Minor changes in the plugin's settings pages.
249
+ * Updated some notifications used by the third party plugins extensions.
250
+ * Third party plugins extensions are now automatically activated on multsite network when installed.
251
+ * Removed all code that was used for file scanning. Now plugin is fully integrated with Website File Changes Monitor.
252
+
253
+ * **Bug fixes**
254
+ * Extensions notifications were wrongly shown to sub sites admins on multisite.
255
+ * Event 1002 (failed user login) was wrongly reported when a user session is blocked.
256
+ * When the setting Delete data on uninstall was enabled the plugin was not deleting all the data from the database.
257
+ * Event ID 1002 (failed user login) incorrectly links to log file.
258
+ * Plugin does not send logs to [Activity Log for MainWP](https://wpactivitylog.com/extensions/mainwp-activity-log/) extension when child site uses a non-default admin URL.
259
+ * Error when loading user session tokens from usermeta table in some cases.
260
+ * Users sessions table was moved to external database when activity log is stored in an external database.
261
+ * Plugin was reporting event ID 1000 (login) when user changes own password in user profile page.
262
+ * Plugin's log files working directory was hardcoded (uploads directory).
263
+ * When super admins changed the plugin's settings on a child site, the settings were not applied globally.
264
+ * Users who are allowed to view the activity log can also see who is logged in.
265
+ * The old plugin name was shown on the daily summary email template.
266
+ * Plugin created working directory in wrong location when site address is different than WordPress address.
267
+ * Setup wizard shows all the extensions for third party plugins instead of those for the installed plugins.
268
+ * Wrong anchor text "view post in editor" used for WooCommerce products.
269
+ * Unknown object reported instead of actual Object in some of the [WPForms activity log](https://wpactivitylog.com/extensions/wpforms-activity-log/) events.
270
+ * Event ID 2080 not reported when the last item was removed from the site menu.
271
+ * Plugin logo missing from license activation screen.
272
+ * [Website File Changes Monitor](https://www.wpwhitesecurity.com/wordpress-plugins/website-file-changes-monitor/) custom posts type changes were reported (these are ignored by default).
273
+
274
+ Refer to the [complete plugin changelog](https://wpactivitylog.com/support/kb/plugin-changelog/?utm_source=wordpress.org&utm_medium=referral&utm_campaign=WSAL&utm_content=plugin+repos+description) for more detailed information about what was new, improved and fixed in previous versions of the WP Activity Log plugin.
sdk/freemius/assets/img/plugin-icon.png CHANGED
Binary file
sdk/freemius/assets/img/wp-security-audit-log.png CHANGED
Binary file
sdk/wsal-freemius.php CHANGED
@@ -21,6 +21,7 @@ if ( file_exists( dirname( __FILE__ ) . '/freemius/start.php' ) ) {
21
  * Create a helper function for easy SDK access.
22
  *
23
  * @return Freemius
 
24
  */
25
  function wsal_freemius() {
26
  global $wsal_freemius;
@@ -32,7 +33,7 @@ if ( file_exists( dirname( __FILE__ ) . '/freemius/start.php' ) ) {
32
  require_once dirname( __FILE__ ) . '/freemius/start.php';
33
 
34
  // Check anonymous mode.
35
- $freemius_state = get_site_option( 'wsal_freemius_state', 'anonymous' );
36
  $is_anonymous = ( 'anonymous' === $freemius_state || 'skipped' === $freemius_state );
37
  $is_premium = false;
38
  $is_anonymous = $is_premium ? false : $is_anonymous;
21
  * Create a helper function for easy SDK access.
22
  *
23
  * @return Freemius
24
+ * @throws Freemius_Exception
25
  */
26
  function wsal_freemius() {
27
  global $wsal_freemius;
33
  require_once dirname( __FILE__ ) . '/freemius/start.php';
34
 
35
  // Check anonymous mode.
36
+ $freemius_state = \WSAL\Helpers\Options::get_option_value_ignore_prefix( 'wsal_freemius_state', 'anonymous' );
37
  $is_anonymous = ( 'anonymous' === $freemius_state || 'skipped' === $freemius_state );
38
  $is_premium = false;
39
  $is_anonymous = $is_premium ? false : $is_anonymous;
wp-security-audit-log.php CHANGED
@@ -2,9 +2,9 @@
2
  /**
3
  * Plugin Name: WP Activity Log
4
  * Plugin URI: http://wpactivitylog.com/
5
- * Description: Identify WordPress security issues before they become a problem. Keep track of everything happening on your WordPress including WordPress users activity. Similar to Windows Event Log and Linux Syslog, WP Activity Log generates a security alert for everything that happens on your WordPress blogs and websites. Use the Audit Log Viewer included in the plugin to see all the security alerts.
6
  * Author: WP White Security
7
- * Version: 4.1.2
8
  * Text Domain: wp-security-audit-log
9
  * Author URI: http://www.wpwhitesecurity.com/
10
  * License: GPL2
@@ -42,17 +42,41 @@ if ( ! function_exists( 'wsal_freemius' ) ) {
42
  class WpSecurityAuditLog {
43
 
44
  /**
45
- * Plugin version.
46
- *
47
  * @var string
48
  */
49
- public $version = '4.1.2';
50
 
51
- // Plugin constants.
 
 
 
 
52
  const PLG_CLS_PRFX = 'WSAL_';
 
 
 
 
 
 
53
  const MIN_PHP_VERSION = '5.5.0';
 
 
 
 
 
 
 
 
 
54
  const OPT_PRFX = 'wsal-';
55
- // Plugins new options prefix.
 
 
 
 
 
56
  const OPTIONS_PREFIX = 'wsal_';
57
 
58
  /**
@@ -121,7 +145,7 @@ if ( ! function_exists( 'wsal_freemius' ) ) {
121
  /**
122
  * Add-ons Manager.
123
  *
124
- * @var object
125
  */
126
  public $extensions;
127
 
@@ -163,6 +187,9 @@ if ( ! function_exists( 'wsal_freemius' ) ) {
163
  // Frontend requests should only log for certain 404 requests.
164
  // For that to happen, we need to delay until template_redirect.
165
  if ( self::is_frontend() ) {
 
 
 
166
  $bootstrap_hook = [ 'wp_loaded', 0 ];
167
  add_action( 'wp', array( $this, 'setup_404' ) );
168
  }
@@ -181,6 +208,43 @@ if ( ! function_exists( 'wsal_freemius' ) ) {
181
  $this->include_options_helper();
182
  }
183
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
184
  /**
185
  * PHP magic __get function to get class properties.
186
  *
@@ -207,7 +271,7 @@ if ( ! function_exists( 'wsal_freemius' ) ) {
207
  }
208
 
209
  /**
210
- * Gets and instansiates the options helper.
211
  *
212
  * @method include_options_helper
213
  * @since 4.0.3
@@ -216,7 +280,7 @@ if ( ! function_exists( 'wsal_freemius' ) ) {
216
  public function include_options_helper() {
217
  require_once 'classes/Helpers/Options.php';
218
  if ( ! isset( $this->options_helper ) ) {
219
- $this->options_helper = new \WSAL\Helpers\Options( $this, self::OPTIONS_PREFIX );
220
  }
221
  return $this->options_helper;
222
  }
@@ -253,7 +317,12 @@ if ( ! function_exists( 'wsal_freemius' ) ) {
253
  * @return bool
254
  */
255
  public static function is_frontend() {
256
- return ! is_admin() && ! self::is_login_screen() && ( ! defined( 'WP_CLI' ) || ! WP_CLI ) && ( ! defined( 'DOING_CRON' ) || ! DOING_CRON ) && ! self::is_rest_api();
 
 
 
 
 
257
  }
258
 
259
  /**
@@ -261,14 +330,22 @@ if ( ! function_exists( 'wsal_freemius' ) ) {
261
  * IF not already loaded on `wp_loaded` hook for frontend request.
262
  */
263
  public function setup_404() {
264
- // If a user is logged in OR if the frontend sensors are allowed to load, then bail.
265
- if ( is_user_logged_in() || self::should_load_frontend() ) {
266
- return;
267
- }
 
 
268
 
269
- // If the current page is not 404 OR if the loading of 404 frontend sensor is not allowed, then bail.
270
- if ( ! is_404() || ! $this->load_for_404s() ) {
271
- return;
 
 
 
 
 
 
272
  }
273
 
274
  // Otherwise load WSAL on wp hook.
@@ -335,8 +412,7 @@ if ( ! function_exists( 'wsal_freemius' ) ) {
335
  * @return bool
336
  */
337
  public static function should_load_frontend() {
338
- $event_opt = 'wsal-frontend-events';
339
- $frontend_events = ! is_multisite() ? get_option( $event_opt ) : get_network_option( get_main_network_id(), $event_opt );
340
  return ! empty( $frontend_events['register'] ) || ! empty( $frontend_events['login'] ) || ! empty( $frontend_events['woocommerce'] );
341
  }
342
 
@@ -541,23 +617,28 @@ if ( ! function_exists( 'wsal_freemius' ) ) {
541
  * @return void
542
  */
543
  public function init_freemius() {
 
 
544
  if ( self::is_frontend() && 'no' !== self::is_premium_freemius() && file_exists( WSAL_BASE_DIR . '/extensions/class-wsal-extension-manager.php' ) ) {
545
  require_once WSAL_BASE_DIR . '/extensions/class-wsal-extension-manager.php';
546
 
547
  if ( defined( 'DOING_CRON' ) && DOING_CRON ) {
548
  WSAL_Extension_Manager::include_extension( 'reports' );
549
- WSAL_Extension_Manager::include_extension( 'sessions' );
550
  WSAL_Extension_Manager::include_extension( 'external-db' );
551
  } elseif ( $this->should_load() ) {
552
  WSAL_Extension_Manager::include_extension( 'notifications' );
553
  }
554
 
555
- return;
 
 
 
556
  }
557
 
558
- if ( is_admin() || self::is_login_screen() || self::is_rest_api() || ( defined( 'DOING_CRON' ) && DOING_CRON ) || ( defined( 'WP_CLI' ) && WP_CLI ) ) {
559
- self::load_freemius();
560
 
 
561
  if ( ! apply_filters( 'wsal_disable_freemius_sdk', false ) ) {
562
  // Add filters to customize freemius welcome message.
563
  wsal_freemius()->add_filter( 'connect_message', array( $this, 'wsal_freemius_connect_message' ), 10, 6 );
@@ -586,8 +667,7 @@ if ( ! function_exists( 'wsal_freemius' ) ) {
586
  if ( null === $this->load_for_404s ) {
587
  if ( ! is_user_logged_in() ) {
588
  // Get the frontend sensors setting.
589
- $event_opt = 'wsal-frontend-events';
590
- $frontend_events = ! is_multisite() ? get_option( $event_opt ) : get_network_option( get_main_network_id(), $event_opt );
591
 
592
  // This overrides the setting.
593
  $this->load_for_404s = ! empty( $frontend_events['system'] ) ? true : false;
@@ -595,6 +675,11 @@ if ( ! function_exists( 'wsal_freemius' ) ) {
595
  // We are doing a raw lookup here because The WSAL options system might not be loaded.
596
  $this->load_for_404s = self::raw_alert_is_enabled( 6007 );
597
  }
 
 
 
 
 
598
  }
599
 
600
  return $this->load_for_404s;
@@ -633,7 +718,7 @@ if ( ! function_exists( 'wsal_freemius' ) ) {
633
  * @return bool Whether the alert is enabled.
634
  */
635
  public static function raw_alert_is_enabled( $alert ) {
636
- $alerts = get_option( self::OPTIONS_PREFIX . 'disabled-alerts' );
637
  $alerts = explode( ',', $alerts );
638
  return ! in_array( $alert, $alerts );
639
  }
@@ -654,10 +739,6 @@ if ( ! function_exists( 'wsal_freemius' ) ) {
654
  $info = new stdClass();
655
  $info->wsal_installed = true;
656
  $info->is_premium = false;
657
-
658
- if ( wsal_freemius()->is__premium_only() ) {
659
- $info->is_premium = true;
660
- }
661
  break;
662
 
663
  case 'get_events':
@@ -716,20 +797,21 @@ if ( ! function_exists( 'wsal_freemius' ) ) {
716
  */
717
  public function wsal_plugin_redirect() {
718
  // WSAL State.
719
- $wsal_state = get_site_option( 'wsal_freemius_state', 'anonymous' );
720
 
721
  if (
722
- get_option( 'wsal_redirect_on_activate', false ) // Redirect flag.
723
  && in_array( $wsal_state, array( 'anonymous', 'skipped' ), true )
724
  ) {
725
  // If the redirect option is true, then continue.
726
- delete_option( 'wsal_redirect_on_activate' ); // Delete redirect option.
 
727
 
728
  // Redirect URL.
729
  $redirect = '';
730
 
731
  // If current site is multisite and user is super-admin then redirect to network audit log.
732
- if ( $this->IsMultisite() && $this->settings->CurrentUserCan( 'edit' ) && is_super_admin() ) {
733
  $redirect = add_query_arg( 'page', 'wsal-auditlog', network_admin_url( 'admin.php' ) );
734
  } else {
735
  // Otherwise redirect to main audit log view.
@@ -799,7 +881,6 @@ if ( ! function_exists( 'wsal_freemius' ) ) {
799
  define( 'WSAL_CLASS_PREFIX', 'WSAL_' );
800
  }
801
  }
802
-
803
  /**
804
  * Customize Freemius connect message for new users.
805
  *
@@ -818,7 +899,7 @@ if ( ! function_exists( 'wsal_freemius' ) ) {
818
  esc_html__( 'Hey %1$s', 'wp-security-audit-log' ) . ',<br>' .
819
  esc_html__( 'Never miss an important update! Opt-in to our security and feature updates notifications, and non-sensitive diagnostic tracking with freemius.com.', 'wp-security-audit-log' ) .
820
  '<br /><br /><strong>' . esc_html__( 'Note: ', 'wp-security-audit-log' ) . '</strong>' .
821
- esc_html__( 'NO AUDIT LOG ACTIVITY & DATA IS SENT BACK TO OUR SERVERS.', 'wp-security-audit-log' ),
822
  $user_first_name,
823
  '<b>' . $plugin_title . '</b>',
824
  '<b>' . $user_login . '</b>',
@@ -846,7 +927,7 @@ if ( ! function_exists( 'wsal_freemius' ) ) {
846
  /* translators: 1: Plugin name. 2: Freemius link. */
847
  esc_html__( 'Please help us improve %2$s! If you opt-in, some non-sensitive data about your usage of %2$s will be sent to %5$s, a diagnostic tracking service we use. If you skip this, that\'s okay! %2$s will still work just fine.', 'wp-security-audit-log' ) .
848
  '<br /><br /><strong>' . esc_html__( 'Note: ', 'wp-security-audit-log' ) . '</strong>' .
849
- esc_html__( 'NO AUDIT LOG ACTIVITY & DATA IS SENT BACK TO OUR SERVERS.', 'wp-security-audit-log' ),
850
  $user_first_name,
851
  '<b>' . $plugin_title . '</b>',
852
  '<b>' . $user_login . '</b>',
@@ -920,7 +1001,7 @@ if ( ! function_exists( 'wsal_freemius' ) ) {
920
  * @return bool
921
  */
922
  public function freemius_show_admin_notice( $show, $msg ) {
923
- if ( $this->settings->CurrentUserCan( 'edit' ) ) {
924
  return $show;
925
  }
926
  return false;
@@ -939,7 +1020,7 @@ if ( ! function_exists( 'wsal_freemius' ) ) {
939
  }
940
  wsal_freemius()->override_i18n(
941
  array(
942
- 'few-plugin-tweaks' => __( 'You need to activate the licence key to use WP Securitity Audit Log Premium. %2$s', 'wp-security-audit-log' ),
943
  'optin-x-now' => __( 'Activate the licence key now', 'wp-security-audit-log' ),
944
  )
945
  );
@@ -990,7 +1071,7 @@ if ( ! function_exists( 'wsal_freemius' ) ) {
990
  }
991
 
992
  if ( is_admin() ) {
993
- if ( $this->settings->IsArchivingEnabled() ) {
994
  // Check the current page.
995
  $get_page = filter_input( INPUT_GET, 'page', FILTER_SANITIZE_STRING );
996
  if ( ( ! isset( $get_page ) || 'wsal-auditlog' !== $get_page ) && ( ! defined( 'DOING_AJAX' ) || ! DOING_AJAX ) ) {
@@ -1005,7 +1086,7 @@ if ( ! function_exists( 'wsal_freemius' ) ) {
1005
  }
1006
 
1007
  // Hide plugin.
1008
- if ( $this->settings->IsIncognito() ) {
1009
  add_action( 'admin_head', array( $this, 'HidePlugin' ) );
1010
  add_filter( 'all_plugins', array( $this, 'wsal_hide_plugin' ) );
1011
  }
@@ -1018,7 +1099,7 @@ if ( ! function_exists( 'wsal_freemius' ) ) {
1018
  }
1019
 
1020
  // Generate index.php for uploads directory.
1021
- $this->settings->generate_index_files();
1022
  }
1023
 
1024
  /**
@@ -1041,7 +1122,7 @@ if ( ! function_exists( 'wsal_freemius' ) ) {
1041
  */
1042
  public function deactivate_actions() {
1043
  /**
1044
- * Allow short circuting of the deactivation email sending by using
1045
  * this filter to return true here instead of default false.
1046
  *
1047
  * @since 3.5.2
@@ -1066,7 +1147,7 @@ if ( ! function_exists( 'wsal_freemius' ) ) {
1066
  */
1067
  public function AjaxDisableCustomField() {
1068
  // Die if user does not have permission to disable.
1069
- if ( ! $this->settings->CurrentUserCan( 'edit' ) ) {
1070
  echo '<p>' . esc_html__( 'Error: You do not have sufficient permissions to disable this custom field.', 'wp-security-audit-log' ) . '</p>';
1071
  die();
1072
  }
@@ -1084,13 +1165,13 @@ if ( ! function_exists( 'wsal_freemius' ) ) {
1084
  die();
1085
  }
1086
 
1087
- $fields = $this->GetGlobalOption( 'excluded-custom' );
1088
  if ( isset( $fields ) && '' != $fields ) {
1089
  $fields .= ',' . esc_html( $post_array['notice'] );
1090
  } else {
1091
  $fields = esc_html( $post_array['notice'] );
1092
  }
1093
- $this->SetGlobalOption( 'excluded-custom', $fields );
1094
 
1095
  // Exclude object link.
1096
  $exclude_objects_link = add_query_arg(
@@ -1111,7 +1192,7 @@ if ( ! function_exists( 'wsal_freemius' ) ) {
1111
  */
1112
  public function AjaxDisableByCode() {
1113
  // Die if user does not have permission to disable.
1114
- if ( ! $this->settings->CurrentUserCan( 'edit' ) ) {
1115
  echo '<p>' . esc_html__( 'Error: You do not have sufficient permissions to disable this alert.', 'wp-security-audit-log' ) . '</p>';
1116
  die();
1117
  }
@@ -1129,13 +1210,13 @@ if ( ! function_exists( 'wsal_freemius' ) ) {
1129
  die();
1130
  }
1131
 
1132
- $s_alerts = $this->options_helper->get_option_value( 'disabled-alerts' );
1133
  if ( isset( $s_alerts ) && '' != $s_alerts ) {
1134
  $s_alerts .= ',' . esc_html( $post_array['code'] );
1135
  } else {
1136
  $s_alerts = esc_html( $post_array['code'] );
1137
  }
1138
- $this->options_helper->set_option_value( 'disabled-alerts', $s_alerts );
1139
  echo wp_sprintf( '<p>' . __( 'Alert %1$s is no longer being monitored.<br /> %2$s', 'wp-security-audit-log' ) . '</p>', esc_html( $post_array['code'] ), __( 'You can enable this alert again from the Enable/Disable Alerts node in the plugin menu.', 'wp-security-audit-log' ) );
1140
  die;
1141
  }
@@ -1155,10 +1236,8 @@ if ( ! function_exists( 'wsal_freemius' ) ) {
1155
  true
1156
  );
1157
 
1158
- // Check if plugin is premium and live events are enabled.
1159
- $is_premium = ( function_exists( 'wsal_freemius' ) ) && ( wsal_freemius()->can_use_premium_code() || wsal_freemius()->is_plan__premium_only( 'starter' ) );
1160
- $live_events_enabled = $is_premium && $this->settings->is_admin_bar_notif() && 'real-time' === $this->settings->get_admin_bar_notif_updates();
1161
-
1162
  // Set data array for common script.
1163
  $script_data = array(
1164
  'ajaxURL' => admin_url( 'admin-ajax.php' ),
@@ -1169,11 +1248,7 @@ if ( ! function_exists( 'wsal_freemius' ) ) {
1169
  'activated' => __( 'Extension activated', 'wp-security-audit-log' ),
1170
  'failed' => __( 'Install failed', 'wp-security-audit-log' ),
1171
  );
1172
- if ( $live_events_enabled ) {
1173
- $occurrence = new WSAL_Models_Occurrence();
1174
- $script_data['eventsCount'] = (int) $occurrence->Count();
1175
- $script_data['commonNonce'] = wp_create_nonce( 'wsal-common-js-nonce' );
1176
- }
1177
  wp_localize_script( 'wsal-common', 'wsalCommonData', $script_data );
1178
 
1179
  // Enqueue script.
@@ -1189,6 +1264,7 @@ if ( ! function_exists( 'wsal_freemius' ) ) {
1189
  require_once 'classes/Alert.php';
1190
  require_once 'classes/AbstractLogger.php';
1191
  require_once 'classes/AbstractSensor.php';
 
1192
  require_once 'classes/AlertManager.php';
1193
  require_once 'classes/ConstantManager.php';
1194
  require_once 'classes/Loggers/Database.php';
@@ -1207,20 +1283,20 @@ if ( ! function_exists( 'wsal_freemius' ) ) {
1207
  }
1208
 
1209
  // Setting the prunig date with the old value or the default value.
1210
- $pruning_date = $this->settings->GetPruningDate();
1211
- $this->settings->SetPruningDate( $pruning_date );
1212
  }
1213
 
1214
- $log_404 = $this->options_helper->get_option_value( 'log-404' );
1215
  // If old setting is empty enable 404 logging by default.
1216
  if ( false === $log_404 ) {
1217
- $this->options_helper->set_option_value( 'log-404', 'on' );
1218
  }
1219
 
1220
- $purge_log_404 = $this->options_helper->get_option_value( 'purge-404-log' );
1221
  // If old setting is empty enable 404 purge log by default.
1222
  if ( false === $purge_log_404 ) {
1223
- $this->options_helper->set_option_value( 'purge-404-log', 'on' );
1224
  }
1225
 
1226
  // Load translations.
@@ -1230,6 +1306,7 @@ if ( ! function_exists( 'wsal_freemius' ) ) {
1230
 
1231
  /**
1232
  * Install all assets required for a useable system.
 
1233
  */
1234
  public function Install() {
1235
  $installation_errors = false;
@@ -1269,6 +1346,17 @@ if ( ! function_exists( 'wsal_freemius' ) ) {
1269
 
1270
  // Ensure that the system is installed and schema is correct.
1271
  $pre_installed = $this->IsInstalled();
 
 
 
 
 
 
 
 
 
 
 
1272
  self::getConnector()->installAll();
1273
 
1274
  if ( ! $pre_installed ) {
@@ -1276,8 +1364,8 @@ if ( ! function_exists( 'wsal_freemius' ) ) {
1276
  self::getConnector()->getAdapter( 'Meta' )->create_indexes();
1277
  self::getConnector()->getAdapter( 'Option' )->create_indexes();
1278
 
1279
- if ( $this->settings->IsArchivingEnabled() ) {
1280
- $this->settings->SwitchToArchiveDB();
1281
  self::getConnector()->getAdapter( 'Occurrence' )->create_indexes();
1282
  self::getConnector()->getAdapter( 'Meta' )->create_indexes();
1283
  }
@@ -1297,23 +1385,23 @@ if ( ! function_exists( 'wsal_freemius' ) ) {
1297
  }
1298
 
1299
  // Setting the prunig date with the old value or the default value.
1300
- $old_disabled = $this->options_helper->get_option_value( 'disabled-alerts' );
1301
 
1302
  // If old setting is empty disable alert 2099 by default.
1303
  if ( empty( $old_disabled ) ) {
1304
- $this->settings->SetDisabledAlerts( array( 2099, 2126 ) );
1305
  }
1306
 
1307
- $log_404 = $this->options_helper->get_option_value( 'log-404' );
1308
  // If old setting is empty enable 404 logging by default.
1309
  if ( false === $log_404 ) {
1310
- $this->options_helper->set_option_value( 'log-404', 'on' );
1311
  }
1312
 
1313
- $purge_log_404 = $this->options_helper->get_option_value( 'purge-404-log' );
1314
  // If old setting is empty enable 404 purge log by default.
1315
  if ( false === $purge_log_404 ) {
1316
- $this->options_helper->set_option_value( 'purge-404-log', 'on' );
1317
  }
1318
 
1319
  // Install cleanup hook (remove older one if it exists).
@@ -1321,12 +1409,12 @@ if ( ! function_exists( 'wsal_freemius' ) ) {
1321
  wp_schedule_event( current_time( 'timestamp' ) + 600, 'hourly', 'wsal_cleanup' );
1322
 
1323
  // WSAL Audit Log page redirect option in anonymous mode.
1324
- if ( 'anonymous' === get_site_option( 'wsal_freemius_state', 'anonymous' ) ) {
1325
- add_option( 'wsal_redirect_on_activate', true );
1326
  }
1327
 
1328
  // Run on each install to check MainWP Child plugin.
1329
- $this->settings->set_mainwp_child_stealth_mode();
1330
 
1331
  // If plugin tables have not installed correctly then don't activate the plugin.
1332
  if ( ! $this->IsInstalled() ) :
@@ -1350,24 +1438,26 @@ if ( ! function_exists( 'wsal_freemius' ) ) {
1350
  }
1351
 
1352
  /**
1353
- * Run some code that updates critical components required for a newwer version.
1354
  *
1355
  * @param string $old_version The old version.
1356
  * @param string $new_version The new version.
 
 
1357
  */
1358
  public function Update( $old_version, $new_version ) {
1359
  // Update version in db.
1360
- $this->options_helper->set_option_value( 'version', $new_version );
1361
 
1362
  // Do version-to-version specific changes.
1363
  if ( '0.0.0' !== $old_version && -1 === version_compare( $old_version, $new_version ) ) {
1364
  // Update pruning alerts option if purning limit is enabled for backwards compatibility.
1365
- if ( $this->settings->IsPruningLimitEnabled() ) {
1366
  $pruning_date = '6';
1367
  $pruning_unit = 'months';
1368
- $this->settings->SetPruningDate( $pruning_date . ' ' . $pruning_unit );
1369
- $this->settings->SetPruningDateEnabled( true );
1370
- $this->settings->SetPruningLimitEnabled( false );
1371
  }
1372
 
1373
  // Dismiss privacy notice.
@@ -1418,20 +1508,8 @@ if ( ! function_exists( 'wsal_freemius' ) ) {
1418
  *
1419
  * @since 3.2.3.3
1420
  */
1421
- if ( false === $this->GetGlobalOption( 'mwp-child-stealth-mode', false ) ) {
1422
- $this->settings->set_mainwp_child_stealth_mode();
1423
- }
1424
-
1425
- /**
1426
- * IMPORTANT: VERSION SPECIFIC UPDATE
1427
- *
1428
- * It only needs to run when old version of the plugin is less than 3.2.4
1429
- * & the plugin is being updated to version 3.2.4 or later versions.
1430
- *
1431
- * @since 3.2.4
1432
- */
1433
- if ( version_compare( $old_version, '3.2.4', '<' ) && version_compare( $new_version, '3.2.3.3', '>' ) ) {
1434
- $this->options_helper->set_option_value( 'dismissed-privacy-notice', '1,wsal_privacy' );
1435
  }
1436
 
1437
  /**
@@ -1447,8 +1525,8 @@ if ( ! function_exists( 'wsal_freemius' ) ) {
1447
  self::getConnector()->getAdapter( 'Meta' )->create_indexes();
1448
  self::getConnector()->getAdapter( 'Option' )->create_indexes();
1449
 
1450
- if ( $this->settings->IsArchivingEnabled() ) {
1451
- $this->settings->SwitchToArchiveDB();
1452
  self::getConnector()->getAdapter( 'Occurrence' )->create_indexes();
1453
  self::getConnector()->getAdapter( 'Meta' )->create_indexes();
1454
  }
@@ -1479,25 +1557,25 @@ if ( ! function_exists( 'wsal_freemius' ) ) {
1479
  $frontend_events['woocommerce'] = true;
1480
  }
1481
 
1482
- $this->settings->set_frontend_events( $frontend_events );
1483
  }
1484
 
1485
  if ( version_compare( $old_version, '4.0.0', '<=' ) ) {
1486
  /*
1487
- * Ensure that the grid view 'info' colum is set to display.
1488
  */
1489
  add_action(
1490
  'init',
1491
  function() {
1492
- $cols = $this->settings->GetColumns();
1493
  // if the `info` col does not exist in the array then add it now.
1494
  if ( ! isset( $cols['info'] ) ) {
1495
  // add this at position 3 in the array.
1496
  $cols = array_slice( $cols, 0, 2, true ) + array( 'info' => '1' ) + array_slice( $cols, 2, null, true );
1497
- $this->settings->SetColumns( $cols );
1498
  } else {
1499
  $cols['info'] = '1';
1500
- $this->settings->SetColumns( $cols );
1501
  }
1502
  }
1503
  );
@@ -1520,6 +1598,170 @@ if ( ! function_exists( 'wsal_freemius' ) ) {
1520
  $settings_mover->run();
1521
 
1522
  }
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1523
  }
1524
  }
1525
 
@@ -1577,15 +1819,12 @@ if ( ! function_exists( 'wsal_freemius' ) ) {
1577
  }
1578
 
1579
  // Migrate settings.
1580
- $this->settings->SetAllowedPluginEditors(
1581
- get_option( 'WPPH_PLUGIN_ALLOW_CHANGE' )
1582
- );
1583
- $this->settings->SetAllowedPluginViewers(
1584
  get_option( 'WPPH_PLUGIN_ALLOW_ACCESS' )
1585
  );
1586
  $s = get_option( 'wpph_plugin_settings' );
1587
- $this->settings->SetViewPerPage( max( $s->showEventsViewList, 5 ) );
1588
- $this->settings->SetWidgetsEnabled( ! ! $s->showDW );
1589
  }
1590
 
1591
  /**
@@ -1604,7 +1843,7 @@ if ( ! function_exists( 'wsal_freemius' ) ) {
1604
  * @return string
1605
  */
1606
  public function GetOldVersion() {
1607
- $old_version = $this->options_helper->get_option_value( 'version', '0.0.0' );
1608
 
1609
  /*
1610
  * This GetGlobalOption is retained for back compatibility for
@@ -1613,7 +1852,7 @@ if ( ! function_exists( 'wsal_freemius' ) ) {
1613
  * TODO: remove this AFTER version 4.1.0.
1614
  */
1615
  if ( ! $old_version || '0.0.0' === $old_version ) {
1616
- $old_version = $this->GetGlobalOption( 'version', '0.0.0' );
1617
  }
1618
  return $old_version;
1619
  }
@@ -1658,11 +1897,16 @@ if ( ! function_exists( 'wsal_freemius' ) ) {
1658
 
1659
  /**
1660
  * Get a global option.
 
 
1661
  *
1662
  * @param string $option - Option name.
1663
  * @param mixed $default - (Optional) Value returned when option is not set (defaults to false).
1664
  * @param string $prefix - (Optional) A prefix used before option name.
1665
  * @return mixed - Option's value or $default if option not set.
 
 
 
1666
  */
1667
  public function GetGlobalOption( $option, $default = false, $prefix = self::OPT_PRFX ) {
1668
  if ( empty( $this->options ) ) {
@@ -1671,12 +1915,30 @@ if ( ! function_exists( 'wsal_freemius' ) ) {
1671
  return $this->options->GetOptionValue( $prefix . $option, $default );
1672
  }
1673
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1674
  /**
1675
  * Set a global option.
1676
  *
 
 
1677
  * @param string $option - Option name.
1678
  * @param mixed $value - New value for option.
1679
  * @param string $prefix - (Optional) A prefix used before option name.
 
 
 
1680
  */
1681
  public function SetGlobalOption( $option, $value, $prefix = self::OPT_PRFX ) {
1682
  if ( empty( $this->options ) ) {
@@ -1689,27 +1951,41 @@ if ( ! function_exists( 'wsal_freemius' ) ) {
1689
  }
1690
 
1691
  /**
1692
- * Get a user-specific option.
1693
  *
1694
  * @param string $option - Option name.
1695
- * @param mixed $default - (Optional) Value returned when option is not set (defaults to false).
1696
- * @param string $prefix - (Optional) A prefix used before option name.
1697
- * @return mixed - Option's value or $default if option not set.
 
1698
  */
1699
- public function GetUserOption( $option, $default = false, $prefix = self::OPT_PRFX ) {
1700
- $result = get_user_option( $prefix . $option, get_current_user_id() );
1701
- return false === $result ? $default : $result;
1702
  }
1703
 
1704
  /**
1705
- * Set a user-specific option.
 
 
 
 
 
 
 
 
 
 
 
 
1706
  *
1707
  * @param string $option - Option name.
1708
- * @param mixed $value - New value for option.
1709
- * @param string $prefix - (Optional) A prefix used before option name.
1710
  */
1711
- public function SetUserOption( $option, $value, $prefix = self::OPT_PRFX ) {
1712
- update_user_option( get_current_user_id(), $prefix . $option, $value, false );
 
1713
  }
1714
 
1715
  /**
@@ -1775,8 +2051,10 @@ if ( ! function_exists( 'wsal_freemius' ) ) {
1775
  * DB connection.
1776
  *
1777
  * @param mixed $config DB configuration.
1778
- * @param bool $reset - True if reset.
 
1779
  * @return WSAL_Connector_ConnectorInterface
 
1780
  */
1781
  public static function getConnector( $config = null, $reset = false ) {
1782
  return WSAL_Connector_ConnectorFactory::getConnector( $config, $reset );
@@ -1838,10 +2116,12 @@ if ( ! function_exists( 'wsal_freemius' ) ) {
1838
  * WSAL-Notifications-Extension Functions.
1839
  *
1840
  * @param string $opt_prefix - Option prefix.
 
 
1841
  */
1842
  public function GetNotificationsSetting( $opt_prefix ) {
1843
- $this->options = new WSAL_Models_Option();
1844
- return $this->options->GetNotificationsSetting( self::OPT_PRFX . $opt_prefix );
1845
  }
1846
 
1847
  /**
@@ -1852,16 +2132,21 @@ if ( ! function_exists( 'wsal_freemius' ) ) {
1852
  * @return string|null
1853
  */
1854
  public function GetNotification( $id ) {
1855
- $this->options = new WSAL_Models_Option();
1856
- return $this->options->GetNotification( $id );
1857
  }
1858
 
1859
  /**
1860
- * Delete option by name.
1861
  *
 
 
1862
  * @param string $name - Option name.
1863
  *
1864
  * @return bool
 
 
 
1865
  */
1866
  public function DeleteByName( $name ) {
1867
  $this->options = new WSAL_Models_Option();
@@ -1869,9 +2154,29 @@ if ( ! function_exists( 'wsal_freemius' ) ) {
1869
  }
1870
 
1871
  /**
1872
- * Delete option by prefix.
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1873
  *
1874
  * @param string $opt_prefix - Option prefix.
 
 
 
 
1875
  */
1876
  public function DeleteByPrefix( $opt_prefix ) {
1877
  $this->options = new WSAL_Models_Option();
@@ -1886,23 +2191,41 @@ if ( ! function_exists( 'wsal_freemius' ) ) {
1886
  * @return int
1887
  */
1888
  public function CountNotifications( $opt_prefix ) {
1889
- $this->options = new WSAL_Models_Option();
1890
- return $this->options->CountNotifications( self::OPT_PRFX . $opt_prefix );
1891
  }
1892
 
1893
  /**
1894
  * Update global option.
1895
  *
 
 
1896
  * @param string $option - Option name.
1897
  * @param mixed $value - Option value.
1898
  *
1899
  * @return bool|int
 
 
 
1900
  */
1901
  public function UpdateGlobalOption( $option, $value ) {
1902
  $this->options = new WSAL_Models_Option();
1903
  return $this->options->SetOptionValue( $option, $value );
1904
  }
1905
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1906
  /**
1907
  * Method: Render login page message.
1908
  *
@@ -1922,7 +2245,7 @@ if ( ! function_exists( 'wsal_freemius' ) ) {
1922
 
1923
  // Default message.
1924
  if ( ! $message ) {
1925
- $message = '<p class="message">' . wp_kses( __( 'For security and auditing purposes, a record of all of your logged-in actions and changes within the WordPress dashboard will be recorded in an audit log with the <a href="https://wpactivitylog.com/" target="_blank">WP Activity Log plugin</a>. The audit log also includes the IP address where you accessed this site from.', 'wp-security-audit-log' ), $this->allowed_html_tags ) . '</p>';
1926
  } else {
1927
  $message = '<p class="message">' . $message . '</p>';
1928
  }
@@ -2059,6 +2382,100 @@ if ( ! function_exists( 'wsal_freemius' ) ) {
2059
  return $plugins;
2060
  }
2061
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
2062
  }
2063
 
2064
  // Begin load sequence.
2
  /**
3
  * Plugin Name: WP Activity Log
4
  * Plugin URI: http://wpactivitylog.com/
5
+ * Description: Identify WordPress security issues before they become a problem. Keep track of everything happening on your WordPress including WordPress users activity. Similar to Windows Event Log and Linux Syslog, WP Activity Log generates a security alert for everything that happens on your WordPress blogs and websites. Use the Activity log viewer included in the plugin to see all the security alerts.
6
  * Author: WP White Security
7
+ * Version: 4.1.3
8
  * Text Domain: wp-security-audit-log
9
  * Author URI: http://www.wpwhitesecurity.com/
10
  * License: GPL2
42
  class WpSecurityAuditLog {
43
 
44
  /**
45
+ * Plugin version.
46
+ *
47
  * @var string
48
  */
49
+ public $version = '4.1.3';
50
 
51
+ /**
52
+ * Plugin constants.
53
+ *
54
+ * @var string
55
+ */
56
  const PLG_CLS_PRFX = 'WSAL_';
57
+
58
+ /**
59
+ * Minimal PHP version.
60
+ *
61
+ * @var string
62
+ */
63
  const MIN_PHP_VERSION = '5.5.0';
64
+
65
+ /**
66
+ * Old option name prefix.
67
+ *
68
+ * @var string
69
+ * @deprecated 4.1.3
70
+ *
71
+ * @todo Remove in future versions.
72
+ */
73
  const OPT_PRFX = 'wsal-';
74
+
75
+ /**
76
+ * New option name prefix.
77
+ *
78
+ * @var string
79
+ */
80
  const OPTIONS_PREFIX = 'wsal_';
81
 
82
  /**
145
  /**
146
  * Add-ons Manager.
147
  *
148
+ * @var WSAL_Extension_Manager
149
  */
150
  public $extensions;
151
 
187
  // Frontend requests should only log for certain 404 requests.
188
  // For that to happen, we need to delay until template_redirect.
189
  if ( self::is_frontend() ) {
190
+ // to track sessions on frontend logins we need to attach the
191
+ // the tracker and all the interfaces and classes it depends on.
192
+ add_action( $bootstrap_hook[0], array( $this, 'maybe_add_sessions_trackers_early' ), $bootstrap_hook[1] );
193
  $bootstrap_hook = [ 'wp_loaded', 0 ];
194
  add_action( 'wp', array( $this, 'setup_404' ) );
195
  }
208
  $this->include_options_helper();
209
  }
210
 
211
+ /**
212
+ * For frontend loading only - adds all dependency classes, interfaces,
213
+ * and helpers from sessions tracking and hooks the tracking methods in
214
+ * when frontend login sensors are enabled.
215
+ *
216
+ * @method add_sessions_trackers
217
+ * @since 4.x.x
218
+ */
219
+ public function maybe_add_sessions_trackers_early() {
220
+
221
+ /**
222
+ * If the frontend login tracking is not enabled don't add anything.
223
+ */
224
+ $frontend_events = WSAL_Settings::get_frontend_events();
225
+ if ( empty( $frontend_events['login'] ) ) {
226
+ return;
227
+ }
228
+
229
+ // To track sessions from the frontend we need to load the session
230
+ // tracking class and init it's hooks plus make available all of the
231
+ // supporting classes it needs to operate.
232
+ $base_path = plugin_dir_path( __FILE__ );
233
+ if ( file_exists( $base_path . 'extensions/user-sessions/user-sessions.php' ) ) {
234
+ spl_autoload_register( array( __CLASS__, 'autoloader' ) );
235
+
236
+ // classes below don't follow any naming convention handled by the autoloader
237
+ require_once $base_path . 'extensions/user-sessions/classes/Adapters/SessionInterface.php';
238
+ require_once $base_path . 'extensions/user-sessions/classes/Adapters/SessionAdapter.php';
239
+ require_once $base_path . 'extensions/user-sessions/classes/Models/Session.php';
240
+ require_once $base_path . 'extensions/user-sessions/classes/Helpers.php';
241
+ require_once $base_path . 'extensions/user-sessions/user-sessions.php';
242
+
243
+ $session_tracking = new WSAL_Sensors_UserSessionsTracking( $this );
244
+ $session_tracking->init();
245
+ }
246
+ }
247
+
248
  /**
249
  * PHP magic __get function to get class properties.
250
  *
271
  }
272
 
273
  /**
274
+ * Gets and instantiates the options helper.
275
  *
276
  * @method include_options_helper
277
  * @since 4.0.3
280
  public function include_options_helper() {
281
  require_once 'classes/Helpers/Options.php';
282
  if ( ! isset( $this->options_helper ) ) {
283
+ $this->options_helper = new \WSAL\Helpers\Options( self::OPTIONS_PREFIX );
284
  }
285
  return $this->options_helper;
286
  }
317
  * @return bool
318
  */
319
  public static function is_frontend() {
320
+ return ! is_admin()
321
+ && ! self::is_login_screen()
322
+ && ( ! defined( 'WP_CLI' ) || ! WP_CLI )
323
+ && ( ! defined( 'DOING_CRON' ) || ! DOING_CRON )
324
+ && ! self::is_rest_api()
325
+ && ! self::is_admin_blocking_plugins_support_enabled();
326
  }
327
 
328
  /**
330
  * IF not already loaded on `wp_loaded` hook for frontend request.
331
  */
332
  public function setup_404() {
333
+ $admin_blocking_plugins_support_enabled = $this->is_admin_blocking_plugins_support_enabled();
334
+ if (!$admin_blocking_plugins_support_enabled) {
335
+ // If a user is logged in OR if the frontend sensors are allowed to load, then bail.
336
+ if ( is_user_logged_in() || self::should_load_frontend() ) {
337
+ return;
338
+ }
339
 
340
+ // If the current page is not 404 OR if the loading of 404 frontend sensor is not allowed, then bail.
341
+ if ( ! is_404() || ! $this->load_for_404s() ) {
342
+ return;
343
+ }
344
+ }
345
+
346
+ if ($admin_blocking_plugins_support_enabled) {
347
+ // setup freemius in stealth mode
348
+ $this->init_freemius();
349
  }
350
 
351
  // Otherwise load WSAL on wp hook.
412
  * @return bool
413
  */
414
  public static function should_load_frontend() {
415
+ $frontend_events = WSAL_Settings::get_frontend_events();
 
416
  return ! empty( $frontend_events['register'] ) || ! empty( $frontend_events['login'] ) || ! empty( $frontend_events['woocommerce'] );
417
  }
418
 
617
  * @return void
618
  */
619
  public function init_freemius() {
620
+
621
+ $is_admin_blocking_plugins_support_enabled = $this->is_admin_blocking_plugins_support_enabled();
622
  if ( self::is_frontend() && 'no' !== self::is_premium_freemius() && file_exists( WSAL_BASE_DIR . '/extensions/class-wsal-extension-manager.php' ) ) {
623
  require_once WSAL_BASE_DIR . '/extensions/class-wsal-extension-manager.php';
624
 
625
  if ( defined( 'DOING_CRON' ) && DOING_CRON ) {
626
  WSAL_Extension_Manager::include_extension( 'reports' );
627
+ WSAL_Extension_Manager::include_extension( 'usersessions' );
628
  WSAL_Extension_Manager::include_extension( 'external-db' );
629
  } elseif ( $this->should_load() ) {
630
  WSAL_Extension_Manager::include_extension( 'notifications' );
631
  }
632
 
633
+ if (!$is_admin_blocking_plugins_support_enabled) {
634
+ // we only stop here if the support for admin blocking plugins is enabled
635
+ return;
636
+ }
637
  }
638
 
639
+ if ( $is_admin_blocking_plugins_support_enabled || is_admin() || self::is_login_screen() || self::is_rest_api() || ( defined( 'DOING_CRON' ) && DOING_CRON ) || ( defined( 'WP_CLI' ) && WP_CLI ) ) {
 
640
 
641
+ self::load_freemius();
642
  if ( ! apply_filters( 'wsal_disable_freemius_sdk', false ) ) {
643
  // Add filters to customize freemius welcome message.
644
  wsal_freemius()->add_filter( 'connect_message', array( $this, 'wsal_freemius_connect_message' ), 10, 6 );
667
  if ( null === $this->load_for_404s ) {
668
  if ( ! is_user_logged_in() ) {
669
  // Get the frontend sensors setting.
670
+ $frontend_events = WSAL_Settings::get_frontend_events();
 
671
 
672
  // This overrides the setting.
673
  $this->load_for_404s = ! empty( $frontend_events['system'] ) ? true : false;
675
  // We are doing a raw lookup here because The WSAL options system might not be loaded.
676
  $this->load_for_404s = self::raw_alert_is_enabled( 6007 );
677
  }
678
+
679
+ if ($this->is_admin_blocking_plugins_support_enabled()) {
680
+ // also load if the support for admin blocking plugins is enabled
681
+ $this->load_for_404s = true;
682
+ }
683
  }
684
 
685
  return $this->load_for_404s;
718
  * @return bool Whether the alert is enabled.
719
  */
720
  public static function raw_alert_is_enabled( $alert ) {
721
+ $alerts = \WSAL\Helpers\Options::get_option_value_ignore_prefix( self::OPTIONS_PREFIX . 'disabled-alerts' );
722
  $alerts = explode( ',', $alerts );
723
  return ! in_array( $alert, $alerts );
724
  }
739
  $info = new stdClass();
740
  $info->wsal_installed = true;
741
  $info->is_premium = false;
 
 
 
 
742
  break;
743
 
744
  case 'get_events':
797
  */
798
  public function wsal_plugin_redirect() {
799
  // WSAL State.
800
+ $wsal_state = $this->GetGlobalSetting( 'freemius_state', 'anonymous' );
801
 
802
  if (
803
+ $this->GetGlobalSetting( 'redirect_on_activate', false ) // Redirect flag.
804
  && in_array( $wsal_state, array( 'anonymous', 'skipped' ), true )
805
  ) {
806
  // If the redirect option is true, then continue.
807
+ $this->include_options_helper();
808
+ $this->options_helper->delete_option( 'wsal_redirect_on_activate' ); // Delete redirect option.
809
 
810
  // Redirect URL.
811
  $redirect = '';
812
 
813
  // If current site is multisite and user is super-admin then redirect to network audit log.
814
+ if ( $this->IsMultisite() && $this->settings()->CurrentUserCan( 'edit' ) && is_super_admin() ) {
815
  $redirect = add_query_arg( 'page', 'wsal-auditlog', network_admin_url( 'admin.php' ) );
816
  } else {
817
  // Otherwise redirect to main audit log view.
881
  define( 'WSAL_CLASS_PREFIX', 'WSAL_' );
882
  }
883
  }
 
884
  /**
885
  * Customize Freemius connect message for new users.
886
  *
899
  esc_html__( 'Hey %1$s', 'wp-security-audit-log' ) . ',<br>' .
900
  esc_html__( 'Never miss an important update! Opt-in to our security and feature updates notifications, and non-sensitive diagnostic tracking with freemius.com.', 'wp-security-audit-log' ) .
901
  '<br /><br /><strong>' . esc_html__( 'Note: ', 'wp-security-audit-log' ) . '</strong>' .
902
+ esc_html__( 'NO ACTIVITY LOG ACTIVITY & DATA IS SENT BACK TO OUR SERVERS.', 'wp-security-audit-log' ),
903
  $user_first_name,
904
  '<b>' . $plugin_title . '</b>',
905
  '<b>' . $user_login . '</b>',
927
  /* translators: 1: Plugin name. 2: Freemius link. */
928
  esc_html__( 'Please help us improve %2$s! If you opt-in, some non-sensitive data about your usage of %2$s will be sent to %5$s, a diagnostic tracking service we use. If you skip this, that\'s okay! %2$s will still work just fine.', 'wp-security-audit-log' ) .
929
  '<br /><br /><strong>' . esc_html__( 'Note: ', 'wp-security-audit-log' ) . '</strong>' .
930
+ esc_html__( 'NO ACTIVITY LOG ACTIVITY & DATA IS SENT BACK TO OUR SERVERS.', 'wp-security-audit-log' ),
931
  $user_first_name,
932
  '<b>' . $plugin_title . '</b>',
933
  '<b>' . $user_login . '</b>',
1001
  * @return bool
1002
  */
1003
  public function freemius_show_admin_notice( $show, $msg ) {
1004
+ if ( $this->settings()->CurrentUserCan( 'edit' ) ) {
1005
  return $show;
1006
  }
1007
  return false;
1020
  }
1021
  wsal_freemius()->override_i18n(
1022
  array(
1023
+ 'few-plugin-tweaks' => __( 'You need to activate the licence key to use WP Activity Log Premium. %2$s', 'wp-security-audit-log' ),
1024
  'optin-x-now' => __( 'Activate the licence key now', 'wp-security-audit-log' ),
1025
  )
1026
  );
1071
  }
1072
 
1073
  if ( is_admin() ) {
1074
+ if ( $this->settings()->IsArchivingEnabled() ) {
1075
  // Check the current page.
1076
  $get_page = filter_input( INPUT_GET, 'page', FILTER_SANITIZE_STRING );
1077
  if ( ( ! isset( $get_page ) || 'wsal-auditlog' !== $get_page ) && ( ! defined( 'DOING_AJAX' ) || ! DOING_AJAX ) ) {
1086
  }
1087
 
1088
  // Hide plugin.
1089
+ if ( $this->settings()->IsIncognito() ) {
1090
  add_action( 'admin_head', array( $this, 'HidePlugin' ) );
1091
  add_filter( 'all_plugins', array( $this, 'wsal_hide_plugin' ) );
1092
  }
1099
  }
1100
 
1101
  // Generate index.php for uploads directory.
1102
+ $this->settings()->generate_index_files();
1103
  }
1104
 
1105
  /**
1122
  */
1123
  public function deactivate_actions() {
1124
  /**
1125
+ * Allow short circuiting of the deactivation email sending by using
1126
  * this filter to return true here instead of default false.
1127
  *
1128
  * @since 3.5.2
1147
  */
1148
  public function AjaxDisableCustomField() {
1149
  // Die if user does not have permission to disable.
1150
+ if ( ! $this->settings()->CurrentUserCan( 'edit' ) ) {
1151
  echo '<p>' . esc_html__( 'Error: You do not have sufficient permissions to disable this custom field.', 'wp-security-audit-log' ) . '</p>';
1152
  die();
1153
  }
1165
  die();
1166
  }
1167
 
1168
+ $fields = $this->GetGlobalSetting( 'excluded-custom' );
1169
  if ( isset( $fields ) && '' != $fields ) {
1170
  $fields .= ',' . esc_html( $post_array['notice'] );
1171
  } else {
1172
  $fields = esc_html( $post_array['notice'] );
1173
  }
1174
+ $this->SetGlobalSetting( 'excluded-custom', $fields );
1175
 
1176
  // Exclude object link.
1177
  $exclude_objects_link = add_query_arg(
1192
  */
1193
  public function AjaxDisableByCode() {
1194
  // Die if user does not have permission to disable.
1195
+ if ( ! $this->settings()->CurrentUserCan( 'edit' ) ) {
1196
  echo '<p>' . esc_html__( 'Error: You do not have sufficient permissions to disable this alert.', 'wp-security-audit-log' ) . '</p>';
1197
  die();
1198
  }
1210
  die();
1211
  }
1212
 
1213
+ $s_alerts = $this->GetGlobalSetting( 'disabled-alerts' );
1214
  if ( isset( $s_alerts ) && '' != $s_alerts ) {
1215
  $s_alerts .= ',' . esc_html( $post_array['code'] );
1216
  } else {
1217
  $s_alerts = esc_html( $post_array['code'] );
1218
  }
1219
+ $this->SetGlobalSetting( 'disabled-alerts', $s_alerts );
1220
  echo wp_sprintf( '<p>' . __( 'Alert %1$s is no longer being monitored.<br /> %2$s', 'wp-security-audit-log' ) . '</p>', esc_html( $post_array['code'] ), __( 'You can enable this alert again from the Enable/Disable Alerts node in the plugin menu.', 'wp-security-audit-log' ) );
1221
  die;
1222
  }
1236
  true
1237
  );
1238
 
1239
+ // live events disabled in free version of the plugin
1240
+ $live_events_enabled = false;
 
 
1241
  // Set data array for common script.
1242
  $script_data = array(
1243
  'ajaxURL' => admin_url( 'admin-ajax.php' ),
1248
  'activated' => __( 'Extension activated', 'wp-security-audit-log' ),
1249
  'failed' => __( 'Install failed', 'wp-security-audit-log' ),
1250
  );
1251
+
 
 
 
 
1252
  wp_localize_script( 'wsal-common', 'wsalCommonData', $script_data );
1253
 
1254
  // Enqueue script.
1264
  require_once 'classes/Alert.php';
1265
  require_once 'classes/AbstractLogger.php';
1266
  require_once 'classes/AbstractSensor.php';
1267
+ require_once 'classes/AbstractMetaDataSensor.php';
1268
  require_once 'classes/AlertManager.php';
1269
  require_once 'classes/ConstantManager.php';
1270
  require_once 'classes/Loggers/Database.php';
1283
  }
1284
 
1285
  // Setting the prunig date with the old value or the default value.
1286
+ $pruning_date = $this->settings()->GetPruningDate();
1287
+ $this->settings()->SetPruningDate( $pruning_date );
1288
  }
1289
 
1290
+ $log_404 = $this->GetGlobalSetting( 'log-404' );
1291
  // If old setting is empty enable 404 logging by default.
1292
  if ( false === $log_404 ) {
1293
+ $this->SetGlobalBooleanSetting( 'log-404', true );
1294
  }
1295
 
1296
+ $purge_log_404 = $this->GetGlobalSetting( 'purge-404-log' );
1297
  // If old setting is empty enable 404 purge log by default.
1298
  if ( false === $purge_log_404 ) {
1299
+ $this->SetGlobalBooleanSetting( 'purge-404-log', true );
1300
  }
1301
 
1302
  // Load translations.
1306
 
1307
  /**
1308
  * Install all assets required for a useable system.
1309
+ * @throws Freemius_Exception
1310
  */
1311
  public function Install() {
1312
  $installation_errors = false;
1346
 
1347
  // Ensure that the system is installed and schema is correct.
1348
  $pre_installed = $this->IsInstalled();
1349
+
1350
+ // On first install this won't be loaded because not premium, add it
1351
+ // now so it installs.
1352
+ if ( file_exists( plugin_dir_path( __FILE__ ) . 'extensions/user-sessions/user-sessions.php' ) ) {
1353
+ $this->maybe_add_sessions_trackers_early();
1354
+ require_once plugin_dir_path( __FILE__ ) . 'extensions/user-sessions/user-sessions.php';
1355
+ $sessions = new WSAL_UserSessions_Plugin();
1356
+ $sessions->require_adapter_classes();
1357
+ }
1358
+
1359
+ // run any installs.
1360
  self::getConnector()->installAll();
1361
 
1362
  if ( ! $pre_installed ) {
1364
  self::getConnector()->getAdapter( 'Meta' )->create_indexes();
1365
  self::getConnector()->getAdapter( 'Option' )->create_indexes();
1366
 
1367
+ if ( $this->settings()->IsArchivingEnabled() ) {
1368
+ $this->settings()->SwitchToArchiveDB();
1369
  self::getConnector()->getAdapter( 'Occurrence' )->create_indexes();
1370
  self::getConnector()->getAdapter( 'Meta' )->create_indexes();
1371
  }
1385
  }
1386
 
1387
  // Setting the prunig date with the old value or the default value.
1388
+ $old_disabled = $this->GetGlobalSetting( 'disabled-alerts' );
1389
 
1390
  // If old setting is empty disable alert 2099 by default.
1391
  if ( empty( $old_disabled ) ) {
1392
+ $this->settings()->SetDisabledAlerts( array( 2099, 2126 ) );
1393
  }
1394
 
1395
+ $log_404 = $this->GetGlobalSetting( 'log-404' );
1396
  // If old setting is empty enable 404 logging by default.
1397
  if ( false === $log_404 ) {
1398
+ $this->SetGlobalBooleanSetting( 'log-404', true );
1399
  }
1400
 
1401
+ $purge_log_404 = $this->GetGlobalSetting( 'purge-404-log' );
1402
  // If old setting is empty enable 404 purge log by default.
1403
  if ( false === $purge_log_404 ) {
1404
+ $this->SetGlobalBooleanSetting( 'purge-404-log', true );
1405
  }
1406
 
1407
  // Install cleanup hook (remove older one if it exists).
1409
  wp_schedule_event( current_time( 'timestamp' ) + 600, 'hourly', 'wsal_cleanup' );
1410
 
1411
  // WSAL Audit Log page redirect option in anonymous mode.
1412
+ if ( 'anonymous' === $this->GetGlobalSetting( 'freemius_state', 'anonymous' ) ) {
1413
+ $this->SetGlobalSetting( 'redirect_on_activate', true );
1414
  }
1415
 
1416
  // Run on each install to check MainWP Child plugin.
1417
+ $this->settings()->set_mainwp_child_stealth_mode();
1418
 
1419
  // If plugin tables have not installed correctly then don't activate the plugin.
1420
  if ( ! $this->IsInstalled() ) :
1438
  }
1439
 
1440
  /**
1441
+ * Run some code that updates critical components required for a newer version.
1442
  *
1443
  * @param string $old_version The old version.
1444
  * @param string $new_version The new version.
1445
+ *
1446
+ * @throws Freemius_Exception
1447
  */
1448
  public function Update( $old_version, $new_version ) {
1449
  // Update version in db.
1450
+ $this->SetGlobalSetting( 'version', $new_version );
1451
 
1452
  // Do version-to-version specific changes.
1453
  if ( '0.0.0' !== $old_version && -1 === version_compare( $old_version, $new_version ) ) {
1454
  // Update pruning alerts option if purning limit is enabled for backwards compatibility.
1455
+ if ( $this->settings()->IsPruningLimitEnabled() ) {
1456
  $pruning_date = '6';
1457
  $pruning_unit = 'months';
1458
+ $this->settings()->SetPruningDate( $pruning_date . ' ' . $pruning_unit );
1459
+ $this->settings()->SetPruningDateEnabled( true );
1460
+ $this->settings()->SetPruningLimitEnabled( false );
1461
  }
1462
 
1463
  // Dismiss privacy notice.
1508
  *
1509
  * @since 3.2.3.3
1510
  */
1511
+ if ( ! $this->GetGlobalBooleanSetting( 'mwp-child-stealth-mode', false ) ) {
1512
+ $this->settings()->set_mainwp_child_stealth_mode();
 
 
 
 
 
 
 
 
 
 
 
 
1513
  }
1514
 
1515
  /**
1525
  self::getConnector()->getAdapter( 'Meta' )->create_indexes();
1526
  self::getConnector()->getAdapter( 'Option' )->create_indexes();
1527
 
1528
+ if ( $this->settings()->IsArchivingEnabled() ) {
1529
+ $this->settings()->SwitchToArchiveDB();
1530
  self::getConnector()->getAdapter( 'Occurrence' )->create_indexes();
1531
  self::getConnector()->getAdapter( 'Meta' )->create_indexes();
1532
  }
1557
  $frontend_events['woocommerce'] = true;
1558
  }
1559
 
1560
+ $this->settings()->set_frontend_events( $frontend_events );
1561
  }
1562
 
1563
  if ( version_compare( $old_version, '4.0.0', '<=' ) ) {
1564
  /*
1565
+ * Ensure that the grid view 'info' column is set to display.
1566
  */
1567
  add_action(
1568
  'init',
1569
  function() {
1570
+ $cols = $this->settings()->GetColumns();
1571
  // if the `info` col does not exist in the array then add it now.
1572
  if ( ! isset( $cols['info'] ) ) {
1573
  // add this at position 3 in the array.
1574
  $cols = array_slice( $cols, 0, 2, true ) + array( 'info' => '1' ) + array_slice( $cols, 2, null, true );
1575
+ $this->settings()->SetColumns( $cols );
1576
  } else {
1577
  $cols['info'] = '1';
1578
+ $this->settings()->SetColumns( $cols );
1579
  }
1580
  }
1581
  );
1598
  $settings_mover->run();
1599
 
1600
  }
1601
+
1602
+ /*
1603
+ * Remove legacy options related to plugin permissions.
1604
+ *
1605
+ * @since 4.1.3
1606
+ */
1607
+ if ( version_compare( $old_version, '4.1.3', '<=' ) ) {
1608
+
1609
+ /*
1610
+ * Rename 'wsal-frontend-events' to 'wsal_frontend-events' to follow the naming convention of all
1611
+ * other options.
1612
+ */
1613
+ if ( function_exists( 'switch_to_blog' ) ) {
1614
+ switch_to_blog( 1 );
1615
+ }
1616
+
1617
+ global $wpdb;
1618
+ $wpdb->update( $wpdb->options, [
1619
+ 'option_name' => 'wsal_frontend-events'
1620
+ ], [
1621
+ 'option_name' => 'wsal-frontend-events'
1622
+ ] );
1623
+
1624
+ if ( is_multisite() ) {
1625
+ $wpdb->update( $wpdb->sitemeta, [
1626
+ 'meta_key' => 'wsal_frontend-events'
1627
+ ], [
1628
+ 'meta_key' => 'wsal-frontend-events'
1629
+ ] );
1630
+ }
1631
+
1632
+ // rename couple of legacy options with duplicated prefix
1633
+ /** @var WSAL_Adapters_MySQL_Option $options_adapter */
1634
+ $options_adapter = $this->options->getAdapter();
1635
+ $options_adapter->Rename( 'wsal-wsal-setup-modal-dismissed', 'wsal-setup-modal-dismissed' );
1636
+ $options_adapter->Rename( 'wsal-wsal-setup-complete', 'wsal-setup-complete' );
1637
+
1638
+ // migrate all options from sitemeta to the options table on master site
1639
+ if ( is_multisite() ) {
1640
+ $site_meta_data = $wpdb->get_results( "SELECT * FROM {$wpdb->sitemeta} WHERE meta_key LIKE 'wsal%' AND meta_key != 'wsal_networkwide_tracker_cpts';" );
1641
+ if ( ! empty( $site_meta_data ) ) {
1642
+ foreach ( $site_meta_data as $site_meta_entry ) {
1643
+ $setting_name = $site_meta_entry->meta_key;
1644
+
1645
+ // the wsal- prefix needs stripped from this option.
1646
+ if ( false !== ( 'wsal-' === substr( $setting_name, 0, 5 ) ) ) {
1647
+ $setting_name = str_replace( 'wsal-', '', $setting_name );
1648
+ }
1649
+
1650
+ // we don't mind overriding the value if its already there
1651
+ $this->SetGlobalSetting( $setting_name, $site_meta_entry->meta_value );
1652
+
1653
+ delete_network_option( $site_meta_entry->site_id, $site_meta_entry->meta_key );
1654
+ }
1655
+ }
1656
+ }
1657
+
1658
+ // use first existing user from the list of editors as the user id with access in case "only me"
1659
+ // access option is selected
1660
+ $plugin_editors = $this->GetGlobalSetting( 'plugin-editors', [] );
1661
+ if ( ! empty( $plugin_editors ) ) {
1662
+ foreach ( explode( ',', $plugin_editors ) as $user_login ) {
1663
+ $user = get_user_by( 'login', trim( $user_login ) );
1664
+ if ( $user instanceof WP_User ) {
1665
+ $this->settings()->set_only_me_user_id( $user->ID );
1666
+ break;
1667
+ }
1668
+ }
1669
+ }
1670
+
1671
+ $this->DeleteByName( 'wsal-plugin-editors' );
1672
+ $this->DeleteByName( 'wsal-restrict-admins' );
1673
+ $this->DeleteSettingByName( 'wsal_plugin-editors' );
1674
+ $this->DeleteSettingByName( 'wsal_restrict-admins' );
1675
+
1676
+ // migrate remaining settings to WordPress options table
1677
+ require_once 'classes/Update/Task/MoveSettingsToOptionsTable.php';
1678
+ $settings_mover = new WSAL\Update\Task\MoveSettingsToOptionsTable( self::GetInstance() );
1679
+ $settings_mover->set_versions( $old_version, $new_version );
1680
+ $settings_mover->run();
1681
+
1682
+ // Delete options transient.
1683
+ delete_transient( 'wsal_options' );
1684
+
1685
+ if ( function_exists( 'restore_current_blog' ) ) {
1686
+ restore_current_blog();
1687
+ }
1688
+
1689
+ // delete the custom options table
1690
+ WSAL_Sensors_Database::$enabled = false;
1691
+ $options_adapter->Uninstall();
1692
+ WSAL_Sensors_Database::$enabled = true;
1693
+
1694
+ // delete settings from option on other sub sites on multisite (only leave settings on the main site)
1695
+ if (is_multisite()) {
1696
+ $sites = get_sites([
1697
+ 'number' => 0,
1698
+ 'offset' => 0
1699
+ ]);
1700
+ if (!empty($sites)) {
1701
+ foreach ( $sites as $site ) {
1702
+ $wpdb->query("DELETE FROM {$wpdb->prefix}{$site->blog_id}_options WHERE option_name LIKE 'wsal%' AND option_name != 'wsal_networkwide_tracker_cpts';");
1703
+ }
1704
+ }
1705
+ }
1706
+
1707
+ wp_cache_flush();
1708
+
1709
+ // delete the sessions table and recreate it from scratch (session token is used as primary key
1710
+ // instead of an autoincrement ID column
1711
+ $extensions_manager = $this->extensions;
1712
+ // we need to check if the extension manager is set for this to work in free version of the plugin
1713
+ if ( $extensions_manager != null ) {
1714
+ $extensions = $extensions_manager->extensions;
1715
+ if ( ! empty( $extensions ) ) {
1716
+ foreach ( $extensions as $extension ) {
1717
+ if ( 'WSAL_UserSessions_Plugin' === get_class( $extension ) ) {
1718
+ WSAL_Sensors_Database::$enabled = false;
1719
+ $adapter = WSAL_UserSessions_Plugin::get_sessions_adapter();
1720
+ $adapter->Uninstall();
1721
+ $adapter->Install();
1722
+ WSAL_Sensors_Database::$enabled = true;
1723
+ }
1724
+ }
1725
+ }
1726
+ }
1727
+
1728
+ // convert all boolean style settings to 'yes'/'no' values
1729
+ // on/off/0/1/true/false/enable/disable => yes/no
1730
+ $yes_no_settings = [
1731
+ 'adapter-use-buffer',
1732
+ 'admin-blocking-plugins-support',
1733
+ 'delete-data',
1734
+ 'disable-widgets',
1735
+ 'hide-plugin',
1736
+ 'is-url-shortner',
1737
+ 'log-404',
1738
+ 'log-404-referrer',
1739
+ 'log-visitor-404',
1740
+ 'log-visitor-404-referrer',
1741
+ 'login_page_notification',
1742
+ 'mwp-child-stealth-mode',
1743
+ 'pruning-date-e',
1744
+ 'pruning-limit-e',
1745
+ 'purge-404-log',
1746
+ 'purge-visitor-404-log',
1747
+ 'setup-complete',
1748
+ 'setup-modal-dismissed',
1749
+ 'show_milliseconds',
1750
+ 'use-proxy-ip',
1751
+ 'wc-all-stock-changes',
1752
+ 'wp-backend'
1753
+ ];
1754
+
1755
+ foreach ($yes_no_settings as $option_name) {
1756
+ $current_value = $this->GetGlobalSetting($option_name);
1757
+ $bool_value = \WSAL\Helpers\Options::string_to_bool($current_value);
1758
+ $new_value = \WSAL\Helpers\Options::bool_to_string($bool_value);
1759
+ $this->SetGlobalSetting($option_name, $new_value);
1760
+ }
1761
+
1762
+ // delete unused setting related to file changes scanner
1763
+ $this->DeleteSettingByName('wsal-scan-file-changes');
1764
+ }
1765
  }
1766
  }
1767
 
1819
  }
1820
 
1821
  // Migrate settings.
1822
+ $this->settings()->SetAllowedPluginViewers(
 
 
 
1823
  get_option( 'WPPH_PLUGIN_ALLOW_ACCESS' )
1824
  );
1825
  $s = get_option( 'wpph_plugin_settings' );
1826
+ $this->settings()->SetViewPerPage( max( $s->showEventsViewList, 5 ) );
1827
+ $this->settings()->SetWidgetsEnabled( ! ! $s->showDW );
1828
  }
1829
 
1830
  /**
1843
  * @return string
1844
  */
1845
  public function GetOldVersion() {
1846
+ $old_version = $this->GetGlobalOption( 'version', '0.0.0' );
1847
 
1848
  /*
1849
  * This GetGlobalOption is retained for back compatibility for
1852
  * TODO: remove this AFTER version 4.1.0.
1853
  */
1854
  if ( ! $old_version || '0.0.0' === $old_version ) {
1855
+ $old_version = $this->GetGlobalSetting( 'version', '0.0.0' );
1856
  }
1857
  return $old_version;
1858
  }
1897
 
1898
  /**
1899
  * Get a global option.
1900
+ *
1901
+ * Deprecated function. It is only kept for the upgrade routine. It should be removed in future releases.
1902
  *
1903
  * @param string $option - Option name.
1904
  * @param mixed $default - (Optional) Value returned when option is not set (defaults to false).
1905
  * @param string $prefix - (Optional) A prefix used before option name.
1906
  * @return mixed - Option's value or $default if option not set.
1907
+ *
1908
+ * @deprecated 4.1.3 Use WpSecurityAuditLog::GetGlobalSetting instead
1909
+ * @see WpSecurityAuditLog::GetGlobalSetting()
1910
  */
1911
  public function GetGlobalOption( $option, $default = false, $prefix = self::OPT_PRFX ) {
1912
  if ( empty( $this->options ) ) {
1915
  return $this->options->GetOptionValue( $prefix . $option, $default );
1916
  }
1917
 
1918
+ /**
1919
+ * Get a global setting.
1920
+ *
1921
+ * @param string $option - Option name.
1922
+ * @param mixed $default - (Optional) Value returned when option is not set (defaults to false).
1923
+ * @param string $prefix - (Optional) A prefix used before option name. Not used. Present only for API compatibility.
1924
+ * @return mixed - Option's value or $default if option not set.
1925
+ */
1926
+ public function GetGlobalSetting( $option, $default = false, $prefix = self::OPT_PRFX ) {
1927
+ $this->include_options_helper();
1928
+ return $this->options_helper->get_option_value( $option, $default );
1929
+ }
1930
+
1931
  /**
1932
  * Set a global option.
1933
  *
1934
+ * Deprecated function. It is only kept for the upgrade routine. It should be removed in future releases.
1935
+ *
1936
  * @param string $option - Option name.
1937
  * @param mixed $value - New value for option.
1938
  * @param string $prefix - (Optional) A prefix used before option name.
1939
+ *
1940
+ * @deprecated 4.1.3 Use WpSecurityAuditLog::SetGlobalSetting instead
1941
+ * @see WpSecurityAuditLog::SetGlobalSetting()
1942
  */
1943
  public function SetGlobalOption( $option, $value, $prefix = self::OPT_PRFX ) {
1944
  if ( empty( $this->options ) ) {
1951
  }
1952
 
1953
  /**
1954
+ * Set a global setting.
1955
  *
1956
  * @param string $option - Option name.
1957
+ * @param mixed $value - New value for option.
1958
+ * @param string $prefix - (Optional) A prefix used before option name. Not used. Present only for API compatibility.
1959
+ *
1960
+ * @return bool
1961
  */
1962
+ public function SetGlobalSetting( $option, $value, $prefix = self::OPT_PRFX ) {
1963
+ $this->include_options_helper();
1964
+ return $this->options_helper->set_option_value( $option, $value );
1965
  }
1966
 
1967
  /**
1968
+ * Get a global boolean setting. It takes care of the conversion between string and boolean.
1969
+ *
1970
+ * @param string $option - Option name.
1971
+ * @param boolean $default - (Optional) Value returned when option is not set (defaults to false).
1972
+ * @return boolean - Option's value or $default if option not set.
1973
+ * @since 4.1.3
1974
+ */
1975
+ public function GetGlobalBooleanSetting( $option, $default = false ) {
1976
+ $result = $this->GetGlobalSetting( $option, \WSAL\Helpers\Options::string_to_bool( $default ) );
1977
+ return \WSAL\Helpers\Options::string_to_bool( $result );
1978
+ }
1979
+ /**
1980
+ * Sets a global boolean setting. It takes care of the conversion between string and boolean.
1981
  *
1982
  * @param string $option - Option name.
1983
+ * @param mixed $value - New value for option.
1984
+ * @since 4.1.3
1985
  */
1986
+ public function SetGlobalBooleanSetting( $option, $value ) {
1987
+ $boolean_value = \WSAL\Helpers\Options::string_to_bool( $value );
1988
+ $this->SetGlobalSetting( $option, \WSAL\Helpers\Options::bool_to_string( $boolean_value ) );
1989
  }
1990
 
1991
  /**
2051
  * DB connection.
2052
  *
2053
  * @param mixed $config DB configuration.
2054
+ * @param bool $reset - True if reset.
2055
+ *
2056
  * @return WSAL_Connector_ConnectorInterface
2057
+ * @throws Freemius_Exception
2058
  */
2059
  public static function getConnector( $config = null, $reset = false ) {
2060
  return WSAL_Connector_ConnectorFactory::getConnector( $config, $reset );
2116
  * WSAL-Notifications-Extension Functions.
2117
  *
2118
  * @param string $opt_prefix - Option prefix.
2119
+ *
2120
+ * @return array|null
2121
  */
2122
  public function GetNotificationsSetting( $opt_prefix ) {
2123
+ $this->include_options_helper();
2124
+ return $this->options_helper->GetNotificationsSetting( self::OPTIONS_PREFIX . $opt_prefix );
2125
  }
2126
 
2127
  /**
2132
  * @return string|null
2133
  */
2134
  public function GetNotification( $id ) {
2135
+ $this->include_options_helper();
2136
+ return $this->options_helper->GetNotification($id);
2137
  }
2138
 
2139
  /**
2140
+ * Deletes option by name.
2141
  *
2142
+ * Deprecated function. It is only kept for the upgrade routine. It should be removed in future releases.
2143
+ *
2144
  * @param string $name - Option name.
2145
  *
2146
  * @return bool
2147
+ *
2148
+ * @deprecated 4.1.3 Use WpSecurityAuditLog::DeleteSettingByName() instead
2149
+ * @see WpSecurityAuditLog::DeleteSettingByName()
2150
  */
2151
  public function DeleteByName( $name ) {
2152
  $this->options = new WSAL_Models_Option();
2154
  }
2155
 
2156
  /**
2157
+ * Deletes setting by name.
2158
+ *
2159
+ * @param string $name - Option name not including the plugin prefix.
2160
+ *
2161
+ * @return bool
2162
+ */
2163
+ public function DeleteSettingByName( $name ) {
2164
+ if ( empty( $this->options_helper ) ) {
2165
+ $this->include_options_helper();
2166
+ }
2167
+ return $this->options_helper->delete_option( $name );
2168
+ }
2169
+
2170
+ /**
2171
+ * Deletes options by prefix.
2172
+ *
2173
+ * Deprecated function. It is only kept for the upgrade routine. It should be removed in future releases.
2174
  *
2175
  * @param string $opt_prefix - Option prefix.
2176
+ *
2177
+ * @return bool
2178
+ *
2179
+ * @deprecated Replacement not implemented.
2180
  */
2181
  public function DeleteByPrefix( $opt_prefix ) {
2182
  $this->options = new WSAL_Models_Option();
2191
  * @return int
2192
  */
2193
  public function CountNotifications( $opt_prefix ) {
2194
+ $this->include_options_helper();
2195
+ return $this->options_helper->CountNotifications( $opt_prefix );
2196
  }
2197
 
2198
  /**
2199
  * Update global option.
2200
  *
2201
+ * Deprecated function. It is only kept for the upgrade routine. It should be removed in future releases.
2202
+ *
2203
  * @param string $option - Option name.
2204
  * @param mixed $value - Option value.
2205
  *
2206
  * @return bool|int
2207
+ *
2208
+ * @deprecated 4.1.3 Use WpSecurityAuditLog::UpdateGlobalSetting instead
2209
+ * @see WpSecurityAuditLog::UpdateGlobalSetting()
2210
  */
2211
  public function UpdateGlobalOption( $option, $value ) {
2212
  $this->options = new WSAL_Models_Option();
2213
  return $this->options->SetOptionValue( $option, $value );
2214
  }
2215
 
2216
+ /**
2217
+ * Update global setting.
2218
+ *
2219
+ * @param string $option - Option name.
2220
+ * @param mixed $value - Option value.
2221
+ *
2222
+ * @return bool|int
2223
+ */
2224
+ public function UpdateGlobalSetting( $option, $value ) {
2225
+ $this->include_options_helper();
2226
+ return $this->options_helper->set_option_value( $option, $value );
2227
+ }
2228
+
2229
  /**
2230
  * Method: Render login page message.
2231
  *
2245
 
2246
  // Default message.
2247
  if ( ! $message ) {
2248
+ $message = '<p class="message">' . wp_kses( __( 'For security and auditing purposes, a record of all of your logged-in actions and changes within the WordPress dashboard will be recorded in an activity log with the <a href="https://wpactivitylog.com/" target="_blank">WP Activity Log plugin</a>. The audit log also includes the IP address where you accessed this site from.', 'wp-security-audit-log' ), $this->allowed_html_tags ) . '</p>';
2249
  } else {
2250
  $message = '<p class="message">' . $message . '</p>';
2251
  }
2382
  return $plugins;
2383
  }
2384
 
2385
+ /**
2386
+ * Temporary autoloader for WSAL classes that somehow bypassed regular means of including
2387
+ * them during the plugin runtime.
2388
+ *
2389
+ * As far as we know, only the UserSessionsTracking object will fall into this autoloader.
2390
+ *
2391
+ * We could optimize the code below by caching the list of extension folders.
2392
+ *
2393
+ * @param string $class Fully qualified class name.
2394
+ *
2395
+ * @return bool
2396
+ */
2397
+ public static function autoloader( $class ) {
2398
+ if ( ! preg_match( '/^WSAL_/', $class ) ) {
2399
+ return false;
2400
+ }
2401
+
2402
+ $base_path = plugin_dir_path( __FILE__ );
2403
+ $subfolders = array();
2404
+ $matches = explode( '_', $class );
2405
+ if ( count( $matches ) > 2 ) {
2406
+ // remove first (WSAL) and last one (actual file name)
2407
+ array_shift( $matches );
2408
+ array_pop( $matches );
2409
+ $subfolders = $matches;
2410
+
2411
+ // workaround for MySQL adapter classes
2412
+ if ( count( $subfolders ) == 2 && $subfolders[0] === 'Adapters' && $subfolders[1] === 'MySQL' ) {
2413
+ $class .= 'Adapter';
2414
+ }
2415
+ }
2416
+
2417
+ // use last part of the class name as the actual file name to look for
2418
+ $file_name = substr( $class, strrpos( $class, '_' ) + 1 );
2419
+
2420
+ // try the main "classes" folder first
2421
+ $partial_path_to_file = 'classes' . DIRECTORY_SEPARATOR . implode( DIRECTORY_SEPARATOR, $subfolders ) . DIRECTORY_SEPARATOR . $file_name . '.php';
2422
+ $path_to_file = $base_path . $partial_path_to_file;
2423
+ if ( file_exists( $path_to_file ) ) {
2424
+ require_once $path_to_file;
2425
+
2426
+ return true;
2427
+ }
2428
+
2429
+ if ( ! function_exists( 'list_files' ) ) {
2430
+ require_once ABSPATH . 'wp-admin/includes/file.php';
2431
+ }
2432
+
2433
+ $extension_folders = list_files( $base_path . 'extensions', 1 );
2434
+ foreach ( $extension_folders as $extension_folder ) {
2435
+ if ( ! is_dir( $extension_folder ) ) {
2436
+ continue;
2437
+ }
2438
+
2439
+ $path_to_file = $extension_folder . $partial_path_to_file;
2440
+ if ( file_exists( $path_to_file ) ) {
2441
+ require_once $path_to_file;
2442
+
2443
+ return true;
2444
+ }
2445
+ }
2446
+ }
2447
+
2448
+ /**
2449
+ * @return bool
2450
+ */
2451
+ private static function is_admin_blocking_plugins_support_enabled() {
2452
+
2453
+ // only meant for 404 pages, but may run before is_404 can be used
2454
+ $is_404 = did_action('wp') ? is_404() : true;
2455
+ if (!$is_404) {
2456
+ return false;
2457
+ }
2458
+
2459
+ // this is called very early so we need to load some settings manually
2460
+ spl_autoload_register( array( __CLASS__, 'autoloader' ) );
2461
+ require_once 'classes/Helpers/Options.php';
2462
+
2463
+ /*
2464
+ * We assume settings have already been migrated (in version 4.1.3) to WordPress options table. We might
2465
+ * miss some 404 events until the plugin upgrade runs, but that is a very rare edge case. The same applies
2466
+ * to loading of 'admin-blocking-plugins-support' option further down.
2467
+ */
2468
+ $options_helper = new \WSAL\Helpers\Options( self::OPTIONS_PREFIX );
2469
+ $is_stealth_mode = $options_helper->get_option_value('mwp-child-stealth-mode', 'no');
2470
+
2471
+ if ('yes' !== $is_stealth_mode ) {
2472
+ // only intended if MainWP stealth mode is active
2473
+ return false;
2474
+ }
2475
+
2476
+ // allow if the admin blocking support settings is active
2477
+ return ('yes' === $options_helper->get_option_value( 'admin-blocking-plugins-support', 'no' ) );
2478
+ }
2479
  }
2480
 
2481
  // Begin load sequence.