Cccamwatch.sh

From digital-bit.ch's wiki
Jump to: navigation, search

Cccamwatch.sh

#!/bin/bash
# written for a friend, checks for a running cccam, why not pgrep?
# cause if cccam is in zombiemode/otherwise broken and runnning, pgrep
# will still see the process and don't report
# In most cases CCcam is used for illegal purpose, I do not support this cases
# this script is only for educational and testing purpose!
 
RECIPIENT='mail@domain.tld'
CCCAMWEBGUI='127.0.0.1:1666' #check port in your config!
 
if curl -i $CCCAMWEBGUI | grep -q 401  
    then
        echo "CCcam is running!"
    else
        echo -e 'CCcam is not running!' |\
        mailx -s "CCcam check on $HOSTNAME failed" $RECIPIENT
fi

raspberry pi
powered by

    ip-exchange.de

Personal tools