Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

ntmlclient: fix linking with libressl #6157

Merged
merged 1 commit into from
Jan 5, 2022

Conversation

boretrk
Copy link
Contributor

@boretrk boretrk commented Dec 31, 2021

Made a PR from the patch provided by @Nuadh in #6134

libressl still declares HMAC_CTX_cleanup so we can't create the dummy function in that case.

@ethomson ethomson merged commit 82f526a into libgit2:main Jan 5, 2022
@ethomson
Copy link
Member

ethomson commented Jan 5, 2022

Thanks!

freebsd-git pushed a commit to freebsd/freebsd-ports that referenced this pull request Jan 6, 2022
Patch upstream:
libgit2/libgit2#6157

PR:		260216
Reported by:	lysfjord.daniel@smokepit.net
freebsd-git pushed a commit to freebsd/freebsd-ports that referenced this pull request Jan 6, 2022
Patch upstream:
libgit2/libgit2#6157

PR:		260216
Reported by:	lysfjord.daniel@smokepit.net

(cherry picked from commit 7679b30)
@boretrk boretrk deleted the hmac_ctx_cleanup branch January 30, 2022 23:43
@botovq
Copy link

botovq commented Feb 14, 2022

HMAC_CTX_cleanup will be removed in LibreSSL 3.5, so this will break again.

The ifdef will become a bit unwieldy:

#if ((OPENSSL_VERSION_NUMBER >= 0x10100000L && !defined(LIBRESSL_VERSION_NUMBER)) || LIBRESSL_VERSION_NUMBER >= 0x3050000f) || defined(CRYPT_OPENSSL_DYNAMIC)

Perhaps it would make more sense to test from cmake whether the OpenSSL lib provides HMAC_CTX_new /HMAC_CTX_cleanup or not?

@Nuadh
Copy link

Nuadh commented Feb 14, 2022

HMAC_CTX_cleanup will be removed in LibreSSL 3.5, so this will break again.

The ifdef will become a bit unwieldy:

#if ((OPENSSL_VERSION_NUMBER >= 0x10100000L && !defined(LIBRESSL_VERSION_NUMBER)) || LIBRESSL_VERSION_NUMBER >= 0x3050000f) || defined(CRYPT_OPENSSL_DYNAMIC)

Perhaps it would make more sense to test from cmake whether the OpenSSL lib provides HMAC_CTX_new /HMAC_CTX_cleanup or not?

Indeed that would be a better alternative:)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

4 participants