Script 'mail_helper' called by obssrc Hello community, here is the log from the commit of package canokey-qemu for openSUSE:Factory checked in at 2026-11-25 16:11:23 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Comparing /work/SRC/openSUSE:Factory/canokey-qemu (Old) and /work/SRC/openSUSE:Factory/.canokey-qemu.new.1340718 (New) ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Package is "canokey-qemu" Wed Nov 25 16:11:23 2026 rev:5 rq:1400059 version:0.0+git20260324.41044ec Changes: -------- --- /work/SRC/openSUSE:Factory/canokey-qemu/canokey-qemu.changes 2026-03-06 18:18:12.803212229 +0100 +++ /work/SRC/openSUSE:Factory/.canokey-qemu.new.1340718/canokey-qemu.changes 2026-11-25 16:11:28.682593470 +0100 @@ -1,0 +2,29 @@ +Wed Nov 18 08:47:43 UTC 2026 - Alberto Planas Dominguez <[email protected]> + +- Update to version 0.0+git20260324.41044ec: + * Add warning on compatibility + * CMake: enable dumb dongle option for core + * Add dummy Init_Done callback for new canokey-core + * doc: add CI badge in README + * chore: fix review comments by Copilot + * ci: add GitHub Actions build workflow + * fix: update device_loop() call to match current canokey-core API + * docs: remove outdated Mac mbedtls patching instructions + * build: modernize CMakeLists.txt and update library paths + * deps: update canokey-core to latest snapshot +- Drop mbedtls-fix-building-with-GCC-16.patch, mbedtls was replaced + by TF-PSA-Crypto +- Refresh canokey-git.diff and canokey-core-static.diff +- Add BuildRequires python3, python3-Jinja2 and python3-jsonschema, + needed to generate the CTAP GetInfo data and TF-PSA-Crypto code +- Add canokey-core-fm-return-type.patch, return an error from the + NFC chip functions when no chip is selected (-Werror=return-type) +- Library soname is now libcanokey-qemu.so.1. FIDO2 credentials + registered with the old version (resident and non-resident, e.g. + systemd-cryptenroll slots) do not work with the new one and must + be enrolled again +- Add the canokey-qemu-libvirt subpackage: a state directory + /var/lib/libvirt/qemu/canokey, an AppArmor rule for it, + and README.SUSE describing how to attach the key to a libvirt guest + +------------------------------------------------------------------- Old: ---- canokey-qemu-0.0+git20230606.151568c.obscpio mbedtls-fix-building-with-GCC-16.patch New: ---- README.SUSE canokey-core-fm-return-type.patch canokey-qemu-0.0+git20260324.41044ec.obscpio canokey-qemu.apparmor canokey-qemu.tmpfiles ----------(Old B)---------- Old: * deps: update canokey-core to latest snapshot - Drop mbedtls-fix-building-with-GCC-16.patch, mbedtls was replaced by TF-PSA-Crypto ----------(Old E)---------- ----------(New B)---------- New: needed to generate the CTAP GetInfo data and TF-PSA-Crypto code - Add canokey-core-fm-return-type.patch, return an error from the NFC chip functions when no chip is selected (-Werror=return-type) ----------(New E)---------- ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Other differences: ------------------ ++++++ canokey-qemu.spec ++++++ --- /var/tmp/diff_new_pack.QFxoOI/_old 2026-11-25 16:11:31.080695692 +0100 +++ /var/tmp/diff_new_pack.QFxoOI/_new 2026-11-25 16:11:31.081695735 +0100 @@ -17,17 +17,25 @@ Name: canokey-qemu -Version: 0.0+git20230606.151568c +Version: 0.0+git20260324.41044ec Release: 0 Summary: Library for CanoKey support in QEMU License: Apache-2.0 URL: https://github.com/canokeys/canokey-qemu Source: %{name}-%{version}.tar +Source1: README.SUSE +Source2: canokey-qemu.apparmor +Source3: canokey-qemu.tmpfiles Patch0: canokey-git.diff Patch1: canokey-core-static.diff -Patch2: mbedtls-fix-building-with-GCC-16.patch +# PATCH-FIX-UPSTREAM part of canokey-core c50b625d and e4a756d6 +Patch2: canokey-core-fm-return-type.patch BuildRequires: cmake BuildRequires: glibc-devel-static +BuildRequires: python3 +BuildRequires: python3-Jinja2 +BuildRequires: python3-jsonschema +BuildRequires: systemd-rpm-macros %description CanoKey is an open-source secure key with supports of U2F / FIDO2 with Ed25519 @@ -45,6 +53,18 @@ and HMAC-secret, OpenPGP Card V3.4 with RSA4096, Ed25519 and more 2, PIV (NIST SP 800-73-4), HOTP / TOTP, NDEF. +%package libvirt +Summary: Use a virtual CanoKey in libvirt-managed QEMU guests +Requires: %{name} = %{version} +Supplements: (%{name} and libvirt-daemon-driver-qemu) +Requires: system-user-qemu +BuildArch: noarch + +%description libvirt +State directory, and an AppArmor rule for it, that let QEMU guests started by +libvirt (virt-manager) use a virtual CanoKey, attached with libvirt's QEMU +command-line passthrough. See README.SUSE for the domain XML. + %prep %autosetup -p1 cp canokey-core/virt-card/git-rev.h.in canokey-core/virt-card/git-rev.h @@ -61,10 +81,16 @@ %install %cmake_install +install -D -m 0644 %{SOURCE2} %{buildroot}%{_sysconfdir}/apparmor.d/abstractions/libvirt-qemu.d/canokey-qemu +install -D -m 0644 %{SOURCE3} %{buildroot}%{_tmpfilesdir}/canokey-qemu.conf +cp %{SOURCE1} . %post -p /sbin/ldconfig %postun -p /sbin/ldconfig +%post libvirt +%tmpfiles_create %{_tmpfilesdir}/canokey-qemu.conf + %files devel %{_libdir}/libcanokey-qemu.so %{_includedir}/canokey-qemu.h @@ -73,5 +99,13 @@ %files %license LICENSE %doc README.md -%{_libdir}/libcanokey-qemu.so.0 +%{_libdir}/libcanokey-qemu.so.1 + +%files libvirt +%doc README.SUSE +%dir %{_sysconfdir}/apparmor.d +%dir %{_sysconfdir}/apparmor.d/abstractions +%dir %{_sysconfdir}/apparmor.d/abstractions/libvirt-qemu.d +%config(noreplace) %{_sysconfdir}/apparmor.d/abstractions/libvirt-qemu.d/canokey-qemu +%{_tmpfilesdir}/canokey-qemu.conf ++++++ README.SUSE ++++++ Using a virtual CanoKey with libvirt / virt-manager =================================================== libvirt has no native CanoKey device, so it is attached with libvirt's QEMU command-line passthrough. This package provides the directory /var/lib/libvirt/qemu/canokey/ for the state files. Confined QEMU processes can use it: the SELinux policy already allows it, and this package adds the AppArmor rule. Edit the domain (virsh edit <vm>, or the XML tab in virt-manager): 1. Add the QEMU namespace to the <domain> element: <domain type='kvm' xmlns:qemu='http://libvirt.org/schemas/domain/qemu/1.0'> 2. Add, just before </domain>: <qemu:commandline> <qemu:arg value='-device'/> <qemu:arg value='{"driver":"canokey","id":"canokey0","file":"/var/lib/libvirt/qemu/canokey/VMNAME.canokey","bus":"usb.0"}'/> </qemu:commandline> Replace VMNAME. The file name must end in .canokey. The file is created on the first start of the guest and keeps the key state (FIDO2 credentials, PINs, OpenPGP and PIV keys). Delete it to get a factory-new key. Notes: - Use the JSON syntax shown above. libvirt creates its own devices with JSON -device options, which QEMU processes after plain "-device canokey,..." options, so the plain form fails with "Bus 'usb.0' not found". - The guest needs a USB controller with the alias "usb" (the default qemu-xhci controller created by virt-manager has it). - The virtual key reports user presence without a touch, so it cannot be used to test touch prompts. - This is a testing tool: the key material is stored unencrypted in the state file, and all guests running as the qemu user can access every state file in the directory. - State files created by canokey-qemu builds before 2026 (libcanokey-qemu.so.0) can be opened, but credentials registered with those builds no longer work: neither FIDO2 resident credentials nor the non-resident credentials used by e.g. systemd-cryptenroll are recognized. Re-enroll them, or start with a new state file. ++++++ _servicedata ++++++ --- /var/tmp/diff_new_pack.QFxoOI/_old 2026-11-25 16:11:31.156698932 +0100 +++ /var/tmp/diff_new_pack.QFxoOI/_new 2026-11-25 16:11:31.161699145 +0100 @@ -1,6 +1,6 @@ <servicedata> <service name="tar_scm"> <param name="url">https://github.com/canokeys/canokey-qemu</param> - <param name="changesrevision">151568c34f5e92b086b7a3a62a11c43dd39f628b</param></service></servicedata> + <param name="changesrevision">41044ec17ddb835b3e5acb385a2e429aa74af627</param></service></servicedata> (No newline at EOF) ++++++ canokey-core-fm-return-type.patch ++++++ --- a/canokey-core/interfaces/NFC/fm.c +++ b/canokey-core/interfaces/NFC/fm.c @@ -23,6 +23,11 @@ return FM_STATUS_OK; #elif NFC_CHIP == NFC_CHIP_FM11NT return fm11nt_read(reg, buf, len); +#else + (void)reg; + (void)buf; + (void)len; + return FM_STATUS_NACK; #endif } @@ -36,6 +41,11 @@ return FM_STATUS_OK; #elif NFC_CHIP == NFC_CHIP_FM11NT return fm11nt_write(reg, buf, len); +#else + (void)reg; + (void)buf; + (void)len; + return FM_STATUS_NACK; #endif } @@ -50,6 +60,11 @@ return FM_STATUS_OK; #elif NFC_CHIP == NFC_CHIP_FM11NT return fm11nt_read(addr, buf, len); +#else + (void)addr; + (void)buf; + (void)len; + return FM_STATUS_NACK; #endif } @@ -74,6 +89,11 @@ const bool ret = fm11nt_write(addr, buf, len); device_delay(10); return ret; +#else + (void)addr; + (void)buf; + (void)len; + return FM_STATUS_NACK; #endif } @@ -87,6 +107,10 @@ return FM_STATUS_OK; #elif NFC_CHIP == NFC_CHIP_FM11NT return fm11nt_read(FM_REG_FIFO_ACCESS, buf, len); +#else + (void)buf; + (void)len; + return FM_STATUS_NACK; #endif } @@ -100,6 +124,10 @@ return FM_STATUS_OK; #elif NFC_CHIP == NFC_CHIP_FM11NT return fm11nt_write(FM_REG_FIFO_ACCESS, buf, len); +#else + (void)buf; + (void)len; + return FM_STATUS_NACK; #endif } ++++++ canokey-core-static.diff ++++++ --- /var/tmp/diff_new_pack.QFxoOI/_old 2026-11-25 16:11:31.181699998 +0100 +++ /var/tmp/diff_new_pack.QFxoOI/_new 2026-11-25 16:11:31.184700125 +0100 @@ -1,14 +1,12 @@ -diff --git a/CMakeLists.txt b/CMakeLists.txt -index f5be451..b6aa294 100644 --- a/canokey-core/CMakeLists.txt +++ b/canokey-core/CMakeLists.txt -@@ -31,7 +31,7 @@ endif () - file(GLOB_RECURSE SRC src/*.c applets/*.c interfaces/*.c - littlefs/lfs.c littlefs/lfs_util.c - tinycbor/src/cborencoder.c tinycbor/src/cborparser.c) +@@ -83,7 +83,7 @@ + tinycbor/src/cborencoder.c + tinycbor/src/cborparser.c + ) -add_library(canokey-core ${SRC}) +add_library(canokey-core STATIC ${SRC}) + add_dependencies(canokey-core generate_ctap_get_info_cbor) - if (ENABLE_TESTS) - target_compile_definitions(canokey-core PUBLIC TEST) + if(ENABLE_TESTS) ++++++ canokey-git.diff ++++++ --- /var/tmp/diff_new_pack.QFxoOI/_old 2026-11-25 16:11:31.195700594 +0100 +++ /var/tmp/diff_new_pack.QFxoOI/_new 2026-11-25 16:11:31.198700722 +0100 @@ -1,16 +1,18 @@ -Index: canokey-qemu/canokey-core/CMakeLists.txt -=================================================================== ---- canokey-qemu.orig/canokey-core/CMakeLists.txt -+++ canokey-qemu/canokey-core/CMakeLists.txt -@@ -63,9 +63,7 @@ if (VIRTCARD OR ENABLE_TESTS OR ENABLE_F - set(gitrev_in virt-card/git-rev.h.in) +--- a/canokey-core/CMakeLists.txt ++++ b/canokey-core/CMakeLists.txt +@@ -123,13 +123,7 @@ set(gitrev virt-card/git-rev.h) - add_custom_target(gitrev -- ${CMAKE_COMMAND} -E remove -f ${CMAKE_CURRENT_SOURCE_DIR}/${gitrev} -- COMMAND ${CMAKE_COMMAND} -E copy ${CMAKE_CURRENT_SOURCE_DIR}/${gitrev_in} ${CMAKE_CURRENT_SOURCE_DIR}/${gitrev} -- COMMAND git describe --always --tags --long --abbrev=8 --dirty >> ${CMAKE_CURRENT_SOURCE_DIR}/${gitrev} -+ COMMAND true - ) - endif () + add_custom_target( + gitrev +- ${CMAKE_COMMAND} -E remove -f ${CMAKE_CURRENT_SOURCE_DIR}/${gitrev} +- COMMAND +- ${CMAKE_COMMAND} -E copy ${CMAKE_CURRENT_SOURCE_DIR}/${gitrev_in} +- ${CMAKE_CURRENT_SOURCE_DIR}/${gitrev} +- COMMAND +- git describe --always --tags --long --abbrev=8 --dirty >> +- ${CMAKE_CURRENT_SOURCE_DIR}/${gitrev} ++ COMMAND true + ) + endif() ++++++ canokey-qemu-0.0+git20230606.151568c.obscpio -> canokey-qemu-0.0+git20260324.41044ec.obscpio ++++++ ++++ 817780 lines of diff (skipped) ++++++ canokey-qemu.apparmor ++++++ # CanoKey QEMU state files, see /usr/share/doc/packages/canokey-qemu-libvirt/README.SUSE owner /var/lib/libvirt/qemu/canokey/*.canokey rwk, ++++++ canokey-qemu.obsinfo ++++++ --- /var/tmp/diff_new_pack.QFxoOI/_old 2026-11-25 16:11:32.490755797 +0100 +++ /var/tmp/diff_new_pack.QFxoOI/_new 2026-11-25 16:11:32.495756011 +0100 @@ -1,5 +1,5 @@ name: canokey-qemu -version: 0.0+git20230606.151568c -mtime: 1685984943 -commit: 151568c34f5e92b086b7a3a62a11c43dd39f628b +version: 0.0+git20260324.41044ec +mtime: 1774314651 +commit: 41044ec17ddb835b3e5acb385a2e429aa74af627 ++++++ canokey-qemu.tmpfiles ++++++ # State files of virtual CanoKeys used by libvirt-managed QEMU guests d /var/lib/libvirt/qemu/canokey 0750 qemu qemu -
