跳到主要内容

Claude Cage · 面向 Claude 的隔离开发环境,支持桌面工作台、多账号、远程部署与移动端连接。上游 Lee-xeo/Claude-Cage 完整源码镜像,非灵栈原创;主许可 MIT,第三方组件遵循各自许可。来源:https://github.com/Lee-xeo/Claude-Cage 。手动同步,不附带 Release 安装包。

浏览文件

macos_login.go

35 行 · 1.5 KB历史下载
1package guestos
2
3// MacLoginRequest is the local one-instance login control protocol. No guest or
4// host file paths, clipboard contents, or global shortcuts are accepted. Only
5// the authenticated host may attach a stored password to fill-password.
6type MacLoginRequest struct {
7 Action string `json:"action"`
8 Session string `json:"session,omitempty"`
9 Setup bool `json:"initial_setup,omitempty"`
10 Maintenance string `json:"maintenance,omitempty"`
11 Geometry string `json:"geometry,omitempty"`
12 Code int `json:"code"`
13 Shift bool `json:"shift"`
14 X int `json:"x"`
15 Y int `json:"y"`
16 DeltaX int `json:"delta_x,omitempty"`
17 DeltaY int `json:"delta_y,omitempty"`
18 Password string `json:"password,omitempty"`
19}
20type MacLoginReply struct {
21 MIME string `json:"mime,omitempty"`
22 Session string `json:"session,omitempty"`
23 Image []byte `json:"image,omitempty"`
24 Error string `json:"error,omitempty"`
25 Closed bool `json:"closed,omitempty"`
26 Geometry string `json:"geometry,omitempty"`
27 Region []int `json:"region,omitempty"`
28 Recovery string `json:"recovery,omitempty"`
29 Administrator string `json:"administrator,omitempty"`
30 MaintenanceVersion int `json:"maintenance_version,omitempty"`
31}
32
33func ValidMacMaintenancePurpose(value string) bool {
34 return value == "projects" || value == "screen" || value == "input"
35}