Commit Graph

11 Commits

Author SHA1 Message Date
pandaadir05
9faba5157c fix: improve macOS process name handling and tests
- Add validation to ensure extracted process names are non-empty
- Trim whitespace from process names before returning
- Update tests to filter for valid processes and better handle edge cases
- Improve test assertions to be more tolerant of system processes
2025-11-21 15:35:23 +02:00
pandaadir05
1fd0996375 fix: use platform-agnostic temp directory for test
- Replace hardcoded /tmp path with std::env::temp_dir()
- Fixes test_profile_persistence failure on Windows
- Removes unused PathBuf import
2025-11-21 15:29:12 +02:00
pandaadir05
a8fe6ed2f8 Fix CI/CD validation errors
- Add allow dead_code to unused helper function
- Remove redundant PID assertion in macOS test
- All clippy checks pass with -D warnings
- All tests passing (33/33)
2025-11-21 13:53:30 +02:00
pandaadir05
f0606d7835 fix: cargo formatting for ci/cd 2025-11-21 12:52:08 +02:00
pandaadir05
2bcfcac407 Fix anomaly detection issues and add missing functionality
Fixed issues:
- Corrected Welford's online algorithm for variance calculation
- Added NaN and infinity guards to prevent invalid calculations
- Added Serialize/Deserialize traits to AnomalyScore and ProcessProfile

Added functionality:
- Profile persistence with save_profiles() and load_profiles()
- Global baseline computation from all process profiles
- Profile cleanup method to remove stale profiles
- Additional utility methods for profile management
2025-11-21 12:49:42 +02:00
pandaadir05
655585d9ef Fix all clippy lints and pass CI checks
- Box large enum variants in EventData to reduce memory footprint
- Add Default trait implementations for types with new() methods
- Replace or_insert_with(Vec::new) with or_default()
- Convert vec init+push patterns to vec! macro
- Fix field reassignment with default initialization
- Convert match to if for simple equality checks
- Remove unused Backend type parameters from TUI draw functions
- Apply rustfmt formatting

All tests passing (24 total). Zero clippy warnings. Ready for CI/CD.
2025-11-20 15:13:16 +02:00
pandaadir05
27dffbd108 Fix formatting issues for CI/CD 2025-11-20 14:55:46 +02:00
pandaadir05
934b367f49 Re-enable disabled tests and reduce warnings to 8 2025-11-20 14:53:31 +02:00
pandaadir05
9d684cab19 Disable outdated tests with TODO comments 2025-11-20 14:26:25 +02:00
pandaadir05
b1f098571d feat: Add PE header validation and LD_PRELOAD detection 2025-11-17 22:02:41 +02:00
Adir Shitrit
47c58f6b50 add comprehensive unit tests for detection engine 2025-11-08 11:11:06 +02:00