The ASN1_time_tm_clamp_notafter function does nothing except when
the portable-only SMALL_TIME_T define has been enabled.

However, the SMALL_TIME_T functionality also needs to be accessed
by the libtls tls_get_peer_cert_times function in order for the
portable build of libtls to also support SMALL_TIME_T.

Therefore make the ASN1_time_tm_clamp_notafter function a public
external rather than a private symbol.

Signed-off-by: Kyle J. McKay <mack...@gmail.com>

---
 lib/libcrypto/Symbols.list     | 1 +
 lib/libcrypto/asn1/asn1.h      | 1 +
 lib/libcrypto/asn1/asn1_locl.h | 2 --
 3 files changed, 2 insertions(+), 2 deletions(-)

diff --git a/lib/libcrypto/Symbols.list b/lib/libcrypto/Symbols.list
index 2b8557b1..94442cc5 100644
--- a/lib/libcrypto/Symbols.list
+++ b/lib/libcrypto/Symbols.list
@@ -214,6 +214,7 @@ ASN1_template_free
 ASN1_template_i2d
 ASN1_template_new
 ASN1_time_parse
+ASN1_time_tm_clamp_notafter
 ASN1_time_tm_cmp
 ASN1_unpack_string
 AUTHORITY_INFO_ACCESS_free
diff --git a/lib/libcrypto/asn1/asn1.h b/lib/libcrypto/asn1/asn1.h
index da16d5c5..fe9a6c5d 100644
--- a/lib/libcrypto/asn1/asn1.h
+++ b/lib/libcrypto/asn1/asn1.h
@@ -1454,6 +1454,7 @@ void ERR_load_ASN1_strings(void);
 
 int ASN1_time_parse(const char *_bytes, size_t _len, struct tm *_tm, int 
_mode);
 int ASN1_time_tm_cmp(struct tm *_tm1, struct tm *_tm2);
+int ASN1_time_tm_clamp_notafter(struct tm *tm);
 #ifdef  __cplusplus
 }
 #endif
diff --git a/lib/libcrypto/asn1/asn1_locl.h b/lib/libcrypto/asn1/asn1_locl.h
index 68f71dfc..c05eb3b9 100644
--- a/lib/libcrypto/asn1/asn1_locl.h
+++ b/lib/libcrypto/asn1/asn1_locl.h
@@ -152,6 +152,4 @@ struct x509_crl_method_st {
 int UTF8_getc(const unsigned char *str, int len, unsigned long *val);
 int UTF8_putc(unsigned char *str, int len, unsigned long value);
 
-int ASN1_time_tm_clamp_notafter(struct tm *tm);
-
 __END_HIDDEN_DECLS

-- 

Reply via email to