Skip to content

Add "no OPENSSL_Applink" warning when SSLKEYLOGFILE is set on win32#1059

Open
LuomingXu wants to merge 1 commit intoencode:masterfrom
LuomingXu:master
Open

Add "no OPENSSL_Applink" warning when SSLKEYLOGFILE is set on win32#1059
LuomingXu wants to merge 1 commit intoencode:masterfrom
LuomingXu:master

Conversation

@LuomingXu
Copy link

Summary

[Windows Only] SSLKEYLOGFILE can trigger the "no OPENSSL_Applink" error.
OpenSSL on Windows requires an 'Applink' interface to safely perform I/O
(like logging keys) across different C-Runtimes (CRT). Since CPython doesn't
provide this bridge and manages I/O independently, OpenSSL fails to access
Windows stdio, leading to a crash or the "no OPENSSL_Applink" error.

Why add this warning or not

我遇到这个问题时被chatgpt和gemini误导走了弯路, 一直以为是多个libssl.dll
加载导致了这个错误, 还用process manager和process explorer去查是不是
加载了多个libssl, 发现没有, 再去搜, 后来才知道因为之前用wireshark, 添加了
SSLKEYLOGFILE环境变量, 导致了这个问题. 我用的httpx才出现了这个问题
若是觉得不应添加这个警告, 便关闭这个pr吧.
或者你觉得应该, 但是应添在其它地方.

Checklist

  • I understand that this PR may be closed in case there was no previous discussion. (This doesn't apply to typos!)
  • I've added a test for each change that was introduced, and I tried as much as possible to make a single atomic change.
  • I've updated the documentation accordingly.

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.

1 participant