Speculative Code Store Bypass
XSA-375 - Xen Security Advisories
InformationAdvisory XSA-375Public release 2021-06-08 17:00Updated 2021-06-08 17:04Version 2CVE(s) CVE-2021-0089Title Speculative Code Store BypassFilesadvisory-375.txt (signed advisory file)xsa375.metaxsa375.patchxsa375-4.12.patchxsa375-4.13.patchAdvisory-----BEGIN PGP SIGNED MESSAGE-----
Xen Security Advisory CVE-2021-0089 / XSA-375
Speculative Code Store Bypass
UPDATES IN VERSION 2
New 4.12 backport (also targeting 4.11), addressing a build issue.
Discuss the need for SPECULATIVE_HARDEN_BRANCH in Resolution.
Provide Arm information links.
Modern superscalar processors may employ sophisticated decoding and
caching of the instruction stream to improve performance. However, a
consequence is that self-modifying code updates may not take effect
Whatever the architectural guarantees, some CPUs have microarchitectural
behaviour whereby the stale instruction stream may be speculatively
decoded and executed.
Speculation of this form can suffer from type confusion in registers,
and potentially leak data.
For more details, see:
In attacker might be able to infer the contents of arbitrary host
memory, including memory assigned to other guests.
Systems running all versions of Xen are affected.
Whether a CPU is potentially vulnerable depends on its
microarchitecture. Consult your hardware vendor.
Xen running on ARM does not have runtime self-modying code, so is
believed to be not vulnerable, irrespective of any hardware
Xen running on x86 does have runtime self-modying code as part of
emulation, and is believed to be potentially vulnerable.
Xen is not vulnerable if retpoline or lfence mitigations for Spectre v2
protection are active. Protections depend on compiler support (as
indicated by INDIRECT_THUNK), and a runtime setting (BTI-Thunk):
# xl dmesg | grep -e INDIRECT_THUNK -e BTI-Thunk
(XEN) Compiled-in support: INDIRECT_THUNK SHADOW_PAGING
(XEN) Xen settings: BTI-Thunk RETPOLINE, SPEC_CTRL: IBRS+ SSBD-, Other: SRB_LOCK+ IBPB L1D_FLUSH VERW BRANCH_HARDEN
BTI-Thunk as either RETPOLINE or LFENCE prevents the vulnerability.
If Spectre v2 support is compiled in, but JMP is used by default,
RETPOLINE or LFENCE can be selected with `spec-ctrl=bti-thunk=retpoline`
This issue was discovered by Enrico Barberis, Hany Ragab, Herbert Bos,
and Cristiano Giuffrida from the VUSec group at VU Amsterdam.
Applying the appropriate attached patch resolves this issue. Note that
in 4.13 and newer the patch will only take effect when the
SPECULATIVE_HARDEN_BRANCH hypervisor config option is enabled. 4.12 and
older do not have such an option, and the change will take effect
Note that patches for released versions are generally prepared to
apply to the stable branches, and may not apply cleanly to the most
recent release tarball. Downstreams are encouraged to update to the
tip of the stable branch before applying these patches.
xsa375.patch xen-unstable - 4.14.x
xsa375-4.13.patch Xen 4.13.x
xsa375-4.12.patch Xen 4.12.x - 4.11.x
$ sha256sum xsa375*
NOTE CONCERNING CVE-2021-0086
Floating Point Value Injection (FPVI) was discovered and disclosed in
the same research as SCSB. Xen on x86 does in some cases emulate
floating point operations with guest provided inputs, but does not have
subsequent control flow dependent on results, transient or otherwise, of
Therefore, we believe Xen is not vulnerable to FPVI, irrespective of any
DEPLOYMENT DURING EMBARGO
Deployment of the patches and/or mitigations described above (or
others which are substantially similar) is permitted during the
embargo, even on public-facing systems with untrusted guest users and
But: Distribution of updated software is prohibited (except to other
members of the predisclosure list).
Predisclosure list members who wish to deploy significantly different
patches and/or mitigations, please contact the Xen Project Security
(Note: this during-embargo deployment notice is retained in
post-embargo publicly released Xen Project advisories, even though it
is then no longer applicable. This is to enable the community to have
oversight of the Xen Project Security Team's decisionmaking.)
For more information about permissible uses of embargoed information,
consult the Xen Project community's agreed Security Policy:
-----BEGIN PGP SIGNATURE-----
-----END PGP SIGNATURE-----
Xenproject.org Security Team