Analysis Correlation Engine (ACE) API Python Bindings.
Project description
# Python Bindings for ACE REST API
## Examples
### Connect to a Server
Setting the default remote host:
>>> import ace_api>>> server = 'ace.integraldefense.com'>>> ace_api.set_default_remote_host(server)>>> ace_api.ping() {'result': 'pong'}
Setting the remote host for an Analysis class:
>>> analysis = ace_api.Analysis('this is the analysis description')>>> analysis.set_remote_host('something.else.com').remote_host 'something.else.com'
If your ACE instance is listening on a port other than 443, specify it like so:
>>> ace_api.set_default_remote_host('ace.integraldefense.com:24443') >>> ace_api.default_remote_host 'ace.integraldefense.com:24443'
### Submit a File to ACE
>>> path_to_file = 'Business.doc'>>> analysis.add_file(path_to_file) <ace_api.Analysis object at 0x7f23d57e74e0>>>> analysis.add_tag('Business.doc').add_tag('suspicious doc') <ace_api.Analysis object at 0x7f23d57e74e0>>>> analysis.submit() <ace_api.Analysis object at 0x7f23d57e74e0>>>> analysis.status 'NEW'>>> analysis.status 'ANALYZING'>>> analysis.status 'COMPLETE (Alerted with 8 detections)'>>> result_url = 'https://{}/ace/analysis?direct={}'.format(analysis.remote_host, analysis.uuid)>>> print("\nThe results of this submission can be viewed here: {}".format(result_url))
The results of this submission can be viewed here: https://ace.integraldefense.com/ace/analysis?direct=137842ac-9d53-4a25-8066-ad2a1f6cfa17
### Submit a URL to Cloudphish
>>> another_url = 'http://medicci.ru/myATT/tu8794_QcbkoEsv_Xw20pYh7ij'>>> cp_result = ace_api.cloudphish_submit(another_url)>>> cp_result['status'] 'NEW'>>> # Query again, a moment later: ... >>> cp_result = ace_api.cloudphish_submit(another_url)>>> cp_result['status'] 'ANALYZED'>>> cp_result['analysis_result'] 'ALERT'>>> result_url = 'https://{}/ace/analysis?direct={}'.format(ace_api.default_remote_host, cp_result['uuid'])>>> print("\nThe results of this submission can be viewed here: {}".format(result_url))
The results of this submission can be viewed here: https://ace.integraldefense.com/ace/analysis?direct=732ec396-ce20-463f-82b0-6b043b07f941
## Documentation
ACE’s API documentation:
View ACE’s full documentation here: [https://ace-analysis.readthedocs.io/en/latest/](https://ace-analysis.readthedocs.io/en/latest/)
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
File details
Details for the file ace_api-1.0.5.tar.gz
.
File metadata
- Download URL: ace_api-1.0.5.tar.gz
- Upload date:
- Size: 15.8 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/1.12.1 pkginfo/1.5.0.1 requests/2.21.0 setuptools/39.0.1 requests-toolbelt/0.9.1 tqdm/4.30.0 CPython/3.6.6
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 7ea0e93e395383990350a37b1f0beebdadbef1b932a23a8b64e329485a851446 |
|
MD5 | 439cf148e81f8a4709a0141f90258d22 |
|
BLAKE2b-256 | 694f5f975763623f59f37f0087e0f2e6381a88a3e3534d19c77384df26f5d535 |
File details
Details for the file ace_api-1.0.5-py3-none-any.whl
.
File metadata
- Download URL: ace_api-1.0.5-py3-none-any.whl
- Upload date:
- Size: 17.3 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/1.12.1 pkginfo/1.5.0.1 requests/2.21.0 setuptools/39.0.1 requests-toolbelt/0.9.1 tqdm/4.30.0 CPython/3.6.6
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 87fc5ad284ef89f78b6a9851fdfff1dcdc635389490cc4f2491b52f64b0c202d |
|
MD5 | 55fcafb6be20247d28cbf89c8e505415 |
|
BLAKE2b-256 | 27ba7083bb863184ce7633767340c28765783cb9d9ce8d52c8e8c44d8b8a6722 |