blob: ae37dab7786a905e94e362a52773aa3f8b776ded [file] [log] [blame] [view]
Tom Cosgrove0b86ac12022-07-29 13:44:01 +01001## Reporting Vulnerabilities
Manuel Pégourié-Gonnarda21abf22021-02-25 11:41:38 +01002
3If you think you have found an Mbed TLS security vulnerability, then please
4send an email to the security team at
5<mbed-tls-security@lists.trustedfirmware.org>.
6
7## Security Incident Handling Process
8
Shaun Case8b0ecbc2021-12-20 21:14:10 -08009Our security process is detailed in our
Gilles Peskinea23df132021-03-16 12:04:44 +010010[security
Manuel Pégourié-Gonnarda21abf22021-02-25 11:41:38 +010011center](https://developer.trustedfirmware.org/w/mbed-tls/security-center/).
12
13Its primary goal is to ensure fixes are ready to be deployed when the issue
14goes public.
15
16## Maintained branches
17
Gilles Peskinea23df132021-03-16 12:04:44 +010018Only the maintained branches, as listed in [`BRANCHES.md`](BRANCHES.md),
19get security fixes.
Manuel Pégourié-Gonnarda21abf22021-02-25 11:41:38 +010020Users are urged to always use the latest version of a maintained branch.
Janos Follath18d41732023-02-24 16:00:21 +000021
22## Threat model
23
24We use the following classification of attacks:
25
26- **Remote Attacks:** The attacker can observe and modify data sent over the
27 network. This includes observing timing of individual packets and potentially
28 delaying legitimate messages.
29- **Timing Attacks:** The attacker can gain information about the time certain
30 sets of instructions in Mbed TLS operations take.
31- **Physical Attacks:** The attacker has access to physical information about
32 the hardware Mbed TLS is running on and/or can alter the physical state of
33 the hardware.
34
35### Remote attacks
36
37Mbed TLS aims to fully protect against remote attacks. Mbed Crypto aims to
38enable the user application in providing full protection against remote
39attacks. Said protection is limited to providing security guarantees offered by
40the protocol in question. (For example Mbed TLS alone won't guarantee that the
41messages will arrive without delay, as the TLS protocol doesn't guarantee that
42either.)
43
44### Timing attacks
45
46Mbed TLS and Mbed Crypto provide limited protection against timing attacks. The
47cost of protecting against timing attacks widely varies depending on the
48granularity of the measurements and the noise present. Therefore the protection
49in Mbed TLS and Mbed Crypto is limited. We are only aiming to provide protection
50against publicly documented attacks.
51
52**Warning!** Block ciphers constitute an exception from this protection. For
53details and workarounds see the section below.
54
55#### Block Ciphers
56
57Currently there are 4 block ciphers in Mbed TLS: AES, CAMELLIA, ARIA and DES.
58The Mbed TLS implementation uses lookup tables, which are vulnerable to timing
59attacks.
60
61**Workarounds:**
62
63- Turn on hardware acceleration for AES. This is supported only on selected
64 architectures and currently only available for AES. See configuration options
65 `MBEDTLS_AESCE_C`, `MBEDTLS_AESNI_C` and `MBEDTLS_PADLOCK_C` for details.
66- Add a secure alternative implementation (typically bitslice implementation or
67 hardware acceleration) for the vulnerable cipher. See the [Alternative
68Implementations Guide](docs/architecture/alternative-implementations.md) for
69 more information.
70- Instead of a block cipher, use ChaCha20/Poly1305 for encryption and data
71 origin authentication.
72
73### Physical attacks
74
75Physical attacks are out of scope. Any attack using information about or
76influencing the physical state of the hardware is considered physical,
77independently of the attack vector. (For example Row Hammer and Screaming
78Channels are considered physical attacks.) If physical attacks are present in a
79use case or a user application's threat model, it needs to be mitigated by
80physical countermeasures.