Swiftpack.co - anquii/BIP39 as Swift Package

Swiftpack.co is a collection of thousands of indexed Swift packages. Search packages.
See all packages published by anquii.
anquii/BIP39 v3.0.0
An implementation of BIP-0039 in Swift
⭐️ 3
🕓 16 weeks ago
iOS macOS
.package(url: "https://github.com/anquii/BIP39.git", from: "v3.0.0")

BIP39

Platform Swift Package Manager compatible License

An implementation of BIP-0039 in Swift. If needed, you can use BIP39UserFlow to launch a customizable user flow of BIP39.

Platforms

  • macOS 10.15+
  • iOS 13+

Installation

Swift Package Manager

Add the following line to your Package.swift file:

.package(url: "https://github.com/anquii/BIP39.git", from: "1.0.0")

...or integrate with Xcode via File -> Swift Packages -> Add Package Dependency... using the URL of the repository.

Usage

import BIP39

let entropyGenerator: EntropyGenerating = EntropyGenerator()
let entropy = entropyGenerator.entropy(security: .strongest)
let wordListProvider: WordListProviding = EnglishWordListProvider()

let mnemonicConstructor: MnemonicConstructing = MnemonicConstructor()
let mnemonic = mnemonicConstructor.mnemonic(entropy: entropy, wordList: wordListProvider.wordList)

let seedDerivator: SeedDerivating = SeedDerivator()
let seed = seedDerivator.seed(mnemonic: mnemonic, passphrase: "")

License

BIP39 is licensed under the terms of the MIT license. See the LICENSE file for more information.

Acknowledgments

In developing BIP39, KevinVitale's WalletKit has been used as a reference implementation.

Donations

If you've found this software useful, please consider making a small contribution to one of these crypto addresses:

XNAV: xNTYqoQDzsiB5Cff9Wpt65AgZxYkt1GFy7KwuDafqRU2bcAZqoZUW4Q9TZ9QRHSy8cPsM5ALkJasizJCmqSNP9CosxrF2RbKHuDz5uJVUBcKJfvnb3RZaWygr8Bhuqbpc3DsgfB3ayc
XMR: 49jzT7Amu9BCvc5q3PGiUzWXEBQTLQw68a2KvBFTMs7SHjeWgrSKgxs69ycFWQupyw9fpR6tdT8Hp5h3KksrBG9m4c8aXiG
BTC: bc1q7hehfmnq67x5k7vz0cnc75qyflkqtxe2avjkyw
ETH (ERC-20) & BNB (BEP-20): 0xe08e383B4042749dE5Df57d48c57A690DC322b8d

GitHub

link
Stars: 3
Last commit: 16 weeks ago
Advertisement: IndiePitcher.com - Cold Email Software for Startups

Release Notes

v3.0.0
16 weeks ago

Changes:

  • Removed dependency of CryptoSwift and replaced its use with CryptoKit and CommonCrypto
  • Removed EntropyGeneratorError and SeedDerivatorError given that no throwing should occur within a working implementation
  • Added dependency of BinaryExtensions to the BIP39Tests target

Full Changelog: https://github.com/anquii/BIP39/compare/v2.1.0...v3.0.0

Swiftpack is being maintained by Petr Pavlik | @ptrpavlik | @swiftpackco | API | Analytics