Skip to content

Conversation

@hansott
Copy link
Member

@hansott hansott commented Nov 18, 2025

No description provided.


export class AttackWaveDetector {
private suspiciousRequestsMap: LRUMap<string, number>;
private suspiciousRequestsMap: LRUMap<string, SuspiciousRequest[]>;
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Only an idea: If we would use a separate Set, we would not store or show duplicates and we can keep the amount of samples independent from the count needed for triggering the event, if needed in the future.

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Good idea!

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We can't use a Set because they don't work on objects :(

@codecov
Copy link

codecov bot commented Nov 21, 2025

Codecov Report

❌ Patch coverage is 91.35802% with 7 lines in your changes missing coverage. Please review.

Files with missing lines Patch % Lines
library/agent/Agent.ts 76.47% 4 Missing ⚠️
...lities/attack-wave-detection/AttackWaveDetector.ts 94.23% 3 Missing ⚠️

📢 Thoughts on this report? Let us know!

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.

3 participants