Bug 43646 - Не работает подключение по протоколу SPICE
Summary: Не работает подключение по протоколу SPICE
Status: CLOSED FIXED
Alias: None
Product: Sisyphus
Classification: Development
Component: openuds-server (show other bugs)
Version: unstable
Hardware: x86_64 Linux
: P5 normal
Assignee: Alexey Shabalin
QA Contact: qa-sisyphus
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2022-08-29 16:52 MSK by Elena Mishina
Modified: 2023-02-08 16:48 MSK (History)
2 users (show)

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Elena Mishina 2022-08-29 16:52:23 MSK
При попытке подключения, на клиенте, формируется файл вида:
[virt-viewer]
type=spice
host=kvm
port=5942
password=123
tls-port=-1
fullscreen=0
title=UDS Enterprise:%d - Press SHIFT+F12 to Release Cursor
enable-smartcard=0
enable-usb-autoshare=1
enable-usbredir=1
delete-this-file=1
usb-filter=-1,-1,-1,-1,0
tls-ciphers=DEFAULT
host-subject=
ca=
toggle-fullscreen=shift+f11
release-cursor=shift+f12
secure-attention=ctrl+alt+end
secure-
channels=main;inputs;cursor;playback;record;display;usbredir;smartcard

Подключения не происходит с ошибкой (Linux/Windows): "Не удалось 
установить соединение с графическим сервером 
/tmp/.private/username/filename"

Проблема оказалась в последней строке:  secure-channels=
если она закомментирована, или если из неё убрать параметры main и 
display, то всё работает так как ожидалось.

(Рабочий лог:
{'as_file': '[virt-viewer]\ntype=spice\nhost=kvm\nport=5942\npassword=123\ntls-port=-1\nfullscreen=1\ntitle=UDS Enterprise:%d - Press SHIFT+F12 to Release Cursor\nenable-smartcard=1\nenable-usb-autoshare=1\nenable-usbredir=1\ndelete-this-file=1\nusb-filter=-1,-1,-1,-1,1\ntls-ciphers=DEFAULT\nhost-subject=\nca=\ntoggle-fullscreen=shift+f11\nrelease-cursor=shift+f12\nsecure-attention=ctrl+alt+end\n#secure-channels=main;inputs;cursor;playback;record;display;usbredir;smartcard\n'}
)

Эта строка формируется в файле 
/usr/share/openuds/uds/transports/SPICE/remote_viewer_file.py:

secure_channel='secure-
channels=main;inputs;cursor;playback;record;display;usbredir;smartcar
d' 
if tls_port != '-1' else ''

Получается, что либо нужно настраивать SPICE TLS в OpenNebula (но в 
веб-интерфейсе этого не сделать), либо что-то еще делать)
Comment 1 Alexander Makeenkov 2023-01-16 15:02:38 MSK
openuds-server-3.5.0-alt3 ошибка воспроизводится.

Если в файле подключения не изменить параметр secure-channels, то подключение падает с ошибкой:
(remote-viewer:54946): GSpice-WARNING **: 14:55:44.824: Invalid port value -1
(remote-viewer:54946): GSpice-DEBUG: 14:55:44.824: ../src/spice-channel.c:2570 main-1:0: Connect error
Comment 2 Alexey Shabalin 2023-01-16 17:18:26 MSK
Планируем реализовать отдельную галку вкючения/выключения для ssl.
Comment 3 Repository Robot 2023-02-08 16:48:21 MSK
openuds-server-3.5.0-alt6 -> sisyphus:

 Wed Feb 08 2023 Alexander Burmatov <thatman@altlinux> 3.5.0-alt6
 - Add checkbox to enable SSL connection for SPICE (ALT #43646)