def setFootprintInfo(self, _db, _footprintID, _footprintName, _doWork, _footprintOptions): self.db = _db self.footprintID = _footprintID self.footprintName = _footprintName self.doWork = _doWork self.options = _footprintOptions dbfunctions.setMsfPass(self.db, self.footprintID, "")
def startMetasploittest(db, footprint_id): p = subprocess.Popen('msfrpcd -U msf -P abc123 -f -a 127.0.0.1 -p 55552 -S'.split(), stdout=subprocess.PIPE, stderr=subprocess.STDOUT) while(True): retcode = p.poll() line = p.stdout.readline() if line.find("MSGRPC starting") != -1: time.sleep(3) print "metasploit rpc interface started" dbfunctions.setMsfPass(db, footprint_id, "abc123")
def startMetasploittest(db, footprint_id): p = subprocess.Popen( 'msfrpcd -U msf -P abc123 -f -a 127.0.0.1 -p 55552 -S'.split(), stdout=subprocess.PIPE, stderr=subprocess.STDOUT) while (True): retcode = p.poll() line = p.stdout.readline() if line.find("MSGRPC starting") != -1: time.sleep(3) print "metasploit rpc interface started" dbfunctions.setMsfPass(db, footprint_id, "abc123")
def startMetasploit(db, footprint_id): p = subprocess.Popen('msfconsole -p msgrpc'.split(), stdout=subprocess.PIPE, stderr=subprocess.STDOUT) while(True): retcode = p.poll() line = p.stdout.readline() if line.find("MSGRPC Password") != -1: passwd = line[:-1].split(' ')[3] print "msfrpc started. password is {0}".format(passwd) time.sleep(5) dbfunctions.setMsfPass(db, footprint_id, passwd) if(retcode is not None): break
def startMetasploit(db, footprint_id): p = subprocess.Popen('msfconsole -p msgrpc'.split(), stdout=subprocess.PIPE, stderr=subprocess.STDOUT) while (True): retcode = p.poll() line = p.stdout.readline() if line.find("MSGRPC Password") != -1: passwd = line[:-1].split(' ')[3] print "msfrpc started. password is {0}".format(passwd) time.sleep(5) dbfunctions.setMsfPass(db, footprint_id, passwd) if (retcode is not None): break