Getting logs for WinHTTP system error.

Ivanov 0 Reputation points
2024-04-11T14:03:06.43+00:00

Hi, All!

Recently, during development of an application, I've started facing troublesome issue: calls to WinHTTP subsystem (specifically, WinHttpReadData/WinHttpQueryDataAvailable APIs) present me with 12004 ERROR_WINHTTP_INTERNAL_ERROR outcome. Doesn't happen always, problem is intermittent. Since this is a very generic error code, I'm out of options for debugging it. I'm wondering, whether there are logging options (Event viewer maybe) that could help in finding the cause? If so, how to turn it on, etc?

Best regards

Windows
Windows
A family of Microsoft operating systems that run across personal computers, tablets, laptops, phones, internet of things devices, self-contained mixed reality headsets, large collaboration screens, and other devices.
4,767 questions
Windows API - Win32
Windows API - Win32
A core set of Windows application programming interfaces (APIs) for desktop and server applications. Previously known as Win32 API.
2,425 questions
{count} votes

1 answer

Sort by: Most helpful
  1. Xiaopo Yang - MSFT 11,496 Reputation points Microsoft Vendor
    2024-04-12T02:40:13.9933333+00:00

    Hello @Ivanov,

    You can Collect WinHTTP traces using netsh.exe.

    There is also Capturing WinHTTP Logs document in WSDAPI Diagnostic Procedures.

    0 comments No comments