Commit 6e65c6e
Clear signature outputs with mld_zeroize on failure
Scrub the detached-signature buffer on error paths with mld_zeroize
rather than memset, matching key generation and pk_from_sk.
This is a conservative measure. A plain memset of an output buffer is
not a dead store while the signing routine is a separate call, so the
compiler will not remove it; it could only be optimized away if the
routine were inlined into a caller that discards the signature.
Signed-off-by: Matthias J. Kannwischer <matthias@zerorisc.com>1 parent e48be7b commit 6e65c6e
1 file changed
Lines changed: 5 additions & 5 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1050 | 1050 | | |
1051 | 1051 | | |
1052 | 1052 | | |
1053 | | - | |
| 1053 | + | |
1054 | 1054 | | |
1055 | 1055 | | |
1056 | 1056 | | |
| |||
1111 | 1111 | | |
1112 | 1112 | | |
1113 | 1113 | | |
1114 | | - | |
| 1114 | + | |
1115 | 1115 | | |
1116 | | - | |
| 1116 | + | |
1117 | 1117 | | |
1118 | 1118 | | |
1119 | 1119 | | |
| |||
1370 | 1370 | | |
1371 | 1371 | | |
1372 | 1372 | | |
1373 | | - | |
| 1373 | + | |
1374 | 1374 | | |
1375 | | - | |
| 1375 | + | |
1376 | 1376 | | |
1377 | 1377 | | |
1378 | 1378 | | |
| |||
0 commit comments