1
0
mirror of https://github.com/openbsd/ports.git synced 2025-12-06 07:36:10 +00:00

fossil: pull in upstreamed patch for opaque ASN1_STRING

ok jturner (maintainer)

https://github.com/openssl/openssl/issues/29117
https://fossil-scm.org/home/info/0d239b52b0db10be
This commit is contained in:
tb
2025-12-05 16:47:36 +00:00
parent 70f559f329
commit 8298e1e600
2 changed files with 23 additions and 0 deletions

View File

@@ -2,6 +2,7 @@ COMMENT = simple distributed software configuration management
V = 2.27
PKGNAME = fossil-${V}
REVISION = 0
# commit ID must be changed in DISTFILES when updating, see
# https://fossil-scm.org/home/uv/download.html

View File

@@ -0,0 +1,22 @@
https://fossil-scm.org/home/info/0d239b52b0db10be
Index: src/http_ssl.c
--- src/http_ssl.c.orig
+++ src/http_ssl.c
@@ -222,11 +222,14 @@ static const char *ssl_asn1time_to_iso8601(ASN1_TIME *
}else{
char res[20];
char *pr = res;
- const char *pt = (char *)asn1_time->data;
+#if OPENSSL_VERSION_NUMBER < 0x10100000L
+ #define ASN1_STRING_get0_data ASN1_STRING_data
+#endif
+ const char *pt = (const char *)ASN1_STRING_get0_data(asn1_time);
/* 0123456789 1234
** UTCTime: YYMMDDHHMMSSZ (YY >= 50 ? 19YY : 20YY)
** GeneralizedTime: YYYYMMDDHHMMSSZ */
- if( asn1_time->length < 15 ){
+ if( ASN1_STRING_length(asn1_time) < 15 ){
/* UTCTime, fill out century digits */
*pr++ = pt[0]>='5' ? '1' : '2';
*pr++ = pt[0]>='5' ? '9' : '0';