CVE-2026-41681: rust-openssl: MdCtxRef::digest_final() writes past caller buffer with no length check

Published Apr 22, 2026
·
Updated

EVPDigestFinal() always writes EVPMDCTXsize(ctx) to the out buffer. If out is smaller than that, MdCtxRef::digestfinal() writes past its end, usually corrupting the stack. This is reachable from safe Rust.

Other sources

rust-openssl provides OpenSSL bindings for the Rust programming language. From 0.10.39 to before 0.10.78, EVPDigestFinal() always writes EVPMDCTXsize(ctx) to the out buffer. If out is smaller than that, MdCtxRef::digestfinal() writes past its end, usually corrupting the stack. This is reachable from safe Rust. This vulnerability is fixed in 0.10.78.

MITRE

Affected Software

2 affected componentsFixes available
rust/openssl>=0.10.39<0.10.78
0.10.78
Rust-openssl Project Rust-openssl Rust>=0.10.39<0.10.78

Remediation

Recommended actions to resolve this vulnerability, in priority order.

  1. Upgrade

    Upgrade rust/openssl to a version that resolves this vulnerability.

    Fixed in 0.10.78
  2. Upgrade

    Upgrade rust-openssl to a version that resolves this vulnerability.

    Fixed in 0.10.78

Event History

Apr 22, 2026
Advisory Published
via GitHub·09:05 PM
Data Sourced
via GitHub·09:05 PM
DescriptionWeaknessAffected Software
Apr 24, 2026
CVE Published
via MITRE·05:19 PM
Data Sourced
via MITRE·05:19 PM
DescriptionWeakness
Data Sourced
via NVD·06:16 PM
RemedyDescriptionSeverityWeaknessAffected Software

Frequently Asked Questions

1

What is the severity of CVE-2026-41681?

CVE-2026-41681 is rated as a high severity vulnerability due to potential stack corruption.

2

How do I fix CVE-2026-41681?

To fix CVE-2026-41681, upgrade to OpenSSL version 0.10.78 or later.

3

What does CVE-2026-41681 affect?

CVE-2026-41681 affects the Rust package 'openssl' versions between 0.10.39 and 0.10.78.

4

What vulnerability does CVE-2026-41681 introduce?

CVE-2026-41681 introduces a buffer overflow vulnerability due to incorrect handling of output buffer sizes.

5

Can CVE-2026-41681 be exploited in safe Rust code?

Yes, CVE-2026-41681 is reachable from safe Rust code, making it a serious concern.

Contact

SecAlerts Pty Ltd.
132 Wickham Terrace
Fortitude Valley,
QLD 4006, Australia
info@secalerts.co
By using SecAlerts services, you agree to our services end-user license agreement. This website is safeguarded by reCAPTCHA and governed by the Google Privacy Policy and Terms of Service. All names, logos, and brands of products are owned by their respective owners, and any usage of these names, logos, and brands for identification purposes only does not imply endorsement. If you possess any content that requires removal, please get in touch with us.
© 2026 SecAlerts Pty Ltd.
ABN: 70 645 966 203, ACN: 645 966 203