diff options
author | Daniel P. Berrangé <berrange@redhat.com> | 2024-03-15 14:29:11 +0000 |
---|---|---|
committer | Daniel P. Berrangé <berrange@redhat.com> | 2024-07-24 10:39:10 +0100 |
commit | 97f7bf113eb50fcdaf0c73aa2ee01e5355abc073 (patch) | |
tree | 2efc788f71855eae6b5aebf68ead7e0a36c2cfcf /module-common.c | |
parent | 57941c9c86357a6a642f9ee3279d881df4043b6d (diff) | |
download | qemu-97f7bf113eb50fcdaf0c73aa2ee01e5355abc073.zip qemu-97f7bf113eb50fcdaf0c73aa2ee01e5355abc073.tar.gz qemu-97f7bf113eb50fcdaf0c73aa2ee01e5355abc073.tar.bz2 |
crypto: propagate errors from TLS session I/O callbacks
GNUTLS doesn't know how to perform I/O on anything other than plain
FDs, so the TLS session provides it with some I/O callbacks. The
GNUTLS API design requires these callbacks to return a unix errno
value, which means we're currently loosing the useful QEMU "Error"
object.
This changes the I/O callbacks in QEMU to stash the "Error" object
in the QCryptoTLSSession class, and fetch it when seeing an I/O
error returned from GNUTLS, thus preserving useful error messages.
Reviewed-by: Philippe Mathieu-Daudé <philmd@linaro.org>
Signed-off-by: Daniel P. Berrangé <berrange@redhat.com>
Diffstat (limited to 'module-common.c')
0 files changed, 0 insertions, 0 deletions