diff options
author | Jaakko Keränen <jaakko.keranen@iki.fi> | 2020-07-31 09:22:56 +0300 |
---|---|---|
committer | Jaakko Keränen <jaakko.keranen@iki.fi> | 2020-07-31 09:22:56 +0300 |
commit | 3b76ce224e40f670c0988985d9a9405edb7ed24d (patch) | |
tree | 40040d74d869cfcef46493e4d0c4c35da98c09d4 /src | |
parent | d8f9c8c034c263b0939b0afe8150fdf8490e0077 (diff) |
GmRequest: Print the server certificate for testing
Diffstat (limited to 'src')
-rw-r--r-- | src/gmrequest.c | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/src/gmrequest.c b/src/gmrequest.c index 25ff90af..5ee3382c 100644 --- a/src/gmrequest.c +++ b/src/gmrequest.c | |||
@@ -164,6 +164,14 @@ static void requestFinished_GmRequest_(iAnyObject *obj) { | |||
164 | SDL_RemoveTimer(d->timeoutId); | 164 | SDL_RemoveTimer(d->timeoutId); |
165 | d->timeoutId = 0; | 165 | d->timeoutId = 0; |
166 | d->state = finished_GmRequestState; | 166 | d->state = finished_GmRequestState; |
167 | #if 0 | ||
168 | printf("Server certificate:\n%s\n", | ||
169 | cstrLocal_String(pem_TlsCertificate(serverCertificate_TlsRequest(d->req)))); | ||
170 | iDate expiry; | ||
171 | validUntil_TlsCertificate(serverCertificate_TlsRequest(d->req), &expiry); | ||
172 | printf("Valid until %04d-%02d-%02d\n", expiry.year, expiry.month, expiry.day); | ||
173 | printf("Subject: %s\n", cstrLocal_String(subject_TlsCertificate(serverCertificate_TlsRequest(d->req)))); | ||
174 | #endif | ||
167 | unlock_Mutex(&d->mutex); | 175 | unlock_Mutex(&d->mutex); |
168 | iNotifyAudience(d, finished, GmRequestFinished); | 176 | iNotifyAudience(d, finished, GmRequestFinished); |
169 | } | 177 | } |