(self, hashes)
Run john against a list of cached hashes
Run john against a list of cached hashes
Run john against a list of cached hashes
def call_john(self, hashes):
        """Run john against a list of cached hashes"""

        wordlist = args.wordlist

        temp = self.get_junkfile()
        for curr_hash in hashes:
            temp.write(curr_hash + '\n')
        temp.close()

        outfile = self.get_outfile(suffix='john')
        junkfile = self.get_junkfile()

        # Spawn hashcat
        command = ['john', '--format=mscash2', 
                           '--wordlist={}'.format(wordlist), 
                           '--pot={}'.format(outfile.name), temp.name,
                           '--session={}'.format(junkfile)] # Sesssion necessary to run multiple johns
        self.john_counter += 1
        verbose(' '.join([str(x) for x in command]))
        verbose("John command: {}".format([str(x) for x in command]))
        res = subprocess.Popen(command, stdout=subprocess.PIPE, stderr=subprocess.PIPE)
def call_john ( self , hashes ) : wordlist = args . wordlist temp = self . get_junkfile ( ) for curr_hash in hashes : temp . write ( curr_hash + '\n' ) temp . close ( ) outfile = self . get_outfile ( suffix = 'john' ) junkfile = self . get_junkfile ( ) # Spawn hashcat command = [ 'john' , '--format=mscash2' , '--wordlist={}' . format ( wordlist ) , '--pot={}' . format ( outfile . name ) , temp . name , '--session={}' . format ( junkfile ) ] # Sesssion necessary to run multiple johns self . john_counter += 1 verbose ( ' ' . join ( [ str ( x ) for x in command ] ) ) verbose ( "John command: {}" . format ( [ str ( x ) for x in command ] ) ) res = subprocess . Popen ( command , stdout = subprocess . PIPE , stderr = subprocess . PIPE )