I have built UA SDK CPP for WinCE6.
The sample server(server_lesson01) works fine.
But UaExpert shows an errror about certificate validation.
Valid From 2 7 15:28:15 2106
Valid To 1 1 09:00:00 1970
Validity date is heading from the future to the past.
I think that the certificate is valid for five years from today.
I checked variables shown below at CertificateConfiguration::createCertificate.
info.validTime : 157680000
info.validFrom : 0
What do I need to check anything else?
Auto generated certificate validity is not correct
Moderator: uasdkcpp
-
- Sr. Member
- Posts: 10
- Joined: 13 Dec 2018, 02:08
- Support Team
- Hero Member
- Posts: 3070
- Joined: 18 Mar 2011, 15:09
Re: Auto generated certificate validity is not correct
Hello manakamu,
did you check the clock on the device - is it set to the current time correctly?
did you check the clock on the device - is it set to the current time correctly?
Best regards
Unified Automation Support Team
Unified Automation Support Team
-
- Sr. Member
- Posts: 10
- Joined: 13 Dec 2018, 02:08
Re: Auto generated certificate validity is not correct
I found that OpenSSL function(BIO_snprintf) is not working properly.
BIO_snprintf is used to set the validity date.
I could not understand the reason, but I solved it by replacing BIO_snprintf implmentation with _snprintf.
BIO_snprintf is used to set the validity date.
I could not understand the reason, but I solved it by replacing BIO_snprintf implmentation with _snprintf.