Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
139 commits
Select commit Hold shift + click to select a range
ccecfac
Add AGENTS.md
AlyaGomaa Feb 10, 2026
39a0933
lo flows per minute from input and profiler in output/flows_per_minut…
AlyaGomaa Feb 10, 2026
0963b45
log FPM for each profiler worker separately
AlyaGomaa Feb 10, 2026
5f1297e
log latency in output/latency.csv for each added evidence
AlyaGomaa Feb 10, 2026
906c7bb
redis: use "127.0.0.1" instead of "localhost" when connecting to redi…
AlyaGomaa Feb 10, 2026
ff612e1
redis: use encoding instead of charset
AlyaGomaa Feb 10, 2026
15e2b14
Add AGENTS.md
AlyaGomaa Feb 10, 2026
5c686f3
lo flows per minute from input and profiler in output/flows_per_minut…
AlyaGomaa Feb 10, 2026
797a7da
log FPM for each profiler worker separately
AlyaGomaa Feb 10, 2026
1cb8b2c
log latency in output/latency.csv for each added evidence
AlyaGomaa Feb 10, 2026
e7b8a7e
redis: use "127.0.0.1" instead of "localhost" when connecting to redi…
AlyaGomaa Feb 10, 2026
4114ed5
Merge remote-tracking branch 'origin/alya/immune/stress_testing' into…
AlyaGomaa Feb 25, 2026
703c5f6
profiler.py: start max 7 workers instead of 10 to test slow pub/sub c…
AlyaGomaa Feb 25, 2026
29cd8a8
Add AGENTS.md
AlyaGomaa Feb 10, 2026
885d01c
lo flows per minute from input and profiler in output/flows_per_minut…
AlyaGomaa Feb 10, 2026
97ccfad
log FPM for each profiler worker separately
AlyaGomaa Feb 10, 2026
9645906
log latency in output/latency.csv for each added evidence
AlyaGomaa Feb 10, 2026
9cb814b
redis: use "127.0.0.1" instead of "localhost" when connecting to redi…
AlyaGomaa Feb 10, 2026
ffe6546
profiler.py: start max 7 workers instead of 10 to test slow pub/sub c…
AlyaGomaa Feb 25, 2026
7d99f0d
Merge remote-tracking branch 'origin/alya/immune/stress_testing' into…
AlyaGomaa Feb 25, 2026
e7195a6
Merge remote-tracking branch 'origin/develop' into alya/immune/stress…
AlyaGomaa Mar 4, 2026
c3a7d3f
evidence: fix getting the latency by converting the flow pcap time to…
AlyaGomaa Mar 5, 2026
ee3a18b
evidence: make latency = wall_elapsed - pcap_elapsed to be able to ha…
AlyaGomaa Mar 5, 2026
0ce4ae5
evidence: handle getting latency of live traffic different than we do…
AlyaGomaa Mar 5, 2026
c223351
plot latency as soon as slips stops
AlyaGomaa Mar 5, 2026
009803a
plot trhoughput for each profiler and for the sum of profilers as soo…
AlyaGomaa Mar 5, 2026
fae6339
add latency and throughput metrics to metrics.txt
AlyaGomaa Mar 5, 2026
4e839f9
fix problem keeping track of input.py analyzed flows per min
AlyaGomaa Mar 5, 2026
687b097
Add a debugging msg when a profiler worker stops
AlyaGomaa Mar 6, 2026
f8621fa
profiler_worker: keep checking for msgs from the input even if it sto…
AlyaGomaa Mar 6, 2026
3fb5476
Add a script that plots the amount of flows recvd over time given a c…
AlyaGomaa Mar 9, 2026
2ca1682
stress_testing.md: Added baseline and sudden spikes experiments stats
AlyaGomaa Mar 9, 2026
52edfc2
Add a soak testing traffic generator
AlyaGomaa Mar 10, 2026
a4c7f0b
add RAM usage monitor for slips, all children and redis for monitorin…
AlyaGomaa Mar 10, 2026
fcb85ab
add CPU usage monitor for slips and all children for monitoring soak …
AlyaGomaa Mar 10, 2026
9a4a7d8
log ram usage of slips and redis every 3 mins
AlyaGomaa Mar 10, 2026
c3659f5
plot the flows recvd in conn.log as soon as slips stops, and the reso…
AlyaGomaa Mar 10, 2026
8727509
soak_testing_traffic_generator.py: add rate limiter to ensure sustain…
AlyaGomaa Mar 10, 2026
1e622a5
add a simple http server that accepts get and post requests
AlyaGomaa Mar 11, 2026
482999f
soak_testing_traffic_generator.py: make a dns query that results in a…
AlyaGomaa Mar 11, 2026
7f6ae5c
soak_testing_traffic_generator.py: add ocassional attacks
AlyaGomaa Mar 11, 2026
100f4f3
add a plotter for resource usage.csv generated files
AlyaGomaa Mar 11, 2026
995c915
build(deps): bump black from 25.9.0 to 26.3.1 in /install
dependabot[bot] Mar 12, 2026
b8b75d8
move all images to docs/images/immune/c3
AlyaGomaa Mar 13, 2026
8947972
evidence_handler: extract threat level accumulation to its own func a…
AlyaGomaa Mar 13, 2026
256315b
evidence_handler: use queue.Queue instead of mp.Queue() for optimizat…
AlyaGomaa Mar 13, 2026
357eb15
evidence_handler: publish new evidence to report_to_peers and export_…
AlyaGomaa Mar 13, 2026
fc0888e
evidence_handler: dont send_to_exporting_module if they're not enabled
AlyaGomaa Mar 13, 2026
858ed7e
Add evidence<handlerWorker class, and start 3 workers for parallel pr…
AlyaGomaa Mar 13, 2026
fa16159
fix how evidence_logger stops
AlyaGomaa Mar 13, 2026
1da8554
get_analyzed_flows_percentage: handle ZeroDivisionError
AlyaGomaa Mar 13, 2026
49f31ac
remove unused attributes from evidence worker
AlyaGomaa Mar 13, 2026
411b254
fix problem logging redis RAM used
AlyaGomaa Mar 13, 2026
6f58233
Add a csv file for each profiler worker that logs each flow's latency
AlyaGomaa Mar 17, 2026
69ae7c2
Add a plotter to plot profiler workers' latency
AlyaGomaa Mar 17, 2026
012a03b
start 3 workers by default and increase when needed
AlyaGomaa Mar 17, 2026
3c2a417
flow_handler: comment out add_tuple to see if it's responsible for th…
AlyaGomaa Mar 17, 2026
52e1396
comment allprofiler logic to see if the latency is caused by the queue
AlyaGomaa Mar 17, 2026
fb803ec
uncomment whitelist checking in profiler to see if its the main sourc…
AlyaGomaa Mar 17, 2026
c64f72b
uncomment add_profile() to see if its the main source of latency
AlyaGomaa Mar 17, 2026
248ed7e
uncomment most of add_flow_to_profile()
AlyaGomaa Mar 18, 2026
d141adf
profiler: uncomment get_aid_and_store_flow_in_the_db()
AlyaGomaa Mar 18, 2026
e442dfd
profiler: uncomment mark_profile_tw_as_modified()
AlyaGomaa Mar 18, 2026
f7ba01e
db: publish a msg in tw_modified once every 40 modifications to see i…
AlyaGomaa Mar 18, 2026
92d923f
fix: correct protocol handling in check_unknown_port method
eldraco Mar 20, 2026
0b42474
test: add check for lowercase protocol handling in known ports
eldraco Mar 20, 2026
c377cbf
Merge pull request #1853 from stratosphereips/fix-FP-in-alerts
eldraco Mar 20, 2026
2c89074
feat: add initial implementation for bruteforcing module
eldraco Mar 23, 2026
6035b6f
feat: implement SSH bruteforcing detection module
eldraco Mar 23, 2026
73025c3
refactor: remove password guessing check from analyze method
eldraco Mar 23, 2026
7d34e1c
refactor: remove password guessing detection logic from SSH analyzer
eldraco Mar 23, 2026
25da33e
feat: add SSH bruteforcing threshold configuration method
eldraco Mar 23, 2026
c591cbe
fix: prevent processing of flows without software information
eldraco Mar 23, 2026
9d61592
feat: add optional sport and dport fields to SSH class and software_n…
eldraco Mar 23, 2026
17f9d8f
feat: add method to create bruteforcing object in ModuleFactory
eldraco Mar 23, 2026
7bb7253
feat: update SSH and software field mappings to include additional at…
eldraco Mar 23, 2026
f319873
feat: add unit tests for SSH bruteforcing detection and reporting
eldraco Mar 23, 2026
4bf4838
fix: correct expected call count for password guessing test
eldraco Mar 23, 2026
578247d
feat: add bruteforcing configuration with SSH attempt threshold
eldraco Mar 23, 2026
d414881
refactor: remove deprecated SSH password guessing test cases
eldraco Mar 23, 2026
0aeced6
feat: add unit tests for ZeekJSON SSH log processing and field mapping
eldraco Mar 23, 2026
a82669c
feat: add new test 19 for malicious SSH bruteforce pcap dataset for t…
eldraco Mar 23, 2026
54c60ec
feat: add README for SSH bruteforce testing with nmap
eldraco Mar 23, 2026
b2570cb
feat: add documentation for the Bruteforcing module and its detection…
eldraco Mar 23, 2026
038dc10
feat: enhance Bruteforcing module documentation and detection capabil…
eldraco Mar 23, 2026
7a81f98
feat: update detection techniques and enhance SSH bruteforcing module…
eldraco Mar 23, 2026
f3f6ad8
feat: update Zeek alerts and clarify SSH bruteforcing documentation i…
eldraco Mar 23, 2026
9f12c2c
feat: add Bruteforcing module documentation entry in index.rst
eldraco Mar 23, 2026
509e18a
Merge pull request #1854 from stratosphereips/ssh-bruteforce-detect
eldraco Mar 23, 2026
355f9f1
profiler: uncomment the rest of profiler logic
AlyaGomaa Mar 23, 2026
20ca9d9
profiler: comment from handle_setting_local_net() onward
AlyaGomaa Mar 23, 2026
02c8546
profiler: comment all msgs published to tw_modified channel
AlyaGomaa Mar 23, 2026
88d83d9
profiler: comment mark_profile_tw_as_modified()
AlyaGomaa Mar 23, 2026
fca615c
profiler: batch update modified tws every 3s to avoid per flow trigge…
AlyaGomaa Mar 24, 2026
f2e8e2d
db: collect modified tws for 3 seconds, and publish them once every 3…
AlyaGomaa Mar 24, 2026
dbbd512
network_discovery: use new_flow channel instead of tw_modified to che…
AlyaGomaa Mar 24, 2026
4670570
profiler: uncomment handle_setting_local_net()
AlyaGomaa Mar 24, 2026
68c9f4b
profiler_worker: move all localnet related logic from profiler to hel…
AlyaGomaa Mar 24, 2026
65450cf
profiler: delete the custom LocalnetCacheShared and use mp Manager() …
AlyaGomaa Mar 24, 2026
fe9d3b3
localnet_handler.py: cache _configured_default_localnet()
AlyaGomaa Mar 24, 2026
9bc7a4e
profiler: comment handle_setting_local_net
AlyaGomaa Mar 24, 2026
cf4220e
profiler: comment _update_modified_tws_in_the_db()
AlyaGomaa Mar 24, 2026
7a355c2
uncomment the rest of profiler logic
AlyaGomaa Mar 25, 2026
29bce35
use better names for the generated plots
AlyaGomaa Mar 25, 2026
0e60bf8
Update the metrics in stress_testing.md
AlyaGomaa Mar 25, 2026
2bd1e74
stress_testing.md: Add ToC, traffic links, and a screenshot of latenc…
AlyaGomaa Mar 26, 2026
f9271cc
update .secrets.baseline
AlyaGomaa Mar 27, 2026
fac8c26
Add a generate_performance_plots param in the config file to enable/d…
AlyaGomaa Mar 27, 2026
e9adcf5
guard all plots-related logic to run only when the generate_performan…
AlyaGomaa Mar 27, 2026
ca5cd62
update .secrets.baseline
AlyaGomaa Mar 27, 2026
0a8952f
update docs and unit tests
AlyaGomaa Mar 27, 2026
4ea7d88
update links in stress_testing.md
AlyaGomaa Mar 27, 2026
d4f4fe8
delete stress testing scripts
AlyaGomaa Mar 27, 2026
a2ac8b7
print a msg when the plots is enabled
AlyaGomaa Mar 27, 2026
f071bf1
add localnet handler unit tests
AlyaGomaa Mar 27, 2026
7a2caa9
update unit tests
AlyaGomaa Mar 29, 2026
3c9c429
update unit tests
AlyaGomaa Mar 29, 2026
2aad8d2
profiler: add a function to _shutdown_localnet_cache_manager on shutdown
AlyaGomaa Mar 29, 2026
0806f6d
use localnet_cache struct again for sharing dicts between profiler pr…
AlyaGomaa Mar 29, 2026
de70757
delete all usage of the custom localnet cahce
AlyaGomaa Mar 29, 2026
ce319f2
db: add a func to get_total_recognized_localnets
AlyaGomaa Mar 29, 2026
c356c90
localnet_handler: use the db for trackign localnets instead of a shar…
AlyaGomaa Mar 29, 2026
b60e39e
update unit tests
AlyaGomaa Mar 29, 2026
fd037d6
fix race condition preventing slips from stopping in very small pcaps
AlyaGomaa Mar 29, 2026
7d29aa7
input: add debugging prints
AlyaGomaa Mar 30, 2026
d375221
input: if the input took less than 2mins to stop, wait extra 10s just…
AlyaGomaa Mar 30, 2026
0088ffb
use /upload-artifact v6 to avoid nodejs deprecation warning
AlyaGomaa Mar 30, 2026
bb1304c
input: wait more time for all profilers to start (to fix integration …
AlyaGomaa Mar 30, 2026
4c85853
Merge pull request #1858 from stratosphereips/alya/immune/stress_testing
AlyaGomaa Mar 30, 2026
c8547ad
fix the plots used in stress_testing.md
AlyaGomaa Mar 30, 2026
38f1b25
stress_testing: replace html tags with markdown for imgs
AlyaGomaa Mar 30, 2026
e8587d0
Merge pull request #1846 from stratosphereips/dependabot/pip/install/…
AlyaGomaa Mar 30, 2026
f5e78e8
aid manager: stop when the stop msgs is recvd only instead of using a…
AlyaGomaa Mar 31, 2026
bde77bb
fix the issue of slips skipping the very first flow
AlyaGomaa Mar 31, 2026
13efa20
update changelog
AlyaGomaa Mar 31, 2026
17e7118
redis_manager.py: handle unable to kill servers with unknown pids
AlyaGomaa Mar 31, 2026
8ad878e
update profiler unit tests
AlyaGomaa Mar 31, 2026
e1d6357
fix prolem parsing argus header
AlyaGomaa Mar 31, 2026
e19ad44
update changelog
AlyaGomaa Mar 31, 2026
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
2 changes: 1 addition & 1 deletion .github/workflows/integration-tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -55,7 +55,7 @@ jobs:

- name: Upload Artifacts
if: always()
uses: actions/upload-artifact@v5
uses: actions/upload-artifact@v6
with:
# Replaces slashes with underscores for valid artifact naming
name: ${{ github.run_id }}-${{ strategy.job-index }}-integration-output
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/unit-tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -56,7 +56,7 @@ jobs:

- name: Upload Artifacts
if: always()
uses: actions/upload-artifact@v5
uses: actions/upload-artifact@v6
with:
name: test_slips-output-${{ strategy.job-index }}
path: |
Expand Down
4 changes: 2 additions & 2 deletions .secrets.baseline
Original file line number Diff line number Diff line change
Expand Up @@ -149,7 +149,7 @@
"filename": "config/slips.yaml",
"hashed_secret": "4cac50cee3ad8e462728e711eac3e670753d5016",
"is_verified": false,
"line_number": 268
"line_number": 278
}
],
"dataset/test14-malicious-zeek-dir/http.log": [
Expand Down Expand Up @@ -7185,5 +7185,5 @@
}
]
},
"generated_at": "2026-03-02T22:46:58Z"
"generated_at": "2026-03-27T14:25:16Z"
}
42 changes: 42 additions & 0 deletions AGENTS.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,42 @@
# AGENTS.md

## Project overview
- Entry point: `slips.py` (starts the main process, spawns modules, runs in interactive/daemon modes).
- Core framework code lives in `slips/`, `slips_files/`, and `managers/`.
- Detection/analysis modules are in `modules/` (implement the `IModule` interface).
- Configuration is in `config/` (main config: `config/slips.yaml`).
- Tests live under `tests/` (unit + integration suites).
- Documentation is in `docs/` (see `docs/contributing.md` for contribution workflow, branching, and PR expectations).
- UIs/tools: `SlipsWeb/`, `webinterface/`, `webinterface.sh`, and `kalipso.sh`.

## Build and test commands
- Run locally (no build step):
- `./slips.py -e 1 -f dataset/test7-malicious.pcap -o output_dir`
- Build the Docker image (from `docs/installation.md`):
- `docker build --no-cache -t slips -f docker/Dockerfile .`
- If build networking fails: `docker build --network=host --no-cache -t slips -f docker/Dockerfile .`
- Run the Docker image:
- `docker run -it --rm --net=host slips`

## Code style guidelines
- Python formatting is enforced via pre-commit:
- Black with `--line-length 79` (see `.pre-commit-config.yaml`).
- Ruff is used for linting and autofixes.
- Keep docstrings at the top of files where present (pre-commit `check-docstring-first`).
- Maintain clean whitespace (no trailing whitespace, final newline).
- Follow existing module patterns (`IModule` in `slips_files/common/abstracts/module.py`).

## Testing instructions
- The canonical test runner is `tests/run_all_tests.sh` (runs unit tests then integration tests).
- Equivalent manual sequence (from `tests/run_all_tests.sh`):
- `./slips.py -cc`
- `printf "0" | ./slips.py -k`
- `python3 -m pytest tests/ --ignore="tests/integration_tests" -n 7 -p no:warnings -vvvv -s`
- `python3 tests/destrctor.py`
- `./slips.py -cc`
- `printf "0" | ./slips.py -k`
- `python3 -m pytest -s tests/integration_tests/test_portscans.py -p no:warnings -vv`
- `python3 -m pytest -s tests/integration_tests/test_dataset.py -p no:warnings -vv`
- `python3 -m pytest -s tests/integration_tests/test_config_files.py -p no:warnings -vv`
- `printf "0" | ./slips.py -k`
- `./slips.py -cc`
8 changes: 8 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,11 @@
1.1.19 (Mar 31st, 2026)

* Add SSH bruteforce detection based on Zeek SSH, software, and notice logs.
* Improve performance under high-throughput traffic with parallel evidence handling, profiler/input optimizations.
* Fix issues while slips is shutting down.
* Add optional performance plots and CSV metrics for latency, throughput, and resource usage.
* Fix skipped first-flow processing and reduce shutdown race conditions on small files and PCAPs.

1.1.18 (Mar 3rd, 2026)

* Add the HTTPS anomaly detection module with adaptive baselines, confidence scoring, and detailed evidence reasons.
Expand Down
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
<h1 align="center">
Slips v1.1.18
Slips v1.1.19
</h1>


Expand Down
2 changes: 1 addition & 1 deletion VERSION
Original file line number Diff line number Diff line change
@@ -1 +1 @@
1.1.18
1.1.19
16 changes: 16 additions & 0 deletions config/slips.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -163,6 +163,16 @@ parameters:
# client_ips : [10.0.0.1, 11.0.0.0/24]
client_ips: []

#############################
Debug:
# Generate latency, throughput, and other performance related CSV files and plots in output/performance_plots/ for debugging
# When enabled, Slips records extra per-flow/per-minute performance data from
# input, profiler workers, and evidence handling, then generates summary plots
# during shutdown. Keep this disabled for normal runs because it adds extra
# bookkeeping and disk writes.
# available options are true/false
generate_performance_plots: false

#############################
detection:

Expand Down Expand Up @@ -215,6 +225,12 @@ flowmldetection:
# 'Malicious' data in order for the test to work.
mode: test

#############################
bruteforcing:
# Minimum number of SSH attempts from one source to one destination
# before Slips considers it brute forcing.
ssh_attempt_threshold: 9

#############################
anomaly_detection_https:
# Number of initial hours used to train the baseline model assuming benign traffic.
Expand Down
5 changes: 5 additions & 0 deletions dataset/test19-malicious-ssh/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
## SSH Bruteforce
Using nmap to bruteforce SSH with 1 user and 40 passwords in port 902/TCP with SSH.

Command
`nmap -p 902 --script ssh-brute --script-args userdb=users.lst,passdb=pass.lst,ssh-brute.timeout=4s 147.32.80.37 -sV`
Binary file not shown.
120 changes: 120 additions & 0 deletions docs/bruteforcing.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,120 @@
# Bruteforcing Module

The `Bruteforcing` module detects SSH bruteforcing by combining repeated SSH sessions, Zeek SSH metadata, client software banners, and Zeek notice confirmations.

This module is loaded automatically by Slips like the rest of the modules in `modules/`, unless it is explicitly disabled in `config/slips.yaml`.

## Inputs

The module subscribes to the following Slips channels:

- `new_ssh`
- `new_software`
- `new_notice`
- `tw_closed`

These channels are populated from Zeek logs:

- `ssh.log`
- `software.log`
- `notice.log`

## What It Detects

The module tracks repeated SSH activity from the same source IP to the same destination IP and destination port inside the same time window.

It uses the following inputs:

- `ssh.log` to count repeated SSH sessions and authentication attempts
- `software.log` to extract the `SSH::CLIENT` banner and identify likely automation libraries such as `libssh`, `libssh2`, `paramiko`, `hydra`, `medusa`, or `ncrack`
- `notice.log` to consume Zeek `SSH::Password_Guessing` confirmations

## Detection Logic

### Counting Attempts

For each SSH flow, the module first checks the Zeek SSH authentication outcome:

- If `auth_success` is `true` or `T`, the flow is ignored for bruteforcing.
- If `auth_attempts` is greater than `0`, that value is added to the bruteforce campaign counter.
- If `auth_attempts` is `0` or missing, but the SSH session is not marked successful, the module counts the session as one suspected password attempt.

The last rule is important for datasets where Zeek records repeated SSH handshakes without recording explicit authentication attempts, such as the `malicious-ssh-bruteforce.pcap` sample.

### Threshold and Reporting

The default SSH bruteforcing threshold is `9` attempts.

After the threshold is reached, the module does not alert on every new attempt. Instead, it uses sparse bucketed reporting so alerts become less frequent over time but never completely stop. With the default threshold, the alert points are:

- 9
- 10
- 12
- 16
- 24
- 40
- ...

### Confidence

The evidence threat level is `medium`.

Confidence grows with the number of attempted passwords:

- first bruteforcing evidence starts at the configured threshold
- full confidence is reached at `30` attempts
- suspicious SSH client banners add a small confidence bonus
- a Zeek `SSH::Password_Guessing` notice acts as confirmation and promotes confidence using Zeek's confirmed connection count

## Evidence Produced

The module emits `PASSWORD_GUESSING` evidence with:

- source attacker IP
- destination victim IP when available
- TCP destination port
- time window
- accumulated UIDs
- threat level `medium`
- confidence based on the number of attempts and confirmation data

Example description:

```text
SSH bruteforcing from 147.32.80.40 to 147.32.80.37 on SSH 902/tcp. Attempts observed: 24. Client banner: libssh libssh2_1.11.0 from software.log. Confidence: 0.89. by Slips
```

## Zeek Confirmation

If Zeek raises `SSH::Password_Guessing` in `notice.log`, the module:

- emits an evidence immediately based on the notice
- stores the notice as confirmation for later bruteforcing evidence
- uses the confirmed connection count from the Zeek notice to increase confidence

If Zeek does not generate `notice.log` for SSH password guessing, the module still detects bruteforcing from `ssh.log` and `software.log`.

## Configuration

The module currently exposes:

```yaml
bruteforcing:
ssh_attempt_threshold: 9
```

This value is read from `config/slips.yaml`.

## Relationship With Flow Alerts

SSH bruteforcing is now handled by the `Bruteforcing` module.

The `Flow Alerts` module still handles:

- successful SSH detections
- Zeek port-scan notices
- certificate alerts
- DNS and connection heuristics
- SMTP bruteforce and the rest of the single-flow detections

It no longer owns SSH password guessing detection.
8 changes: 8 additions & 0 deletions docs/contributing.md
Original file line number Diff line number Diff line change
Expand Up @@ -167,6 +167,14 @@ Once all modules are done processing, EvidenceHandler is killed by the Process m
- It runs the unit tests first, then the integration tests.
- Please get familiar with pytest first https://docs.pytest.org/en/stable/how-to/output.html

### What does `generate_performance_plots` do?

- `Debug.generate_performance_plots` in [config/slips.yaml](config/slips.yaml) is a developer-only debugging switch for performance investigations.
- When it is `true`, Slips writes extra CSVs under `output/performance_plots/csv/`, including alert latency (`latency.csv`), profiler worker latency (`profiler_worker_*_latency.csv`), and throughput (`flows_per_minute.csv`).
- On shutdown, the process manager turns those CSVs into plots and metrics under `output/performance_plots/` and `output/metrics.txt`.
- Leave it `false` for normal development and production-style runs. Enabling it adds Redis bookkeeping, file writes, and plot-generation work that are only useful when diagnosing throughput or latency behavior.
- The plots shown in [docs/immune/stress_testing.md](docs/immune/stress_testing.md) were generated with this parameter enabled.

### Where and how do we get the GW info?

Using one of these 3 ways
Expand Down
23 changes: 22 additions & 1 deletion docs/detection_modules.md
Original file line number Diff line number Diff line change
Expand Up @@ -95,7 +95,12 @@ tr:nth-child(even) {
</tr>
<tr>
<td>Flow Alerts</td>
<td>Finds malicious behaviours by analyzing only one flow. Now detects: self-signed certificates, TLS certificates which validation failed, vertical port scans detected by Zeek (contrary to detected by Slips), horizontal port scans detected by Zeek (contrary to detected by Slips), password guessing in SSH as detected by Zeek, long connection, successful ssh</td>
<td>Finds malicious behaviours by analyzing one flow at a time. It detects self-signed certificates, invalid TLS certificates, Zeek vertical and horizontal port-scan notices, long connections, successful SSH, DNS and connection heuristics, SMTP bruteforce, and related per-flow behaviours.</td>
<td>✅</td>
</tr>
<tr>
<td>Bruteforcing</td>
<td>Detects SSH bruteforcing from repeated SSH sessions, SSH authentication metadata, client banners from software.log, and Zeek SSH password-guessing notices.</td>
<td>✅</td>
</tr>
<tr>
Expand Down Expand Up @@ -126,6 +131,22 @@ tr:nth-child(even) {

</table>

## Bruteforcing Module

The `Bruteforcing` module is responsible for SSH bruteforcing detection.

It consumes:

- `ssh.log`
- `software.log`
- `notice.log`

It correlates repeated SSH sessions by source IP, destination IP, destination port, and time window. It starts alerting at `9` attempts by default, reports sparsely as the count grows, uses the SSH client banner to adjust confidence, and uses Zeek `SSH::Password_Guessing` notices as confirmation.

For the full design and configuration details, see:

- [Bruteforcing Module](bruteforcing.md)

## HTTPS Anomaly Detection Module

For the full technical description of the HTTPS anomaly detector (features, training, adaptation, z-score logic, evidence format, and configuration), see:
Expand Down
9 changes: 7 additions & 2 deletions docs/features.md
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ The detection techniques are:
- Malicious JA3 hashes
- Connections to port 0
- Multiple reconnection attempts
- Alerts from Zeek: Self-signed certs, invalid certs, port-scans and address scans, and password guessing
- Alerts from Zeek: Self-signed certs, invalid certs, port-scans and address scans
- DGA
- Connection to multiple ports
- Malicious SSL certificates
Expand Down Expand Up @@ -507,7 +507,12 @@ tr:nth-child(even) {
</tr>
<tr>
<td>flowalerts</td>
<td>Finds malicious behaviours by analyzing only one flow. Now detects: self-signed certificates, TLS certificates which validation failed, vertical port scans detected by Zeek (contrary to detected by Slips), horizontal port scans detected by Zeek (contrary to detected by Slips), password guessing in SSH as detected by Zeek, long connection, successful ssh</td>
<td>Finds malicious behaviours by analyzing one flow at a time. It detects self-signed certificates, invalid TLS certificates, Zeek vertical and horizontal port-scan notices, long connections, successful SSH, DNS and connection heuristics, SMTP bruteforce, and related per-flow behaviours.</td>
<td>✅</td>
</tr>
<tr>
<td>bruteforcing</td>
<td>Detects SSH bruteforcing from repeated SSH sessions, SSH authentication metadata, client banners from software.log, and Zeek SSH password-guessing notices.</td>
<td>✅</td>
</tr>
<tr>
Expand Down
16 changes: 8 additions & 8 deletions docs/flowalerts.md
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ The detection techniques are:
- Malicious JA3 hashes
- Connections to port 0
- Multiple reconnection attempts
- Alerts from Zeek: Self-signed certs, invalid certs, port-scans and address scans, and password guessing
- Alerts from Zeek: Self-signed certs, invalid certs, port-scans and address scans
- DGA
- Connection to multiple ports
- Malicious SSL certificates
Expand Down Expand Up @@ -184,9 +184,7 @@ the same destination IP on the same destination port.
## Zeek alerts

By default, Slips depends on Zeek for detecting different behaviours, for example
Self-signed certs, invalid certs, port-scans, address scans, and password guessing.

Password guessing is detected by zeek when 30 failed ssh logins happen over 30 mins.
Self-signed certs, invalid certs, port-scans, and address scans.

Some scans are also detected by Slips independently of Zeek, like ICMP sweeps and vertical/horizontal portscans.
Check
Expand All @@ -197,11 +195,13 @@ section for more info

Slips alerts when 3+ invalid SMTP login attempts occurs within 10s

## Password Guessing
## SSH Bruteforcing

SSH bruteforcing is documented in the dedicated `Bruteforcing` module page:

- [Bruteforcing Module](bruteforcing.md)

Password guessing is detected using 2 ethods in slips
1. by Zeek engine. when 30 failed ssh logins happen over 30 mins.
2. By slips. when 20 failed ssh logins happen over 1 tiemwindow.
The `Flow Alerts` module still detects successful SSH sessions, but SSH password guessing is no longer owned by `Flow Alerts`.

## DGA

Expand Down
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
1 change: 1 addition & 0 deletions docs/immune/Immune.md
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,7 @@ This is the main guide to the documentation related to the changes done to Slips
- [Testing](https://stratospherelinuxips.readthedocs.io/en/develop/immune/testing.html)
- [LLM Research and Selection](https://stratospherelinuxips.readthedocs.io/en/develop/immune/research_and_selection_of_llm_candidates.html)
- [LLM RPI Performance](https://stratospherelinuxips.readthedocs.io/en/develop/immune/research_rpi_llm_performance.html)
- [Stress Testing](https://stratospherelinuxips.readthedocs.io/en/develop/immune/stress_testing.html)

### Security & Network Configuration

Expand Down
Loading
Loading