1
0
Fork 0
mirror of https://github.com/pavel-odintsov/fastnetmon synced 2024-05-27 13:06:13 +02:00

change A10 TPS to A10 Thunder TPS, added sample test outputs

This commit is contained in:
Eric Chou 2016-07-27 16:47:38 -07:00
parent 13e112f239
commit 5b8575f6ef
3 changed files with 57 additions and 10 deletions

View File

@ -1,14 +1,14 @@
Fastnetmon Plugin: A10 Networks TPS AXAPIv3 integration for FastNetMon
Fastnetmon Plugin: A10 Networks Thunder TPS Appliance AXAPIv3 integration for FastNetMon
This script connect to A10 TPS device to create Protected Object and announce BGP route toward upstream router upon FastNetMon ban detection.
This script connect to A10 Thunder TPS Appliance to create Protected Object and announce BGP route toward upstream router upon FastNetMon ban detection.
1. Place both Python files at a directory that is reachable by FastNetMon
2. Make sure both scripts are executable, i.e. "chmod +x a10.py fastnetmon_a10_v0.2.py"
3. Modify fastnetmon.conf for notification, i.e. notify_script_path = <path>/fastnetmon_a10_v0.2.py
1. Indicate the fastnetmon_a10_xx.py script as the executed script under /etc/fastnetmon.conf, i.e. notify_script_path=<path>/fastnetmon_a10_v0.2.py.
1a. Alternatively, place all files in a directory that is reachable by FastNetMon and indicate it as the executed script in /etc/fastnetmon.conf.
2. Make sure both Python scripts are executable, i.e. "chmod +x a10.py fastnetmon_a10_v0.2.py"
Please modify the following:
1. A10 mitigator IP
1. A10 Thunder TPS mitigator IP
2. BGP Autonomous System Number
3. Username and Password for your A10 Device. Note that you can use your own password vault or protection schema
@ -18,9 +18,9 @@ https://www.a10networks.com/resources/glossary/axapi-custom-management
v0.2 - Jul 7th, 2016 - initial commit
Author: Eric Chou ericc@a10networks.com
Author: Eric Chou ericc@a10networks.com, Rich Groves rgroves@a10networks.com
Feedback and Feature Requests are Welcomed.
Feedback and Feature Requests are Appreciated and Welcomed.
Example Usage:

View File

@ -1,8 +1,8 @@
#!/usr/bin/python
#
# v0.2 created [ban | unban] [on ramp | off ramp action] for A10 TPS
# v0.3 offload URI path and json_body into separate json_config files
# v0.1 created [ban | unban] [on ramp | off ramp action] for A10 TPS
# v0.2 offload URI path and json_body into separate json_config files
# Eric Chou (ericc@a10networks.com)
#

View File

@ -0,0 +1,47 @@
##Sample Test Output
```
echou@a10-ubuntu3:~/fastnetmon/src/a10_plugin/tests$ python helperTests.py
Testing GET
{
"version": {
"oper" : {
"hw-platform":"TH4435 TPS",
"copyright":"Copyright 2007-2014 by A10 Networks, Inc.",
"sw-version":"3.2.1 build 175 (May-17-2016,16:57)",
"plat-features":"",
"boot-from":"HD_PRIMARY",
"serial-number":"<skip?",
"firmware-version":"5.6",
"hd-pri":"3.2.1.175",
"hd-sec":"3.2.1-SP2.4",
"cf-pri":"3.0.0.419",
"cf-sec":"",
"last-config-saved-time":"Jul-26-2016, 10:56",
"virtualization-type":"NA",
"hw-code":"<skip>",
"current-time":"Jul-27-2016, 09:46",
"up-time":"70 days, 22 hours, 44 minutes"
},
"a10-url":"/axapi/v3/version/oper"
}
}
Testing POST
{
"hostname": {
"value":"TH4435",
"uuid":"<skip>",
"a10-url":"/axapi/v3/hostname"
}
}
.Testing axapi_auth
('base url: ', 'https://192.168.199.152', 'Signature: ', u'0855fef4da06d7beb89b27e7d2d042')
.
----------------------------------------------------------------------
Ran 2 tests in 0.092s
OK
echou@a10-ubuntu3:~/fastnetmon/src/a10_plugin/tests$
```