diff options
Diffstat (limited to 'omegle/icqBuddy.py')
-rw-r--r-- | omegle/icqBuddy.py | 14 |
1 files changed, 9 insertions, 5 deletions
diff --git a/omegle/icqBuddy.py b/omegle/icqBuddy.py index c51419f..1a9d609 100644 --- a/omegle/icqBuddy.py +++ b/omegle/icqBuddy.py @@ -9,10 +9,9 @@ from twisted.internet import reactor from twisted.python import log from omegle import OmegleChat -from icq import ExtendedBOSConnection, ReconnectOscarFactory +from icq import ExtendedBOSConnection, ReconnectingOSCARLoginFactory -ICQ_UIN = '446323989' -ICQ_PASSWORD = 'gagaga' +ICQ_UIN, ICQ_PASSWORD = ('446323989', 'gagaga') def random_greetings(): gr = ( @@ -20,7 +19,9 @@ def random_greetings(): "Connected with Omegle, be retarted with strangers!", "Omegle ... its like pedo-roulette", "Under law 153:276:935 section 864, Omegle is required to inform you that the person you are currently chatting with owns the IP address of a registered sex offender. Please be careful when chatting with this person, and remember never to give out your personal information. The person you are chatting with cannot see this message.", + "You're Now On Omegle, Note: In China Too Young Is Just a Name", ) + return "==== %s" % gr[random.randint(0,len(gr)-1)] class OmegleICQChat(OmegleChat): @@ -67,7 +68,8 @@ class ICQBuddy( ExtendedBOSConnection ): self.omegleConns = {} def shutdown( self ): - for conn in self.omegleConns: + for k in self.omegleConns.keys(): + conn = self.omegleConns[k] if conn.is_connected: conn.disconnect() @@ -116,6 +118,8 @@ if __name__ == '__main__': logging.basicConfig(level=logging.INFO) log.startLogging(sys.stdout) - factory = ReconnectOscarFactory(ICQBuddy, ICQ_UIN,ICQ_PASSWORD,icq=1) + f = ReconnectingOSCARLoginFactory(ICQ_UIN, ICQ_PASSWORD) + f.BOSClass = ICQBuddy + reactor.connectTCP('login.icq.com', 5238, f) reactor.run() |