Howdy, Stranger!

It looks like you're new here. If you want to get involved, click one of these buttons!

Top Posters

Who's Online (2)

Powered by Vanilla. Made with Bootstrap.
[PYTHON]Simple IRC bot
  • chroniccommand
    Posts: 1,389

    #!/usr/bin/python

    import socket, sys, string, time
    port = 6667
    nick = \"iSploit_bot\"
    host = 'irc.darkscience.ws'
    name = \"pwnz0r\"
    channel = '#iexploit'
    ident = 'chronicz'
    woot = socket.socket()
    woot.connect ( (host, port) )
    woot.send ( 'NICK ' + nick + '\r\n' )
    woot.send ( 'USER ' + ident + ' ' + ident + ' ' + ident + ' :chroniczbot\r\n' )

    while 1:
    data = woot.recv ( 1024 )
    print(data)

    if data.find ( '376' ) != -1:
    woot.send( 'JOIN ' + channel + '\r\n' )

    if data.find ( 'PING' ) != -1:
    woot.send( 'PONG ' + data.split() [1] + '\r\n')

    if data.find ( '!test' ) != -1:
    woot.send (\"PRIVMSG #chroniccommand :Test message! \r\n\")

    if data.fiind ( '!quit' ) != -1:
    woot.send (\"QUIT\r\n\")
    sys.exit()

    This is a simple version of iExploit IRC bot. All it includes is 2 functions. A test message and a quit command. I will of course be adding some more functions such as MD5 hasher, google search and more..
  • Xin
    Posts: 3,251
    Sounds good! :) when its done be sure to connect it to the irc
    Xin
  • chroniccommand
    Posts: 1,389
    said:


    Sounds good! :) when its done be sure to connect it to the irc



    Will do. And of course, just PM me with extra messages / functions you would like in there.