Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/splitline/PHPFuck
PHPFuck: ([+.^]) / Using only 7 different characters to write and execute php.
https://github.com/splitline/PHPFuck
obfuscator php phpfuck
Last synced: 3 months ago
JSON representation
PHPFuck: ([+.^]) / Using only 7 different characters to write and execute php.
- Host: GitHub
- URL: https://github.com/splitline/PHPFuck
- Owner: splitline
- License: mit
- Created: 2019-11-13T06:54:09.000Z (about 5 years ago)
- Default Branch: master
- Last Pushed: 2021-02-05T08:52:31.000Z (almost 4 years ago)
- Last Synced: 2024-04-24T18:26:20.027Z (7 months ago)
- Topics: obfuscator, php, phpfuck
- Language: Python
- Homepage: https://splitline.github.io/PHPFuck/
- Size: 50.8 KB
- Stars: 385
- Watchers: 8
- Forks: 37
- Open Issues: 4
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# PHPFuck: ([+.^])
Using only 7 different characters to write and execute php.Only support PHP 7+ currently.
## Example Code
The following source will execute `phpinfo();`:```php
```
## Usage
```
usage: phpfuck.py [-h] [-O FILE] [-P] [-E {assert,create_function}] codepositional arguments:
code any string to encode.optional arguments:
-h, --help show this help message and exit
-O FILE, --output-file FILE
write encoded string into some file.
-P, --plain-string encode as plain string (without eval it).
-E {assert,create_function}, --eval {assert,create_function}
choose eval mode. (`assert` mode only support PHP < 7.1)
```You can just use it like this: `python3 phpfuck.py "system('id');"`
### Arguments
- code (required)
- Any string or php code to encode.
- -O, --output-file
- Write encoded string into some file.
- -P, --plain-string
- Encode as plain string (without eval it).
- With this argument, I will not wrap your code into `assert` or `create_function` to eval.
- -E, --eval
- You can choose your eval mode!
- `create_function` mode (default)
- `create_function('', YOUR_CODE)();`
- `assert` mode
- Only support PHP < 7.1 (=7.0.x).
- `assert( '(function(){ YOUR_CODE; return 1; })()' );`## TODO
- [x] Support characters other than ASCII range.
- [ ] Don't use deprecated feature. (`create_function` has been DEPRECATED)
- [x] Web interface. (https://splitline.github.io/PHPFuck/)
- [ ] Compatible with PHP 8
- Maybe string mode only, since the `create_function` has been removed from PHP 8 :(