Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Unable to use Yubikey without additional pcsc rules #180

Open
jmgilman opened this issue Dec 31, 2023 · 1 comment · May be fixed by #231
Open

Unable to use Yubikey without additional pcsc rules #180

jmgilman opened this issue Dec 31, 2023 · 1 comment · May be fixed by #231

Comments

@jmgilman
Copy link

I was unable to get my Yubikey to work with GPG on the latest bluefin-dx image:

$ gpg --card-status
gpg: OpenPGP card not available: No such device

It was necessary to add some additional rules in /etc/polkit-1/rules.d/99-pcscd.rules:

polkit.addRule(function(action, subject) {
        if (action.id == "org.debian.pcsc-lite.access_card" &&
                subject.isInGroup("wheel")) {
                return polkit.Result.YES;
        }
});
polkit.addRule(function(action, subject) {
        if (action.id == "org.debian.pcsc-lite.access_pcsc" &&
                subject.isInGroup("wheel")) {
                return polkit.Result.YES;
        }
});

With these rules, I was able to access the Yubikey. I'm unsure if this is worth baking into the main image.

@jmgilman
Copy link
Author

jmgilman commented Jan 1, 2024

One other issue: even after adding the above rules, they seem to not take effect after a reboot. I get the same error trying to access the Yubikey. However, manually restarting the pcsc daemon fixes the issue:

sudo systemctl restart pcscd

Is there something going on that would prevent the rules from applying after a reboot?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant