al0ne / Vxscan

python3写的综合扫描工具,主要用来存活验证,敏感文件探测(目录扫描/js泄露接口/html注释泄露),WAF/CDN识别,端口扫描,指纹/服务识别,操作系统识别,POC扫描,SQL注入,绕过CDN,查询旁站等功能,主要用来甲方自测或乙方授权测试,请勿用来搞破坏。
Apache License 2.0
1.74k stars 441 forks source link

Undefined names in pyh.py #3

Closed cclauss closed 5 years ago

cclauss commented 5 years ago

flake8 testing of https://github.com/al0ne/Vxscan on Python 3.7.1

$ flake8 . --count --select=E9,F63,F72,F82 --show-source --statistics

./lib/pyh.py:143:11: F821 undefined name 'a'
    out = a(img(src='http://www.w3.org/Icons/valid-xhtml10',
          ^
./lib/pyh.py:143:13: F821 undefined name 'img'
    out = a(img(src='http://www.w3.org/Icons/valid-xhtml10',
            ^
./lib/pyh.py:152:17: F821 undefined name 'head'
        self += head()
                ^
./lib/pyh.py:153:17: F821 undefined name 'body'
        self += body()
                ^
./lib/pyh.py:155:22: F821 undefined name 'title'
        self.head += title(name)
                     ^
./lib/pyh.py:158:28: F821 undefined name 'head'
        if isinstance(obj, head) or isinstance(obj, body):
                           ^
./lib/pyh.py:158:53: F821 undefined name 'body'
        if isinstance(obj, head) or isinstance(obj, body):
                                                    ^
./lib/pyh.py:160:30: F821 undefined name 'meta'
        elif isinstance(obj, meta) or isinstance(obj, link):
                             ^
./lib/pyh.py:160:55: F821 undefined name 'link'
        elif isinstance(obj, meta) or isinstance(obj, link):
                                                      ^
./lib/pyh.py:170:26: F821 undefined name 'script'
            self.head += script(type='text/javascript', src=f)
                         ^
./lib/pyh.py:174:26: F821 undefined name 'link'
            self.head += link(rel='stylesheet', type='text/css', href=f)
                         ^
./lib/pyh.py:181:26: F821 undefined name 'style'
            self.head += style(txt, type="text/css")
                         ^
./lib/pyh.py:187:26: F821 undefined name 'script'
            self.head += script(txt, type="text/javascript")
                         ^
./script/solr_unauthorized_access.py:28:16: F632 use ==/!= to compare str, bytes, and int literals
            if g.status_code is 200 and 'Solr Admin' in g.content and 'Dashboard' in g.content:
               ^
1     F632 use ==/!= to compare str, bytes, and int literals
13    F821 undefined name 'a'
14

E901,E999,F821,F822,F823 are the "showstopper" flake8 issues that can halt the runtime with a SyntaxError, NameError, etc. These 5 are different from most other flake8 issues which are merely "style violations" -- useful for readability but they do not effect runtime safety.