deriveOnChainId hashes UUIDs into u64 keys with no collision check, and milestone/pool keys share the escrow contract's issue_id space

Abierto
#609 0 comentarios 0 reacciones 0 asignados Ver en GitHub

Los mantenedores suelen responder en 1 día

@urielit1313-creator ya está trabajando en esto.

Desde el 13/10/2026.

  • #646 de @urielit1313-creator — abierto
  • #653 de @yggdrasilworld — cerrado sin fusionar

Evaluación

Dificultad
4/5
Tiempo estimado
3-5 días
Aptitud para principiantes
15/100
Tipo de issue
Error
Claridad
Bastante claro
Estado de actividad
Activo
Stack tecnológico
blockchain, typescript

Línea de trabajo

Start from EscrowService.deriveOnChainId, which hashes the UUID into the on-chain issue_id, and trace how milestone and pool escrows share that key space with GitHub-issue-keyed bounties. The work is already under way: PRs #646 and #653 are open against this issue, so check them before starting. Done means derived keys cannot collide with live escrows and the mapping is persisted.

Escrito por el modelo de indexación a partir del texto del issue.

Descripción

bug security

Problem

EscrowService.deriveOnChainId FNV-1a-64-hashes the bounty/milestone/pool UUID to get the on-chain issue_id. Milestone escrows are funded on the escrow contract (until #162), in the same u64 key space as bounties keyed by real GitHub issue ids. Nothing checks for a collision with an existing on-chain escrow. A hashed key that equals a live GitHub-issue-keyed escrow makes fund fail with AlreadyFunded, or worse, after that escrow terminates, silently re-uses its key and stale contribution records (contracts #41).

Suggested fix

Namespace the keys (e.g. high bit set for derived ids), call get_escrow before funding to detect collisions, and persist the mapping.

Related: #158, #162

Lenguaje dominante
TypeScript
Estrellas
2
Forks
90
Merge medio
31 min
PR fusionados (30 d)
20

Preparar el entorno

  • Incluye un Dockerfile o un archivo de Docker Compose
  • Sin plantilla de pull request
  • Sin guía de contribución

Primeros pasos

  1. Lee el issue completo y luego la guía de contribución del proyecto.
  2. Comenta en el issue que vas a ocuparte — evita que dos personas hagan lo mismo.
  3. Haz un fork del repositorio y trabaja en una rama.
  4. Abre un pull request que haga referencia al número del issue.

Más de MergeFi/backend

Todos los issues de MergeFi/backend

Issues similares

Más issues de TypeScript

Recibe los nuevos issues en tu correo

Un resumen breve de issues de GitHub para principiantes.