Skip to content

Using higher-level wrapper of OpenSSL SHA1 hash function#1072

Merged
bel2125 merged 1 commit into
civetweb:masterfrom
guitargeek:openssl_deprecation_1
Apr 13, 2022
Merged

Using higher-level wrapper of OpenSSL SHA1 hash function#1072
bel2125 merged 1 commit into
civetweb:masterfrom
guitargeek:openssl_deprecation_1

Conversation

@guitargeek

@guitargeek guitargeek commented Apr 11, 2022

Copy link
Copy Markdown
Contributor

This is to get rid of deprecation warninigs when building with newer
OpenSSL versions:
https://www.openssl.org/docs/manmaster/man3/SHA1_Init.html

This is to get rid of deprecation warninigs when building with newer
OpenSSL versions.
@guitargeek

Copy link
Copy Markdown
Contributor Author

I now use EVP_Digest(), which seems fine as it is already used in other places in civetweb.c:
https://github.com/civetweb/civetweb/blob/master/src/civetweb.c#L16585

And this other place is not guarded by any preprocessor macros other that if !defined(NO_SSL).

@bel2125

bel2125 commented Apr 13, 2022

Copy link
Copy Markdown
Member

Thank you.
Merged.

@guitargeek guitargeek deleted the openssl_deprecation_1 branch April 13, 2022 21:01
guitargeek added a commit to guitargeek/root that referenced this pull request May 5, 2022
This is to get rid of deprecation warninigs when building on Ubuntu
22.04.

Should cause no backwards compatibility poblems, as the functions that
are used now are around at least since OpenSSL 1.0.2:
https://www.openssl.org/docs/man1.0.2/man3/EVP_DigestInit_ex.html

This patch was already applied to upstream civet:
civetweb/civetweb#1072
@linev

linev commented May 23, 2022

Copy link
Copy Markdown
Contributor

One comment - one can remove #include "sha1.inl" from the source and file sha1.inl itself.
But after this PR civetweb cannot be compiled without direct linking with SSL libraries.
Before SHA1 functions could be used from sha1.inl.

@bel2125

bel2125 commented May 30, 2022

Copy link
Copy Markdown
Member

It seems this change has an unintended side effect: If the server is built without OpenSSL support, the EVP_Digest function is not loaded - however WebSocket still uses it:

#1078

The original "deprecation warning" did not warn about OpenSSL functions but functions implemented in sha1.inl.

@linev

linev commented May 31, 2022

Copy link
Copy Markdown
Contributor

In my mind, one either revert this change or have to provide EVP_Digest function without OpenSSH.
But I did not found inline version of EVP_Digest

linev pushed a commit to root-project/root that referenced this pull request Jun 29, 2022
This is to get rid of deprecation warninigs when building on Ubuntu
22.04.

Should cause no backwards compatibility poblems, as the functions that
are used now are around at least since OpenSSL 1.0.2:
https://www.openssl.org/docs/man1.0.2/man3/EVP_DigestInit_ex.html

This patch was already applied to upstream civet:
civetweb/civetweb#1072
linev pushed a commit to linev/root that referenced this pull request Jun 29, 2022
This is to get rid of deprecation warninigs when building on Ubuntu
22.04.

Should cause no backwards compatibility poblems, as the functions that
are used now are around at least since OpenSSL 1.0.2:
https://www.openssl.org/docs/man1.0.2/man3/EVP_DigestInit_ex.html

This patch was already applied to upstream civet:
civetweb/civetweb#1072
linev pushed a commit to root-project/root that referenced this pull request Jun 30, 2022
This is to get rid of deprecation warninigs when building on Ubuntu
22.04.

Should cause no backwards compatibility poblems, as the functions that
are used now are around at least since OpenSSL 1.0.2:
https://www.openssl.org/docs/man1.0.2/man3/EVP_DigestInit_ex.html

This patch was already applied to upstream civet:
civetweb/civetweb#1072
@linev

linev commented Jul 7, 2022

Copy link
Copy Markdown
Contributor

#1080 should solve problem with platforms without OpenSSL

@bel2125

bel2125 commented Jul 9, 2022

Copy link
Copy Markdown
Member

Thank you, I already merged #1080.
But since I was "out" for almost two weeks, I will need some days to have a look at all open issues of these two weeks.

vepadulano pushed a commit to vepadulano/root that referenced this pull request Jul 20, 2022
This is to get rid of deprecation warninigs when building on Ubuntu
22.04.

Should cause no backwards compatibility poblems, as the functions that
are used now are around at least since OpenSSL 1.0.2:
https://www.openssl.org/docs/man1.0.2/man3/EVP_DigestInit_ex.html

This patch was already applied to upstream civet:
civetweb/civetweb#1072
j-mathe pushed a commit to j-mathe/root that referenced this pull request Jul 26, 2022
This is to get rid of deprecation warninigs when building on Ubuntu
22.04.

Should cause no backwards compatibility poblems, as the functions that
are used now are around at least since OpenSSL 1.0.2:
https://www.openssl.org/docs/man1.0.2/man3/EVP_DigestInit_ex.html

This patch was already applied to upstream civet:
civetweb/civetweb#1072
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants