发布时间:2019-08-28 09:10:29编辑:auto阅读(2022)
#-*- 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
50463
49755
40351
37380
31798
28660
27593
22379
22374
20680
445°
1055°
853°
796°
1041°
914°
1530°
2865°
2563°
1967°