{"id":20114401,"url":"https://github.com/leecjson/damproxy","last_synced_at":"2025-07-13T12:09:49.640Z","repository":{"id":53383396,"uuid":"217233939","full_name":"leecjson/damproxy","owner":"leecjson","description":"A reverse proxy tool which can let WAN server's data flows to LAN server. support TCP, HTTP, SSH or other protocols based on TCP.","archived":false,"fork":false,"pushed_at":"2021-03-31T04:19:54.000Z","size":40,"stargazers_count":2,"open_issues_count":1,"forks_count":0,"subscribers_count":3,"default_branch":"master","last_synced_at":"2025-02-13T11:52:31.325Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":"","language":"JavaScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/leecjson.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-10-24T07:05:05.000Z","updated_at":"2023-09-25T17:18:08.000Z","dependencies_parsed_at":"2022-08-20T04:00:20.548Z","dependency_job_id":null,"html_url":"https://github.com/leecjson/damproxy","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/leecjson%2Fdamproxy","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/leecjson%2Fdamproxy/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/leecjson%2Fdamproxy/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/leecjson%2Fdamproxy/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/leecjson","download_url":"https://codeload.github.com/leecjson/damproxy/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":241557194,"owners_count":19981881,"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":[],"created_at":"2024-11-13T18:29:37.055Z","updated_at":"2025-03-02T19:14:44.925Z","avatar_url":"https://github.com/leecjson.png","language":"JavaScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"可以将公网（WAN）主机流量转到内网（LAN）主机的反向代理工具库，实现了内网穿透。采用多链接+配对的方式实现，支持TCP、HTTP、SSH协议等。\n\nA reverse proxy tool which can let WAN server's data flows to LAN server. support TCP, HTTP, SSH or others protocol based on TCP.\n\n# Getting started\nPrepare a WAN server and a LAN server. Follow the steps on both of servers.\n1. Download and install \u003ccode\u003eNode.js(\u003e=12.0.0)\u003c/code\u003e.\n2. Install \u003ccode\u003edamproxy\u003c/code\u003e\n```bash\n$ npm i damproxy -g\n```\n\u003cbr /\u003e\n\n# WAN Server\nSimple usage, forward data from port 80 and 443 to LAN server:\n```bash\n$ damproxy listen --forward-ports 80 443\n```\nFull options:\n```bash\n$ damproxy listen --host 0.0.0.0 --port 8991 --pwd mypassword --forward-ports 80@17080 443@17443\n```\n### Options\n#### \u003ccode\u003e--host\u003c/code\u003e\nHost for LAN server connection, default \u003ccode\u003e0.0.0.0\u003c/code\u003e.\n#### \u003ccode\u003e--port\u003c/code\u003e\nPort for LAN server connection, default \u003ccode\u003e8991\u003c/code\u003e.\n#### \u003ccode\u003e--pwd\u003c/code\u003e\nSet the password to identify LAN server. Should less than 32 characters.\n#### \u003ccode\u003e--forward-ports\u003c/code\u003e\nSpecify the port that will receive data from real client, then it will forward to the LAN server via the secondary port as outbound port. 80@17080 means receive data from 80 and forward to LAN server that output via 17080. Defaults the secondary port will automatically provided. May specify it in whitelist situation.\n\n\u003cbr /\u003e\n\n# LAN Server\nSimple usage, connect to WAN server\n```bash\n$ damproxy connect --host x.x.x.x --forward-ports 80\n```\nFull options:\n```bash\n$ damproxy connect --host x.x.x.x --port 8991 --pwd mypassword --forward-ports 80 443@20443 22@192.168.0.102:22\n```\n### Options\n#### \u003ccode\u003e--host\u003c/code\u003e\nWAN server's host to connect.\n#### \u003ccode\u003e--port\u003c/code\u003e\nWAN server's port to connect, default \u003ccode\u003e8991\u003c/code\u003e.\n#### \u003ccode\u003e--pwd\u003c/code\u003e\nSend the password to WAN server. Should less than 32 characters.\n#### \u003ccode\u003e--forward-ports\u003c/code\u003e\nWhitelist of forwarding port and specify a redirect address. It formed by A@B:C which means allowing data from WAN server's port A and send it to B:C. \u003ccode\u003e80\u003c/code\u003e equivalent to \u003ccode\u003e80@127.0.0.1:80\u003c/code\u003e and \u003ccode\u003e80:8080\u003c/code\u003e equivalent to \u003ccode\u003e80@127.0.0.1:8080\u003c/code\u003e.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fleecjson%2Fdamproxy","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fleecjson%2Fdamproxy","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fleecjson%2Fdamproxy/lists"}