This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env python | |
from twisted.conch import error, manhole, manhole_ssh, ssh | |
from twisted.conch.ssh import keys, factory, common | |
from twisted.cred import checkers, portal, credentials | |
from twisted.python import failure, log | |
from zope.interface import implements | |
from twisted.cred.error import UnauthorizedLogin, UnhandledCredentials | |
import os.path |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
from Core.ZalgoBase.BaseModule import BaseModule | |
from twisted.web.client import getPage | |
from twisted.internet.defer import inlineCallbacks | |
from Core.ZalgoUtil.CmdWraps import command, timeout, needsArg, stripColors | |
from Core.ZalgoUtil.ModUtil import utf8 | |
from urllib import urlencode | |
from xml.etree.cElementTree import fromstring | |
from Core import version | |
from Core.ZalgoUtil.DeferredCache import deferred_lfu_cache |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
proxies = [] | |
from collections import deque | |
class rotate(deque): | |
def get(self): | |
item = self.pop() | |
self.appendleft(item) | |
return item | |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
def parseWolframAlphaResponse(self, response, redirected = False, results = None): | |
results = results if results is not None else [] | |
xmlTree = fromstring(response) | |
recalculate = xmlTree.get('recalculate') | |
success = xmlTree.get('success') | |
if success == 'true': | |
for pod in xmlTree.findall('pod'): | |
title = pod.get('title') | |
plaintext = pod.find('subpod/plaintext') | |
if plaintext is not None and plaintext.text: |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import sys | |
import socket | |
import string | |
import os | |
VERBOSE = True | |
class AstonixIRCBot(object): | |
socket = None | |
connected = False |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
""" | |
Omegle twisted client | |
""" | |
DISCONNECTED = 0 | |
CONNECTING = 1 | |
WAITING = 2 | |
CONNECTED = 3 | |
from random import choice |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
""" | |
Omegle Twisted Client version 1.0 | |
""" | |
__author__ = "e" | |
__version___ = "1.0" | |
DISCONNECTED = 0 | |
CONNECTING = 1 | |
WAITING = 2 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
2011-02-18 01:17:00+0000 [-] .5 secs passed | |
2011-02-18 01:17:00+0000 [Core.ZalgoUtil.SSHManhole.ZalgoSSHFactory] disabling diffie-hellman-group-exchange because we cannot find moduli file | |
2011-02-18 01:17:00+0000 [-] .5 secs passed | |
2011-02-18 01:17:01+0000 [SSHServerTransport,0,127.0.0.1] kex alg, key alg: diffie-hellman-group1-sha1 ssh-rsa | |
2011-02-18 01:17:01+0000 [SSHServerTransport,0,127.0.0.1] outgoing: aes128-ctr hmac-md5 none | |
2011-02-18 01:17:01+0000 [SSHServerTransport,0,127.0.0.1] incoming: aes128-ctr hmac-md5 none | |
2011-02-18 01:17:03+0000 [-] .5 secs passed | |
2011-02-18 01:17:03+0000 [SSHServerTransport,0,127.0.0.1] NEW KEYS | |
2011-02-18 01:17:03+0000 [-] .5 secs passed |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
class RC4: | |
def __init__(self, key): | |
self._key, x, box, kl = key, 0, range(256), len(key) | |
for i in xrange(256): | |
x = (x + box[i] + ord(key[i % kl])) & 0xff | |
box[i], box[x] = box[x], box[i] | |
self._box = box | |
def crypt(self, data): |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
from twisted.conch.ssh import transport, userauth, connection, common, keys, channel, forwarding | |
from twisted.internet import defer, protocol, reactor, interfaces, base, address, error | |
import socket | |
import types | |
from twisted.python import failure | |
from twisted.internet.protocol import connectionDone | |
__all__ = ['SSHTransport', 'SSHTransportFactory', 'SSHConnection', 'SSHForwardConnector', 'SSHForwardTransport'] | |
class SSHTransport(transport.SSHClientTransport): |