bediger4000 / reverse-php-malware

De-obfuscate and reverse engineer PHP malware
MIT License
77 stars 32 forks source link

PHP Warning: addcslashes() expects parameter 1 to be string, object given #5

Open youri-- opened 4 years ago

youri-- commented 4 years ago

Hi, getting this error 5 times before it ends:

PHP Warning: addcslashes() expects parameter 1 to be string, object given in /.../reverse-php-malware/vendor/nikic/php-parser/lib/PhpParser/PrettyPrinter/Standard.php on line 101

Using:

$ php -v
PHP 7.3.21 (cli) (built: Aug  4 2020 08:06:20) ( NTS )
Copyright (c) 1997-2018 The PHP Group
Zend Engine v3.3.21, Copyright (c) 1998-2018 Zend Technologies

Tried replacing vendor/nikic/php-parser with latest version, but then got this:

PHP Notice:  Undefined property: PhpParser\Node\Param::$name in /.../reverse-php-malware/RevPHPNodeVisitor.php on line 402
PHP Notice:  Undefined property: PhpParser\Node\Param::$name in /.../reverse-php-malware/RevPHPNodeVisitor.php on line 402
PHP Notice:  Undefined property: PhpParser\Node\Param::$name in /.../reverse-php-malware/RevPHPNodeVisitor.php on line 402
PHP Fatal error:  Uncaught TypeError: Argument 1 passed to PhpParser\Node\Scalar\String_::__construct() must be of the type string, object given, called in /.../reverse-php-malware/RevPHPNodeVisitor.php on line 439 and defined in /.../reverse-php-malware/vendor/nikic/php-parser/lib/PhpParser/Node/Scalar/String_
.php:36
Stack trace:
#0 /.../reverse-php-malware/RevPHPNodeVisitor.php(439): PhpParser\Node\Scalar\String_->__construct(Object(PhpParser\Node\Expr\Variable))
#1 /.../reverse-php-malware/RevPHPNodeVisitor.php(498): RevPHPNodeVisitor->newNodeAsType(Object(PhpParser\Node\Expr\Variable))
#2 /.../reverse-php-malware/RevPHPNodeVisitor.php(700): RevPHPNodeVisitor->performAssignment(Object(PhpParser\Node\Expr\Assign))
#3 /.../reverse-php-malware/vendor/nikic/php-parser/lib/PhpParser/NodeTraverser.php(153): RevPHPNodeVisitor->leaveNode(Object(PhpParser\Node\Expr\Assign))
#4 /... in /.../reverse-php-malware/vendor/nikic/php-parser/lib/PhpParser/Node/Scalar/String_.php on line 36