mirror of https://github.com/MISP/MISP
Example file on how to get the exported IDS data from MISP
parent
1ede687c63
commit
f36304e635
Binary file not shown.
|
@ -0,0 +1,23 @@
|
|||
#!/usr/bin/python
|
||||
|
||||
'''
|
||||
Example file on how to get the exported IDS data from MISP
|
||||
|
||||
Add your API key, set the MISP host and define the output file.
|
||||
'''
|
||||
|
||||
import urllib2
|
||||
|
||||
MISP_HOST="http:/"
|
||||
API_KEY=""
|
||||
EXPORT_DATA="events/nids/suricata/download"
|
||||
OUTPUT_FILE="misp-suricata"
|
||||
|
||||
URL="%s/%s" % (MISP_HOST, EXPORT_DATA)
|
||||
request = urllib2.Request(URL)
|
||||
f = open(OUTPUT_FILE,'w')
|
||||
request.add_header('Authorization', API_KEY)
|
||||
data = urllib2.urlopen(request).read()
|
||||
f.write(data)
|
||||
f.close()
|
||||
|
Loading…
Reference in New Issue