Skip to content

Conversation

@bartonjs
Copy link
Member

Restructure CryptoNative_LookupFriendlyNameByOid to not depend on the so-deprecated-its-removed ERR_GET_FUNC.

This approach calls a2d_ASN1_OBJECT directly, rather than looking for it having been the source of the error.
While that does make for double work on success, it's just a state walker for a short string, so it's not too bad.

While noodling around in the function, I noticed that there was a small memory leak, so now that's fixed, too.

Fixes #57674 (in main).

@bartonjs bartonjs added this to the 7.0.0 milestone Aug 20, 2021
@bartonjs bartonjs self-assigned this Aug 20, 2021
@ghost
Copy link

ghost commented Aug 20, 2021

Tagging subscribers to this area: @bartonjs, @vcsjones, @krwq, @GrabYourPitchforks
See info in area-owners.md if you want to be subscribed.

Issue Details

Restructure CryptoNative_LookupFriendlyNameByOid to not depend on the so-deprecated-its-removed ERR_GET_FUNC.

This approach calls a2d_ASN1_OBJECT directly, rather than looking for it having been the source of the error.
While that does make for double work on success, it's just a state walker for a short string, so it's not too bad.

While noodling around in the function, I noticed that there was a small memory leak, so now that's fixed, too.

Fixes #57674 (in main).

Author: bartonjs
Assignees: bartonjs
Labels:

area-System.Security

Milestone: 7.0.0

@stephentoub stephentoub merged commit 50576e3 into dotnet:main Aug 21, 2021
@stephentoub
Copy link
Member

Does this need to be backported?

@bartonjs
Copy link
Member Author

/backport to release/6.0

@github-actions
Copy link
Contributor

Started backporting to release/6.0: https://github.com/dotnet/runtime/actions/runs/1153824338

@ghost ghost locked as resolved and limited conversation to collaborators Sep 20, 2021
@bartonjs bartonjs deleted the avoid_err_get_func branch October 7, 2021 20:23
@bartonjs bartonjs removed their assignment Nov 15, 2021
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

OpenSSL 3.0 has removed ERR_GET_FUNC

3 participants