mirror of https://github.com/MISP/misp-modules
Merge pull request #395 from SteveClement/master
chg: [deps] pyfaup seems to be required but not installedpull/402/head
commit
e981966776
10
.travis.yml
10
.travis.yml
|
@ -9,14 +9,22 @@ python:
|
||||||
- "3.6"
|
- "3.6"
|
||||||
- "3.6-dev"
|
- "3.6-dev"
|
||||||
- "3.7-dev"
|
- "3.7-dev"
|
||||||
|
- "3.8-dev"
|
||||||
|
|
||||||
before_install:
|
before_install:
|
||||||
- docker build -t misp-modules --build-arg BUILD_DATE=$(date -u +"%Y-%m-%d") docker/
|
- docker build -t misp-modules --build-arg BUILD_DATE=$(date -u +"%Y-%m-%d") docker/
|
||||||
|
|
||||||
install:
|
install:
|
||||||
- sudo apt-get install libzbar0 libzbar-dev libpoppler-cpp-dev tesseract-ocr libfuzzy-dev
|
- sudo apt-get install libzbar0 libzbar-dev libpoppler-cpp-dev tesseract-ocr libfuzzy-dev libcaca-dev liblua5.3-dev
|
||||||
- pip install pipenv
|
- pip install pipenv
|
||||||
- pipenv install --dev
|
- pipenv install --dev
|
||||||
|
# install gtcaca
|
||||||
|
- git clone git://github.com/stricaud/gtcaca.git
|
||||||
|
- mkdir -p gtcaca/build
|
||||||
|
- pushd gtcaca/build
|
||||||
|
- cmake .. && make
|
||||||
|
- sudo make install
|
||||||
|
- popd
|
||||||
# install pyfaup
|
# install pyfaup
|
||||||
- git clone https://github.com/stricaud/faup.git
|
- git clone https://github.com/stricaud/faup.git
|
||||||
- pushd faup/build
|
- pushd faup/build
|
||||||
|
|
|
@ -8,6 +8,7 @@
|
||||||
-e git+https://github.com/cartertemm/ODTReader.git/@49d6938693f6faa3ff09998f86dba551ae3a996b#egg=odtreader
|
-e git+https://github.com/cartertemm/ODTReader.git/@49d6938693f6faa3ff09998f86dba551ae3a996b#egg=odtreader
|
||||||
-e git+https://github.com/sebdraven/pydnstrails@48c1f740025c51289f43a24863d1845ff12fd21a#egg=pydnstrails
|
-e git+https://github.com/sebdraven/pydnstrails@48c1f740025c51289f43a24863d1845ff12fd21a#egg=pydnstrails
|
||||||
-e git+https://github.com/sebdraven/pyonyphe@1ce15581beebb13e841193a08a2eb6f967855fcb#egg=pyonyphe
|
-e git+https://github.com/sebdraven/pyonyphe@1ce15581beebb13e841193a08a2eb6f967855fcb#egg=pyonyphe
|
||||||
|
-e git+https://github.com/stricaud/faup.git#egg=pyfaup&subdirectory=src/lib/bindings/python
|
||||||
aiohttp==3.4.4
|
aiohttp==3.4.4
|
||||||
antlr4-python3-runtime==4.8 ; python_version >= '3'
|
antlr4-python3-runtime==4.8 ; python_version >= '3'
|
||||||
apiosintds==1.8.3
|
apiosintds==1.8.3
|
||||||
|
|
|
@ -21,8 +21,28 @@ $SUDO_WWW virtualenv -p python3 /var/www/MISP/venv
|
||||||
# END with virtualenv
|
# END with virtualenv
|
||||||
|
|
||||||
cd /usr/local/src/
|
cd /usr/local/src/
|
||||||
sudo git clone https://github.com/MISP/misp-modules.git
|
# Ideally you add your user to the staff group and make /usr/local/src group writeable, below follows an example with user misp
|
||||||
cd misp-modules
|
sudo adduser misp staff
|
||||||
|
sudo chmod 2775 /usr/local/src
|
||||||
|
sudo chown root:staff /usr/local/src
|
||||||
|
git clone https://github.com/MISP/misp-modules.git
|
||||||
|
git clone git://github.com/stricaud/faup.git faup
|
||||||
|
git clone git://github.com/stricaud/gtcaca.git gtcaca
|
||||||
|
|
||||||
|
# Install gtcaca/faup
|
||||||
|
cd gtcaca
|
||||||
|
mkdir -p build
|
||||||
|
cd build
|
||||||
|
cmake .. && make
|
||||||
|
sudo make install
|
||||||
|
cd ../../faup
|
||||||
|
mkdir -p build
|
||||||
|
cd build
|
||||||
|
cmake .. && make
|
||||||
|
sudo make install
|
||||||
|
sudo ldconfig
|
||||||
|
|
||||||
|
cd ../../misp-modules
|
||||||
|
|
||||||
# BEGIN with virtualenv:
|
# BEGIN with virtualenv:
|
||||||
$SUDO_WWW /var/www/MISP/venv/bin/pip install -I -r REQUIREMENTS
|
$SUDO_WWW /var/www/MISP/venv/bin/pip install -I -r REQUIREMENTS
|
||||||
|
@ -168,4 +188,4 @@ tar xvf misp-module-bundeled.tar.bz2 -C misp-modules-bundle
|
||||||
cd misp-modules-bundle
|
cd misp-modules-bundle
|
||||||
ls -1|while read line; do sudo pip3 install --force-reinstall --ignore-installed --upgrade --no-index --no-deps ${line};done
|
ls -1|while read line; do sudo pip3 install --force-reinstall --ignore-installed --upgrade --no-index --no-deps ${line};done
|
||||||
~~~
|
~~~
|
||||||
Next you can follow standard install procedure.
|
Next you can follow standard install procedure.
|
||||||
|
|
|
@ -73,9 +73,9 @@ def handler(q=False):
|
||||||
do_not_include_vmrayjobids = request["config"].get("do_not_include_vmrayjobids")
|
do_not_include_vmrayjobids = request["config"].get("do_not_include_vmrayjobids")
|
||||||
|
|
||||||
try:
|
try:
|
||||||
shareable = bool(strtobool(shareable)) # Do we want the sample to be shared?
|
shareable = bool(strtobool(shareable)) # Do we want the sample to be shared?
|
||||||
reanalyze = not bool(strtobool(do_not_reanalyze)) # Always reanalyze the sample?
|
reanalyze = not bool(strtobool(do_not_reanalyze)) # Always reanalyze the sample?
|
||||||
include_vmrayjobids = not bool(strtobool(do_not_include_vmrayjobids)) # Include the references to VMRay job IDs
|
include_vmrayjobids = not bool(strtobool(do_not_include_vmrayjobids)) # Include the references to VMRay job IDs
|
||||||
except ValueError:
|
except ValueError:
|
||||||
misperrors["error"] = "Error while processing settings. Please double-check your values."
|
misperrors["error"] = "Error while processing settings. Please double-check your values."
|
||||||
return misperrors
|
return misperrors
|
||||||
|
|
|
@ -105,9 +105,10 @@ class TestExpansions(unittest.TestCase):
|
||||||
query = {"module": "btc_steroids", "btc": "1ES14c7qLb5CYhLMUekctxLgc1FV2Ti9DA"}
|
query = {"module": "btc_steroids", "btc": "1ES14c7qLb5CYhLMUekctxLgc1FV2Ti9DA"}
|
||||||
response = self.misp_modules_post(query)
|
response = self.misp_modules_post(query)
|
||||||
try:
|
try:
|
||||||
self.assertTrue(self.get_values(response).startswith('\n\nAddress:\t1ES14c7qLb5CYhLMUekctxLgc1FV2Ti9DA\nBalance:\t0.0000000000 BTC (+0.0005355700 BTC / -0.0005355700 BTC)'))
|
self.assertTrue(self.get_values(response).startswith('\n\nAddress:\t1ES14c7qLb5CYhLMUekctxLgc1FV2Ti9DA\nBalance:\t0.0002126800 BTC (+0.0007482500 BTC / -0.0005355700 BTC)'))
|
||||||
|
|
||||||
except Exception:
|
except Exception:
|
||||||
self.assertEqual(self.get_values(response), 'Not a valid BTC address')
|
self.assertEqual(self.get_values(response), 'Not a valid BTC address, or Balance has changed')
|
||||||
|
|
||||||
def test_btc_scam_check(self):
|
def test_btc_scam_check(self):
|
||||||
query = {"module": "btc_scam_check", "btc": "1ES14c7qLb5CYhLMUekctxLgc1FV2Ti9DA"}
|
query = {"module": "btc_scam_check", "btc": "1ES14c7qLb5CYhLMUekctxLgc1FV2Ti9DA"}
|
||||||
|
|
Loading…
Reference in New Issue