From e1aae10b7751cc2078f3a86ab0aeb9d644ba1488 Mon Sep 17 00:00:00 2001 From: Beto HydroxyButyrate Date: Tue, 2 Mar 2021 20:55:32 +1000 Subject: [PATCH] qrexec-client-vm was stripping the escape chars on output. The server was not aware of the TERM setting, so I made it explicit, based on common assumptions. For both gnome-term and Xterm, the output now matches that of the pass command. --- bin/qvm-pass | 5 ++++- etc/qubes-rpc/ruddo.PassManage | 5 +++++ etc/qubes-rpc/ruddo.PassRead | 5 +++++ 3 files changed, 14 insertions(+), 1 deletion(-) diff --git a/bin/qvm-pass b/bin/qvm-pass index af8820c..fbeaf01 100755 --- a/bin/qvm-pass +++ b/bin/qvm-pass @@ -142,7 +142,10 @@ PASS_MANAGE = "ruddo.PassManage" def send_args(rpc, *args, **kwargs): - cmd = ['/usr/lib/qubes/qrexec-client-vm', opts.dest_vm, rpc] + cmd = ['/usr/lib/qubes/qrexec-client-vm', + '--no-filter-escape-chars-stdout', + '--no-filter-escape-chars-stderr', + opts.dest_vm, rpc] # print(cmd, file=sys.stderr) return_stdout = kwargs.get("return_stdout", False) if "return_stdout" in kwargs: diff --git a/etc/qubes-rpc/ruddo.PassManage b/etc/qubes-rpc/ruddo.PassManage index 2ae0659..c3c99d1 100644 --- a/etc/qubes-rpc/ruddo.PassManage +++ b/etc/qubes-rpc/ruddo.PassManage @@ -1,4 +1,9 @@ #!/bin/bash +# +# xterm-256color seems to be the qubes default +# for gnome-term and Xterm +# +export TERM="xterm-256color" set -e set -o pipefail diff --git a/etc/qubes-rpc/ruddo.PassRead b/etc/qubes-rpc/ruddo.PassRead index 93a07c7..6033c5c 100644 --- a/etc/qubes-rpc/ruddo.PassRead +++ b/etc/qubes-rpc/ruddo.PassRead @@ -1,4 +1,9 @@ #!/bin/bash +# +# xterm-256color seems to be the qubes default +# for gnome-term and Xterm +# +export TERM="xterm-256color" set -e