Hi,
I just set this up and got it working.
In the python script, the authentication username and password fields are in the line: response = requests.post(url, headers=headers, data=payload, auth=('username', 'password'), verify=False)
I also had to copy appIcon.png to thehive_logo_small.png under etc/apps/create_thehive_alert/appserver/static/ to fix the icon.
For my purposes, I did not have a good unique value for the sourceref. I then replaced that section of the python script.
I added imports for "random" and "string"
e.g. "import os, sys, json, gzip, csv, requests, random, string"
Then I added:
from random import *
min_char = 8
max_char = 8
allchar = string.ascii_letters + string.digits
sourceRef = "".join(choice(allchar) for x in range(randint(min_char, max_char))) #add random 8 character sourceRef
And commented out the "sourceRef = id"
I hope that helps
Cheers
Craig
... View more