Skip to content

feat: implement #723, #725, #726, #727 - IP block, audit-log validation#848

Merged
nanaf6203-bit merged 3 commits into
MettaChain:mainfrom
monique-7arch:feat/monique-7arch-issues
Jun 29, 2026
Merged

feat: implement #723, #725, #726, #727 - IP block, audit-log validation#848
nanaf6203-bit merged 3 commits into
MettaChain:mainfrom
monique-7arch:feat/monique-7arch-issues

Conversation

@monique-7arch

Copy link
Copy Markdown
Contributor

Closes #723, Closes #725, Closes #726, Closes #727

#723 - Block re-registration from same IP

Added in-memory IP tracking to prevent registration from the same IP until the pending email verification is completed or expires. registrationIpMap tracks IP-to-email mappings. IP entry is cleared on successful verification or token expiry.

#725 - Add @type(() => Date) to audit-log DTO

Already implemented - audit-log-query.dto.ts has @type(() => Date) on both dateFrom and dateTo.

#726 - Add @IsOptional and @IsISO8601

Already implemented - DTO has @IsOptional() and @IsISO8601() on date fields.

#727 - Add validation tests for audit-log date params

Added unit tests verifying malformed date strings return 400 rather than 500.

@drips-wave

drips-wave Bot commented Jun 29, 2026

Copy link
Copy Markdown

@monique-7arch Great news! 🎉 Based on an automated assessment of this PR, the linked Wave issue(s) no longer count against your application limits.

You can now already apply to more issues while waiting for a review of this PR. Keep up the great work! 🚀

Learn more about application limits

@monique-7arch monique-7arch force-pushed the feat/monique-7arch-issues branch from 9792fff to fa42766 Compare June 29, 2026 13:51
@monique-7arch monique-7arch force-pushed the feat/monique-7arch-issues branch from fa42766 to 221d266 Compare June 29, 2026 14:03
IsISO8601 + Type(() => Date) fails validation because class-transformer
converts the string to a Date before class-validator runs. IsDateString
validates the raw string input correctly.

@nanaf6203-bit nanaf6203-bit left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

LGTM

@nanaf6203-bit nanaf6203-bit merged commit b1c49ed into MettaChain:main Jun 29, 2026
5 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

2 participants