Skip to content

Instantly share code, notes, and snippets.

@rmdhfz
Created May 17, 2023 03:56
Show Gist options
  • Save rmdhfz/d8a60c7c94b14be25b64ef62bba23673 to your computer and use it in GitHub Desktop.
Save rmdhfz/d8a60c7c94b14be25b64ef62bba23673 to your computer and use it in GitHub Desktop.

Revisions

  1. rmdhfz created this gist May 17, 2023.
    17 changes: 17 additions & 0 deletions antiwebsitecoppier.php
    Original file line number Diff line number Diff line change
    @@ -0,0 +1,17 @@
    <?php
    $UA = $_SERVER["HTTP_USER_AGENT"];
    private function ProtectWebCopier(){
    global $UA;
    $state = false;
    if (preg_match("/webzip|httrack|wget|FlickBot|downloader|production
    bot|superbot|PersonaPilot|NPBot|WebCopier|vayala|imagefetch|
    Microsoft URL Control|mac finder|
    emailreaper|emailsiphon|emailwolf|emailmagnet|emailsweeper|
    Indy Library|FrontPage|cherry picker|WebCopier|netzip|
    Share Program|TurnitinBot|full web bot|zeus/i",$UA)){
    $state = true;
    print "sorry :)";
    exit();
    }
    }
    ?>