Merged
Conversation
|
@SatyamPandey-07 is attempting to deploy a commit to the Om Roy's projects Team on Vercel. A member of the Team first needs to authorize it. |
Thanks for creating a PR for your Issue!
|
Owner
|
Conflict |
Contributor
Author
|
No conflicts with base branch |
a9369e4 to
e67992c
Compare
…and farm management modules
|
🎉 Congrats @SatyamPandey-07 on getting your PR merged! 🙌 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Auditing Core & Intelligence
backend/models/audit_log.py
: A high-fidelity schema for recording security events, including differential value analysis (JSON diffs), gravity scores, and risk levels. It also includes
UserSession
tracking for session management.
backend/services/audit_service.py
: The "brain" of the audit system. Features include:
Threat Detection: Heuristics for detecting brute-force attacks, SQL injection patterns, and automated sensitive operations.
Forensic Analysis: Multi-vector search capabilities for security investigations.
Behavioral Tracking: Anomaly detection by comparing current activity against historical user norms.
Compliance Export: Generates encrypted audit trails in JSON/CSV formats.
Middleware & Integration
backend/middleware/audit.py
: Global middleware that intercepting all state-changing requests (POST, PUT, DELETE) and sensitive paths. It also provides an @audit_request decorator for granular control over critical endpoints.
app.py
: Registered the audit middleware globally and initialized the system-wide tracking.
Security Integration: Refactored
security_utils.py
and
auth_utils.py
to route all security events through the unified audit registry.
Module-Specific Auditing
Authentication (
auth.py
): Audits registrations, password resets, and email verifications.
Financial & Market (
market.py
,
loan.py
): Tracks market watchlist updates, manual price refreshes, and AI-driven loan eligibility checks.
Community (
forum.py
): Audits thread creation, moderation actions (flagging), and category management.
Asset Management (
assets.py
): Records high-value transactions like asset registration, failure predictions, and retirement.
Administrative Interface & Automation
audit_dashboard.html
: A premium, real-time monitoring interface for admins featuring:
Live interaction statistics (24h).
Threat detection alerts with pulse animations.
Dynamic risk distribution charts (Chart.js).
Forensic log stream with risk-level badging.
backend/tasks/audit_tasks.py
: Celery tasks for automated session purging, daily forensic reporting, and audit log rotation (retention management).
closes #1460