Hi, Ian jonhson wrote: > Hi, > > I wrote a function to fetch the lifetime (expire time) of a > certificate. But it seems not to work right. >
I think you've misunderstood what SSL_CTX_get_timeout() does. This timeout is the SSL session timeout which lets you decide how long an SSL session can stay in cache before it becomes non-resumable. The openssl manual pages have sufficient info. [snip..] > > $ ./my_test_code > Session ID timeout value = 7200 > > what is the meaning of 7200? I have set the expire time of certificate > 12 hours, but 7200 is not the right time if it is calculated by > seconds. 7200 secs = 2 hrs, which is the default timeout from ssl/s3_lib.c: ssl3_default_timeout() You can override it though. And it hasn't got anything to do with ur certificates. > > What is wrong in my codes? Could anybody give me some advices? > > nothing in fact is wrong with ur code in a sense, it is printing the timeout value of the session :) -jb -- Tact is the art of making a point without making an enemy. ______________________________________________________________________ OpenSSL Project http://www.openssl.org User Support Mailing List openssl-users@openssl.org Automated List Manager [EMAIL PROTECTED]