Skip to content

Commit 62e3e95

Browse files
committed
Fix build on legacy openssl 1.0.2
Fixes #133
1 parent 5fbe62a commit 62e3e95

File tree

3 files changed

+9
-1
lines changed

3 files changed

+9
-1
lines changed

DESCRIPTION

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
Package: openssl
22
Type: Package
33
Title: Toolkit for Encryption, Signatures and Certificates Based on OpenSSL
4-
Version: 2.3.3
4+
Version: 2.3.4
55
Authors@R: c(person("Jeroen", "Ooms", role = c("aut", "cre"), email = "[email protected]",
66
comment = c(ORCID = "0000-0002-4035-0289")),
77
person("Oliver", "Keyes", role = "ctb"))

NEWS

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,6 @@
1+
2.3.4
2+
- Fix build on legacy openssl 1.0.2
3+
14
2.3.3
25
- Fix a unit test for CRAN Fedora builds
36

src/info.c

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
#include <Rinternals.h>
22
#include <openssl/opensslconf.h>
33
#include <openssl/opensslv.h>
4+
#include "compatibility.h"
45

56
#include <openssl/evp.h>
67
#ifdef EVP_PKEY_ED25519
@@ -25,7 +26,11 @@ SEXP R_openssl_config(void) {
2526
has_fips = 1;
2627
#endif
2728
SEXP res = PROTECT(Rf_allocVector(VECSXP, 4));
29+
#ifdef HAS_OPENSSL11_API
2830
SET_VECTOR_ELT(res, 0, Rf_mkString(OpenSSL_version(OPENSSL_VERSION)));
31+
#else
32+
SET_VECTOR_ELT(res, 0, Rf_mkString(OPENSSL_VERSION_TEXT));
33+
#endif
2934
SET_VECTOR_ELT(res, 1, Rf_ScalarLogical(has_ec));
3035
SET_VECTOR_ELT(res, 2, Rf_ScalarLogical(has_x25519));
3136
SET_VECTOR_ELT(res, 3, Rf_ScalarLogical(has_fips));

0 commit comments

Comments
 (0)