xpra icon
Bug tracker and wiki

This bug tracker and wiki are being discontinued
please use https://github.com/Xpra-org/xpra instead.

Opened 4 years ago

Closed 4 years ago

Last modified 8 months ago

#1681 closed enhancement (worksforme)

allow http/websocket over unix socket when --html

Reported by: idupree Owned by: idupree
Priority: major Milestone: 2.2
Component: network Version: trunk
Keywords: Cc:


xpra supports binding to unix sockets.

At first it doesn't sound like HTTP over Unix socket would be useful, because browsers can't connect to unix sockets. However:

ssh supports proxying unix sockets to IP ports elsewhere.

This can be useful because it can keep other Unix users on the box running xpra server from trying to connect to xpra.

When I combine --bind= and --html=on, however, the browser receives "this port does not support HTTP requests", and xpra logs "Error: unix-domain connection failed"..."invalid packet header, HTTP GET request".

Are there reasons not to change xpra to allow HTTP on unix socket when --html is on?

Change History (3)

comment:1 Changed 4 years ago by Antoine Martin

Component: html5network
Owner: changed from Antoine Martin to idupree

Turned out to be (almost) trivial, so done in r17381.

Tested with:

  • server:
    xpra start --start=xterm  --daemon=no -d network,websocket :10
  • socat to make the unix-domain socket available as TCP:
    socat TCP-LISTEN:20000,fork  UNIX:$XDG_RUNTIME_DIR/xpra/$HOSTNAME-10
  • point browser at the TCP port:
    xdg-open http://localhost:20000/

@idupree: please close if that works for you.

comment:2 Changed 4 years ago by Antoine Martin

Resolution: worksforme
Status: newclosed

comment:3 Changed 8 months ago by migration script

this ticket has been moved to: https://github.com/Xpra-org/xpra/issues/1681

Note: See TracTickets for help on using tickets.