@amadio commented on this pull request.


In src/XrdCrypto/XrdCryptosslAux.cc:

> @@ -730,16 +730,26 @@ time_t XrdCryptosslASN1toUTC(const ASN1_TIME *tsn1)
        &(ltm.tm_year), &(ltm.tm_mon), &(ltm.tm_mday),
        &(ltm.tm_hour), &(ltm.tm_min), &(ltm.tm_sec),
                                       &zz) != 7) || (zz != 'Z')) {
-       return -1;
+       // Try GeneralizedTime
+       if ((sscanf((const char *)(tsn1->data),
+           "%04d%02d%02d%02d%02d%02d%c", 
+           &(ltm.tm_year), &(ltm.tm_mon), &(ltm.tm_mday),
+           &(ltm.tm_hour), &(ltm.tm_min), &(ltm.tm_sec),
+                                          &zz) != 7) || (zz != 'Z')) {
+           return -1;
+       }

Hi @gganis, I wonder if we shouldn't also handle the case with a timezone if we are touching this code (i.e. something like the third example here)? What do you think?


Reply to this email directly, view it on GitHub, or unsubscribe.
You are receiving this because you are subscribed to this thread.Message ID: <xrootd/xrootd/pull/1970/review/1350394056@github.com>

[ { "@context": "http://schema.org", "@type": "EmailMessage", "potentialAction": { "@type": "ViewAction", "target": "https://github.com/xrootd/xrootd/pull/1970#pullrequestreview-1350394056", "url": "https://github.com/xrootd/xrootd/pull/1970#pullrequestreview-1350394056", "name": "View Pull Request" }, "description": "View this Pull Request on GitHub", "publisher": { "@type": "Organization", "name": "GitHub", "url": "https://github.com" } } ]

Use REPLY-ALL to reply to list

To unsubscribe from the XROOTD-DEV list, click the following link:
https://listserv.slac.stanford.edu/cgi-bin/wa?SUBED1=XROOTD-DEV&A=1