HSEC-2025-0002

See a problem?
Import Source
https://github.com/haskell/security-advisories/blob/generated/osv-export/2025/HSEC-2025-0002.json
JSON Data
https://api.osv.dev/v1/vulns/HSEC-2025-0002
Related
Published
2025-04-03T12:07:41Z
Modified
2025-04-03T12:44:14.039077Z
Summary
Double Public Key Signing Function Oracle Attack on Ed25519
Details

Double Public Key Signing Function Oracle Attack on Ed25519

The standard specification of Ed25519 message signing involves providing the algorithm with a message and private key.

The function will use the private key to compute the public key and sign the message. Some libraries provide a variant of the message signing function that also takes the pre-computed public key as an input parameter.

Libraries that allow arbitrary public keys as inputs without checking if the input public key corresponds to the input private key are vulnerable to the following attack.

By using several public keys and messages, a malicious user with access to the signing mechanism may build up insights into the private key parameters resulting in access to the private key.

This shortcoming means that an attacker could use the signing function as an Oracle, perform crypto-analysis and ultimately get at secrets. For example, an attacker who can’t access the private key but can access the signing mechanism through an API call could use several public keys and messages to gradually build up insights into private key parameters.

References

Affected packages

Hackage / cryptonite

Package

Name
cryptonite
Purl
pkg:hackage/cryptonite

Severity

  • 7.7 (High) CVSS_V3 - CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:C/C:N/I:H/A:N CVSS Calculator

Affected ranges

Type
ECOSYSTEM
Events
Introduced
0.1

Affected versions

0.*

0.1
0.2
0.3
0.4
0.5
0.6
0.7
0.8
0.9
0.10
0.11
0.12
0.13
0.14
0.15
0.15.1
0.16
0.17
0.18
0.19
0.20
0.21
0.22
0.23
0.24
0.25
0.26
0.27
0.28
0.29
0.30

Hackage / crypton

Package

Name
crypton
Purl
pkg:hackage/crypton

Severity

  • 7.7 (High) CVSS_V3 - CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:C/C:N/I:H/A:N CVSS Calculator

Affected ranges

Type
ECOSYSTEM
Events
Introduced
0.31
Fixed
1.0.3

Affected versions

0.*

0.31
0.32
0.33
0.34

1.*

1.0.0
1.0.1
1.0.2