{"id":31714672,"url":"https://github.com/metowolf/wsdog","last_synced_at":"2025-10-09T01:44:11.168Z","repository":{"id":57400025,"uuid":"173763748","full_name":"metowolf/wsdog","owner":"metowolf","description":"An encrypted proxy service program through websocket","archived":false,"fork":false,"pushed_at":"2025-10-04T17:17:23.000Z","size":59,"stargazers_count":16,"open_issues_count":0,"forks_count":4,"subscribers_count":1,"default_branch":"master","last_synced_at":"2025-10-04T17:36:37.103Z","etag":null,"topics":["node","proxy","websocket"],"latest_commit_sha":null,"homepage":null,"language":"JavaScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"gpl-3.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/metowolf.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2019-03-04T14:48:27.000Z","updated_at":"2025-10-04T17:17:26.000Z","dependencies_parsed_at":"2022-08-25T22:51:23.277Z","dependency_job_id":null,"html_url":"https://github.com/metowolf/wsdog","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/metowolf/wsdog","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/metowolf%2Fwsdog","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/metowolf%2Fwsdog/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/metowolf%2Fwsdog/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/metowolf%2Fwsdog/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/metowolf","download_url":"https://codeload.github.com/metowolf/wsdog/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/metowolf%2Fwsdog/sbom","scorecard":{"id":638320,"data":{"date":"2025-08-11","repo":{"name":"github.com/metowolf/wsdog","commit":"182b52c094c99c31c922e0e262d3326a4764763d"},"scorecard":{"version":"v5.2.1-40-gf6ed084d","commit":"f6ed084d17c9236477efd66e5b258b9d4cc7b389"},"score":2.3,"checks":[{"name":"Code-Review","score":0,"reason":"Found 0/4 approved changesets -- score normalized to 0","details":null,"documentation":{"short":"Determines if the project requires human code review before pull requests (aka merge requests) are merged.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#code-review"}},{"name":"Maintained","score":0,"reason":"project is archived","details":["Warn: Repository is archived."],"documentation":{"short":"Determines if the project is \"actively maintained\".","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#maintained"}},{"name":"Dangerous-Workflow","score":-1,"reason":"no workflows found","details":null,"documentation":{"short":"Determines if the project's GitHub Action workflows avoid dangerous patterns.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#dangerous-workflow"}},{"name":"Packaging","score":-1,"reason":"packaging workflow not detected","details":["Warn: no GitHub/GitLab publishing workflow detected."],"documentation":{"short":"Determines if the project is published as a package that others can easily download, install, easily update, and uninstall.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#packaging"}},{"name":"SAST","score":0,"reason":"no SAST tool detected","details":["Warn: no pull requests merged into dev branch"],"documentation":{"short":"Determines if the project uses static code analysis.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#sast"}},{"name":"Token-Permissions","score":-1,"reason":"No tokens found","details":null,"documentation":{"short":"Determines if the project's workflows follow the principle of least privilege.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#token-permissions"}},{"name":"Binary-Artifacts","score":10,"reason":"no binaries found in the repo","details":null,"documentation":{"short":"Determines if the project has generated executable (binary) artifacts in the source repository.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#binary-artifacts"}},{"name":"CII-Best-Practices","score":0,"reason":"no effort to earn an OpenSSF best practices badge detected","details":null,"documentation":{"short":"Determines if the project has an OpenSSF (formerly CII) Best Practices Badge.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#cii-best-practices"}},{"name":"Security-Policy","score":0,"reason":"security policy file not detected","details":["Warn: no security policy file detected","Warn: no security file to analyze","Warn: no security file to analyze","Warn: no security file to analyze"],"documentation":{"short":"Determines if the project has published a security policy.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#security-policy"}},{"name":"License","score":10,"reason":"license file detected","details":["Info: project has a license file: LICENSE:0","Info: FSF or OSI recognized license: GNU General Public License v3.0: LICENSE:0"],"documentation":{"short":"Determines if the project has defined a license.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#license"}},{"name":"Fuzzing","score":0,"reason":"project is not fuzzed","details":["Warn: no fuzzer integrations found"],"documentation":{"short":"Determines if the project uses fuzzing.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#fuzzing"}},{"name":"Pinned-Dependencies","score":0,"reason":"dependency not pinned by hash detected -- score normalized to 0","details":["Warn: containerImage not pinned by hash: Dockerfile:1: pin your Docker image by updating node:alpine to node:alpine@sha256:dec6d30010dc33ae4bb341a47b49c7add553b0a1213d9bac6b7fea1e3b5e35a4","Info:   0 out of   1 containerImage dependencies pinned"],"documentation":{"short":"Determines if the project has declared and pinned the dependencies of its build process.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#pinned-dependencies"}},{"name":"Signed-Releases","score":-1,"reason":"no releases found","details":null,"documentation":{"short":"Determines if the project cryptographically signs release artifacts.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#signed-releases"}},{"name":"Branch-Protection","score":0,"reason":"branch protection not enabled on development/release branches","details":["Warn: branch protection not enabled for branch 'master'"],"documentation":{"short":"Determines if the default and release branches are protected with GitHub's branch protection settings.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#branch-protection"}},{"name":"Vulnerabilities","score":6,"reason":"4 existing vulnerabilities detected","details":["Warn: Project is vulnerable to: GHSA-78xj-cgh5-2h22","Warn: Project is vulnerable to: GHSA-2p57-rm9w-gvfp","Warn: Project is vulnerable to: GHSA-6fc8-4gx4-v693","Warn: Project is vulnerable to: GHSA-3h5v-q93c-6h6q"],"documentation":{"short":"Determines if the project has open, known unfixed vulnerabilities.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#vulnerabilities"}}]},"last_synced_at":"2025-08-21T09:55:45.638Z","repository_id":57400025,"created_at":"2025-08-21T09:55:45.638Z","updated_at":"2025-08-21T09:55:45.638Z"},"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":279000711,"owners_count":26082895,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","status":"online","status_checked_at":"2025-10-08T02:00:06.501Z","response_time":56,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["node","proxy","websocket"],"created_at":"2025-10-09T01:44:10.183Z","updated_at":"2025-10-09T01:44:11.159Z","avatar_url":"https://github.com/metowolf.png","language":"JavaScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"\u003cp align=\"center\"\u003e\n\u003ca href=\"https://github.com/metowolf/wsdog\"\u003e\n\u003cimg src=\"https://user-images.githubusercontent.com/2666735/53743687-5d416100-3ed6-11e9-9fe8-5a8581c48157.png\"\u003e\n\u003c/a\u003e\n\u003c/p\u003e\n\n\u003cp align=\"center\"\u003eAn encrypted proxy service program through websocket.\u003c/p\u003e\n\n\u003cp align=center\u003e\n\u003ca href=\"https://github.com/metowolf/wsdog/\"\u003eProject Source\u003c/a\u003e ·\n\u003ca href=\"https://t.me/wsdog\"\u003eTelegram Channel\u003c/a\u003e\n\u003c/p\u003e\n\n---\n\n## wsdog v2.0 - Hono + Cloudflare Workers\n\n基于 Hono 框架重构的 wsdog,支持部署到 Cloudflare Workers。\n\n### 主要特性\n\n- ✅ 使用 **ESM** 标准重构全部代码\n- ✅ 服务端基于 **Hono** 框架,支持部署到 **Cloudflare Workers**\n- ✅ 使用 **Web Crypto API** 实现加密 (兼容 Workers 环境)\n- ✅ 简化配置,使用 **wrangler.toml** 管理服务端配置\n- ✅ 保持完整的加密和 SOCKS5 代理功能\n- ✅ 使用 **pnpm** 作为包管理器\n\n## 快速开始\n\n### 1. 安装依赖\n\n```bash\npnpm install\n```\n\n### 2. 本地开发\n\n启动服务端 (使用 Wrangler 本地开发服务器):\n```bash\npnpm run dev\n```\n\n在另一个终端启动客户端:\n```bash\n# 创建 .env 文件\ncp .env.example .env\n\n# 编辑 .env,设置 URL 和密钥\n# URL=\"ws://127.0.0.1:8787/ws\"\n# KEY=\"your-secret-key\"\n\npnpm run client\n```\n\n### 3. 测试连接\n\n```bash\ncurl -Lx socks5h://127.0.0.1:1080 www.google.com\n```\n\n### 4. 部署到 Cloudflare Workers\n\n编辑 `wrangler.toml`,设置生产环境配置:\n```toml\n[env.production]\nname = \"wsdog-production\"\nvars = { KEY = \"your-production-key\", METHOD = \"aes-256-gcm\" }\n```\n\n部署:\n```bash\npnpm run deploy\n```\n\n部署后更新客户端 `.env`:\n```env\nURL=\"wss://wsdog-production.your-account.workers.dev/ws\"\nKEY=\"your-production-key\"\nMETHOD=\"aes-256-gcm\"\n```\n\n## 配置说明\n\n### 服务端配置 (wrangler.toml)\n\n```toml\n[vars]\nKEY = \"wsdog\"              # 加密密钥\nMETHOD = \"aes-256-gcm\"     # 加密算法\n```\n\n### 客户端配置 (.env)\n\n```env\nURL=\"ws://127.0.0.1:8787/ws\"  # WebSocket 服务器地址\nKEY=\"wsdog\"                    # 加密密钥 (需与服务端一致)\nMETHOD=\"aes-256-gcm\"           # 加密算法 (需与服务端一致)\nTIMEOUT=600                    # 超时时间 (秒)\nLOCAL_HOST=127.0.0.1          # 本地监听地址\nLOCAL_PORT=1080               # SOCKS5 端口\n```\n\n### 支持的加密算法\n\n- `aes-128-gcm`\n- `aes-192-gcm`\n- `aes-256-gcm`\n- `none` (仅用于测试,不推荐生产环境)\n\n## 架构说明\n\n### 组件\n\n- **服务端 (src/worker.js)**: 基于 Hono 的 WebSocket 服务器,部署在 Cloudflare Workers\n- **客户端 (src/client.js)**: SOCKS5 代理服务器,运行在本地 Node.js 环境\n\n### 项目结构\n\n```\nwsdog/\n├── src/\n│   ├── worker.js              # Cloudflare Workers 入口 (Hono 应用)\n│   ├── client.js              # SOCKS5 客户端\n│   └── utils/\n│       ├── crypto.js          # Web Crypto API 加密 (服务端)\n│       ├── crypto-node.js     # Node.js 加密 (客户端)\n│       └── config.js          # 客户端配置管理\n├── wrangler.toml              # Cloudflare Workers 配置\n├── package.json               # 项目依赖和脚本\n└── .env.example               # 客户端配置示例\n```\n\n## 优势\n\n### Cloudflare Workers 部署\n\n- ✅ **全球边缘网络**: 自动部署到全球数据中心\n- ✅ **高可用**: 无需管理服务器\n- ✅ **快速**: 边缘计算,低延迟\n- ✅ **免费额度**: 每天 100,000 次请求\n\n### 技术栈\n\n- ✅ **Hono**: 轻量级、高性能 Web 框架\n- ✅ **ESM**: 现代 JavaScript 模块标准\n- ✅ **Web Crypto API**: 标准化加密接口\n- ✅ **pnpm**: 快速、节省磁盘空间的包管理器\n\n## 常见问题\n\n### Q: 如何调试?\n\nA: 使用 `pnpm run dev` 启动本地开发模式,支持热重载和日志输出。\n\n### Q: 为什么客户端还是 Node.js?\n\nA: SOCKS5 代理需要监听本地端口,这个功能 Cloudflare Workers 不支持,必须在本地运行。\n\n### Q: v1.0 和 v2.0 能否互通?\n\nA: 不能。v2.0 使用 PBKDF2 密钥派生,与 v1.0 的实现不兼容。\n\n## 许可证\n\nMIT License\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmetowolf%2Fwsdog","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fmetowolf%2Fwsdog","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmetowolf%2Fwsdog/lists"}