Skip to content

Siem - #1

Merged
parv68 merged 8 commits into
mainfrom
SIEM
May 19, 2026
Merged

Siem#1
parv68 merged 8 commits into
mainfrom
SIEM

Conversation

@parv68

@parv68 parv68 commented May 19, 2026

Copy link
Copy Markdown
Collaborator

No description provided.

parv68 added 8 commits May 17, 2026 23:54
  documents, images, audio, video, executables, archives, disk images,
  cryptographic keys, fonts, databases, and bytecode
- src/update.rs: UpdateManager with check, apply (backup-first),
  rollback, and air-gap import; rejects empty registries
- src/core/compression.rs: real decompression for GZIP (flate2),
  BZ2 (bzip2), Zstd (zstd), XZ (xz2) with 100MB cap and 100:1
  expansion ratio guard
- src/signatures/mod.rs: match_signatures() at offset, default_registry()
  via include_str!, category_risk_level() mapping
- Pipeline: analyze_bytes() overlays registry matches onto detection
  results (detected_type, algorithm, risk_level, magic_bytes signal)
- CLI: update subcommand wired to UpdateManager, version shows
  Signature DB from registry YAML
- dependencies: +bzip2
- 70 tests passing, zero warnings, docker/ refs removed from docs
…descent,

  L2 regularization, predict_proba(), signal_contributions(), CSV loader,
  JSON persistence, synthetic data generator (5 classes, 200 samples/class)
- src/core/confidence.rs: rewired to use CalibrationModel via global RwLock;
  falls back to provisional heuristic when no model loaded; decision_trace
  populated with per-signal log-odds contributions
- src/types.rs: added CalibrationModel (weights[6], intercept, metadata)
  and SignalContribution structs
- src/cli.rs: calibrate subcommand with 	rain, generate, status
- src/reports/terminal.rs: shows (calibrated) badge + decision trace
- src/main.rs: loads default model at startup from calibration_data/model.json
- dependencies: +csv, +rand 0.9
- 78 tests passing, zero warnings, full pipeline verified end-to-end
- Add async AiProvider trait (OpenAI, Anthropic, Local/Ollama) via reqwest
- Add structured prompt builder — no raw input bytes, only detection fields
- Add per-field AI narrative validator with hallucinated CVE detection,
  sentence limits, signal keyword check, graceful degradation on bad output
- Wire --ai flag into CLI analyze command with env/config provider loading
- Update terminal report to show AI Narrative section
- Add async-trait and reqwest dependencies
- 86 tests pass, zero warnings
- Add SandboxConfig + Sandbox struct with run_worker() — spawns
  cryptotrace-worker subprocess, pipes input via stdin, collects stdout,
  enforces hard timeout with kill-on-expiry, background-threaded stdin
  writer to prevent deadlock, CREATE_NO_WINDOW on Windows
- Rewrite cryptotrace-worker binary with three operations:
  detect (full pipeline → JSON), decompress (format detection + decompress),
  passthrough (echo, for testing), JSON error output on stderr
- Add analyze_file_sandboxed() and analyze_bytes_sandboxed() to
  analyzers/file.rs with automatic in-process fallback on worker crash
- Add --sandbox CLI flag to analyze subcommand
- Maintain backward-compat WorkerPool wrapper in workers.rs
- 88 tests pass, zero warnings
- Add 6 API integration tests: health, version, analyze (string/base64/
  bad-request), auth key validation with Bearer/X-API-Key headers
- Remove remaining #[allow(dead_code)] in workers.rs
- Update README with: 6.09 MB binary, all phases completed, calibration/
  AI/sandbox/API features, 93 tests, updated architecture diagram
- Mark CryptoTrace_Implementation_Plan.md as historical
- Fix race condition in confidence tests (combine parallel tests into one)
- 93 tests pass, zero warnings, release build clean
…intel

Phase E: Async API & job queue
- JobQueue with atomic IDs, RwLock storage, background worker loop (200ms poll)
- POST/GET/DELETE /v1/jobs endpoints (submit, poll, cancel)
- Display impl for ApiError
Phase F: Update mechanism hardening
- Ed25519 signature verification via ring (fallback to gpg CLI)
- apply_verified_update() with provenance.jsonl logging
- --verify flag on cryptotrace update --from-file
Phase G: Community registry + docs
- community-providers.json with 5 verified/community providers
- CommunityRegistry loader with download + caching
- CONTRIBUTING.md and CODE_OF_CONDUCT.md
Phase H: Threat intel + IDE extensions
- VirusTotal API v3 query, YARA CLI scanning, composite threat scan
- VSCode extension blueprint (decorations, commands, settings)
154 tests pass, zero errors.
- Add CEF/LEEF log formatters in src/intelligence/siem.rs (5 tests)
- Add sandbox crash test: missing worker returns error gracefully
- Add compression bomb test: 100:1 expansion ratio correctly rejected
- Add air-gap test: AI disabled by default, zero network in analysis
- Fix fuzz setup (explicit [[bin]], nightly +cargo-fuzz, CI 100K runs)
- Add fuzz-long.sh script for 1M-iteration runs on Linux
- Fix unused variable warnings across cli.rs, routes.rs, confidence.rs
- All 171 tests pass, zero warnings
@parv68
parv68 merged commit 0bac424 into main May 19, 2026
0 of 6 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant