Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

From confidential #138

Merged
merged 2 commits into from
Nov 6, 2020
Merged

From confidential #138

merged 2 commits into from
Nov 6, 2020

Conversation

altafan
Copy link
Collaborator

@altafan altafan commented Nov 6, 2020

This adds the methods FromBase58Confidential and ToBase58Confidential useful for the user to parse confidential legay P2PKH and P2SH addresses, like FromBlech32 and ToBlech32 do for those bech32 confidentials.

This also adds 2 new methods FromConfidential and ToConfidential that help the user to convert an address from the confidential to the unconfidential format and viceversa.

The last method added with this is NetworkFromAddress that is useful for knowing the network (either mainnet or regtest) an address refers to.

In conclusion, this refactors the tests for the address package to increase order and readability, along with adding tests for the new methods mentioned above.

Please @tiero, review this.

@tiero tiero merged commit f8c2715 into vulpemventures:master Nov 6, 2020
@altafan altafan deleted the from-confidential branch November 17, 2020 14:28
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.

None yet

2 participants