{"id":17018375,"url":"https://github.com/darosior/python-bip32","last_synced_at":"2026-04-01T17:02:00.611Z","repository":{"id":38830535,"uuid":"239892116","full_name":"darosior/python-bip32","owner":"darosior","description":"Minimalistic implementation of BIP32","archived":false,"fork":false,"pushed_at":"2025-11-13T19:03:45.000Z","size":125,"stargazers_count":51,"open_issues_count":14,"forks_count":29,"subscribers_count":3,"default_branch":"master","last_synced_at":"2026-03-27T23:42:21.214Z","etag":null,"topics":["bip32","bitcoin","hdwallet","wallet"],"latest_commit_sha":null,"homepage":"","language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"bsd-3-clause","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/darosior.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null,"notice":null,"maintainers":null,"copyright":null,"agents":null,"dco":null,"cla":null}},"created_at":"2020-02-12T00:15:54.000Z","updated_at":"2026-01-28T09:43:40.000Z","dependencies_parsed_at":"2024-01-23T10:14:23.611Z","dependency_job_id":"eea29147-bb72-4b2e-8caf-d1eecd3410c1","html_url":"https://github.com/darosior/python-bip32","commit_stats":{"total_commits":69,"total_committers":5,"mean_commits":13.8,"dds":0.07246376811594202,"last_synced_commit":"1492d39312f1d9630363c292f6ab8beb8ceb16dd"},"previous_names":[],"tags_count":9,"template":false,"template_full_name":null,"purl":"pkg:github/darosior/python-bip32","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/darosior%2Fpython-bip32","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/darosior%2Fpython-bip32/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/darosior%2Fpython-bip32/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/darosior%2Fpython-bip32/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/darosior","download_url":"https://codeload.github.com/darosior/python-bip32/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/darosior%2Fpython-bip32/sbom","scorecard":{"id":323076,"data":{"date":"2025-08-11","repo":{"name":"github.com/darosior/python-bip32","commit":"0a26152327c0902a4d1fdf226c4a802ecd553969"},"scorecard":{"version":"v5.2.1-40-gf6ed084d","commit":"f6ed084d17c9236477efd66e5b258b9d4cc7b389"},"score":3.6,"checks":[{"name":"Dangerous-Workflow","score":10,"reason":"no dangerous workflow patterns detected","details":null,"documentation":{"short":"Determines if the project's GitHub Action workflows avoid dangerous patterns.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#dangerous-workflow"}},{"name":"Code-Review","score":2,"reason":"Found 2/9 approved changesets -- score normalized to 2","details":null,"documentation":{"short":"Determines if the project requires human code review before pull requests (aka merge requests) are merged.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#code-review"}},{"name":"Packaging","score":-1,"reason":"packaging workflow not detected","details":["Warn: no GitHub/GitLab publishing workflow detected."],"documentation":{"short":"Determines if the project is published as a package that others can easily download, install, easily update, and uninstall.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#packaging"}},{"name":"Binary-Artifacts","score":10,"reason":"no binaries found in the repo","details":null,"documentation":{"short":"Determines if the project has generated executable (binary) artifacts in the source repository.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#binary-artifacts"}},{"name":"Maintained","score":0,"reason":"0 commit(s) and 0 issue activity found in the last 90 days -- score normalized to 0","details":null,"documentation":{"short":"Determines if the project is \"actively maintained\".","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#maintained"}},{"name":"Token-Permissions","score":0,"reason":"detected GitHub workflow tokens with excessive permissions","details":["Warn: no topLevel permission defined: .github/workflows/python-package.yml:1","Info: no jobLevel write permissions found"],"documentation":{"short":"Determines if the project's workflows follow the principle of least privilege.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#token-permissions"}},{"name":"Pinned-Dependencies","score":0,"reason":"dependency not pinned by hash detected -- score normalized to 0","details":["Warn: GitHub-owned GitHubAction not pinned by hash: .github/workflows/python-package.yml:22: update your workflow using https://app.stepsecurity.io/secureworkflow/darosior/python-bip32/python-package.yml/master?enable=pin","Warn: GitHub-owned GitHubAction not pinned by hash: .github/workflows/python-package.yml:24: update your workflow using https://app.stepsecurity.io/secureworkflow/darosior/python-bip32/python-package.yml/master?enable=pin","Warn: GitHub-owned GitHubAction not pinned by hash: .github/workflows/python-package.yml:46: update your workflow using https://app.stepsecurity.io/secureworkflow/darosior/python-bip32/python-package.yml/master?enable=pin","Warn: GitHub-owned GitHubAction not pinned by hash: .github/workflows/python-package.yml:48: update your workflow using https://app.stepsecurity.io/secureworkflow/darosior/python-bip32/python-package.yml/master?enable=pin","Warn: GitHub-owned GitHubAction not pinned by hash: .github/workflows/python-package.yml:64: update your workflow using https://app.stepsecurity.io/secureworkflow/darosior/python-bip32/python-package.yml/master?enable=pin","Warn: GitHub-owned GitHubAction not pinned by hash: .github/workflows/python-package.yml:66: update your workflow using https://app.stepsecurity.io/secureworkflow/darosior/python-bip32/python-package.yml/master?enable=pin","Warn: pipCommand not pinned by hash: .github/workflows/python-package.yml:53","Warn: pipCommand not pinned by hash: .github/workflows/python-package.yml:54","Warn: pipCommand not pinned by hash: .github/workflows/python-package.yml:71","Warn: pipCommand not pinned by hash: .github/workflows/python-package.yml:72","Warn: pipCommand not pinned by hash: .github/workflows/python-package.yml:73","Warn: pipCommand not pinned by hash: .github/workflows/python-package.yml:74","Warn: pipCommand not pinned by hash: .github/workflows/python-package.yml:29","Warn: pipCommand not pinned by hash: .github/workflows/python-package.yml:30","Warn: pipCommand not pinned by hash: .github/workflows/python-package.yml:35","Warn: pipCommand not pinned by hash: .github/workflows/python-package.yml:40","Info:   0 out of   6 GitHub-owned GitHubAction dependencies pinned","Info:   0 out of  10 pipCommand dependencies pinned"],"documentation":{"short":"Determines if the project has declared and pinned the dependencies of its build process.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#pinned-dependencies"}},{"name":"CII-Best-Practices","score":0,"reason":"no effort to earn an OpenSSF best practices badge detected","details":null,"documentation":{"short":"Determines if the project has an OpenSSF (formerly CII) Best Practices Badge.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#cii-best-practices"}},{"name":"Security-Policy","score":0,"reason":"security policy file not detected","details":["Warn: no security policy file detected","Warn: no security file to analyze","Warn: no security file to analyze","Warn: no security file to analyze"],"documentation":{"short":"Determines if the project has published a security policy.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#security-policy"}},{"name":"Fuzzing","score":0,"reason":"project is not fuzzed","details":["Warn: no fuzzer integrations found"],"documentation":{"short":"Determines if the project uses fuzzing.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#fuzzing"}},{"name":"License","score":10,"reason":"license file detected","details":["Info: project has a license file: LICENCE:0","Info: FSF or OSI recognized license: BSD 3-Clause \"New\" or \"Revised\" License: LICENCE:0"],"documentation":{"short":"Determines if the project has defined a license.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#license"}},{"name":"Vulnerabilities","score":10,"reason":"0 existing vulnerabilities detected","details":null,"documentation":{"short":"Determines if the project has open, known unfixed vulnerabilities.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#vulnerabilities"}},{"name":"Signed-Releases","score":-1,"reason":"no releases found","details":null,"documentation":{"short":"Determines if the project cryptographically signs release artifacts.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#signed-releases"}},{"name":"Branch-Protection","score":0,"reason":"branch protection not enabled on development/release branches","details":["Warn: branch protection not enabled for branch 'master'"],"documentation":{"short":"Determines if the default and release branches are protected with GitHub's branch protection settings.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#branch-protection"}},{"name":"SAST","score":0,"reason":"SAST tool is not run on all commits -- score normalized to 0","details":["Warn: 0 commits out of 29 are checked with a SAST tool"],"documentation":{"short":"Determines if the project uses static code analysis.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#sast"}}]},"last_synced_at":"2025-08-18T01:50:53.656Z","repository_id":38830535,"created_at":"2025-08-18T01:50:53.656Z","updated_at":"2025-08-18T01:50:53.656Z"},"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":31290538,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-04-01T13:12:26.723Z","status":"ssl_error","status_checked_at":"2026-04-01T13:12:25.102Z","response_time":53,"last_error":"SSL_read: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["bip32","bitcoin","hdwallet","wallet"],"created_at":"2024-10-14T06:45:41.438Z","updated_at":"2026-04-01T17:02:00.562Z","avatar_url":"https://github.com/darosior.png","language":"Python","funding_links":[],"categories":[],"sub_categories":[],"readme":"# python-bip32\n\nA minimalistic implementation of [BIP 32](https://github.com/bitcoin/bips/blob/master/bip-0032.mediawiki).\n\n## Usage\n\n```python\n\u003e\u003e\u003e from bip32 import BIP32, HARDENED_INDEX\n\u003e\u003e\u003e bip32 = BIP32.from_seed(bytes.fromhex(\"01\"))\n# Specify the derivation path as a list ...\n\u003e\u003e\u003e bip32.get_xpriv_from_path([1, HARDENED_INDEX, 9998])\n'xprv9y4sBgCuub5x2DtbdNBDDCZ3btybk8YZZaTvzV5rmYd3PbU63XLo2QEj6cUt4JAqpF8gJiRKFUW8Vm7thPkccW2DpUvBxASycypEHxmZzts'\n# ... Or in usual m/the/path/\n\u003e\u003e\u003e bip32.get_xpriv_from_path(\"m/1/0'/9998\")\n'xprv9y4sBgCuub5x2DtbdNBDDCZ3btybk8YZZaTvzV5rmYd3PbU63XLo2QEj6cUt4JAqpF8gJiRKFUW8Vm7thPkccW2DpUvBxASycypEHxmZzts'\n\u003e\u003e\u003e bip32.get_xpub_from_path([HARDENED_INDEX, 42])\n'xpub69uEaVYoN1mZyMon8qwRP41YjYyevp3YxJ68ymBGV7qmXZ9rsbMy9kBZnLNPg3TLjKd2EnMw5BtUFQCGrTVDjQok859LowMV2SEooseLCt1'\n# You can also use \"h\" or \"H\" to signal for hardened derivation\n\u003e\u003e\u003e bip32.get_xpub_from_path(\"m/0h/42\")\n'xpub69uEaVYoN1mZyMon8qwRP41YjYyevp3YxJ68ymBGV7qmXZ9rsbMy9kBZnLNPg3TLjKd2EnMw5BtUFQCGrTVDjQok859LowMV2SEooseLCt1'\n# You can use pubkey-only derivation\n\u003e\u003e\u003e bip32 = BIP32.from_xpub(\"xpub6AKC3u8URPxDojLnFtNdEPFkNsXxHfgRhySvVfEJy9SVvQAn14XQjAoFY48mpjgutJNfA54GbYYRpR26tFEJHTHhfiiZZ2wdBBzydVp12yU\")\n\u003e\u003e\u003e bip32.get_xpub_from_path([42, 43])\n'xpub6FL7T3s7GuVb4od1gvWuumhg47y6TZtf2DSr6ModQpX4UFGkQXw8oEVhJXcXJ4edmtAWCTrefD64B9RP4sYSkSumTW1wadTS3SYurBGYccT'\n\u003e\u003e\u003e bip32.get_xpub_from_path(\"m/42/43\")\n'xpub6FL7T3s7GuVb4od1gvWuumhg47y6TZtf2DSr6ModQpX4UFGkQXw8oEVhJXcXJ4edmtAWCTrefD64B9RP4sYSkSumTW1wadTS3SYurBGYccT'\n\u003e\u003e\u003e bip32.get_pubkey_from_path(\"m/1/1/1/1/1/1/1/1/1/1/1\")\nb'\\x02\\x0c\\xac\\n\\xa8\\x06\\x96C\\x8e\\x9b\\xcf\\x83]\\x0c\\rCm\\x06\\x1c\\xe9T\\xealo\\xa2\\xdf\\x195\\xebZ\\x9b\\xb8\\x9e'\n```\n\n## Installation\n\n```\npip install bip32\n```\n\n### Dependencies\n\nThis uses [`coincurve`](https://github.com/ofek/coincurve) as a wrapper for [`libsecp256k1`](https://github.com/bitcoin-core/secp256k1) for EC operations.\n\n### Running the test suite\n\n```\n# From the root of the repository\npython3 -m venv venv\n. venv/bin/activate\npip install -r tests/requirements.txt \u0026\u0026 pip install pytest\nPYTHONPATH=$PYTHONPATH:$PWD/bip32 pytest -vvv\n```\n\n## Interface\n\nAll public keys below are compressed.\n\nAll `path` below are a list of integers representing the index of the key at each depth.\n\n### BIP32\n\n#### from_seed(seed)\n\n__*classmethod*__\n\nInstanciate from a raw seed (as `bytes`). See [bip-0032's master key\ngeneration](https://github.com/bitcoin/bips/blob/master/bip-0032.mediawiki#master-key-generation).\n\n#### from_xpriv(xpriv)\n\n__*classmethod*__\n\nInstanciate with an encoded serialized extended private key (as `str`) as master.\n\n#### from_xpub(xpub)\n\n__*classmethod*__\n\nInstanciate with an encoded serialized extended public key (as `str`) as master.\n\nYou'll only be able to derive unhardened public keys.\n\n#### get_extended_privkey_from_path(path)\n\nReturns `(chaincode (bytes), privkey (bytes))` of the private key pointed by the path.\n\n#### get_privkey_from_path(path)\n\nReturns `privkey (bytes)`, the private key pointed by the path.\n\n#### get_extended_pubkey_from_path(path)\n\nReturns `(chaincode (bytes), pubkey (bytes))` of the public key pointed by the path.\n\nNote that you don't need to have provided the master private key if the path doesn't\ninclude an index `\u003e= HARDENED_INDEX`.\n\n#### get_pubkey_from_path(path)\n\nReturns `pubkey (bytes)`, the public key pointed by the path.\n\nNote that you don't need to have provided the master private key if the path doesn't\ninclude an index `\u003e= HARDENED_INDEX`.\n\n#### get_xpriv_from_path(path)\n\nReturns `xpriv (str)` the serialized and encoded extended private key pointed by the given\npath.\n\n#### get_xpub_from_path(path)\n\nReturns `xpub (str)` the serialized and encoded extended public key pointed by the given\npath.\n\nNote that you don't need to have provided the master private key if the path doesn't\ninclude an index `\u003e= HARDENED_INDEX`.\n\n#### get_xpriv()\n\nEquivalent to `get_xpriv_from_path([])`.\n\n#### get_xpriv_bytes()\n\nEquivalent to `get_xpriv([])`, but not serialized in base58.\n\n#### get_xpub()\n\nEquivalent to `get_xpub_from_path([])`.\n\n#### get_xpub_bytes()\n\nEquivalent to `get_xpub([])`, but not serialized in base58.\n\n#### get_fingerprint()\n\nReturns `fingerprint (bytes)`, equivalent to `utils._pubkey_to_fingerprint(self.pubkey)`.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdarosior%2Fpython-bip32","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fdarosior%2Fpython-bip32","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdarosior%2Fpython-bip32/lists"}