Skip to contentSkip to conversation

Logic error in rsa_private

DISCUSSION Olaf Hering 1 participant 1 message May 16, 2023

lore
Share & tools
lore
#0 lore raw

Hello,

as shown in 'build.log' at
https://gitlab.com/xen-project/xen/-/jobs/4284741850/artifacts/browse
there is a logic error spotted by gcc 13.

crypto/rsa.c: In function 'rsa_private':
crypto/rsa.c:56:7: error: the comparison will always evaluate as 'true' for the address of 'p' will never be NUL
56 | if (!key->p || !key->q || !key->u) {

None of p/q/u are pointers. Please have a look at some point.

Thanks,
Olaf