Skip to main content

solve_puzzle

Function solve_puzzle 

Source
pub fn solve_puzzle(puzzle: &TimeLockPuzzle) -> Result<Payload, TimeLockError>
Expand description

Solve a time-lock puzzle by performing sequential squarings and decrypting.

This is CPU-bound and cannot be parallelised.

ยงErrors

Returns TimeLockError::ComputationFailed or TimeLockError::DecryptFailed.