Code Monkey home page Code Monkey logo

wayvnc's Introduction

wayvnc

Introduction

This is a VNC server for wlroots based Wayland compositors. It attaches to a running Wayland session, creates virtual input devices and exposes a single display via the RFB protocol. The Wayland session may be a headless one, so it is also possible to run wayvnc without a physical display attached.

Please check the FAQ for answers to common questions. For further support, join the #wayvnc IRC channel on freenode.

Installing

archlinux

yay -S wayvnc

FreeBSD

pkg install wayvnc

Fedora

dnf install wayvnc

Building

Runtime Dependencies

  • aml
  • drm
  • gbm
  • libxkbcommon
  • neatvnc
  • pixman

Build Dependencies

  • GCC
  • meson
  • ninja
  • pkg-config

For archlinux

pacman -S base-devel libglvnd libxkbcommon pixman gnutls

For fedora 31

dnf install -y meson gcc ninja-build pkg-config egl-wayland egl-wayland-devel \
	mesa-libEGL-devel mesa-libEGL libwayland-egl libglvnd-devel \
	libglvnd-core-devel libglvnd mesa-libGLES-devel mesa-libGLES \
	libxkbcommon-devel libxkbcommon libwayland-client libwayland \
	wayland-devel gnutls-devel

The easiest way to satisfy the neatvnc and aml dependencies is to link to them in the subprojects directory:

git clone https://github.com/any1/wayvnc.git
git clone https://github.com/any1/neatvnc.git
git clone https://github.com/any1/aml.git

mkdir wayvnc/subprojects
cd wayvnc/subprojects
ln -s ../../neatvnc .
ln -s ../../aml .
cd -

mkdir neatvnc/subprojects
cd neatvnc/subprojects
ln -s ../../aml .
cd -

meson build
ninja -C build

Running

Wayvnc can be run from the build directory like so:

./build/wayvnc

☢️ The server only accepts connections from localhost by default. To accept connections via any interface, set the address to 0.0.0.0 like this:

./build/wayvnc 0.0.0.0

⚠️ Do not do this on a public network or the internet without user authentication enabled. The best way to protect your VNC connection is to use SSH tunneling while listening on localhost, but users can also be authenticated when connecting to Wayvnc.

Encryption & Authentication

You'll need a private X509 key and a certificate. A self signed key with a certificate can be generated like so:

openssl req -x509 -newkey rsa:4096 -sha256 -days 3650 -nodes \
	-keyout key.pem -out cert.pem -subj /CN=localhost \
	-addext subjectAltName=DNS:localhost,DNS:localhost,IP:127.0.0.1

Replace localhost and 127.0.0.1 in the command above with your public facing host name and IP address, respectively, or just keep them as is if you're testing locally.

Create a config with the authentication info and load it using the --config command line option or place it at the default location $HOME/.config/wayvnc/config.

address=0.0.0.0
enable_auth=true
username=luser
password=p455w0rd
private_key_file=/path/to/key.pem
certificate_file=/path/to/cert.pem

Compatible Software

See https://github.com/any1/neatvnc#client-compatibility

wayvnc's People

Contributors

any1 avatar valpackett avatar danshick avatar jbeich avatar ddevault avatar bhepple avatar cherusk avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.