OP-TEE / optee_os

Trusted side of the TEE
Other
1.59k stars 1.07k forks source link

core: fix undefined behavior aborts during xtest #6935

Closed Abhishek-612 closed 3 months ago

Abhishek-612 commented 4 months ago
  1. Replace i64 with u64 in lib/libtomcrypt/tweetnacl.c to avoid shift_out_of_bounds error by UBSan.

  2. Add null pointer checks in kernel/user_access.c before memcpy to avoid nonnull_args error by UBSan.

Signed-off-by: Abhishek Revadekar abhishek.rvdkr@yahoo.com

jenswi-linaro commented 4 months ago

It looks like you're using markup in the commit messages. Commit messages are supposed to be plain text so please drop all the back-ticks. With that fixed, please apply: Reviewed-by: Jens Wiklander <jens.wiklander@linaro.org>

Abhishek-612 commented 4 months ago

It looks like you're using markup in the commit messages. Commit messages are supposed to be plain text so please drop all the back-ticks. With that fixed, please apply: Reviewed-by: Jens Wiklander <jens.wiklander@linaro.org>

Commit messages have been fixed along with the Review tags.

jforissier commented 4 months ago

The second commit should also be proposed upstream (https://github.com/libtom/libtomcrypt) in order minimize the local changes.