2014-08-06 11:43:40 +02:00
|
|
|
#!/bin/bash
|
|
|
|
|
|
|
|
set -e
|
|
|
|
|
2019-05-01 13:49:07 +02:00
|
|
|
wget -q http://dygraphs.com/dygraph-combined.js -O ./static/js/dygraph-combined.js
|
2014-08-06 11:43:40 +02:00
|
|
|
|
2016-09-15 21:14:55 +02:00
|
|
|
SBADMIN_VERSION='3.3.7'
|
2019-02-05 17:16:44 +01:00
|
|
|
BOOTSTRAP_VERSION='4.2.1'
|
2019-02-08 17:16:58 +01:00
|
|
|
FONT_AWESOME_VERSION='5.7.1'
|
2018-06-29 15:52:13 +02:00
|
|
|
D3_JS_VERSION='5.5.0'
|
2014-08-06 11:43:40 +02:00
|
|
|
|
|
|
|
rm -rf temp
|
|
|
|
mkdir temp
|
|
|
|
|
2019-05-01 13:49:07 +02:00
|
|
|
wget -q https://github.com/twbs/bootstrap/releases/download/v${BOOTSTRAP_VERSION}/bootstrap-${BOOTSTRAP_VERSION}-dist.zip -O temp/bootstrap${BOOTSTRAP_VERSION}.zip
|
|
|
|
wget -q https://github.com/BlackrockDigital/startbootstrap-sb-admin/archive/v${SBADMIN_VERSION}.zip -O temp/${SBADMIN_VERSION}.zip
|
|
|
|
wget -q https://github.com/BlackrockDigital/startbootstrap-sb-admin-2/archive/v${SBADMIN_VERSION}.zip -O temp/${SBADMIN_VERSION}-2.zip
|
|
|
|
wget -q https://github.com/FortAwesome/Font-Awesome/archive/v4.7.0.zip -O temp/FONT_AWESOME_4.7.0.zip
|
|
|
|
wget -q https://github.com/FortAwesome/Font-Awesome/archive/5.7.1.zip -O temp/FONT_AWESOME_${FONT_AWESOME_VERSION}.zip
|
|
|
|
wget -q https://github.com/d3/d3/releases/download/v${D3_JS_VERSION}/d3.zip -O temp/d3_${D3_JS_VERSION}.zip
|
2018-07-05 13:58:40 +02:00
|
|
|
|
|
|
|
# dateRangePicker
|
2020-03-04 15:12:32 +01:00
|
|
|
wget -q https://github.com/moment/moment/archive/2.24.0.zip -O temp/moment.zip
|
|
|
|
wget -q https://github.com/longbill/jquery-date-range-picker/archive/v0.20.0.zip -O temp/daterangepicker.zip
|
2018-07-05 13:58:40 +02:00
|
|
|
|
2019-05-01 13:49:07 +02:00
|
|
|
unzip -qq temp/bootstrap${BOOTSTRAP_VERSION}.zip -d temp/
|
|
|
|
unzip -qq temp/${SBADMIN_VERSION}.zip -d temp/
|
|
|
|
unzip -qq temp/${SBADMIN_VERSION}-2.zip -d temp/
|
|
|
|
unzip -qq temp/FONT_AWESOME_4.7.0.zip -d temp/
|
|
|
|
unzip -qq temp/FONT_AWESOME_${FONT_AWESOME_VERSION}.zip -d temp/
|
|
|
|
unzip -qq temp/d3_${D3_JS_VERSION}.zip -d temp/
|
2018-07-05 13:58:40 +02:00
|
|
|
|
2020-03-04 15:12:32 +01:00
|
|
|
unzip -qq temp/moment.zip -d temp/
|
|
|
|
unzip -qq temp/daterangepicker.zip -d temp/
|
2018-07-05 13:58:40 +02:00
|
|
|
|
2019-02-07 17:22:44 +01:00
|
|
|
mv temp/bootstrap-${BOOTSTRAP_VERSION}-dist/js/bootstrap.min.js ./static/js/bootstrap4.min.js
|
2019-02-15 17:00:07 +01:00
|
|
|
mv temp/bootstrap-${BOOTSTRAP_VERSION}-dist/js/bootstrap.min.js.map ./static/js/bootstrap.min.js.map
|
2019-02-07 17:22:44 +01:00
|
|
|
mv temp/bootstrap-${BOOTSTRAP_VERSION}-dist/css/bootstrap.min.css ./static/css/bootstrap4.min.css
|
|
|
|
mv temp/bootstrap-${BOOTSTRAP_VERSION}-dist/css/bootstrap.min.css.map ./static/css/bootstrap4.min.css.map
|
2019-02-05 17:16:44 +01:00
|
|
|
|
2016-09-15 21:14:55 +02:00
|
|
|
mv temp/startbootstrap-sb-admin-${SBADMIN_VERSION} temp/sb-admin
|
|
|
|
mv temp/startbootstrap-sb-admin-2-${SBADMIN_VERSION} temp/sb-admin-2
|
2019-02-08 17:16:58 +01:00
|
|
|
mv temp/Font-Awesome-4.7.0 temp/font-awesome
|
|
|
|
|
2019-02-19 11:56:08 +01:00
|
|
|
rm -rf ./static/webfonts/
|
2019-02-08 17:16:58 +01:00
|
|
|
mv temp/Font-Awesome-${FONT_AWESOME_VERSION}/css/all.min.css ./static/css/font-awesome.min.css
|
|
|
|
mv temp/Font-Awesome-${FONT_AWESOME_VERSION}/webfonts ./static/webfonts
|
2016-07-20 14:11:39 +02:00
|
|
|
|
|
|
|
rm -rf ./static/js/plugins
|
2016-09-15 21:14:55 +02:00
|
|
|
mv temp/sb-admin/js/* ./static/js/
|
2016-07-20 14:11:39 +02:00
|
|
|
|
|
|
|
rm -rf ./static/fonts/ ./static/font-awesome/
|
2016-09-15 21:14:55 +02:00
|
|
|
mv temp/sb-admin/fonts/ ./static/
|
2018-05-31 10:07:23 +02:00
|
|
|
mv temp/font-awesome/ ./static/
|
2016-07-20 14:11:39 +02:00
|
|
|
|
|
|
|
rm -rf ./static/css/plugins/
|
2016-09-15 21:14:55 +02:00
|
|
|
mv temp/sb-admin/css/* ./static/css/
|
|
|
|
mv temp/sb-admin-2/dist/css/* ./static/css/
|
2020-03-04 15:12:32 +01:00
|
|
|
mv temp/jquery-date-range-picker-0.20.0/dist/daterangepicker.min.css ./static/css/
|
2016-07-20 14:11:39 +02:00
|
|
|
|
2018-06-29 15:52:13 +02:00
|
|
|
mv temp/d3.min.js ./static/js/
|
2020-03-04 15:12:32 +01:00
|
|
|
mv temp/moment-2.24.0/min/moment.min.js ./static/js/
|
|
|
|
mv temp/jquery-date-range-picker-0.20.0/dist/jquery.daterangepicker.min.js ./static/js/
|
2018-06-29 15:52:13 +02:00
|
|
|
|
2016-07-20 14:11:39 +02:00
|
|
|
rm -rf temp
|
2014-08-06 11:43:40 +02:00
|
|
|
|
2020-03-04 15:12:32 +01:00
|
|
|
JQVERSION="3.4.1"
|
2019-05-01 13:49:07 +02:00
|
|
|
wget -q http://code.jquery.com/jquery-${JQVERSION}.js -O ./static/js/jquery.js
|
2014-08-06 11:43:40 +02:00
|
|
|
|
2016-07-08 09:04:19 +02:00
|
|
|
#Ressources for dataTable
|
2020-03-04 15:12:32 +01:00
|
|
|
wget -q https://cdn.datatables.net/1.10.20/js/jquery.dataTables.min.js -O ./static/js/jquery.dataTables.min.js
|
|
|
|
wget -q https://cdn.datatables.net/plug-ins/1.10.20/integration/bootstrap/3/dataTables.bootstrap.css -O ./static/css/dataTables.bootstrap.css
|
|
|
|
wget -q https://cdn.datatables.net/plug-ins/1.10.20/integration/bootstrap/3/dataTables.bootstrap.js -O ./static/js/dataTables.bootstrap.js
|
|
|
|
|
|
|
|
wget -q https://cdn.datatables.net/1.10.20/css/dataTables.bootstrap4.min.css -O ./static/css/dataTables.bootstrap.min.css
|
|
|
|
wget -q https://cdn.datatables.net/1.10.20/js/dataTables.bootstrap4.min.js -O ./static/js/dataTables.bootstrap.min.js
|
2016-07-08 09:04:19 +02:00
|
|
|
|
2020-03-04 15:12:32 +01:00
|
|
|
#Ressources for bootstrap popover
|
|
|
|
POPPER_VERSION="2.0.6"
|
|
|
|
wget -q https://unpkg.com/@popperjs/core@${POPPER_VERSION}/dist/umd/popper.min.js -O ./static/js/popper.min.js
|
|
|
|
wget -q https://unpkg.com/@popperjs/core@${POPPER_VERSION}/dist/umd/popper.min.js.map -O ./static/js/popper.min.js.map
|
2019-02-05 17:16:44 +01:00
|
|
|
|
2016-07-19 16:49:57 +02:00
|
|
|
#Ressource for graph
|
2019-05-01 13:49:07 +02:00
|
|
|
wget -q https://raw.githubusercontent.com/flot/flot/958e5fd43c6dff4bab3e1fd5cb6109df5c1e8003/jquery.flot.js -O ./static/js/jquery.flot.js
|
|
|
|
wget -q https://raw.githubusercontent.com/flot/flot/958e5fd43c6dff4bab3e1fd5cb6109df5c1e8003/jquery.flot.pie.js -O ./static/js/jquery.flot.pie.js
|
|
|
|
wget -q https://raw.githubusercontent.com/flot/flot/958e5fd43c6dff4bab3e1fd5cb6109df5c1e8003/jquery.flot.time.js -O ./static/js/jquery.flot.time.js
|
|
|
|
wget -q https://raw.githubusercontent.com/flot/flot/958e5fd43c6dff4bab3e1fd5cb6109df5c1e8003/jquery.flot.stack.js -O ./static/js/jquery.flot.stack.js
|
2016-08-17 11:04:48 +02:00
|
|
|
|
2016-08-26 11:10:39 +02:00
|
|
|
#Ressources for sparkline and canvasJS and slider
|
2019-05-01 13:49:07 +02:00
|
|
|
wget -q http://omnipotent.net/jquery.sparkline/2.1.2/jquery.sparkline.min.js -O ./static/js/jquery.sparkline.min.js
|
2016-08-26 11:10:39 +02:00
|
|
|
mkdir temp
|
2019-05-01 13:49:07 +02:00
|
|
|
wget -q http://canvasjs.com/fdm/chart/ -O temp/canvasjs.zip
|
|
|
|
unzip -qq temp/canvasjs.zip -d temp/
|
2017-12-14 11:47:11 +01:00
|
|
|
mv temp/jquery.canvasjs.min.js ./static/js/jquery.canvasjs.min.js
|
2016-08-26 11:10:39 +02:00
|
|
|
|
2020-03-04 15:12:32 +01:00
|
|
|
wget -q https://jqueryui.com/resources/download/jquery-ui-1.12.1.zip -O temp/jquery-ui.zip
|
2019-05-01 13:49:07 +02:00
|
|
|
unzip -qq temp/jquery-ui.zip -d temp/
|
2020-03-04 15:12:32 +01:00
|
|
|
mv temp/jquery-ui-1.12.1/jquery-ui.min.js ./static/js/jquery-ui.min.js
|
|
|
|
mv temp/jquery-ui-1.12.1/jquery-ui.min.css ./static/css/jquery-ui.min.css
|
2016-08-17 11:04:48 +02:00
|
|
|
rm -rf temp
|
2016-07-19 16:49:57 +02:00
|
|
|
|
2014-12-22 18:08:02 +01:00
|
|
|
mkdir -p ./static/image
|
2016-07-20 14:11:39 +02:00
|
|
|
pushd static/image
|
2019-05-01 13:49:07 +02:00
|
|
|
wget -q https://www.circl.lu/assets/images/logos/AIL.png -O AIL.png
|
2019-06-24 17:14:16 +02:00
|
|
|
wget -q https://www.circl.lu/assets/images/logos/AIL-logo.png -O AIL-logo.png
|
2016-07-20 14:11:39 +02:00
|
|
|
popd
|
2018-05-31 10:07:23 +02:00
|
|
|
|
2019-04-02 09:50:52 +02:00
|
|
|
if ! [[ -n "$AIL_HOME" ]]
|
|
|
|
then
|
|
|
|
#active virtualenv
|
|
|
|
source ./../../AILENV/bin/activate
|
|
|
|
fi
|
|
|
|
|
2018-05-31 10:07:23 +02:00
|
|
|
#Update MISP Taxonomies and Galaxies
|
2020-03-26 10:00:40 +01:00
|
|
|
python3 -m pip install git+https://github.com/MISP/PyTaxonomies --upgrade
|
2018-11-06 17:04:02 +01:00
|
|
|
python3 -m pip install git+https://github.com/MISP/PyMISPGalaxies --upgrade
|
2018-06-19 11:31:30 +02:00
|
|
|
|
|
|
|
#Update PyMISP
|
2020-02-19 16:23:19 +01:00
|
|
|
python3 -m pip install git+https://github.com/MISP/PyMISP --upgrade
|
2018-06-19 11:31:30 +02:00
|
|
|
|
|
|
|
#Update the Hive
|
2020-02-21 11:36:22 +01:00
|
|
|
python3 -m pip install thehive4py --upgrade
|