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 v1.0.2
An implementation of BIP-0039 in Swift
⭐️ 3
🕓 1 week ago
iOS macOS
.package(url: "https://github.com/anquii/BIP39.git", from: "v1.0.2")


Platform Swift Package Manager compatible License

An implementation of BIP-0039 in Swift.


  • macOS 10.15+
  • iOS 13+


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.


import BIP39

let entropyGenerator: EntropyGenerating = EntropyGenerator()
let entropy = try 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 = try seedDerivator.seed(mnemonic: mnemonic, passphrase: "")


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


In developing BIP39, KevinVitale's WalletKit has been used as a reference implementation. In addition, BIP39 depends on krzyzanowskim's CryptoSwift for crypto operations.


Stars: 3
Last commit: 1 week ago
jonrohan Something's broken? Yell at me @ptrpavlik. Praise and feedback (and money) is also welcome.

Release Notes

1 week ago

Updated SeedDerivator to encode the given mnemonic and passphrase as UTF-8 NFKD before using them as input in the PBKDF2 function when derivating the binary seed.

Full Changelog: https://github.com/anquii/BIP39/compare/v1.0.1...v1.0.2

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