-
Notifications
You must be signed in to change notification settings - Fork 38
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
b7d3247
commit 7373989
Showing
9 changed files
with
114 additions
and
0 deletions.
There are no files selected for viewing
17 changes: 17 additions & 0 deletions
17
tests/phpunit/testdata/plugins/test-plugin-code-obfuscation-ioncube-multiple-errors/load.php
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,17 @@ | ||
<?php | ||
/** | ||
* Plugin Name: Test Plugin Code Obfuscation ionCube Multiple Errors | ||
* Plugin URI: https://github.com/WordPress/plugin-check | ||
* Description: Some plugin description. | ||
* Author: WordPress Performance Team | ||
* Author URI: https://make.wordpress.org/performance/ | ||
* License: GPLv2 or later | ||
* License URI: https://www.gnu.org/licenses/old-licenses/gpl-2.0.html | ||
* Text Domain: test-plugin-code-obfuscation-ioncube-multiple-errors | ||
* | ||
* @package test-plugin-code-obfuscation-ioncube-multiple-errors | ||
*/ | ||
|
||
/** | ||
* Just the word "ionCube" in this file will trigger the detection. | ||
*/ |
1 change: 1 addition & 0 deletions
1
...unit/testdata/plugins/test-plugin-code-obfuscation-ioncube-multiple-errors/obfuscated.php
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
<?php // Just the word "ionCube" in this file will trigger the detection. |
19 changes: 19 additions & 0 deletions
19
...nit/testdata/plugins/test-plugin-code-obfuscation-sourceguardian-multiple-errors/load.php
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,19 @@ | ||
<?php | ||
/** | ||
* Plugin Name: Test Plugin Code Obfuscation Source Guardian Multiple Errors | ||
* Plugin URI: https://github.com/WordPress/plugin-check | ||
* Description: Some plugin description. | ||
* Author: WordPress Performance Team | ||
* Author URI: https://make.wordpress.org/performance/ | ||
* License: GPLv2 or later | ||
* License URI: https://www.gnu.org/licenses/old-licenses/gpl-2.0.html | ||
* Text Domain: test-plugin-code-obfuscation-sourceguardian-multiple-errors | ||
* | ||
* @package test-plugin-code-obfuscation-sourceguardian-multiple-errors | ||
*/ | ||
|
||
/** | ||
* Files contain code which is used to detect Source Guardian obfuscated files. | ||
*/ | ||
require_once __DIR__ . '/obfuscated.php'; | ||
require_once __DIR__ . '/obfuscated2.php'; |
4 changes: 4 additions & 0 deletions
4
...stdata/plugins/test-plugin-code-obfuscation-sourceguardian-multiple-errors/obfuscated.php
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
<?php | ||
if(function_exists('sg_load')) { | ||
$random_global = 'random_string'; | ||
} |
2 changes: 2 additions & 0 deletions
2
...tdata/plugins/test-plugin-code-obfuscation-sourceguardian-multiple-errors/obfuscated2.php
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
<?php | ||
$domain = 'sourceguardian.com'; |
24 changes: 24 additions & 0 deletions
24
.../phpunit/testdata/plugins/test-plugin-code-obfuscation-zendguard-multiple-errors/load.php
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,24 @@ | ||
<?php | ||
/** | ||
* Plugin Name: Test Plugin Code Obfuscation Zend Guard Multiple Errors | ||
* Plugin URI: https://github.com/WordPress/plugin-check | ||
* Description: Some plugin description. | ||
* Author: WordPress Performance Team | ||
* Author URI: https://make.wordpress.org/performance/ | ||
* License: GPLv2 or later | ||
* License URI: https://www.gnu.org/licenses/old-licenses/gpl-2.0.html | ||
* Text Domain: test-plugin-code-obfuscation-zendguard-multiple-errors | ||
* | ||
* @package test-plugin-code-obfuscation-zendguard-multiple-errors | ||
*/ | ||
|
||
// This constant is defined here to prevent fatal errors from the file below. | ||
if ( ! defined( 'Zend' ) ) { | ||
define( 'Zend', true ); | ||
} | ||
|
||
/** | ||
* Files contain code which is used to detect Zend Guard obfuscated files. | ||
*/ | ||
require_once __DIR__ . '/obfuscated.php'; | ||
require_once __DIR__ . '/obfuscated2.php'; |
3 changes: 3 additions & 0 deletions
3
...it/testdata/plugins/test-plugin-code-obfuscation-zendguard-multiple-errors/obfuscated.php
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
<?php @Zend; | ||
|
||
$random_global = 'random_string'; |
2 changes: 2 additions & 0 deletions
2
...t/testdata/plugins/test-plugin-code-obfuscation-zendguard-multiple-errors/obfuscated2.php
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
<?php | ||
$message = 'This file was encoded by Zend'; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters