Home | Platform SDK

BIP38

The BIP38 class provides methods to extract the numerical value out of any currency representation by normalising the input and removing any locale specific rules like symbols and use of commas.

Importing the BIP38 class

import { BIP38 } from "@arkecosystem/platform-sdk-crypto";

Encrypt a buffer with the given mnemonic

BIP38.encrypt(someBuffer, "password");

Decrypt a string with the given mnemonic

BIP38.decrypt(BIP38.encrypt(someBuffer, "password"), "password");

Decrypt a string with the given mnemonic

BIP38.verify(BIP38.encrypt("message", "password"));

2020 © ARK.io | All rights reserved | An ARK.io Product