[gnutls-devel] GnuTLS | tests/slow/cipher-api-test.c: Make test more portable (!852)
Development of GNU's TLS library
gnutls-devel at lists.gnutls.org
Wed Jan 2 14:22:19 CET 2019
>> This test checks whether the abort signal is received from invalid use of gnutls calls.
> _AND_ it also tests that the functions return error. In case assert() has _not_ been called, the test still PASSes as long as an error is returned. Thus your above statement is technically wrong (or not 100% correct).
Could be sorry. I think seeing the test it checks whether one of the two happens. Either an error is returned or an abort is seen.
> My changes let assert() abort the program, and abortion is taken as success.
I do not think that's the case. For example you skip the Additional data misuse in GCM ciphers, thus abort or error is not caught in that case.
> So the functionality of the test has not changed - it just doesn't rely on SIGABRT signal handlers. I could add a check `WIFSIGNALED(status) && WTERMSIG(status) == SIGABRT` to make 100% sure that not anything else caused program abortion, if that is what you are missing.
Ok, now I see that you rely on the fact that `check_wait_status()` does not fail on abort signal. I cannot think why `_check_wait_status()` would treat ABRT as success, and it may just be broken (thus you have uncovered a bug).
Reply to this email directly or view it on GitLab: https://gitlab.com/gnutls/gnutls/merge_requests/852#note_128384081
You're receiving this email because of your account on gitlab.com.
-------------- next part --------------
An HTML attachment was scrubbed...
More information about the Gnutls-devel