註冊並分享邀請連結,可獲得影片播放與邀請獎勵。

Mitchell Hashimoto
@mitchellh
Co-founder of @Superlogical. Creator of Ghostty. 👻 Prev founded @HashiCorp, created Vagrant, Terraform, Vault, and others.
加入 January 2008
150 正在關注    221.3K 粉絲
OSC8 is the terminal sequence for linking arbitrary text (similar to `a` tags in HTML). It is mandatory for a modern terminal experience but prone to malicious use. The next version of Ghostty contains the strongest protections for malicious OSC8 short of disabling it entirely. In the next version of Ghostty, we've added a classifier for OSC8 URLs (any hidden URL, really) that classifies a URL as: trusted, requires-confirmation, or deny. The screenshots below show the separate requires-confirmation and deny alerts. We also now show hidden characters in the URL preview in the bottom of the window (previously we interpreted the Unicode directly which allowed maliciously crafted URLs to hide themselves). Hidden characters immediately trigger the `deny` classification, too. These are the strongest, most comprehensive protections for OSC8 across terminals. As a comparison: * Alacritty, Kitty, iTerm2, WezTerm: enabled by default with zero filtering at all. Can directly open executables or maliciously crafted schemes without any filter. Can hide the real URL through Unicode tricks. * Gnome Terminal: enables all OSC8, no configuration I could find to disable. Only rejects remote-host `file://` URLs. No other sanitization, confirmation, etc. * VS Code Terminal: Allowlist of safe protocols, prompts for unknown, silently replaces whitespace characters. Very good! * Windows Terminal: Allowlist, prompts for anything executable, prompts for any custom schemes. Very good!
顯示更多
0
20
499
10
轉發到社區