Foreword |
|
xv | |
|
|
1 | (6) |
|
Arm Platform Security Architecture |
|
|
2 | (1) |
|
|
2 | (1) |
|
How much development effort is required? |
|
|
2 | (1) |
|
|
3 | (1) |
|
|
3 | (1) |
|
|
4 | (1) |
|
Part 1 Cryptography and secure communications for IoT devices |
|
|
4 | (1) |
|
|
4 | (2) |
|
|
6 | (1) |
|
|
6 | (1) |
|
Chapter 2 Arm platform security architecture |
|
|
7 | (12) |
|
|
7 | (1) |
|
|
7 | (1) |
|
|
8 | (1) |
|
|
8 | (1) |
|
|
9 | (1) |
|
|
9 | (1) |
|
Application-specific threat modeling |
|
|
9 | (1) |
|
|
9 | (1) |
|
|
10 | (2) |
|
|
12 | (1) |
|
Secure boot and assistive security features |
|
|
13 | (1) |
|
|
13 | (1) |
|
|
13 | (1) |
|
|
13 | (1) |
|
|
14 | (1) |
|
|
14 | (1) |
|
|
15 | (1) |
|
|
16 | (1) |
|
|
17 | (1) |
|
|
17 | (1) |
|
|
17 | (2) |
|
Chapter 3 Development tools and device platform |
|
|
19 | (30) |
|
|
19 | (1) |
|
|
19 | (1) |
|
|
19 | (1) |
|
|
20 | (1) |
|
|
20 | (1) |
|
|
21 | (1) |
|
<to do> Install community license |
|
|
21 | (1) |
|
|
21 | (2) |
|
|
23 | (10) |
|
|
33 | (14) |
|
|
47 | (2) |
|
Chapter 4 Cryptography---The basics |
|
|
49 | (52) |
|
|
49 | (1) |
|
|
50 | (1) |
|
Exercise: Install and verify mbedTLS |
|
|
50 | (4) |
|
|
54 | (1) |
|
|
55 | (1) |
|
|
55 | (1) |
|
|
55 | (1) |
|
Nonrepudiation and authentication |
|
|
55 | (1) |
|
|
55 | (1) |
|
|
56 | (1) |
|
|
56 | (1) |
|
Message authentication code (MAC) |
|
|
56 | (1) |
|
|
56 | (1) |
|
Random number generator (RNG) |
|
|
56 | (1) |
|
|
56 | (1) |
|
|
57 | (1) |
|
|
58 | (2) |
|
|
60 | (1) |
|
|
61 | (1) |
|
Data Encryption Standard (DES) |
|
|
61 | (3) |
|
|
64 | (1) |
|
|
64 | (1) |
|
|
65 | (1) |
|
Exercise: DES and triple DES |
|
|
66 | (1) |
|
Advanced Encryption Standard (AES) |
|
|
67 | (6) |
|
Exercise: Advanced Encryption Standard |
|
|
73 | (1) |
|
|
74 | (1) |
|
|
75 | (2) |
|
|
77 | (1) |
|
|
77 | (1) |
|
Exercise: Cipher abstraction layer |
|
|
78 | (1) |
|
|
79 | (2) |
|
|
81 | (1) |
|
Secure Hashing Algorithm (SHA) |
|
|
81 | (3) |
|
|
84 | (1) |
|
|
84 | (2) |
|
Message authentication code (MAC) |
|
|
86 | (1) |
|
|
86 | (1) |
|
|
87 | (1) |
|
Exercise: HASH and MAC abstraction layer |
|
|
87 | (1) |
|
|
88 | (1) |
|
Authenticated Encryption with Associated Data (AEAD) |
|
|
89 | (2) |
|
Exercise: AEAD in mbedTLS |
|
|
91 | (1) |
|
|
92 | (1) |
|
|
93 | (1) |
|
|
93 | (1) |
|
True random number generator (TRNG) |
|
|
93 | (1) |
|
|
94 | (1) |
|
Deterministic random bitstream generator (DRBG) |
|
|
94 | (1) |
|
|
94 | (1) |
|
Exercise: Random generation |
|
|
95 | (1) |
|
|
96 | (1) |
|
|
96 | (1) |
|
|
97 | (1) |
|
|
97 | (1) |
|
Key derivation functions (KDF) |
|
|
98 | (1) |
|
|
98 | (1) |
|
|
99 | (2) |
|
Chapter 5 Cryptography---Secure communications |
|
|
101 | (54) |
|
|
101 | (1) |
|
|
101 | (1) |
|
|
102 | (2) |
|
Exercise: RSA small numbers |
|
|
104 | (1) |
|
|
105 | (1) |
|
Exercise: RSA malleability |
|
|
105 | (1) |
|
|
106 | (2) |
|
Exercise: mbedTLS RSA key generation and cipher |
|
|
108 | (1) |
|
|
109 | (1) |
|
The Diffie Hellman (DH) Key agreement system |
|
|
110 | (1) |
|
Exercise: DH small numbers |
|
|
110 | (2) |
|
Exercise: Diffie Hellman Key agreement |
|
|
112 | (2) |
|
Elliptic curve cryptography |
|
|
114 | (1) |
|
|
115 | (1) |
|
|
116 | (1) |
|
|
116 | (2) |
|
Exercise: Elliptic Curve Diffie Hellman |
|
|
118 | (1) |
|
|
119 | (1) |
|
|
119 | (1) |
|
|
120 | (2) |
|
Elliptic Curve Digital Signature Algorithm |
|
|
122 | (1) |
|
|
123 | (1) |
|
Using asymmetrical ciphers |
|
|
124 | (1) |
|
|
124 | (1) |
|
Public key infrastructure |
|
|
125 | (1) |
|
|
125 | (1) |
|
|
126 | (1) |
|
|
127 | (1) |
|
Certificate revocation list |
|
|
127 | (1) |
|
|
127 | (1) |
|
Certificate authority selection |
|
|
128 | (1) |
|
|
128 | (1) |
|
Exercise: Creating X.509 certificates |
|
|
128 | (1) |
|
|
129 | (4) |
|
|
133 | (2) |
|
|
135 | (3) |
|
Certificate and key storage |
|
|
138 | (1) |
|
Exercise: Parsing X.509 certificates and keys |
|
|
139 | (1) |
|
|
140 | (5) |
|
Establishing a TLS connection |
|
|
145 | (4) |
|
Exercise: TLS server authentication |
|
|
149 | (2) |
|
Server and client authentication |
|
|
151 | (1) |
|
Exercise: TLS server and client authentication |
|
|
152 | (1) |
|
|
153 | (2) |
|
Chapter 6 IoT networking and data formats |
|
|
155 | (32) |
|
|
155 | (1) |
|
Message queued telemetry transport (MQTT) |
|
|
155 | (1) |
|
|
156 | (1) |
|
|
156 | (1) |
|
|
157 | (1) |
|
|
157 | (1) |
|
|
158 | (1) |
|
|
159 | (1) |
|
|
159 | (1) |
|
|
159 | (1) |
|
Exercise: PC broker and client |
|
|
160 | (3) |
|
Exercise: Embedded MQTT client |
|
|
163 | (4) |
|
|
167 | (1) |
|
|
168 | (1) |
|
|
168 | (1) |
|
|
169 | (2) |
|
|
171 | (4) |
|
|
175 | (1) |
|
JavaScript Object Notation |
|
|
175 | (1) |
|
|
175 | (1) |
|
|
176 | (1) |
|
|
177 | (1) |
|
|
178 | (1) |
|
Concise binary object representation |
|
|
179 | (1) |
|
|
180 | (1) |
|
|
180 | (3) |
|
|
183 | (1) |
|
|
184 | (1) |
|
|
184 | (1) |
|
Indefinite arrays, strings, and maps |
|
|
184 | (1) |
|
|
185 | (1) |
|
|
186 | (1) |
|
Chapter 7 Using an IoT cloud service |
|
|
187 | (36) |
|
|
187 | (1) |
|
|
188 | (1) |
|
|
188 | (1) |
|
|
189 | (1) |
|
Create a connection policy |
|
|
190 | (10) |
|
Adding the Dynamo DB database |
|
|
200 | (2) |
|
|
202 | (4) |
|
Setting the Time Series rule |
|
|
206 | (2) |
|
Testing the Time Series database |
|
|
208 | (2) |
|
|
210 | (5) |
|
|
215 | (1) |
|
|
216 | (1) |
|
|
216 | (1) |
|
|
216 | (4) |
|
|
220 | (1) |
|
|
221 | (1) |
|
|
222 | (1) |
|
Chapter 8 Software attacks and threat modeling |
|
|
223 | (36) |
|
|
223 | (1) |
|
|
223 | (1) |
|
|
224 | (1) |
|
|
224 | (1) |
|
|
224 | (1) |
|
Common security exploits and vulnerabilities |
|
|
224 | (1) |
|
|
224 | (2) |
|
Exercise: Buffer overflow |
|
|
226 | (1) |
|
|
226 | (2) |
|
|
228 | (2) |
|
Return orientated programming (ROP) |
|
|
230 | (3) |
|
|
233 | (3) |
|
|
236 | (1) |
|
|
237 | (1) |
|
|
237 | (1) |
|
|
238 | (3) |
|
|
241 | (2) |
|
The IEEE top 10 secure coding practices |
|
|
243 | (1) |
|
|
244 | (1) |
|
|
245 | (1) |
|
|
245 | (2) |
|
Threat modeling techniques |
|
|
247 | (6) |
|
Document the threats and bugs |
|
|
253 | (1) |
|
Rate the threats and bugs |
|
|
253 | (4) |
|
|
257 | (1) |
|
|
257 | (2) |
|
Chapter 9 Building a defense with the PSA security model |
|
|
259 | (22) |
|
|
259 | (1) |
|
|
260 | (1) |
|
|
261 | (1) |
|
|
262 | (1) |
|
|
262 | (1) |
|
Trusted Platform Module (TPM) |
|
|
262 | (1) |
|
Dual core microcontroller |
|
|
262 | (1) |
|
Trusted Execution Environment |
|
|
263 | (1) |
|
PSA Execution environment |
|
|
263 | (1) |
|
Immutable Root of Trust (RoT) |
|
|
264 | (1) |
|
Execution environment validation |
|
|
265 | (1) |
|
|
266 | (1) |
|
Updatable Root of Trust (RoT) |
|
|
266 | (1) |
|
|
267 | (1) |
|
Non-Secure Processing Environment |
|
|
267 | (1) |
|
Secure Processing Environment |
|
|
267 | (4) |
|
Secure Partition Manager (SPM) |
|
|
271 | (1) |
|
|
271 | (1) |
|
|
271 | (2) |
|
|
273 | (1) |
|
|
273 | (1) |
|
|
273 | (1) |
|
|
273 | (2) |
|
|
275 | (2) |
|
|
277 | (1) |
|
|
277 | (2) |
|
|
279 | (2) |
|
Chapter 10 Device partitioning with TrustZone |
|
|
281 | (60) |
|
|
281 | (1) |
|
Processor operating modes |
|
|
281 | (1) |
|
TrustZone security extension |
|
|
282 | (2) |
|
|
284 | (1) |
|
|
284 | (4) |
|
|
288 | (2) |
|
|
290 | (2) |
|
|
292 | (1) |
|
|
293 | (2) |
|
|
295 | (1) |
|
Exercise: TrustZone configuration |
|
|
295 | (13) |
|
TrustZone interrupt handling |
|
|
308 | (1) |
|
|
308 | (3) |
|
Locating the nonsecure vector table |
|
|
311 | (1) |
|
Secure/nonsecure peripheral interrupt routing |
|
|
311 | (1) |
|
Exercise: TrustZone interrupt routing |
|
|
312 | (1) |
|
TrustZone system control block |
|
|
313 | (2) |
|
|
315 | (1) |
|
Exercise: TrustZone SysTick support |
|
|
315 | (1) |
|
Using an RTOS with TrustZone |
|
|
316 | (1) |
|
Multi-threaded access to secure functions |
|
|
316 | (1) |
|
CMSIS core TrustZone functions |
|
|
317 | (1) |
|
Exercise: Using an RTOS with TrustZone |
|
|
318 | (3) |
|
Memory protection unit (MPU) |
|
|
321 | (1) |
|
|
322 | (2) |
|
|
324 | (1) |
|
|
325 | (1) |
|
|
325 | (1) |
|
Memory attribute indirection registers |
|
|
326 | (3) |
|
Exercise: Memory protection unit |
|
|
329 | (2) |
|
|
331 | (1) |
|
|
331 | (1) |
|
Exercise: Using the CMSIS-zone utility |
|
|
331 | (9) |
|
|
340 | (1) |
|
Chapter 11 The NXP LPC55S69 a reference IoT microcontroller |
|
|
341 | (34) |
|
|
341 | (1) |
|
Trusted execution environment (TEE) |
|
|
342 | (1) |
|
|
342 | (2) |
|
Trusted execution environment configuration |
|
|
344 | (1) |
|
Example: Trusted execution environment |
|
|
345 | (2) |
|
|
347 | (1) |
|
|
347 | (1) |
|
|
347 | (3) |
|
|
350 | (7) |
|
Exercise: Key storage using the PUF |
|
|
357 | (1) |
|
|
357 | (4) |
|
|
361 | (1) |
|
|
361 | (3) |
|
|
364 | (2) |
|
|
366 | (1) |
|
|
366 | (1) |
|
|
367 | (1) |
|
Exercise: Casper primitives |
|
|
368 | (1) |
|
|
369 | (1) |
|
|
370 | (1) |
|
Executable image encryption |
|
|
370 | (1) |
|
Exercise: Image encryption |
|
|
371 | (1) |
|
|
371 | (2) |
|
|
373 | (2) |
|
Chapter 12 Trusted firmware |
|
|
375 | (34) |
|
|
375 | (1) |
|
|
376 | (1) |
|
|
377 | (1) |
|
Exercise: TF-M setup and testing |
|
|
377 | (5) |
|
|
382 | (2) |
|
|
384 | (1) |
|
|
385 | (7) |
|
|
392 | (2) |
|
Exercise: Secure partition manifest |
|
|
394 | (1) |
|
|
395 | (5) |
|
Selecting the communication model |
|
|
400 | (1) |
|
Secure partition runtime library |
|
|
400 | (1) |
|
|
401 | (1) |
|
|
402 | (2) |
|
|
404 | (1) |
|
|
405 | (1) |
|
|
405 | (1) |
|
|
406 | (1) |
|
|
407 | (2) |
|
Chapter 13 Trusted firmware secure services |
|
|
409 | (30) |
|
|
409 | (1) |
|
|
409 | (1) |
|
|
409 | (1) |
|
|
410 | (2) |
|
|
412 | (1) |
|
|
413 | (3) |
|
Exercise: Internal trusted storage |
|
|
416 | (1) |
|
|
417 | (12) |
|
Exercise: Cryptography service |
|
|
429 | (1) |
|
|
430 | (4) |
|
Exercise: Attestation token |
|
|
434 | (1) |
|
|
435 | (1) |
|
|
436 | (1) |
|
|
436 | (1) |
|
|
436 | (1) |
|
|
437 | (2) |
|
Chapter 14 The PSA Secure Bootloader |
|
|
439 | (23) |
|
|
439 | (1) |
|
|
439 | (2) |
|
|
441 | (1) |
|
|
441 | (1) |
|
|
442 | (1) |
|
|
442 | (1) |
|
|
442 | (1) |
|
|
442 | (3) |
|
|
445 | (3) |
|
|
448 | (1) |
|
|
448 | (1) |
|
|
449 | (1) |
|
Exercise: BL2 first project |
|
|
449 | (4) |
|
|
453 | (5) |
|
Updating the bootloader keys |
|
|
458 | (1) |
|
Exercise: Bootloader keys |
|
|
458 | (2) |
|
Bootloading by hardware key |
|
|
460 | (1) |
|
|
460 | (1) |
|
|
461 | (1) |
Conclusion |
|
462 | (1) |
Bibliography |
|
463 | (6) |
Index |
|
469 | |