Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
145 commits
Select commit Hold shift + click to select a range
c98e24e
fix a readme typo
wULLSnpAXbWZGYDYyhWTKKspEQoaYxXyhoisqHf Oct 29, 2024
ef5a29e
Add a light dockerfile
AlyaGomaa Oct 30, 2024
701888c
dont install scikit learn in the light dockerfile
AlyaGomaa Oct 30, 2024
6f09f83
dont install yappi in the light dockerfile
AlyaGomaa Oct 30, 2024
8c4d696
dont install recommonmark in the light dockerfile
AlyaGomaa Oct 30, 2024
b246529
dont install setuptools and wheel in the light dockerfile
AlyaGomaa Oct 30, 2024
70b3536
move all the profiling logic from main to managers/profiler_manager.py
AlyaGomaa Oct 30, 2024
7a9d7f9
profiler_manager.py: delete the memory_profiler_multiproc_test()
AlyaGomaa Oct 30, 2024
3c05fab
profiler_manager.py: import viztracer and memray on demand
AlyaGomaa Oct 30, 2024
eed5fd7
move the logic of stopping the profilers to process_manager's shutdow…
AlyaGomaa Oct 30, 2024
07d7cdc
remove vistrace, memray, tqdm, setuptools and wheel from requirements…
AlyaGomaa Oct 30, 2024
558a081
update profiler unit tests
AlyaGomaa Oct 31, 2024
ccff6dd
CI: cache zeek builds
AlyaGomaa Oct 31, 2024
9c57833
unit-tests: cache apt and pip dependencies
AlyaGomaa Nov 1, 2024
4c9e7f1
unit-tests: hardcode cache keys to avoid cache miss
AlyaGomaa Nov 1, 2024
91b34de
unit-tests:use actions/setup-python@v5 for caching python dependencies
AlyaGomaa Nov 1, 2024
a0fa9b2
add apt_Dependencies file in install/ to avoid repetition of dependen…
AlyaGomaa Nov 1, 2024
42b1b14
CI: try caching /var/cache/ and /var/lib
AlyaGomaa Nov 1, 2024
24be296
CI: install python dependencies/restore from cache before running uni…
AlyaGomaa Nov 1, 2024
c73f7f6
CI: cache pip, zeek and apt dependencies in integration tests workflo…
AlyaGomaa Nov 1, 2024
f35b258
CI: unit-tests: run unit tests without installing zeek
AlyaGomaa Nov 1, 2024
1988fcd
CI: make installing slips a reusable workflow
AlyaGomaa Nov 1, 2024
cf2a88d
CI: fix a typo in install-slips-dependencies.yml
AlyaGomaa Nov 1, 2024
2a96716
CI: make hardcoded zeek repos optional variables
AlyaGomaa Nov 1, 2024
4f30789
CI: fix installing python dependencies
AlyaGomaa Nov 1, 2024
054b7c2
CI: integration-tests: fix using reusable workflow
AlyaGomaa Nov 1, 2024
f5fbfac
CI: dependencies: add missing "type" property to workflow_call
AlyaGomaa Nov 1, 2024
4a06d6c
CI: make sure integration-tests can access Zeek from the cache if it …
AlyaGomaa Nov 4, 2024
24d22d6
Merge pull request #1056 from stratosphereips/alya/reusable-workflows
AlyaGomaa Nov 4, 2024
1c88582
move all the profiling logic from main to managers/profiler_manager.py
AlyaGomaa Oct 30, 2024
79c0816
profiler_manager.py: delete the memory_profiler_multiproc_test()
AlyaGomaa Oct 30, 2024
d5f4ae1
profiler_manager.py: import viztracer and memray on demand
AlyaGomaa Oct 30, 2024
2bb024c
move the logic of stopping the profilers to process_manager's shutdow…
AlyaGomaa Oct 30, 2024
e8f2a47
remove vistrace, memray, tqdm, setuptools and wheel from requirements…
AlyaGomaa Oct 30, 2024
27dada8
update profiler unit tests
AlyaGomaa Oct 31, 2024
f7bf2fb
Merge remote-tracking branch 'origin/alya/use-on-demand-imports' into…
AlyaGomaa Nov 4, 2024
6971edd
CI: integration tests: attempt to re-install zeek to be able to resto…
AlyaGomaa Nov 4, 2024
68ac8cd
CI: integration tests: restore apt cache before attempting to restore…
AlyaGomaa Nov 4, 2024
49a8ca9
CI: integration tests: fix typo
AlyaGomaa Nov 4, 2024
397fc73
CI: integration tests: install zeek 3 times in parallel due to cache …
AlyaGomaa Nov 4, 2024
a7c0c44
Merge pull request #1054 from stratosphereips/alya/use-on-demand-imports
AlyaGomaa Nov 4, 2024
247bc24
Merge pull request #1050 from wULLSnpAXbWZGYDYyhWTKKspEQoaYxXyhoisqHf…
AlyaGomaa Nov 4, 2024
9c202ad
Add a light dockerfile
AlyaGomaa Oct 30, 2024
341ddf6
dont install scikit learn in the light dockerfile
AlyaGomaa Oct 30, 2024
d5ea841
dont install yappi in the light dockerfile
AlyaGomaa Oct 30, 2024
1021aa4
dont install recommonmark in the light dockerfile
AlyaGomaa Oct 30, 2024
f8685d3
dont install setuptools and wheel in the light dockerfile
AlyaGomaa Oct 30, 2024
420330c
Merge remote-tracking branch 'origin/alya/add_a_light_docker_image' i…
AlyaGomaa Nov 4, 2024
4ba97a1
add a light dockerfile at docker/light
AlyaGomaa Nov 4, 2024
1401536
add a list of excluded python libraries from the light docker image
AlyaGomaa Nov 4, 2024
bf183f7
docker/light: remove the optional modules from the Dockerfile
AlyaGomaa Nov 4, 2024
a2a19a9
CI: publish the light docker image on push to master
AlyaGomaa Nov 4, 2024
a236a86
installation: add the minimal slips docker image to the docs
AlyaGomaa Nov 4, 2024
97a89f9
build(deps): bump actions/cache from 3 to 4
dependabot[bot] Nov 5, 2024
e1c3bca
Merge pull request #1058 from stratosphereips/alya/add_a_light_docker…
AlyaGomaa Nov 5, 2024
2619f80
update submodules
AlyaGomaa Nov 8, 2024
5790d2f
Add reference to feel project in the README.md
AlyaGomaa Nov 8, 2024
4ba386e
improve the docs
AlyaGomaa Nov 13, 2024
1c79f2a
dns.py: check for whitelisted whitelist dst domains when detecting DGA
AlyaGomaa Nov 14, 2024
eb9edcb
Merge pull request #1059 from stratosphereips/dependabot/github_actio…
AlyaGomaa Nov 14, 2024
722b860
Merge pull request #1064 from stratosphereips/alya/fix-fp-dga
AlyaGomaa Nov 14, 2024
7675f53
conn.py: move the logic for interface timeout to its own function
AlyaGomaa Nov 14, 2024
4cb7b22
dns.py: wait 30 mins before the first "dns without conn" evidence
AlyaGomaa Nov 14, 2024
3608438
database.py: dont store slips start time in the local timezone, store…
AlyaGomaa Nov 14, 2024
f2728da
update existing and add more unit tests
AlyaGomaa Nov 14, 2024
bbefbdb
update the docs
AlyaGomaa Nov 14, 2024
fae67b2
Fix the problem of comparing timezone aware with timezone naive dates
AlyaGomaa Nov 14, 2024
2862508
update the database MAC address unit tests
AlyaGomaa Nov 14, 2024
1cb4978
Merge pull request #1065 from stratosphereips/alya/fix_domain_resolve…
AlyaGomaa Nov 14, 2024
4383948
use whois.validTlds() instead of hardcoded valid tlds
AlyaGomaa Nov 17, 2024
14b3803
Merge pull request #1067 from stratosphereips/alya/remove_hardcoded_tlds
AlyaGomaa Nov 17, 2024
1439f9a
.pre-commit-config.yaml: allow uploading of large files at config/loc…
AlyaGomaa Nov 18, 2024
5a53c3c
.pre-commit-config.yaml: add an exception for check-added-large-files…
AlyaGomaa Nov 18, 2024
dc91776
add a list of known fp hashes from https://github.com/Neo23x0/ti-fals…
AlyaGomaa Nov 18, 2024
761e842
threat_intelligence.py: add a parser for the list of known FP hashes
AlyaGomaa Nov 18, 2024
b942d72
db: add functions to store and retrieve FP hashes
AlyaGomaa Nov 18, 2024
381e35f
use md5 hashes only in known_fp_md5_hashes.csv
AlyaGomaa Nov 18, 2024
21c93b7
threat_intelligence.py: dont lookup known FP hashes
AlyaGomaa Nov 18, 2024
04d1b71
test_threat_intelligence.py: add a unit test for is_known_fp_md5_hash()
AlyaGomaa Nov 18, 2024
807fa0e
detection_modules.md: document the MD5 whitelist
AlyaGomaa Nov 18, 2024
6384354
test_threat_intelligence.py: update unit tests
AlyaGomaa Nov 18, 2024
7d5c6d4
Merge pull request #1068 from stratosphereips/alya/add_known_fps_list
AlyaGomaa Nov 18, 2024
727891f
timeline: improve detecting inbound traffic
AlyaGomaa Nov 18, 2024
86bed41
update timeline.py unit tests
AlyaGomaa Nov 18, 2024
a4ffd09
host_ip_manager.py: use the hosts's ipv6 if ipv4 isn't available
AlyaGomaa Nov 18, 2024
78d9565
Merge pull request #1069 from stratosphereips/alya/improve_inbound_tr…
AlyaGomaa Nov 19, 2024
e610ccf
Merge pull request #1071 from stratosphereips/alya/use_ipv6_host_ip_i…
AlyaGomaa Nov 19, 2024
bafebae
user lowercase function names and move hardcoded key names to constan…
AlyaGomaa Nov 19, 2024
d13019e
user lowercase function names
AlyaGomaa Nov 19, 2024
4be77ef
move the rest of redis db constants to constants.py
AlyaGomaa Nov 19, 2024
113f490
fix Changing the database from the web interface
AlyaGomaa Nov 21, 2024
3953886
db: add a function to get_malicious_profiles() for the web interface
AlyaGomaa Nov 21, 2024
6f9d686
analysis.py: use the db manager instead of the web interface's own db
AlyaGomaa Nov 21, 2024
0530973
app.py: use the db manager instead of the web interface's own db
AlyaGomaa Nov 21, 2024
cdc123c
webinterface/database.py : use the database manager instead of initia…
AlyaGomaa Nov 21, 2024
61f4393
webinterface/general.py: use db manager instead of redis directly
AlyaGomaa Nov 21, 2024
8a1edfc
db: add wrappers to be used by the web interface
AlyaGomaa Nov 21, 2024
afa686f
redis_manager.py: return all info from running_slips_info.txt from ge…
AlyaGomaa Nov 21, 2024
256d2fb
webinterface/utils.py: add a function to parse all info from running_…
AlyaGomaa Nov 21, 2024
d01b028
web interface: fix problem changing the db using the button at the to…
AlyaGomaa Nov 25, 2024
a5cf318
analysis.py: refactor
AlyaGomaa Nov 25, 2024
61ff97b
user lowercase function names and move hardcoded key names to constan…
AlyaGomaa Nov 19, 2024
61fc347
user lowercase function names
AlyaGomaa Nov 19, 2024
25d99b9
move the rest of redis db constants to constants.py
AlyaGomaa Nov 19, 2024
4936df0
fix Changing the database from the web interface
AlyaGomaa Nov 21, 2024
43afbf5
db: add a function to get_malicious_profiles() for the web interface
AlyaGomaa Nov 21, 2024
05b52bc
analysis.py: use the db manager instead of the web interface's own db
AlyaGomaa Nov 21, 2024
e8d659c
app.py: use the db manager instead of the web interface's own db
AlyaGomaa Nov 21, 2024
a5badfe
webinterface/database.py : use the database manager instead of initia…
AlyaGomaa Nov 21, 2024
28092f2
webinterface/general.py: use db manager instead of redis directly
AlyaGomaa Nov 21, 2024
7221b8c
db: add wrappers to be used by the web interface
AlyaGomaa Nov 21, 2024
bbf5662
redis_manager.py: return all info from running_slips_info.txt from ge…
AlyaGomaa Nov 21, 2024
cf595bc
webinterface/utils.py: add a function to parse all info from running_…
AlyaGomaa Nov 21, 2024
1196b02
web interface: fix problem changing the db using the button at the to…
AlyaGomaa Nov 25, 2024
bcd2912
analysis.py: refactor
AlyaGomaa Nov 25, 2024
ab42907
ioc_handler: remove trailing-whitespace
AlyaGomaa Nov 25, 2024
b3632de
update cesnet unit tests to use latest db function names
AlyaGomaa Nov 25, 2024
195f995
fix getting the used redis port
AlyaGomaa Nov 25, 2024
86f81a5
module_factory.py: set alert handler constants
AlyaGomaa Nov 25, 2024
a5a0c13
test_redis_manager.py: update unit tests
AlyaGomaa Nov 25, 2024
014a1ca
test_database.py: hardcode redis server ports
AlyaGomaa Nov 25, 2024
f513ee1
Merge pull request #1079 from stratosphereips/alya/fix_db_issues_in_t…
AlyaGomaa Nov 25, 2024
b875e04
use 0.25 as the default slips threshold
AlyaGomaa Nov 26, 2024
651fbf4
ti: fix checking FP hashes
AlyaGomaa Nov 26, 2024
8f6a5db
ip_info: cache valid tlds instead of retreiving and sorting them for …
AlyaGomaa Nov 28, 2024
e74012c
slips.yaml: update the link of the mac lookup db to the latest one av…
AlyaGomaa Nov 28, 2024
0e8d37e
set_evidence: fix trying to get sport and dport from a Files object
AlyaGomaa Nov 28, 2024
17edc51
ssl: fix setting malicious ja3s evidence
AlyaGomaa Nov 28, 2024
0f6d2d5
http: fix setting incompatible_user_agent evidence
AlyaGomaa Nov 28, 2024
1379978
asn: move the asn update period to asn.py from ip info
AlyaGomaa Nov 28, 2024
f52b6e8
ip info: set a timeout for querying macvendors.com
AlyaGomaa Nov 28, 2024
ddd926d
make ip info an async module
AlyaGomaa Nov 28, 2024
82fd2ac
ip_info: lookup mac vendors offline only if they're in the pending queue
AlyaGomaa Nov 28, 2024
fe88b62
update ip info unit tests
AlyaGomaa Nov 28, 2024
bbab4d2
tests: dont start sqlite when creating db manager object
AlyaGomaa Nov 28, 2024
18672ef
web interface: fix displaying profiles
AlyaGomaa Nov 28, 2024
96b4292
CI: fix matplot warning about some missing font
AlyaGomaa Nov 28, 2024
3b0cbc0
CI: fix matplot warning about some missing font
AlyaGomaa Nov 28, 2024
3b3b1c4
Merge pull request #1088 from stratosphereips/alya/add_timeouts_to_ev…
AlyaGomaa Nov 28, 2024
b399e96
update CHANGELOG.md
AlyaGomaa Nov 29, 2024
f96cb00
Merge remote-tracking branch 'origin/develop' into develop
AlyaGomaa Nov 29, 2024
1a76139
web interface: fix erasing the db when connected
AlyaGomaa Nov 29, 2024
9cb226c
bump version to 1.1.4
AlyaGomaa Nov 29, 2024
dc0c7f6
update slips.gif
AlyaGomaa Nov 29, 2024
1feaa36
fix slips version in CHANGELOG.md
AlyaGomaa Nov 29, 2024
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
64 changes: 64 additions & 0 deletions .github/workflows/install-slips-dependencies.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,64 @@
name: Install Slips Dependencies

on:
# workflow_call make this workflow re-usable
workflow_call:
# these are like variables to make the workflow more clean
# we can pass these variable from another workflows if we want
inputs:
zeek-repo-url:
description: 'Zeek repository URL'
required: false
default: 'http://download.opensuse.org/repositories/security:/zeek/xUbuntu_22.04/'
type: string
zeek-key-url:
description: 'Zeek key URL'
required: false
default: 'https://download.opensuse.org/repositories/security:zeek/xUbuntu_22.04/Release.key'
type: string
python-version:
description: 'Python version to set up'
required: false
default: '3.10.12'
type: string

jobs:
install-dependencies:
runs-on: ubuntu-22.04
steps:
- uses: actions/checkout@v4
with:
ref: ${{ github.ref }}
fetch-depth: ''

- name: Enable memory overcommit (for Redis)
run: sysctl vm.overcommit_memory=1

- name: Install APT dependencies
run: |
sudo apt-get update --fix-missing && sudo apt-get -y --no-install-recommends install $(cat install/apt_dependencies.txt)
sudo apt-get -y install font-manager

- name: Save APT Cache
uses: actions/cache@v4
with:
path: |
/var/cache/apt/archives
/var/lib/apt/lists
key: apt-cache

- name: Set up Python with caching enabled
uses: actions/setup-python@v5
with:
python-version: ${{ inputs.python-version }}
cache: 'pip'

- name: Install Python dependencies
run: python3 -m pip install -r install/requirements.txt

- name: Install Zeek
run: |
echo "deb ${{ inputs.zeek-repo-url }} /" | sudo tee /etc/apt/sources.list.d/security:zeek.list
curl -fsSL ${{ inputs.zeek-key-url }} | sudo gpg --dearmor -o /etc/apt/trusted.gpg.d/security_zeek.gpg
sudo apt update && sudo apt install -y --no-install-recommends zeek
sudo ln -s /opt/zeek/bin/zeek /usr/local/bin/bro
55 changes: 39 additions & 16 deletions .github/workflows/integration-tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7,25 +7,45 @@ on:
- 'develop'

jobs:
tests:
# uses the common workflow that builds slips
install-dependencies-using-reusable-workflow:
uses: ./.github/workflows/install-slips-dependencies.yml


integration-tests:
runs-on: ubuntu-22.04
timeout-minutes: 7200
timeout-minutes: 1800
# make this job depend on the first job
needs: install-dependencies-using-reusable-workflow

strategy:
matrix:
test_file:
- tests/integration_tests/test_config_files.py
- tests/integration_tests/test_portscans.py
- tests/integration_tests/test_dataset.py
- test_config_files.py
- test_portscans.py
- test_dataset.py

steps:
- uses: actions/checkout@v4
with:
ref: ${{ github.ref }}
fetch-depth: ''

- name: Install slips dependencies
run: sudo apt-get update --fix-missing && sudo apt-get -y --no-install-recommends install python3 redis-server python3-pip python3-certifi python3-dev build-essential file lsof net-tools iproute2 iptables python3-tzlocal nfdump tshark git whois golang nodejs notify-osd yara libnotify-bin
- name: Restore Zeek Build from Cache
id: zeek-cache
uses: actions/cache@v4
with:
path: /opt/zeek
key: zeek-cache

- name: Restore APT cache
id: apt-cache
uses: actions/cache@v4
with:
path: |
/var/cache/apt/archives
/var/lib/apt/lists
key: apt-cache

- name: Install Zeek
run: |
Expand All @@ -34,22 +54,25 @@ jobs:
sudo apt update && sudo apt install -y --no-install-recommends --fix-missing zeek
sudo ln -s /opt/zeek/bin/zeek /usr/local/bin/bro

- name: Set up Python 3.10.12
uses: actions/setup-python@v5
with:
python-version: "3.10.12"

- name: Install Python dependencies
- name: Install apt dependencies (from cache if possible)
run: |
sudo apt-get update
sudo apt-get install -y $(cat install/apt_dependencies.txt)

- name: Install Python dependencies (from cache if possible)
run: |
python -m pip install --upgrade pip
python3 -m pip install --no-cache-dir -r install/requirements.txt
python3 -m pip install pytest-timeout
python3 -m pip install --upgrade pip
python3 -m pip install -r install/requirements.txt



- name: Start redis server
run: redis-server --daemonize yes

- name: Run Integration Tests for ${{ matrix.test_file }}
run: python3 -m pytest ${{ matrix.test_file }} -vvv -s
run: |
python3 -m pytest tests/integration_tests/${{ matrix.test_file }} -p no:warnings -vv -s -n 5

- name: Upload Artifacts
if: success() || failure()
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
name: CI-production-publishing-slips-image
name: CI-production-publishing-slips-images

on:
push:
Expand Down Expand Up @@ -40,7 +40,7 @@ jobs:
- name: Set up Docker Buildx
uses: docker/setup-buildx-action@v3

- name: Build and push Slips image using dockerfile
- name: Build and push the main Slips image
id: docker_build_slips
uses: docker/build-push-action@v6
with:
Expand All @@ -51,3 +51,15 @@ jobs:
stratosphereips/slips:latest
stratosphereips/slips:${{ env.SLIPS_VERSION }}
push: true

- name: Build and push the light Slips image
id: docker_build_light_slips
uses: docker/build-push-action@v6
with:
allow: network.host
context: ./
file: ./docker/light/Dockerfile
tags: |
stratosphereips/slips_light:latest
stratosphereips/slips_light:${{ env.SLIPS_VERSION }}
push: true
148 changes: 79 additions & 69 deletions .github/workflows/unit-tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -6,100 +6,110 @@ on:
- 'master'
- 'develop'


jobs:
tests:
# uses the common workflow that builds slips
install-dependencies-using-reusable-workflow:
uses: ./.github/workflows/install-slips-dependencies.yml

unit-tests:
runs-on: ubuntu-22.04
timeout-minutes: 1800
# make this job depend on the first job
needs: install-dependencies-using-reusable-workflow

strategy:
matrix:
test_file:
- tests/test_inputProc.py
- tests/test_main.py
- tests/test_conn.py
- tests/test_downloaded_file.py
- tests/test_ssl.py
- tests/test_tunnel.py
- tests/test_ssh.py
- tests/test_dns.py
- tests/test_notice.py
- tests/test_software.py
- tests/test_smtp.py
- tests/test_whitelist.py
- tests/test_arp.py
- tests/test_blocking.py
- tests/test_flow_handler.py
- tests/test_horizontal_portscans.py
- tests/test_http_analyzer.py
- tests/test_vertical_portscans.py
- tests/test_network_discovery.py
- tests/test_virustotal.py
- tests/test_update_file_manager.py
- tests/test_threat_intelligence.py
- tests/test_slips_utils.py
- tests/test_slips.py
- tests/test_profiler.py
- tests/test_leak_detector.py
- tests/test_ip_info.py
- tests/test_evidence.py
- tests/test_asn_info.py
- tests/test_urlhaus.py
- tests/test_markov_chain.py
- tests/test_daemon.py
- tests/test_go_director.py
- tests/test_notify.py
- tests/test_checker.py
- tests/test_base_model.py
- tests/test_set_evidence.py
- tests/test_trustdb.py
- tests/test_cesnet.py
- tests/test_output.py
- tests/test_riskiq.py
- tests/test_spamhaus.py
- tests/test_circllu.py
- tests/test_evidence_handler.py
- tests/test_alert_handler.py
- tests/test_redis_manager.py
- tests/test_ioc_handler.py
- tests/test_timeline.py
- tests/test_database.py
- tests/test_symbols_handler.py
- test_inputProc.py
- test_main.py
- test_conn.py
- test_downloaded_file.py
- test_ssl.py
- test_tunnel.py
- test_ssh.py
- test_dns.py
- test_notice.py
- test_software.py
- test_smtp.py
- test_whitelist.py
- test_arp.py
- test_blocking.py
- test_flow_handler.py
- test_horizontal_portscans.py
- test_http_analyzer.py
- test_vertical_portscans.py
- test_network_discovery.py
- test_virustotal.py
- test_update_file_manager.py
- test_threat_intelligence.py
- test_slips_utils.py
- test_slips.py
- test_profiler.py
- test_leak_detector.py
- test_ip_info.py
- test_evidence.py
- test_asn_info.py
- test_urlhaus.py
- test_markov_chain.py
- test_daemon.py
- test_go_director.py
- test_notify.py
- test_checker.py
- test_base_model.py
- test_set_evidence.py
- test_trustdb.py
- test_cesnet.py
- test_output.py
- test_riskiq.py
- test_spamhaus.py
- test_circllu.py
- test_evidence_handler.py
- test_alert_handler.py
- test_redis_manager.py
- test_ioc_handler.py
- test_timeline.py
- test_database.py
- test_symbols_handler.py

steps:
- uses: actions/checkout@v4
with:
ref: ${{ github.ref }}
fetch-depth: ''

- name: Enable memory overcommit (for redis)
run: sysctl vm.overcommit_memory=1

- name: Install slips dependencies
run: sudo apt-get update --fix-missing && sudo apt-get -y --no-install-recommends install python3 redis-server python3-pip python3-certifi python3-dev build-essential file lsof net-tools iproute2 iptables python3-tzlocal nfdump tshark git whois golang nodejs notify-osd yara libnotify-bin
- name: Restore APT cache
id: apt-cache
uses: actions/cache@v4
with:
path: |
/var/cache/apt/archives
/var/lib/apt/lists
key: apt-cache

- if: ${{ steps.apt-cache.outputs.cache-hit == 'true' }}
name: Echo restored from cache
continue-on-error: true
run: echo "Restored APT dependencies from cache successfully"

- name: Install Zeek
- name: Install Python dependencies (from cache if possible)
run: |
sudo echo 'deb http://download.opensuse.org/repositories/security:/zeek/xUbuntu_22.04/ /' | sudo tee /etc/apt/sources.list.d/security:zeek.list
curl -fsSL https://download.opensuse.org/repositories/security:zeek/xUbuntu_22.04/Release.key | gpg --dearmor | sudo tee /etc/apt/trusted.gpg.d/security_zeek.gpg > /dev/null
sudo apt update && sudo apt install -y --no-install-recommends --fix-missing zeek
sudo ln -s /opt/zeek/bin/zeek /usr/local/bin/bro

- name: Set up Python 3.10.12
uses: actions/setup-python@v5
with:
python-version: "3.10.12"
python3 -m pip install --upgrade pip
python3 -m pip install -r install/requirements.txt

- name: Install Python dependencies
- name: Install apt dependencies (from cache if possible)
run: |
python -m pip install --upgrade pip
python3 -m pip install --no-cache-dir -r install/requirements.txt
sudo apt-get update
sudo apt-get install -y $(cat install/apt_dependencies.txt)


- name: Start redis server
run: redis-server --daemonize yes

- name: Run Unit Tests for ${{ matrix.test_file }}
run: |
python3 -m pytest ${{ matrix.test_file }} -p no:warnings -vv -s -n 5
python3 -m pytest tests/${{ matrix.test_file }} -p no:warnings -vv -s -n 5

- name: Upload Artifacts
if: success() || failure()
Expand Down
3 changes: 2 additions & 1 deletion .pre-commit-config.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -16,11 +16,12 @@ repos:
hooks:
- id: trailing-whitespace
- id: check-added-large-files
exclude: ^config/local_ti_files/known_fp_hashes\.csv$
- id: check-docstring-first
- id: check-merge-conflict
- id: end-of-file-fixer
- id: detect-private-key
exclude: .*dataset/.*|
exclude: .*dataset/.* |
(?x)(
^config/$|
.*test.* |
Expand Down
7 changes: 7 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,10 @@
- 1.1.4 (Nov 29th, 2024)
- Fix changing the used database in the web interface.
- Reduce false positive evidence about malicious downloaded files.
- Fix datetime errors when running on interface
- Improve the detection of "DNS without connection".
- Add support for a light Slips docker image.

- 1.1.3 (October 30th, 2024)
- Enhanced Slips shutdown process for smoother operations.
- Optimized resource management in Slips, resolving issues with lingering threads in memory.
Expand Down
Loading
Loading