Skip to content

fix(crypto-wallet-core): add input validation and error handling to p…#4108

Open
amussara wants to merge 1 commit intobitpay:masterfrom
amussara:fix/proxy-input-validation-and-error-handling
Open

fix(crypto-wallet-core): add input validation and error handling to p…#4108
amussara wants to merge 1 commit intobitpay:masterfrom
amussara:fix/proxy-input-validation-and-error-handling

Conversation

@amussara
Copy link

@amussara amussara commented Feb 16, 2026

…roxy classes

  • Add proper input validation to ValidationProxy, DeriverProxy, and TransactionsProxy
  • Throw descriptive errors for unsupported chains instead of crashing on undefined
  • Add getSupportedChains() and isSupported() methods to all proxy classes
  • Add TypeScript type annotations to all proxy method parameters
  • Improve ETH/XRP validation with explicit URI parameter validation
  • Add try-catch to XRP address validation to handle malformed base58 inputs
  • Add comprehensive test suite for proxy error handling and edge cases
  • Validate address/URI inputs are non-empty strings before delegating

Description

Link to an issue if one exists and/or briefly describe what this PR does and why it's needed.

Changelog

  • Add bullet points summarizing your changes.

Testing Notes

Add any helpful notes for reviewers to test your code here.


Checklist

  • I have read CONTRIBUTING.md and verified that this PR follows the guidelines and requirements outlined in it.
  • I have added the appropriate package tag(s) (e.g. BWC if modifying the bitcore-wallet-client package, CLI if modifying the bitcore-cli package, etc.)
  • I have verified that this is not an existing PR (open or closed)

…roxy classes

- Add proper input validation to ValidationProxy, DeriverProxy, and TransactionsProxy
- Throw descriptive errors for unsupported chains instead of crashing on undefined
- Add getSupportedChains() and isSupported() methods to all proxy classes
- Add TypeScript type annotations to all proxy method parameters
- Improve ETH/XRP validation with explicit URI parameter validation
- Add try-catch to XRP address validation to handle malformed base58 inputs
- Add comprehensive test suite for proxy error handling and edge cases
- Validate address/URI inputs are non-empty strings before delegating
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.

1 participant

Comments