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 development | Windows API - Win32
Windows for business | Windows Client for IT Pros | User experience | Other
{count} votes

1 answer

Sort by: Most helpful
  1. Xiaopo Yang - MSFT 12,736 Reputation points Microsoft External Staff
    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

Your answer

Answers can be marked as 'Accepted' by the question author and 'Recommended' by moderators, which helps users know the answer solved the author's problem.