Skip to content

feat: Add KYC file upload validation (#936) - #1025

Open
Kenlachy wants to merge 4 commits into
Fracverse:masterfrom
Kenlachy:issue-936-kyc-upload-validation
Open

feat: Add KYC file upload validation (#936)#1025
Kenlachy wants to merge 4 commits into
Fracverse:masterfrom
Kenlachy:issue-936-kyc-upload-validation

Conversation

@Kenlachy

Copy link
Copy Markdown

Add KYC file upload validation

  • Add multipart support to axum for file upload handling
  • Implement file type validation (JPEG, PNG, PDF only)
  • Implement 10MB file size limit to prevent storage overflow
  • Add proper error responses for validation failures
  • Return detailed file metadata on successful upload

closes #936

github-actions Bot added 3 commits July 29, 2026 23:41
- Add liveness_expiration field to InheritancePlan struct
- Add LivenessExpired error variant for emergency exit validation
- Implement withdraw_plan function with owner signature verification
- Add liveness expiration check (30 days from plan creation)
- Implement secure token transfer back to owner
- Add reentrancy protection by deactivating plan before transfer
- Add comprehensive test suite for withdraw_plan functionality
- Tests cover success case, liveness expiration, unauthorized access, and event emission
- Implement InheritX smart contract in Solidity
- Add withdraw_plan function for emergency exit
- Owner signature verification via msg.sender
- Liveness expiration check (30 days default)
- Safe token transfers using OpenZeppelin SafeERC20
- Reentrancy protection by deactivating plan before transfer
- Add plan creation and yield accumulation functions
- Add view functions for plan details and withdrawal checks
- Add multipart support to axum for file upload handling
- Implement file type validation (JPEG, PNG, PDF only)
- Implement 10MB file size limit to prevent storage overflow
- Add proper error responses for validation failures
- Return detailed file metadata on successful upload
@drips-wave

drips-wave Bot commented Jul 29, 2026

Copy link
Copy Markdown

@Kenlachy 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

@ONEONUORA

Copy link
Copy Markdown
Contributor

@Kenlachy
Make implementation to pass CI checks

@ONEONUORA

Copy link
Copy Markdown
Contributor

@Kenlachy
Update on this PR

@ONEONUORA

Copy link
Copy Markdown
Contributor

@Kenlachy
Run cargo fmt --all -- --check

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.

[Backend] Issue #27: Support KYC File Upload Validation

2 participants