VaultPress - Version 1.9.4

Version Description

  • 15 November 2017
  • Error handling improvements in the scanner
Download this release

Release Info

Developer benedictsinger
Plugin Icon 128x128 VaultPress
Version 1.9.4
Comparing to
See all releases

Code changes from version 1.9.3 to 1.9.4

Files changed (3) hide show
  1. readme.txt +4 -1
  2. vaultpress.php +2 -2
  3. vp-scanner.php +9 -2
readme.txt CHANGED
@@ -3,7 +3,7 @@ Contributors: automattic, apokalyptik, briancolinger, josephscott, shaunandrews,
3
  Tags: security, malware, virus, archive, back up, back ups, backup, backups, scanning, restore, wordpress backup, site backup, website backup
4
  Requires at least: 3.2
5
  Tested up to: 4.9
6
- Stable tag: 1.9.3
7
  License: GPLv2
8
 
9
  VaultPress is a subscription service offering real-time backup, automated security scanning, and support from WordPress experts.
@@ -47,6 +47,9 @@ A VaultPress subscription is for a single WordPress site. You can purchase addit
47
  Yes, VaultPress supports Multisite installs. Each site will require its own subscription.
48
 
49
  == Changelog ==
 
 
 
50
  = 1.9.3 - 9 November 2017
51
  * Compatibility update
52
  * Send a better user-agent string to VaultPress servers
3
  Tags: security, malware, virus, archive, back up, back ups, backup, backups, scanning, restore, wordpress backup, site backup, website backup
4
  Requires at least: 3.2
5
  Tested up to: 4.9
6
+ Stable tag: 1.9.4
7
  License: GPLv2
8
 
9
  VaultPress is a subscription service offering real-time backup, automated security scanning, and support from WordPress experts.
47
  Yes, VaultPress supports Multisite installs. Each site will require its own subscription.
48
 
49
  == Changelog ==
50
+ = 1.9.4 - 15 November 2017
51
+ * Error handling improvements in the scanner
52
+
53
  = 1.9.3 - 9 November 2017
54
  * Compatibility update
55
  * Send a better user-agent string to VaultPress servers
vaultpress.php CHANGED
@@ -3,7 +3,7 @@
3
  * Plugin Name: VaultPress
4
  * Plugin URI: http://vaultpress.com/?utm_source=plugin-uri&utm_medium=plugin-description&utm_campaign=1.0
5
  * Description: Protect your content, themes, plugins, and settings with <strong>realtime backup</strong> and <strong>automated security scanning</strong> from <a href="http://vaultpress.com/?utm_source=wp-admin&amp;utm_medium=plugin-description&amp;utm_campaign=1.0" rel="nofollow">VaultPress</a>. Activate, enter your registration key, and never worry again. <a href="http://vaultpress.com/help/?utm_source=wp-admin&amp;utm_medium=plugin-description&amp;utm_campaign=1.0" rel="nofollow">Need some help?</a>
6
- * Version: 1.9.3
7
  * Author: Automattic
8
  * Author URI: http://vaultpress.com/?utm_source=author-uri&amp;utm_medium=plugin-description&amp;utm_campaign=1.0
9
  * License: GPL2+
@@ -18,7 +18,7 @@ class VaultPress {
18
  var $option_name = 'vaultpress';
19
  var $auto_register_option = 'vaultpress_auto_register';
20
  var $db_version = 4;
21
- var $plugin_version = '1.9.3';
22
 
23
  function __construct() {
24
  register_activation_hook( __FILE__, array( $this, 'activate' ) );
3
  * Plugin Name: VaultPress
4
  * Plugin URI: http://vaultpress.com/?utm_source=plugin-uri&amp;utm_medium=plugin-description&amp;utm_campaign=1.0
5
  * Description: Protect your content, themes, plugins, and settings with <strong>realtime backup</strong> and <strong>automated security scanning</strong> from <a href="http://vaultpress.com/?utm_source=wp-admin&amp;utm_medium=plugin-description&amp;utm_campaign=1.0" rel="nofollow">VaultPress</a>. Activate, enter your registration key, and never worry again. <a href="http://vaultpress.com/help/?utm_source=wp-admin&amp;utm_medium=plugin-description&amp;utm_campaign=1.0" rel="nofollow">Need some help?</a>
6
+ * Version: 1.9.4
7
  * Author: Automattic
8
  * Author URI: http://vaultpress.com/?utm_source=author-uri&amp;utm_medium=plugin-description&amp;utm_campaign=1.0
9
  * License: GPL2+
18
  var $option_name = 'vaultpress';
19
  var $auto_register_option = 'vaultpress_auto_register';
20
  var $db_version = 4;
21
+ var $plugin_version = '1.9.4';
22
 
23
  function __construct() {
24
  register_activation_hook( __FILE__, array( $this, 'activate' ) );
vp-scanner.php CHANGED
@@ -100,7 +100,10 @@ function vp_is_interesting_file($file) {
100
  * @return array An array with 3 arrays of lines
101
  */
102
  function split_file_to_php_html( $file ) {
103
- $source = file_get_contents( $file );
 
 
 
104
  return split_to_php_html( $source );
105
  }
106
 
@@ -252,7 +255,11 @@ function vp_scan_file( $file, $tmp_file = null, $use_parser = false ) {
252
  // if there is no filename_regex, we assume it's the same of vp_is_interesting_file().
253
  if ( empty( $signature->filename_regex ) || preg_match( '#' . addcslashes( $signature->filename_regex, '#' ) . '#i', $file ) ) {
254
  if ( null === $file_content || !is_array( $file_content ) ) {
255
- $file_content = file( $real_file );
 
 
 
 
256
 
257
  if ( $use_parser ) {
258
  $file_parsed = split_file_to_php_html( $real_file );
100
  * @return array An array with 3 arrays of lines
101
  */
102
  function split_file_to_php_html( $file ) {
103
+ $source = @file_get_contents( $file );
104
+ if ( $source === false ) {
105
+ $source = '';
106
+ }
107
  return split_to_php_html( $source );
108
  }
109
 
255
  // if there is no filename_regex, we assume it's the same of vp_is_interesting_file().
256
  if ( empty( $signature->filename_regex ) || preg_match( '#' . addcslashes( $signature->filename_regex, '#' ) . '#i', $file ) ) {
257
  if ( null === $file_content || !is_array( $file_content ) ) {
258
+ $file_content = @file( $real_file );
259
+
260
+ if ( $file_content === false ) {
261
+ return false;
262
+ }
263
 
264
  if ( $use_parser ) {
265
  $file_parsed = split_file_to_php_html( $real_file );