Intel

AIKIDO-2026-387567

cryptoki is vulnerable to Out-of-bounds Read

GHSA-r6vc-97x9-63vvPublished Sep 21, 2026
September 21, 2026

51

CVE Score

Medium

Out-of-bounds Read

Are you affected? Scan for Free

TL;DR

Affected versions of cryptoki treat the PKCS #11 CKA_ALLOWED_MECHANISMS ulValueLen byte count as a CK_MECHANISM_TYPE element count. Reading a valid nonempty attribute through the safe Session::get_attributes API can therefore construct an out-of-bounds slice and trigger undefined behavior. That can crash the process or cause a denial of service, and may disclose adjacent heap words through decoded mechanism values. The fix interprets the length as a byte count when decoding the attribute. cryptoki-sys is not affected.

How do I fix this?

Upgrade the cryptoki library to the patch version.

Who does this affect?

You are affected if you are using a version that falls within the vulnerable range and request AttributeType::AllowedMechanisms through Session::get_attributes. Exploitability depends on who can influence the PKCS #11 provider or object response.

Package

Versions

0.1.0 - 0.10.0

Fixed in 0.10.1

0.11.0 - 0.11.0

Fixed in 0.11.1

0.12.0 - 0.12.0

Fixed in 0.12.1

Background info

cryptoki is vulnerable to Out-of-bounds Read in versions 0.12.0 - 0.12.0, 0.11.0 - 0.11.0 and 0.1.0 - 0.10.0.

Get secure today,
quickly and for free.

Secure your code, cloud, and runtime in one central system. Connect a repo to discover what the reasoning agents find in your codebase.

No credit card required | Scan results in 32 seconds.

Trusted by 150k+ orgs
  • Revolut
  • n8n
  • Lovable
  • Deel
  • Prove
  • Omnea