{"id":13775922,"url":"https://github.com/lersh/potatostream","last_synced_at":"2025-05-11T08:34:26.601Z","repository":{"id":94277001,"uuid":"106187904","full_name":"lersh/potatoStream","owner":"lersh","description":"Shadowsocks like Proxy,Written by nodejs","archived":false,"fork":false,"pushed_at":"2017-11-02T02:05:36.000Z","size":69318,"stargazers_count":22,"open_issues_count":1,"forks_count":14,"subscribers_count":3,"default_branch":"master","last_synced_at":"2024-08-03T17:12:21.584Z","etag":null,"topics":["nodejs","proxy","shadowsocks","socks5"],"latest_commit_sha":null,"homepage":"","language":"JavaScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/lersh.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null}},"created_at":"2017-10-08T15:39:13.000Z","updated_at":"2023-11-26T06:12:23.000Z","dependencies_parsed_at":"2023-07-27T16:16:04.020Z","dependency_job_id":null,"html_url":"https://github.com/lersh/potatoStream","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/lersh%2FpotatoStream","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/lersh%2FpotatoStream/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/lersh%2FpotatoStream/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/lersh%2FpotatoStream/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/lersh","download_url":"https://codeload.github.com/lersh/potatoStream/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":225031377,"owners_count":17410054,"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","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":["nodejs","proxy","shadowsocks","socks5"],"created_at":"2024-08-03T17:01:54.545Z","updated_at":"2024-11-17T11:30:36.763Z","avatar_url":"https://github.com/lersh.png","language":"JavaScript","funding_links":[],"categories":["\u003ca id=\"d03d494700077f6a65092985c06bf8e8\"\u003e\u003c/a\u003e工具"],"sub_categories":["\u003ca id=\"cb16466a31a167bb61f39e2a4a85f449\"\u003e\u003c/a\u003eShadowsocks"],"readme":"# potatoStream\n使用Nodejs实现的代理服务器，使用AES-256-GCM加密。已经添加了添加obfs混淆。\n\n目前还在试验阶段，请谨慎使用。需要在服务器和本地安装[Node.js](https://nodejs.org/)\n\n\n1. potatoServer.js是服务器。\n2. potatoSocks5.js是客户端，也就是本地的socks5代理服务器。\n3. 使用git clone到本地后，请先执行npm install来安装依赖组件\n4. 然后新建一个config.josn文件作为配置\n\n```\n{\n    \"server_addr\": \"127.0.0.1\",\n    \"server_port\": 1999,\n    \"local_port\": 3000,\n    \"method\": \"https\",\n    \"camouflage\":\"/C=CN/ST=Guangdong/...\",\n    \"algorithm\": \"aes-256-cfb\",\n    \"password\": \"password\"\n}\n```\n\u003e 由于json文件不能带注释，我在这里解释下各个参数的含义  \n\u003e `server_addr`代表服务器地址，客户端需要这个参数来获 取服务器的地址  \n\u003e `server_port`代表服务器的端口，服务器端也需要这个参数来知道自己需要监听哪个端口  \n\u003e `local_port`表示客户端需要监听的端口，客户端需要这个参数来知道监听在什么端口，一般是1080  \n\u003e `method`表示用什么方法来混淆。  \n\n***有`http`和`https`两个选项，使用`http`的话，会在服务器和客户端的通讯之间加上伪装的http的头，部分运营商（比如联通）会直接识别http头里的host信息来认为你连接的就是伪装的网址，现在默认使用aliyun的网址。使用`https`的话，会在服务器和客户端之间使用tls加密通讯，通讯的证书是自签名证书，自签名证书需要自己运行`node cert.js`来生成，生成证书需要`camouflage`参数。`https`的参数的cpu占用较小，如果你发现`http`方式占用cpu较大可以采用这个方式。***\n\n\u003e `camouflage`生成证书用的参数，一般的构成是这样的：\n\n`/C=国家，两个字母缩写/ST=省，全拼/L=城市，全拼/O=公司全称/OU=部门/CN=域名`  \n目前的思路是采用比较大的企业的证书来伪装，比如aliyun,腾讯云等等，脑洞比较大的话也可以试试12306的证书。  \n填好这个字段后，运行`node cert.js`，就会自动生成伪装的证书（需要安装了openssl），之后就可以使用`https`的伪装方式了\n\n\u003e `algorithm`暂时没有用。\n\n\u003e `password`服务器和客户端之间通讯的密码，也是生成证书用的密码，需要服务器和客户端保持一致。\n\n\n5. 配置好config.json后，就可以在服务器上运行 `node potatoServer.js` 如果想后台运行，执行 `node potatoServer.js \u0026`\n6. 本地运行 node potatoSocks5.js 即可在你指定的端口开启socks5代理\n7. 浏览器里设置socks5代理服务器，就可以安心的浏览了~\n---\n\n### 关于pipe.js\n用于中转流量，常见于部分公司网络屏蔽所有国外ip，这时你可以找一台国内的服务器，用pipe.js来中转流量。pipe.js不关心具体的协议无论是http还是https，还是shadowsocks(R)，只要是tcp连接都可以中转。\n\n- 用法\n\n \u003e node pipe.js 国外服务器ip 国外服务器端口 本地端口  \n \u003e 比如 node pipe.js 45.190.\\*.\\* 443 1080  \n \u003e 这样只要连接你这台机器的1080端口，就能转发到  45.190.*.*的443端口上了","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Flersh%2Fpotatostream","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Flersh%2Fpotatostream","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Flersh%2Fpotatostream/lists"}