Uploaded image for project: 'Qt'
  1. Qt
  2. QTBUG-76567

QNetworkAccessManager: Stack overflow crash when proxy server closes connection shortly after connecting using spdy/http2

    XMLWordPrintable

Details

    • Windows
    • e21169796297f752a62db25c722ff8e2ff66d8dc (qt/qtbase/5.12)

    Description

      (presumably affects all platforms, but not tested)

      Tail of the stack trace is attached.

      The steps needed:

      1. Use QNAM with a proxy which will reject you quickly (I use CCproxy with my IP not in the allowed list)
      2. Needs to have the SPDY or H2 attribute enabled on the QNetworkRequest
      3. Start connecting to any address (possibly needs to be an endpoint with TLS)
      4. Get rejected by the proxy / have the proxy close the connection
      5. Crash due to stack overflow

      The problem is that it will then recursively emit errors until it crashes (the recursion being due to QHttpNetworkConnectionChannel::close trying to close the socket, which triggers a flush, which triggers an error emission which loops back to the aforementioned close() method).

      Attachments

        No reviews matched the request. Check your Options in the drop-down menu of this sections header.

        Activity

          People

            manordheim Mårten Nordheim
            manordheim Mårten Nordheim
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved:

              Gerrit Reviews

                There are no open Gerrit changes