CVE-2021-40040 Memory corruption in HarmonyOS;EMUI;Magic UI

High 7.5 Published Updated

Attackers can write data to arbitrary memory addresses in the HW_KEYMASTER module, potentially compromising confidentiality on Huawei devices.

Exploited in the wild
Not known
Login needed
Not needed
Attackable
Over the internet
Victim action needed
Not needed
Fix
None listed

What is CVE-2021-40040?

CVE-2021-40040 is a high-severity memory corruption vulnerability in Huawei Emui, published on 9 Aug 2022. An attacker can exploit it over the internet without logging in, with no action from the victim.

Official description

Vulnerability of writing data to an arbitrary address in the HW_KEYMASTER module. Successful exploitation of this vulnerability may affect confidentiality.

Which versions are affected by CVE-2021-40040?

It affects 3 products.

Products include Huawei Emui, Huawei Harmonyos, Huawei Magic Ui.

How do I fix CVE-2021-40040?

No fix has been published for CVE-2021-40040 yet. Limit exposure of the affected software until one is available.

Upgrade to the fixed version. Memory-safe languages, compiler hardening and fuzzing prevent most new cases. More about Memory corruption.

Is CVE-2021-40040 being exploited?

It is not confirmed as exploited in the wild, but public exploit code for CVE-2021-40040 exists.

All Huawei Emui vulnerabilities

Sources

Also known as GHSA-86g3-53hw-mw23.

Is CVE-2021-40040 in your software?

Upload an SBOM and sbomify checks it against every vulnerability here, every day.

Check your SBOMs for free