Example #1
0
def handler(c, e, t, signal, frame):
    logging.info('- Autokill -')
    # stop tor session
    socks.setdefaultproxy()
    import urllib2

    logging.info(
        '- Closing tor. Public IP address: {0}'.format(str(urllib2.urlopen('http://icanhazip.com').read())))
    # sending debug mail
    EmailNotifiers.debugCall()
    # exit(2) - by autokill
    exit(2)