发布时间:2019-08-28 09:10:29编辑:auto阅读(1966)
#-*- coding:utf-8 -*- import os import sys if len(sys.argv) == 2: filename=sys.argv[1] if not os.path.isfile(filename): print '[-]' + filename + 'does not exist.' exit(0) if not os.access(filename, os.R_OK): print '[-]' + filename + 'access denied.' exit(0) print '[+] reading vulnerabilities from : ' + filename
执行结果:第一个是不存在的文件,第二个是存在且有权限的文件
上一篇: python学习:Indentation
下一篇: CentOS 6.4 安装python2
49365
48557
39256
36340
30755
27566
26562
21381
21238
19585
225°
461°
449°
548°
893°
617°
1291°
1419°
1222°
1209°