Feat/alerts and enterprise#38
Merged
Merged
Conversation
List company alerts with severity color coding, search and severity/status filters. Acknowledge and resolve inline via a company-scoped PATCH route.
Export the currently filtered rows to CSV from each page, generated client-side without a round trip.
Send one Resend email per new breach record to company admins, with the employee, breach, exposed data and a link to the alerts page. Gated on RESEND_API_KEY and EMAIL_FROM; failures never abort a scan.
In-memory fixed-window limiter: 10 login attempts/min per email to slow brute force, 5 scans/min per company to protect the expensive breach lookups.
Add Webhook model with AES-encrypted URLs. Admins manage endpoints on the Data API page (add, enable, test, delete) with a minimum severity filter. New breach exposures are dispatched alongside email.
Single source of truth for route authorization, replacing the duplicated session/role guards. Behavior unchanged: config routes stay admin-only, operational routes (scan, alert triage) stay open to any authenticated user. Dashboard preset routes keep their own ownership logic.
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.
Summary
Type of change
Checklist