惯性聚合 高效追踪和阅读你感兴趣的博客、新闻、科技资讯
阅读原文 在惯性聚合中打开

推荐订阅源

云风的 BLOG
云风的 BLOG
freeCodeCamp Programming Tutorials: Python, JavaScript, Git & More
博客园 - 叶小钗
OSCHINA 社区最新新闻
OSCHINA 社区最新新闻
V
V2EX
酷 壳 – CoolShell
酷 壳 – CoolShell
月光博客
月光博客
人人都是产品经理
人人都是产品经理
宝玉的分享
宝玉的分享
博客园 - 司徒正美
WordPress大学
WordPress大学
Microsoft Azure Blog
Microsoft Azure Blog
罗磊的独立博客
Vercel News
Vercel News
T
The Blog of Author Tim Ferriss
T
Tailwind CSS Blog
A
About on SuperTechFans
Apple Machine Learning Research
Apple Machine Learning Research
L
LangChain Blog
让小产品的独立变现更简单 - ezindie.com
让小产品的独立变现更简单 - ezindie.com
V
Visual Studio Blog
S
SegmentFault 最新的问题
Google DeepMind News
Google DeepMind News
博客园 - 聂微东

刘荣星的博客

CentOS7 python2 安装 elasticsearch 模块 Gentoo Gnome 登陆界面开启触摸板轻击 python3去除emoji表情符号 记录几个内网广播包
在VMWare Workstation虚拟机里使用 yubikey
JavasBoy · 2022-10-31 · via 刘荣星的博客

我在VMWare中安装的linux mint,刚开始简单的以为使用yubikey像使用U盘一样的方式,把Yubikey插到电脑上,然后再VMWare里直接选择连接到客户机,dmessge 里有日志显示,但 gpg --card-status 找不到。

根据Yubikey的帮助文档显示,你需要把不是 Shared Yubikey 连接到客户机里,即需要选择如下图的 Yubico.com YubiKey OTP+FIDO+CCID 连接到虚拟机里。

YubiKey Link to VMWare

设置方法:

  1. 在这里 https://support.yubico.com/hc/en-us/articles/360016614920-YubiKey-USB-ID-Values 查询好你对应型号的 Yubikey ID Values,记下来
  2. 关闭客户机
  3. 编辑对应客户机的 .vmx 文件,在里面添加这几行:
usb.generic.allowHID = "TRUE"
usb.generic.allowLastHID = "TRUE"
usb.generic.allowCCID = "TRUE"
usb.quirks.device0 = "0x1050:0x0407 allow"

其中 usb.quirks.device0 的值要对应你的 Yubikey 的型号,上面这个是 Yubikey 4 和 5 的。

最后把虚拟机开机,选择连接即可,然后配置 gpg

# gpg --card-status
gpg: selecting card failed: Service is not running
gpg: OpenPGP card not available: Service is not running

# pkill gpg-agent

# gpg --card-status
Reader ...........: Yubico YubiKey OTP FIDO CCID
...