utkusen / leviathan

wide range mass audit toolkit
GNU General Public License v3.0
988 stars 235 forks source link

Seven undefined name errors #13

Open cclauss opened 7 years ago

cclauss commented 7 years ago

flake8 testing of https://github.com/leviathan-framework/leviathan on Python 2.7.13

$ flake8 . --count --select=E901,E999,F821,F822,F823 --show-source --statistics

./lib/brute_forcer.py:87:17: F821 undefined name 'cracked_list'
                cracked_list.append(ip+" "+username+" "+password)
                ^

./lib/brute_forcer.py:88:72: F821 undefined name 'discovery_id'
                ncrack_file_name = "ncrack_%s_%s.txt" % (protocol, str(discovery_id))
                                                                       ^

./lib/utils.py:149:45: F821 undefined name 'output_file'
        print "There is no such file: %s" % output_file
                                            ^

./lib/utils.py:173:45: F821 undefined name 'output_file'
        print "There is no such file: %s" % output_file
                                            ^

./lib/utils.py:189:45: F821 undefined name 'output_file'
        print "There is no such file: %s" % output_file
                                            ^

./lib/exploits/detect_doublepulsar_rdp.py:137:39: F821 undefined name 'ip'
                successful_ips.append(ip)
                                      ^

./lib/exploits/detect_doublepulsar_smb.py:162:39: F821 undefined name 'ip'
                successful_ips.append(ip)
                                      ^
utkusen commented 7 years ago

thanks for the testing. however, I believe they are false positives, I couldn't reproduce any of them.

cclauss commented 7 years ago

Perhaps your test cases do not execute the lines in question. If those lines are executed, they will throw the exceptions indicated.