Skip to content

Conversation

@terrier989
Copy link
Member

No description provided.

Copilot AI review requested due to automatic review settings November 21, 2025 20:31
Copilot finished reviewing on behalf of terrier989 November 21, 2025 20:33
Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull request overview

This PR adds browser-based Web Cryptography API implementations for Ed25519 and X25519 algorithms with fallback to Dart implementations. It also refactors Ed25519 validation logic into static helper methods and reorganizes imports for consistency.

Key changes:

  • Introduces BrowserEd25519 and BrowserX25519 classes that leverage Web Cryptography API
  • Refactors Ed25519 validation into reusable static methods (checkPrivateKeyLength, checkPublicKeyLength, checkSignatureLength)
  • Standardizes import ordering across browser implementation files

Reviewed changes

Copilot reviewed 13 out of 13 changed files in this pull request and generated 6 comments.

Show a summary per file
File Description
cryptography/lib/src/browser/ed25519.dart New BrowserEd25519 implementation with Web Crypto API support and fallback
cryptography/lib/src/browser/x25519.dart New BrowserX25519 implementation with Web Crypto API support and fallback
cryptography/lib/src/dart/ed25519.dart Refactored to use static validation methods from Ed25519 base class
cryptography/lib/src/browser/browser_cryptography.dart Integrated new ed25519() and x25519() methods, reordered imports
cryptography/lib/src/browser/browser_cryptography_when_not_browser.dart Reordered isRunningInWasm and isSupported getters
cryptography/lib/src/browser/rsa_ssa_pkcs1v15.dart Standardized import ordering
cryptography/lib/src/browser/rsa_pss.dart Standardized import ordering
cryptography/lib/src/browser/pbkdf2.dart Standardized import ordering
cryptography/lib/src/browser/aes_gcm.dart Standardized import ordering
cryptography/lib/src/browser/aes_ctr.dart Standardized import ordering
cryptography/lib/src/browser/aes_cbc.dart Standardized import ordering
cryptography/lib/src/browser/_javascript_bindings.dart Added blank lines for better formatting in CryptoKey extension type
cryptography_test/lib/algorithms/ed25519.dart Simplified test structure by removing anonymous function wrapper

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

@terrier989 terrier989 force-pushed the feature/browser_curve25519 branch from bfb58f1 to 313aae9 Compare November 21, 2025 21:17
@terrier989 terrier989 force-pushed the feature/browser_curve25519 branch from 313aae9 to 1ff9595 Compare November 21, 2025 21:19
@terrier989 terrier989 merged commit 777e6d2 into master Nov 21, 2025
24 checks passed
@terrier989 terrier989 deleted the feature/browser_curve25519 branch November 21, 2025 23:12
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.

2 participants