Step 1:
– The .htaccess doesn’t provide a protection to anyone from downloading the backups.
– The .htaccess doesn’t prevent search engines from entering this folder so:
– Open .htaccess which in your backup folder and enter this code:
Deny from all
</Files>
<Files “*.gz”>
Deny from all
</Files>
Now you prevent the search engines from entering and indexing this folder and you prevent anyone to download these backups even you.
Step 2:
– When you take a backup it saved it in a unique format like this:
Or
For example:
Or
– So to prevent someone from guessing the prefix then downloading the backup follow me:
– Open:
– Find:
– Replace it with:
$name = $pref . ‘_’ . $db . ‘_’ . date(“Y-m-d_H-i-s”);
Now it’s impossible for someone to guess the prefix.
Step 3:
– Create a password for the backup directory from your cPanel.
Now it’s impossible for someone to steal your backup.