You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
[Feature] 添加 类似 GM_xmlhttpRequest 的 WebSocket 绕过 Mixed Content / CORS / Origin API #1640
Activity
cyfung1031 commentedon Jul 29, 2026
有沒有實際示例? 在哪裡你用不了 new WebSocket
dawn-lc commentedon Jul 30, 2026
局域网内一台nas跑aria2,IP地址是
10.0.0.2,浏览器所在的设备ip地址为10.0.0.101,此时访问一个https的网站时脚本尝试连接ws://10.0.0.2:22222会触发混合内容(Mixed Content)安全策略导致连接被阻止
而
GM_xmlhttpRequest则可以正常访问http://10.0.0.2:22222cyfung1031 commentedon Aug 3, 2026
不太清楚。让 @CodFrm 决定
个人建议是,有需要增加API的话,先去 Tampermonkey 讲一下。主流不支持的话,只有ScriptCat加一堆API也没用
你不能强迫你的UserScript使用者全部人都用 ScriptCat
(因此本人一直反对 CAT_* 做法)
CodFrm commentedon Aug 11, 2026
🤔,短期内应该没这个打算,如果是你自有的ws服务,可以配置好cors来解决这个问题吧,后续也可以增加csp管理来移除页面限制
dawn-lc commentedon Aug 11, 2026
主要是混合内容(Mixed Content),局域网配自签名证书再加浏览器信任这个操作对于一般用户太麻烦