⚠️

سلب مسئولیت و اخلاق حرفه‌ای

این مطالب صرفاً برای اهداف آموزشی، پژوهشی و افزایش آگاهی امنیتی ارائه شده‌اند. هرگونه استفاده غیرمجاز، غیرقانونی یا سوءاستفاده از اطلاعات، ابزارها و روش‌های مطرح‌شده، کاملاً بر عهده مخاطب است. نویسنده و منتشرکننده هیچ مسئولیتی در قبال خسارات، آسیب‌ها یا پیامدهای ناشی از استفاده نادرست از این مطالب نخواهند داشت.

CVE-2026-139648: Linux Kernel PKCS#7 Authenticated-Attribute Waiver Flaw | Alireza Bolbolabadi - Red Team Security
LOADING

CVE-2026-139648: Linux Kernel PKCS#7 Authenticated-Attribute Waiver Flaw

Executive summary

CVE-2026-139648 affects the Linux kernel's PKCS#7 verification logic in crypto/asymmetric_keys/pkcs7*, specifically the function pkcs7_check_authattrs(). In a PKCS#7 message containing multiple SignerInfo entries, the function may decide to waive rejection of authenticated attributes based only on the first signer. That waiver was intended for a particular class of ML-DSA signers, but it can remain enabled while a later RSA, ECDSA, or ECRDSA signer is processed.

The flaw does not automatically grant an attacker the ability to forge a signature. It requires a crafted, multi-signer PKCS#7 structure to reach a kernel verification path in which the attacker can also arrange for a trusted non-ML-DSA signer to be recognized. No public exploit, proof of concept, in-the-wild exploitation, CVSS vector, or CISA KEV listing is identified in the supplied information. An upstream fix is reported, although specific affected versions and backport identifiers are not provided.

Technical analysis

Root cause

The vulnerable function applies two distinct checks:

  1. It evaluates whether rejection of authenticated attributes may be waived, but performs that eligibility check only against the first SignerInfo.

  1. It confirms a weaker consistency condition across all signers: authenticated attributes are either present for every signer or absent from every signer.

The second check does not repeat the waiver-eligibility decision for each signer. As a result, the algorithm selected by the first signer controls the policy for the entire message.

The advisory identifies the corrective approach: each SignerInfo's public-key algorithm must be checked before the waiver remains enabled.

Potential attack sequence

Based on the advisory's described scenario, an attacker constructs a PKCS#7 message with an unmatched ML-DSA signer first and a trusted RSA, ECDSA, or ECRDSA signer afterward. The unmatched signature does not validate and is effectively skipped, but the first signer has already enabled the authenticated-attribute waiver. When the trusted classical signer is evaluated, the waiver remains active even though it was intended only for the ML-DSA case.

This is a policy-state propagation flaw rather than a break of RSA, ECDSA, ECRDSA, or ML-DSA cryptography. The verification result depends on how the affected consumer handles the skipped signer, the presence and state of trusted keys, and whether the crafted message satisfies surrounding policy checks.

Affected surface

The affected component is the Linux kernel's crypto/asymmetric_keys/pkcs7* subsystem, with the flaw located in pkcs7_check_authattrs(). Kernel consumers that may use PKCS#7 signature verification include workflows involving module signing, kexec image verification, and IMA or appraisal signature checks. The supplied information does not establish that every such workflow is exploitable in the same way; each consumer has distinct input, trust-store, and policy requirements.

The available advisory does not enumerate affected version numbers or identify mainline and stable release branches. It reports that the vulnerability has been resolved upstream, so kernels predating the applicable upstream resolution or backport may remain exposed.

Affected systems

  • Linux kernels containing the vulnerable implementation of pkcs7_check_authattrs() in crypto/asymmetric_keys/pkcs7*.

  • Systems that verify attacker-influenced, multi-signer PKCS#7 objects through affected kernel consumers.

  • Deployments in which a trusted RSA, ECDSA, or ECRDSA signer can be present in the relevant trust context alongside a crafted ML-DSA SignerInfo.

The context does not name specific stable or long-term-support branches, vendor packages, distribution advisories, or backport commit hashes. Version applicability therefore requires confirmation against the kernel source and the vendor advisory for the deployed build.

Mitigation

An upstream resolution is reported in the CVE record. The fix changes the waiver behavior so that every SignerInfo's public-key algorithm is checked before the waiver remains enabled. Operators should determine whether their kernel build contains that change, including any distribution-specific backport.

Where an affected build cannot yet be updated:

  • Restrict which artifacts and signature blobs can reach kernel PKCS#7 verification consumers.

  • For module loading, preserve enforced module-signature policy and limit acceptable modules to sources covered by the intended trust chain.

  • For kexec workflows, authenticate kernel and initramfs sources through a separate, intact trust chain.

  • For IMA, review keyring contents and ensure that only intended signing keys are enrolled.

  • Prefer single-signer PKCS#7 artifacts where the operating workflow permits it, since the described defect concerns multi-signer processing.

  • Review trust-anchor configuration to ensure that an attacker cannot introduce or combine keys that alter the relevant verification decision.

A reliable detection signature is not provided in the advisory. Targeted analysis could focus on multi-signer messages whose first SignerInfo uses ML-DSA, whose later signers use RSA, ECDSA, or ECRDSA, and for which authenticated attributes are rejected for a classical signer. Kernel verification logs may also help identify unusual combinations of authenticated-attribute rejection and downstream acceptance, although the available source does not specify a canonical log event.

Expert insight

The defect illustrates why exception handling in multi-signature formats must remain local to the entry that qualifies for the exception. Evaluating the first signer and then carrying the result across every later signer creates a confused-deputy condition inside the verifier: one signer's algorithm becomes authorization for another signer's processing.

Its practical severity depends less on the cryptographic novelty of ML-DSA than on the surrounding trust model. The attacker still needs a route to submit a crafted PKCS#7 object, a trusted later signer, and a consumer that continues verification after handling the unmatched signer. These requirements make the issue narrower than a general kernel signature-verification bypass. They also explain why the available risk assessment is low despite the security significance of the underlying logic error.

The absence of exploitation evidence should not be treated as proof that exploitation is impossible. It does, however, support prioritizing verified kernel updates over emergency defensive measures when the affected input paths are strongly controlled.

Actionable recommendations

  1. Review the Linux kernel package version and vendor advisory in use, and confirm whether it contains the upstream change to pkcs7_check_authattrs().

  1. Apply the applicable upstream or distribution security update, including stable and long-term-support backports.

  1. Identify kernel workflows that accept externally influenced PKCS#7 signatures, with particular attention to module, kexec, and IMA-related paths.

  1. Verify that module enforcement, kexec trust chains, and IMA keyrings remain restricted to intended signing authorities.

  1. Audit systems for unusual multi-signer PKCS#7 structures that combine ML-DSA and classical public-key algorithms.

  1. Treat version, commit, CVSS, and exploitation details as unresolved until confirmed by vendor advisories or upstream kernel records.

منابع

·
← اخبار