84 lines
2.3 KiB
Plaintext
84 lines
2.3 KiB
Plaintext
async def get_firewall_protocol(ns={}):
|
|
return {
|
|
'status': True,
|
|
'msg': 'get firewall protocol success',
|
|
'data': {
|
|
'base_protocol': [
|
|
{
|
|
'label': '指定端口TCP',
|
|
'value': 'TCP',
|
|
'port': ''
|
|
},
|
|
{
|
|
'label': '指定端口UDP',
|
|
'value': 'UDP',
|
|
'port': ''
|
|
},
|
|
{
|
|
'label': '全端口TCP',
|
|
'value': 'TCP',
|
|
'port': '1-65535'
|
|
},
|
|
{
|
|
'label': '全端口UDP',
|
|
'value': 'UDP',
|
|
'port': '1-65535'
|
|
},
|
|
{
|
|
'label': 'GRE',
|
|
'value': 'GRE',
|
|
'port': '1-65535'
|
|
},
|
|
{
|
|
'label': 'ICMP',
|
|
'value': 'ICMP',
|
|
'port': '1-65535'
|
|
},
|
|
],
|
|
'quick_rules': [
|
|
{
|
|
'label': 'FTP',
|
|
'value': 'TCP',
|
|
'port': '21'
|
|
},
|
|
{
|
|
'label': 'HTTP',
|
|
'value': 'TCP',
|
|
'port': '80'
|
|
},
|
|
{
|
|
'label': 'HTTPS',
|
|
'value': 'TCP',
|
|
'port': '443'
|
|
},
|
|
{
|
|
'label': 'PING',
|
|
'value': 'ICMP',
|
|
'port': '/'
|
|
},
|
|
{
|
|
'label': 'OpenVPN',
|
|
'value': 'UDP',
|
|
'port': '1194'
|
|
},
|
|
{
|
|
'label': 'PPTP',
|
|
'value': 'TCP',
|
|
'port': '1723'
|
|
},
|
|
{
|
|
'label': 'RDP',
|
|
'value': 'TCP',
|
|
'port': '3389'
|
|
},
|
|
{
|
|
'label': 'SSH',
|
|
'value': 'TCP',
|
|
'port': '22'
|
|
},
|
|
]
|
|
}
|
|
}
|
|
|
|
ret = await get_firewall_protocol(params_kw)
|
|
return ret |