skillfed

poseidon-py

Python implementation of Poseidon hash

poseidon-py v0.2.0 108.7K downloads/30d#12,542 on PyPI4
License unclear Active released

What it is and what it does

Poseidon-py provides a Python wrapper around a C implementation of the Poseidon hash function with the Hades permutation, preconfigured with parameters used in Starknet. It is a cryptographic hash function designed for zero-knowledge proof systems and blockchain applications. The package compiles to native code for performance-critical hashing operations and is distributed as precompiled wheels for most common platforms (Linux, macOS, Windows across multiple architectures). With zero runtime dependencies, it integrates directly into Python applications that need Starknet-compatible hashing.

The package is actively maintained and supports modern Python versions (3.10 and later), with recent updates adding support for Python 3.13 and 3.14. Installation is straightforward on supported platforms via prebuilt wheels, though the compiled nature means some architectures may require local compilation. The Starknet parameter set is baked into the library, making it suitable for applications that specifically need Starknet-compatible hashing without configuration overhead.

Use it for:

  • Compute Poseidon hashes for Starknet smart contracts or off-chain verification
  • Implement zero-knowledge proof systems that require Starknet-compatible hash functions
  • Validate or generate Merkle trees using Poseidon hashing in blockchain applications
  • Integrate Starknet-compatible cryptographic operations into Python applications

Worth the install?

AI-flagged interpretation of the facts on this page — verify before relying

Poseidon hash implementation in Python with a C-based Hades permutation, configured for Starknet parameters.

Yes, if you need Starknet-compatible Poseidon hashing. The package is actively maintained, has no known vulnerabilities, zero runtime dependencies, and offers precompiled wheels for broad platform coverage. The main caveat is that the license status is unclear—verify the licensing terms before use in proprietary contexts. Install friction is moderate due to compilation requirements on unsupported architectures, but negligible on common platforms.

Install

poseidon-py on PyPI

pip

pip install poseidon-py

uv

uv add poseidon-py

poetry

poetry add poseidon-py

Installing poseidon-py

Before you install

Medium install friction due to compiled wheels across many platforms (x86_64, aarch64, armv7l, ppc64le, s390x, riscv64, Windows, macOS). Actively maintained with recent release (2026-03-26) and current repository activity.

License in practice

License status is unclear—no SPDX identifier or raw license text provided. Verify licensing before use in proprietary or commercial contexts.

Quickstart

pip install poseidon-py

import poseidon_py
# Hash computation using Starknet-configured parameters

Requires Python 3.10 or later; precompiled wheels available for common platforms but may require compilation on unsupported architectures.

Verify before relying

  • Exact API surface and available functions beyond the hash computation itself
  • Whether parameters in poseidon_params.txt are user-configurable or Starknet-only
  • Performance characteristics compared to other Poseidon implementations
  • Formal license under which the package is distributed

Package facts

License not declared (unclear)
Python support supports the current Python release (>=3.10)
Install friction medium — platform-specific wheel
Runtime dependencies none
Maintenance actively maintained — 141 days since the last release
Last repo commit
First released
Downloads 108,704/month — #12,542 on PyPI (30-day window, as of 2026-08-14)
Known vulnerabilities none known (OSV.dev, checked 2026-08-14)

Evidence: poseidon_py-0.2.0-cp310-cp310-macosx_11_0_universal2.whl; poseidon_py-0.2.0-cp310-cp310-manylinux1_x86_64.manylinux_2_28_x86_64.manylinux_2_5_x86_64.whl; poseidon_py-0.2.0-cp310-cp310-manylinux2014_aarch64.manylinux_2_17_aarch64.manylinux_2_28_aarch64.whl; poseidon_py-0.2.0-cp310-cp310-manylinux2014_armv7l.manylinux_2_17_armv7l.manylinux_2_31_armv7l.whl; poseidon_py-0.2.0-cp310-cp310-manylinux2014_ppc64le.manylinux_2_17_ppc64le.manylinux_2_28_ppc64le.whl; poseidon_py-0.2.0-cp310-cp310-manylinux2014_s390x.manylinux_2_17_s390x.manylinux_2_28_s390x.whl; poseidon_py-0.2.0-cp310-cp310-manylinux_2_31_riscv64.manylinux_2_39_riscv64.whl; poseidon_py-0.2.0-cp310-cp310-musllinux_1_2_aarch64.whl; poseidon_py-0.2.0-cp310-cp310-musllinux_1_2_armv7l.whl; poseidon_py-0.2.0-cp310-cp310-musllinux_1_2_ppc64le.whl; poseidon_py-0.2.0-cp310-cp310-musllinux_1_2_riscv64.whl; poseidon_py-0.2.0-cp310-cp310-musllinux_1_2_s390x.whl; poseidon_py-0.2.0-cp310-cp310-musllinux_1_2_x86_64.whl; poseidon_py-0.2.0-cp310-cp310-win32.whl; poseidon_py-0.2.0-cp310-cp310-win_amd64.whl; poseidon_py-0.2.0-cp311-cp311-macosx_11_0_universal2.whl; poseidon_py-0.2.0-cp311-cp311-manylinux1_x86_64.manylinux_2_28_x86_64.manylinux_2_5_x86_64.whl; poseidon_py-0.2.0-cp311-cp311-manylinux2014_aarch64.manylinux_2_17_aarch64.manylinux_2_28_aarch64.whl; poseidon_py-0.2.0-cp311-cp311-manylinux2014_armv7l.manylinux_2_17_armv7l.manylinux_2_31_armv7l.whl; poseidon_py-0.2.0-cp311-cp311-manylinux2014_ppc64le.manylinux_2_17_ppc64le.manylinux_2_28_ppc64le.whl

Tags

poseidon hash pythonstarknet hashingcryptographic hash functionposeidon permutationzero-knowledge proof hashingstarknet cryptography
starknetzero-knowledge-proofscryptographic-hashing

More Cryptography packages