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

QNetwork for webassembly



    • Type: Task
    • Status: In Progress
    • Priority: P2: Important
    • Resolution: Unresolved
    • Affects Version/s: None
    • Fix Version/s: None
    • Component/s: Network
    • Labels:


      Applications running on the web platform are sandboxed, and this applies to network connectivity as well. Many standard protocols such as DNS and TCP sockets are not directly available (but see below):

      We are looking at several options:

      1) Use QNetworkAccessManager to make requests back to the origin server. This maps to the native XMLHttpRequest or Fetch APIs. Status: Merged for 5.12

      2) Use QWebSocket to make WebSocket connections to any host. Connecting by host name works; the browser will resolve the hostname. Status: merged for 5.12

      3) Use QTcpSocket to make a TCP connection to a forwarding server that runs e.g. websockify. This tunnels TCP traffic over WebSocket, which again means that connecting by hostname is OK. Status: working in 5.12

      Future Tech 4) Look at WebRTC for peer-to-peer communication. We could possibly tunnel TCP connections to other application instances.


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



            • Assignee:
              lpotter Lorn Potter
              lpotter Lorn Potter
            • Votes:
              4 Vote for this issue
              12 Start watching this issue


              • Created:

                Gerrit Reviews

                There are no open Gerrit changes