Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- # -*- coding: cp1250 -*-
- import socket, time
- nick = "Lunux_"
- password = "LMAO"
- debug = True
- network = "irc.pirc.pl"
- port = 6667
- if debug == True:
- chan = "#testingchannel"
- elif debug == False:
- chan = "#mirkofm"
- irc = socket.socket(socket.AF_INET, socket.SOCK_STREAM)
- irc.connect((network, port))
- irc.recv(4096)
- irc.send("NICK " + nick + "\r\n\
- USER " + nick + " " + nick + " " + nick + " :PIRC.pl\r\n")
- #irc.send("PRIVMSG NICKSERV IDENTIFY " + password + "\r\n\
- #MODE +i+w\r\n\
- #JOIN " + chan + "\r\n"
- #)
- # irc.send("PRIVMSG " + chan + " :no kurwa wreszcie XD\r\n")
- while True:
- data = irc.recv(4096).decode("UTF-8")
- print(data)
- if data.find("PING") != -1:
- irc.send("PONG " + data.split()[1] + "\r\n")
- if data.find("limit sesji") != -1:
- irc.send("/quit")
- exit()
- if data.find("nick nie jest zarejestrowany") or data.find("Ten nick jest zarejestrowany i chroniony") != -1:
- irc.send("PRIVMSG NICKSERV IDENTIFY " + password + "\r\n\
- MODE +i+w\r\n\
- JOIN " + chan + "\r\n")
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement