Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revision Previous revision
Next revision
Previous revision
systems:linux_maintenance_scripts [2018/05/01 15:03]
smayr
systems:linux_maintenance_scripts [2018/05/01 15:07] (current)
smayr [RSync]
Line 59: Line 59:
  
 # Subserver Repositories # Subserver Repositories
-rsync --archive --verbose --progress --stats --rsh=/usr/bin/ssh --recursive --times --perms --links --delete 192.168.0.31::repos /data/mirror/swdev/repos+rsync --archive --verbose --progress --stats --rsh=/usr/bin/ssh --recursive --times --perms  
 +  --links --delete 192.168.0.31::repos /data/mirror/swdev/repos
 </code> </code>
  
 +== Anti-spam / Anti-crack ==
 +Run this script to scan the website and see signs of spamming or cracking: ''scan-website.sh'':
 +<code bash>
 +#!/bin/bash
 +## script: scan-website.sh
 +##
 +
 +echo "Scan Website for vulnerabilities" > /tmp/scan.txt
 +
 +cd /var/www
 +find . -name "*.php.suspected" >> /tmp/scan.txt
 +find . -name "*.php" -exec grep -H "eval(" "{}" \; >> /tmp/scan.txt
 +find . -name "*.php" -exec grep -H "\$GLOBALS.*\\x" "{}" \; >> /tmp/scan.txt
 +find . -name "*.php" -exec grep -H "function.*for.*strlen.*isset" "{}" \; >> /tmp/scan.txt
 +find . -name "*.php" -exec grep -H '<iframe' "{}" \; >> /tmp/scan.txt
 +find . -name "*.php" -exec grep -H 'header(*Location:' "{}" \; >> /tmp/scan.txt
 +less /tmp/scan.txt
 +</code>
 == Mail Spool Maintenance == == Mail Spool Maintenance ==