Guest User

/usr/bin/enable-adblocking

a guest
Oct 22nd, 2019
46
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.36 KB | None | 0 0
  1. #!/bin/bash
  2.  
  3. # Create new empty hosts file (with default entries for a normally functioning OS)
  4. mv /etc/hosts /etc/hosts.old
  5. touch /etc/hosts
  6. echo "127.0.0.1 localhost.localdomain localhost" > /etc/hosts
  7. echo "::1 localhost.localdomain localhost" >> /etc/hosts
  8.  
  9. # Execute script to populate hosts entries
  10. sh /usr/bin/update-hosts
  11.  
  12. echo "Ad-blocking enabled"
Add Comment
Please, Sign In to add comment