vnc: Enable password authentication in non-TLS mode

If VNC is enabled without specifying server certificate and key,
TLS won't be activated. Use regular passsword authentication
instead.

Signed-off-by: Lukasz Czechowski <lukasz.czechowski@thaumatec.com>
This commit is contained in:
Lukasz Czechowski 2024-05-21 16:21:21 +02:00 committed by Marius Vlad
parent 58a0abcb58
commit 3ecdd0486c
1 changed files with 7 additions and 0 deletions

View File

@ -1266,6 +1266,13 @@ vnc_backend_create(struct weston_compositor *compositor,
weston_log("TLS support activated\n");
} else {
ret = nvnc_enable_auth(backend->server, NVNC_AUTH_REQUIRE_AUTH,
vnc_handle_auth, NULL);
if (ret) {
weston_log("Failed to enable authentication\n");
goto err_output;
}
weston_log(
"warning: VNC enabled without Transport Layer "
"Security!\n");