VOPRF sobre ristretto255 con pruebas DLEQ: cliente del servicio Quipu OPRF
Project description
quipu-voprf
VOPRF (OPRF verificable) sobre ristretto255 con pruebas DLEQ. Son las primitivas
que hablan con un quipu-oprf-server.
Argon2 solo: robas la BD -> fuerza bruta offline, a la velocidad de tu GPU.
Con VOPRF: robas la BD -> no puedes derivar nada sin la clave del servidor.
Cada intento exige una peticion que el operador ve, limita y corta.
El servidor nunca ve la entrada (llega cegada) y no puede mentir sobre el
resultado: adjunta una prueba DLEQ de que uso la misma k de su clave publica,
y el cliente la verifica contra una clave fijada fuera de banda.
Licencia: Apache-2.0 (distinta del núcleo)
El núcleo de Quipu es AGPL-3.0-or-later. Este crate no, y es deliberado.
Es lo único que un cliente del servicio Quipu OPRF debe enlazar dentro de su servidor de autenticación. Si arrastrara la AGPL, el copyleft de red alcanzaría al SaaS del cliente — y nadie enchufa eso a su auth. Poner Apache solo en el SDK no bastaba: la licencia de un envoltorio no relicencia su dependencia, así que había que separar el código de verdad.
Lo que se cede son ~270 líneas de matemática de curva estándar. No es el foso:
el foso son el servidor, la clave k y la biblioteca post-cuántica completa,
que siguen AGPL. Apache-2.0 y no MIT por la concesión expresa de patentes, que
es lo que revisa el departamento legal de una empresa.
Apache-2.0 fluye hacia AGPL-3.0, así que el núcleo puede seguir usando este crate sin fricción. Al revés no funcionaría — de ahí la dirección de la dependencia.
Uso
use quipu_voprf::{Server, blind, finalize};
// Servidor (guarda k; publica Y = k·G)
let server = Server::from_seed(&seed);
let public_key = server.public_key();
// Cliente: cegar
let (state, blinded) = blind(b"contraseña");
// Servidor: evaluar + probar
let (evaluated, proof) = server.evaluate(&blinded).unwrap();
// Cliente: verificar la prueba contra la clave FIJADA y finalizar
let secret = finalize(b"contraseña", &state, &evaluated, &proof, &public_key)
.expect("la prueba DLEQ no valida: servidor deshonesto o clave incorrecta");
finalize devuelve None si la prueba no valida. No lo ignores: significa que
el servidor no es el que fijaste, o que rotó su clave.
Conforme a RFC 9497
Ciphersuite ristretto255-SHA512, modo VOPRF (contextString = "OPRFV1-\x01-ristretto255-SHA512"). Verificado contra los vectores oficiales
del Apéndice A.1.2: cargo test -p quipu-voprf.
Los tests cubren DeriveKeyPair, Blind, BlindEvaluate + GenerateProof y
Finalize contra los vectores 1 y 2 (lote 1). El vector 3 es de lote 2 y este
API no expone lotes: queda fuera de alcance, y se dice en vez de fingir
cobertura.
Interoperable con cualquier otra implementación de RFC 9497.
Nota: la construcción propia nunca se publicó
Durante el desarrollo hubo una construcción propia (quipu/v2/voprf), inspirada
en la RFC pero no conforme. Nunca llegó a PyPI: 0.2.0 es la primera versión
publicada, y nace conforme. Se documenta aquí porque la instancia
oprf.xiliux.com sí la sirvió hasta el 2026-07-17, y su clave pública cambió al
migrar. La construcción vieja era: dominio propio, hash_to_curve sin
expand_message_xmd y transcripción DLEQ propia. No interoperaba con nadie ni
heredaba el análisis de seguridad de la RFC. Se eliminó, no se deprecó:
dejarla solo invitaba a usarla por error.
Lo que cambia, y no es reversible:
- La salida pasa de 32 a 64 bytes (
Hashes SHA-512; truncarla haría fallar los vectores). - La clave pública del servidor cambia para la misma semilla: ahora se deriva
con
DeriveKeyPair(§3.2), coninfo = "quipu-oprf-server-v1". - Todo secreto endurecido con la versión anterior queda invalidado.
Se hizo con cero clientes, que era la única ventana: el dominio está horneado en
cada secreto y, como k, no rota nunca.
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distributions
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file quipu_voprf-0.2.1.tar.gz.
File metadata
- Download URL: quipu_voprf-0.2.1.tar.gz
- Upload date:
- Size: 28.1 kB
- Tags: Source
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.12
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
a87befb8a3fb7305a53a55247fffb8af1fe5800b2ef869937c9632aa5fce1df7
|
|
| MD5 |
a017efe4c1f7d923994ca4acbef82b02
|
|
| BLAKE2b-256 |
350123e02ea76236a8cfb27a7dd674f4daff5831f7f7eceac5e6b78b64eca076
|
Provenance
The following attestation bundles were made for quipu_voprf-0.2.1.tar.gz:
Publisher:
release.yml on isazajuancarlos/quipu
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
quipu_voprf-0.2.1.tar.gz -
Subject digest:
a87befb8a3fb7305a53a55247fffb8af1fe5800b2ef869937c9632aa5fce1df7 - Sigstore transparency entry: 2188359271
- Sigstore integration time:
-
Permalink:
isazajuancarlos/quipu@840fb4df963d96cd13e2c480cd301b0e66b0a2b0 -
Branch / Tag:
refs/tags/voprf-v0.2.1 - Owner: https://github.com/isazajuancarlos
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
release.yml@840fb4df963d96cd13e2c480cd301b0e66b0a2b0 -
Trigger Event:
push
-
Statement type:
File details
Details for the file quipu_voprf-0.2.1-cp39-abi3-win_amd64.whl.
File metadata
- Download URL: quipu_voprf-0.2.1-cp39-abi3-win_amd64.whl
- Upload date:
- Size: 153.5 kB
- Tags: CPython 3.9+, Windows x86-64
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.12
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
2b68665de16db14778e9814d9215a2d5803dc2d346824e70e35ae60cc1935060
|
|
| MD5 |
7c5b9ec77fa53d9f9e13a4016132e7e5
|
|
| BLAKE2b-256 |
c16b3813d474c5b3ed7b0cdb53fb3b9bf5f9f2ee555650a26e06c170b3b90bbd
|
Provenance
The following attestation bundles were made for quipu_voprf-0.2.1-cp39-abi3-win_amd64.whl:
Publisher:
release.yml on isazajuancarlos/quipu
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
quipu_voprf-0.2.1-cp39-abi3-win_amd64.whl -
Subject digest:
2b68665de16db14778e9814d9215a2d5803dc2d346824e70e35ae60cc1935060 - Sigstore transparency entry: 2188359288
- Sigstore integration time:
-
Permalink:
isazajuancarlos/quipu@840fb4df963d96cd13e2c480cd301b0e66b0a2b0 -
Branch / Tag:
refs/tags/voprf-v0.2.1 - Owner: https://github.com/isazajuancarlos
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
release.yml@840fb4df963d96cd13e2c480cd301b0e66b0a2b0 -
Trigger Event:
push
-
Statement type:
File details
Details for the file quipu_voprf-0.2.1-cp39-abi3-manylinux_2_17_x86_64.manylinux2014_x86_64.whl.
File metadata
- Download URL: quipu_voprf-0.2.1-cp39-abi3-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
- Upload date:
- Size: 290.9 kB
- Tags: CPython 3.9+, manylinux: glibc 2.17+ x86-64
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.12
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
b6ce56a40a9c69bdefd4e7de3230d2c0b95cd2f12b8b977aa12c27db23b82c55
|
|
| MD5 |
75d475839e8663e8bb8d8bac08ae7491
|
|
| BLAKE2b-256 |
dc44e12bbedc7ac338fdd86d6e30a18144e8e01a929ef5100423eb6d19bc9d92
|
Provenance
The following attestation bundles were made for quipu_voprf-0.2.1-cp39-abi3-manylinux_2_17_x86_64.manylinux2014_x86_64.whl:
Publisher:
release.yml on isazajuancarlos/quipu
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
quipu_voprf-0.2.1-cp39-abi3-manylinux_2_17_x86_64.manylinux2014_x86_64.whl -
Subject digest:
b6ce56a40a9c69bdefd4e7de3230d2c0b95cd2f12b8b977aa12c27db23b82c55 - Sigstore transparency entry: 2188359317
- Sigstore integration time:
-
Permalink:
isazajuancarlos/quipu@840fb4df963d96cd13e2c480cd301b0e66b0a2b0 -
Branch / Tag:
refs/tags/voprf-v0.2.1 - Owner: https://github.com/isazajuancarlos
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
release.yml@840fb4df963d96cd13e2c480cd301b0e66b0a2b0 -
Trigger Event:
push
-
Statement type:
File details
Details for the file quipu_voprf-0.2.1-cp39-abi3-macosx_11_0_arm64.whl.
File metadata
- Download URL: quipu_voprf-0.2.1-cp39-abi3-macosx_11_0_arm64.whl
- Upload date:
- Size: 248.2 kB
- Tags: CPython 3.9+, macOS 11.0+ ARM64
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.12
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
eab2af3a72e30857a15e0fdfb43260c74dc89d8d9a57fc13c0584218b51bc359
|
|
| MD5 |
89e67d08c65ed834c8929779d949b126
|
|
| BLAKE2b-256 |
080a6382adc1f230ed116a5a99b87acf05f73f4a482c306fbc8ea5d6ddf336b9
|
Provenance
The following attestation bundles were made for quipu_voprf-0.2.1-cp39-abi3-macosx_11_0_arm64.whl:
Publisher:
release.yml on isazajuancarlos/quipu
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
quipu_voprf-0.2.1-cp39-abi3-macosx_11_0_arm64.whl -
Subject digest:
eab2af3a72e30857a15e0fdfb43260c74dc89d8d9a57fc13c0584218b51bc359 - Sigstore transparency entry: 2188359295
- Sigstore integration time:
-
Permalink:
isazajuancarlos/quipu@840fb4df963d96cd13e2c480cd301b0e66b0a2b0 -
Branch / Tag:
refs/tags/voprf-v0.2.1 - Owner: https://github.com/isazajuancarlos
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
release.yml@840fb4df963d96cd13e2c480cd301b0e66b0a2b0 -
Trigger Event:
push
-
Statement type: