资源简介
绿盟web安全漏洞扫描器管理客户端,批量下发任务、导出报告,适用于绿盟漏洞扫描器
Python的脚本(运行环境Python)。
Python的脚本(运行环境Python)。
代码片段和文件信息
# -*- coding: utf-8 -*-
‘‘‘
程序设置
@author:
‘‘‘
import json
# import os.path
class AppSettings(object):
‘‘‘程序设置类‘‘‘
@property
def filePath(self):
return ‘appsetting.settings‘
@property
def Templates(self):
‘‘‘任务模板列表‘‘‘
return self._settings[‘Templates‘]
@Templates.setter
def Templates(self value):
if not isinstance(value dict):
raise TypeError(‘Need a dict‘)
self._settings[‘Templates‘] = value
@property
def Connections(self):
‘‘‘连接信息列表‘‘‘
return self._settings[‘Connections‘]
@Connections.setter
def Connections(self value):
if not isinstance(value dict):
raise TypeError(‘Need a dict‘)
self._settings[‘Connections‘] = value
def __init__(self):
‘‘‘‘‘‘
self._settings = {‘Connections‘: {} ‘Templates‘: {}}
self.load()
def load(self):
‘‘‘加载设置‘‘‘
try:
of = open(self.filePath ‘r‘ encoding=‘utf-8‘)
settings = json.load(of)
of.close()
if settings:
self._settings = settings
except:
pass
def save(self):
‘‘‘保存程序设置到文件‘‘‘
of = open(self.filePath ‘w‘ encoding=‘utf-8‘)
json.dump(self._settings of)
of.close()
属性 大小 日期 时间 名称
----------- --------- ---------- ----- ----
.CA.... 1460 2016-02-17 13:51 绿盟客户端\appsettings.py
.CA.... 25325 2016-08-09 16:22 绿盟客户端\databa
.CA.... 2090676 2016-03-11 16:19 绿盟客户端\jone_rc.py
.CA.... 269094 2016-03-11 16:13 绿盟客户端\log.ico
.CA.... 6779 2016-08-16 14:38 绿盟客户端\models.py
.CA.... 37514 2016-07-25 11:20 绿盟客户端\Nsfocus\rsas6helper.py
.CA.... 33679 2016-08-01 10:33 绿盟客户端\Nsfocus\rsas6_curl.py
.CA.... 151 2016-02-17 13:51 绿盟客户端\Nsfocus\__init__.py
.CA.... 415 2017-06-26 10:51 绿盟客户端\README.md
.CA.... 9505 2016-08-22 18:09 绿盟客户端\rsashelper3.py
.CA.... 830 2016-03-11 16:26 绿盟客户端\setuppy2exe.py
.CA.... 3409 2016-06-02 09:18 绿盟客户端\UI\advanceexecutedialog.py
.CA.... 6106 2016-02-17 13:51 绿盟客户端\UI\connectioneditdialog.py
.CA.... 10096 2016-02-18 15:01 绿盟客户端\UI\createtaskdialog.py
.CA.... 3172 2016-03-11 10:55 绿盟客户端\UI\devicemanagementdialog.py
.CA.... 4735 2016-02-24 13:54 绿盟客户端\UI\edittaskinfodialog.py
.CA.... 8899 2016-03-02 09:17 绿盟客户端\UI\exportreportdialog.py
.CA.... 3471 2016-03-02 09:17 绿盟客户端\UI\logindialog.py
.CA.... 12431 2016-06-16 15:12 绿盟客户端\UI\mainwindow.py
.CA.... 11862 2016-03-03 12:45 绿盟客户端\UI\preferenceswindow.py
.CA.... 5612 2016-06-01 15:29 绿盟客户端\UI\scheduledtasksexecutetypedialog.py
.CA.... 2209 2016-06-01 15:29 绿盟客户端\UI\scheduledtasksmanagementdialog.py
.CA.... 3375 2016-06-16 15:14 绿盟客户端\UI\taskmanagedialog.py
.CA.... 57829 2016-06-01 15:31 绿盟客户端\UI\tasktemplatedialog.py
.CA.... 0 2016-02-17 13:51 绿盟客户端\UI\__init__.py
.CA.... 3674 2016-02-22 11:36 绿盟客户端\UI\__pycache__\connectioneditdialog.cpython-34.pyc
.CA.... 5647 2016-02-22 11:36 绿盟客户端\UI\__pycache__\createtaskdialog.cpython-34.pyc
.CA.... 2270 2016-03-11 10:56 绿盟客户端\UI\__pycache__\devicemanagementdialog.cpython-34.pyc
.CA.... 2965 2016-02-24 13:54 绿盟客户端\UI\__pycache__\edittaskinfodialog.cpython-34.pyc
.CA.... 5033 2016-03-02 09:17 绿盟客户端\UI\__pycache__\exportreportdialog.cpython-34.pyc
............此处省略27个文件信息
评论
共有 条评论