microsoft / msquic

Cross-platform, C implementation of the IETF QUIC protocol, exposed to C, C++, C# and Rust.
MIT License
4.04k stars 532 forks source link

QUIC_CONNECTION_EVENT_SHUTDOWN_INITIATED_BY_TRANSPORT with ErrorCode QUIC_ERROR_INTERNAL_ERROR when sending moderately sized stream #4233

Open shit-lord opened 5 months ago

shit-lord commented 5 months ago

Describe the bug

In the attachment are simple sample programs used to reproduce the issue.

At server's QUIC_CONNECTION_EVENT_CONNECTED, it creates a stream and sends the whole msquic.dll inside the directory of server.exe. Client's QUIC_STREAM_EVENT_RECEIVE then writes received data to a file so data can be compared later.

QUIC_CONNECTION_EVENT_SHUTDOWN_INITIATED_BY_TRANSPORT almost always happens mid transmission. This problem only occurs when client runs in a particular pc with wired network connection in someone's home. All other people requested to test did not meet the problem. I think OS version is irrelevant because the problem also occurs in vmware virtual machine running inside that pc, with a different Windows version.

The problem goes away when it switched to wireless, so I assume something is wrong with the cable/network card causing packet drops, but other traditional network programs(browser,mstsc,etc) work without apparant problem.

quictest.zip

Affected OS

Additional OS information

No response

MsQuic version

v2.3

Steps taken to reproduce bug

Run server.exe in a machine1 Run client.exe in another machine2 enter the ip of machine1 to client.exe

Expected behavior

client.exe writes client.out which should be identical to msquic.dll

Actual outcome

QUIC_CONNECTION_EVENT_SHUTDOWN_INITIATED_BY_TRANSPORT

Additional details

No response

nibanks commented 4 months ago

Can you take a look at these to try to debug the problem?

shit-lord commented 2 months ago

here are log files converted from quic.etl quic.txt contains a successful run and two failed ones quic1.txt and quic2.txt contain only failed runs quictest.zip