title: Malformed HTTP Request
body: <p>Any reason why I am getting 'Malformed HTTP Request' from server?</p>
  
  <pre><code>Private Sub Form1_Load(sender As Object, e As EventArgs) Handles Me.Load
          ConnectAsync("ws://127.0.0.1:8000/api/setup/importwizard/checkUpdates/").Wait()
    End Sub
  
    Private Async Function ConnectAsync(uri As String) As Task
          Thread.Sleep(1000)
  
          Dim WebSocket As ClientWebSocket = Nothing
  
          Try
  
                WebSocket = New ClientWebSocket
                Await WebSocket.ConnectAsync(New Uri(uri), CancellationToken.None)
  
                'Await Task.WhenAll(ReceiveAsync(WebSocket), SendAsync(WebSocket))
                Await Task.WhenAll(ReceiveAsync(WebSocket))
  
          Catch ex As Exception
                Debug.WriteLine("Exception: {0}", ex.Message)
          Finally
                If WebSocket IsNot Nothing Then
                      WebSocket.Dispose()
                End If
  
                Debug.WriteLine(vbCrLf &amp; "Websocket closed.")
          End Try
    End Function
  </code></pre>
  
  <p>Response From Server</p>
  
  <blockquote>
    <p>Laravel development server started on <a href="http://127.0.0.1:8000/" rel="nofollow noreferrer">http://127.0.0.1:8000/</a>
    [Wed Oct  4 16:15:05 2017] 127.0.0.1:59590 Invalid request (Malformed HTTP request)</p>
  </blockquote>
  
  <p><a href="https://i.stack.imgur.com/hO4H8.png" rel="nofollow noreferrer">Response From Server</a></p>