Skip to content

Add reusable cryptographic parameter validation framework - #1817

Merged
csxark merged 2 commits into
csxark:mainfrom
revatikadam0607:feat/1772
Aug 31, 2026
Merged

Add reusable cryptographic parameter validation framework#1817
csxark merged 2 commits into
csxark:mainfrom
revatikadam0607:feat/1772

Conversation

@revatikadam0607

Copy link
Copy Markdown
Contributor

Summary

Introduce a reusable schema-based cryptographic parameter validation framework.

Changes

  • Added reusable algorithm parameter schemas.
  • Added support for required parameters, accepted types, numeric ranges, hexadecimal lengths, enumerated values, and composite parameters.
  • Added cross-parameter dependency validation.
  • Added algorithm-specific validation for important symmetric, asymmetric, and KDF algorithms.
  • Added generic schemas for all registered algorithms.
  • Added structured validation errors identifying the invalid parameter and expected constraint.
  • Performed validation inside the worker before the cryptographic algorithm is loaded or executed.
  • Preserved existing algorithm-level validation as a second layer.
  • Exposed structured validation details to the UI.
  • Added security and educational warnings to parameter schemas.
  • Added tests covering schema exposure, boundary values, invalid key lengths, invalid nonce lengths, cross-parameter validation, and structured errors.

Result

Invalid cryptographic configurations are rejected consistently before execution, while the UI receives enough structured information to explain which parameter is invalid and what constraint was expected.

Closes #1772
@csxark
I've resolved the issue. Kindly review it, and if everything looks good, please consider merging the corresponding PR.

@vercel

vercel Bot commented Aug 31, 2026

Copy link
Copy Markdown

@revatikadam0607 is attempting to deploy a commit to the csxark's projects Team on Vercel.

A member of the Team first needs to authorize it.

@coderabbitai

coderabbitai Bot commented Aug 31, 2026

Copy link
Copy Markdown
Contributor

Warning

Review limit reached

Next included review available in 10 minutes.

View limit details

Limit details: You’ve used the included review currently available.

You've used all free OSS reviews for now. Wait for the free limit to reset to keep reviewing this public repository.

Learn how review limits work.

Review configuration:

⚙️ Run configuration

Configuration used: defaults

Review profile: CHILL

Plan: Pro Plus

Run ID: 67dcf6c5-cb5b-40d2-95f3-5e1aa6a42f6b

📥 Commits

Reviewing files that changed from the base of the PR and between 24f6111 and c485f52.

📒 Files selected for processing (15)
  • components/cipher/CipherExecutionController.ts
  • components/cipher/CipherLayout.tsx
  • hooks/useCipherWorker.ts
  • lib/cipher/parameterValidation.ts
  • lib/cipher/registry.ts
  • lib/cipher/stepVirtualization.ts
  • lib/trace/traceBuffer.ts
  • lib/utils/errors.ts
  • lib/workers/cipher.worker.ts
  • tests/unit/cipher/traceBuffer.test.ts
  • tests/unit/cipherParameterValidation.test.ts
  • tests/unit/components/cipher/CipherExecutionController.test.ts
  • tests/unit/workers/cipherWorker.test.ts
  • tests/unit/workers/stepTransfer.test.ts
  • types/worker.ts

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

@github-actions

Copy link
Copy Markdown
Contributor

🎉 Thank You for Your Contribution

Hello @revatikadam0607,

Thank you for submitting a Pull Request to CryptoViz. We appreciate the time and effort you've invested in contributing to the project.

Your Pull Request has been received successfully and will be reviewed by the maintainers as soon as possible.

📋 Pull Request Checklist

  • ✅ Linked the related issue
  • ✅ No merge conflicts
  • ✅ Synced with the latest main branch
  • ✅ Build passes successfully
  • ✅ All tests pass

Ensuring these requirements are met helps streamline the review process and enables maintainers to review your contribution more efficiently.

❤️ Support CryptoViz

If you find CryptoViz helpful, consider supporting the project by:

  • ⭐ Starring the repository
  • 🍴 Forking the repository
  • 👤 Following Ark on GitHub
  • 💼 Connecting on LinkedIn
  • 🌐 Visiting the Portfolio

Your support helps increase the project's visibility and encourages continued development. Thank you for being a part of the CryptoViz community!

Thank you once again for contributing to CryptoViz. We appreciate your support and look forward to reviewing your contribution.

@csxark csxark added ECSoC26 Elite Coders Summer of Code 2026 and removed needs review labels Aug 31, 2026
@csxark
csxark merged commit aca28f9 into csxark:main Aug 31, 2026
4 of 10 checks passed
@github-actions

Copy link
Copy Markdown
Contributor

🎉 Pull Request Merged

Hello @revatikadam0607,

Thank you for your contribution to CryptoViz. Your Pull Request has been reviewed and successfully merged into the project.

We sincerely appreciate the time and effort you invested in improving the project. Contributions like yours help make CryptoViz better for the entire community.

We look forward to your future contributions and hope to collaborate with you again.

❤️ Support CryptoViz

If you find CryptoViz helpful, consider supporting the project by:

  • ⭐ Starring the repository
  • 🍴 Forking the repository
  • 👤 Following Ark on GitHub
  • 💼 Connecting on LinkedIn
  • 🌐 Visiting the Portfolio

Your support helps increase the project's visibility and encourages continued development. Thank you for being a part of the CryptoViz community!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

ECSoC26-L3 ECSoC26 Elite Coders Summer of Code 2026

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Cryptographic Parameter Validation Framework

2 participants