Commit d05116b
bpf, arm64: sign return address for jited code
Sign return address for jited code when the kernel is built with pointer
authentication enabled.
1. Sign lr with paciasp instruction before lr is pushed to stack. Since
paciasp acts like landing pads for function entry, no need to insert
bti instruction before paciasp.
2. Authenticate lr with autiasp instruction after lr is poped from stack.
Signed-off-by: Xu Kuohai <xukuohai@huawei.com>1 parent 7e8ae09 commit d05116b
2 files changed
+12
-2
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
249 | 249 | | |
250 | 250 | | |
251 | 251 | | |
| 252 | + | |
| 253 | + | |
| 254 | + | |
252 | 255 | | |
253 | 256 | | |
254 | 257 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
192 | 192 | | |
193 | 193 | | |
194 | 194 | | |
195 | | - | |
| 195 | + | |
196 | 196 | | |
197 | 197 | | |
198 | 198 | | |
| |||
233 | 233 | | |
234 | 234 | | |
235 | 235 | | |
| 236 | + | |
| 237 | + | |
| 238 | + | |
236 | 239 | | |
237 | | - | |
| 240 | + | |
238 | 241 | | |
239 | 242 | | |
240 | 243 | | |
| |||
529 | 532 | | |
530 | 533 | | |
531 | 534 | | |
| 535 | + | |
| 536 | + | |
| 537 | + | |
| 538 | + | |
532 | 539 | | |
533 | 540 | | |
534 | 541 | | |
| |||
0 commit comments