Hacktoberfest 2026: le issue che i maintainer hanno segnato per ottobre, aperte e adatte ai principianti. Sfoglia le issue Hacktoberfest

didn't respect origin server Sec-WebSocket-Extension header

Chiusa
#41 2 commenti 0 reazioni 1 assegnatario Vedi su GitHub

@vietj ci sta già lavorando.

Dal 17/2/2023.

Valutazione

Questa issue non è ancora stata valutata.

Descrizione

bug
Questions

Header Sec-WebSocket-Extension is used to negotiate the list of supported extensions between WebSocket client and server.

In Websocket response 101 Switch Protocols, even origin server returns without permessage-deflate extension, vertx-http-server proxies websocket message to orign server permessage-deflated.

Undoubly, it will not be functional as orgin server doesn't not support that extension.

Version

Which version(s) did you encounter this bug ?
4.3.5

Context
Do you have a reproducer?
Steps to reproduce
  1. create a new proxy project with below options:
val proxyClient: HttpClient = vertx.createHttpClient()
val proxyOptions = ProxyOptions()
proxyOptions.supportWebSocket = true
val proxy = HttpProxy.reverseProxy(proxyOptions, proxyClient)
proxy.origin(30000, "localhost")

val options = HttpServerOptions()
options.addWebSocketSubProtocol("tty")

vertx
      .createHttpServer(options)
      .requestHandler(proxy)
      .listen(8888) { http ->
        if (http.succeeded()) {
          startPromise.complete()
          println("HTTP server started on port 8888")
        } else {
          startPromise.fail(http.cause());
        }
      }
  1. downlown and execute ttyd
    ttyd is an open source project to serve terminal in Web interface.
    Download from https://github.com/tsl0922/ttyd/releases and run with command ./ttyd -p 30000 -b /ttyd bash

  2. Open http://localhost:8888/ttyd/

Extra

As a workaround, I turn off message compression:

options.setPerMessageWebSocketCompressionSupported(false)
  • Anything that can be relevant such as OS version, JVM version
Lingua principale
Java
Stelle
68
Fork
39
Merge medio
2g 43m
PR unite (30g)
5

Preparare l'ambiente

Come iniziare

  1. Leggi tutta la issue e poi la guida ai contributi del progetto.
  2. Commenta sulla issue per dire che te ne occupi tu — evita che due persone facciano lo stesso lavoro.
  3. Fai un fork del repository e lavora su un branch.
  4. Apri una pull request che faccia riferimento al numero della issue.

Altre issue di eclipse-vertx/vertx-http-proxy

Tutte le issue di eclipse-vertx/vertx-http-proxy

Issue simili

Altre issue su Java

Ricevi le nuove issue nella tua casella

Un breve riepilogo di issue GitHub adatte ai principianti.