summary refs log tree commit diff stats
path: root/gitlab/issues/target_missing/host_missing/accel_missing/2293.toml
blob: a5b1126078e498302d3bf623b59f63ba795cb07f (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
id = 2293
title = "[u2f-passthru]: pamu2fcfg command will stuck forever in Guest OS of Qemu"
state = "opened"
created_at = "2024-04-19T13:33:00.367Z"
closed_at = "n/a"
labels = ["USB"]
url = "https://gitlab.com/qemu-project/qemu/-/issues/2293"
host-os = "Ubuntu"
host-arch = "x86_64"
qemu-version = "QEMU emulator version 6.2.0"
guest-os = "Ubuntu"
guest-arch = "x86_64"
description = """To use FIDO2 user verification we need to run `pamu2fcfg` command which will stuck forever in Guest OS of Qemu 

Passing `-usb -device u2f-passthru,hidraw=/dev/hidraw2` for U2F-Passthrough"""
reproduce = """1. Make you have have plugged Yubikey.
2. In Guest shell install package using following command `sudo apt-get install pamu2fcfg`
3. Run $`pamu2fcfg` command will stuck forever.

**Note:** If I run `pamu2fcfg` in my Ubuntu Host environment it works fine."""
additional = """**lsusb output:**

**$lusb**

Bus 001 Device 002: ID 46f4:0005 **QEMU U2F USB key**

Bus 001 Device 001: ID 1d6b:0001 Linux Foundation 1.1 root hub

**Debug Details:**

When pamu2fcfg was launched following will be the call flow.

[u2f_key_recv_from_guest](https://github.com/qemu/qemu/blob/master/hw/usb/u2f.c#L251 "https://github.com/qemu/qemu/blob/master/hw/usb/u2f.c#L251") → [recv_from_guest](https://github.com/qemu/qemu/blob/master/hw/usb/u2f.c#L204 "https://github.com/qemu/qemu/blob/master/hw/usb/u2f.c#L204") → [u2f_passthru_recv_from_guest](https://github.com/qemu/qemu/blob/master/hw/usb/u2f-passthru.c#L332 "https://github.com/qemu/qemu/blob/master/hw/usb/u2f-passthru.c#L332") → [u2f_passthru_read](https://github.com/qemu/qemu/blob/master/hw/usb/u2f-passthru.c#L305 "https://github.com/qemu/qemu/blob/master/hw/usb/u2f-passthru.c#L305") → [u2f_passthru_recv_from_host](https://github.com/qemu/qemu/blob/master/hw/usb/u2f-passthru.c#L329 "https://github.com/qemu/qemu/blob/master/hw/usb/u2f-passthru.c#L329") →[ u2f_transaction_get_from_nonce](https://github.com/qemu/qemu/blob/master/hw/usb/u2f-passthru.c#L272 "https://github.com/qemu/qemu/blob/master/hw/usb/u2f-passthru.c#L272") → [u2f_send_to_guest](https://github.com/qemu/qemu/blob/master/hw/usb/u2f-passthru.c#L302 "https://github.com/qemu/qemu/blob/master/hw/usb/u2f-passthru.c#L302") →[ u2f_pending_in_add](https://github.com/qemu/qemu/blob/master/hw/usb/u2f.c#L207 "https://github.com/qemu/qemu/blob/master/hw/usb/u2f.c#L207") → [main_loop_wait](https://github.com/qemu/qemu/blob/master/system/runstate.c#L783 "https://github.com/qemu/qemu/blob/master/system/runstate.c#L783") (stuck here)

From above call flow looks like guest is waiting for key.

Even I have tried enabling U2F support flag in Qemu while building but that one was not helping either.

**References:**

https://github.com/Yubico/pam-u2f/tree/main

https://www.qemu.org/docs/master/system/devices/usb-u2f.html"""