{"id":18015396,"url":"https://github.com/hirbodbehnam/shift-forwarder","last_synced_at":"2025-04-04T15:17:02.765Z","repository":{"id":108181444,"uuid":"208802035","full_name":"HirbodBehnam/Shift-Forwarder","owner":"HirbodBehnam","description":"A small and stupid way to maybe, just maybe escape DPI","archived":false,"fork":false,"pushed_at":"2020-02-25T08:47:42.000Z","size":10,"stargazers_count":3,"open_issues_count":0,"forks_count":1,"subscribers_count":3,"default_branch":"master","last_synced_at":"2024-10-30T06:08:28.273Z","etag":null,"topics":["censorship-circumvention","dpi","port-forwarding"],"latest_commit_sha":null,"homepage":"","language":"Go","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/HirbodBehnam.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,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2019-09-16T13:06:47.000Z","updated_at":"2022-09-10T20:26:07.000Z","dependencies_parsed_at":null,"dependency_job_id":"d7e4fa46-80d9-430b-8e4c-c9e074ce1dae","html_url":"https://github.com/HirbodBehnam/Shift-Forwarder","commit_stats":null,"previous_names":[],"tags_count":3,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/HirbodBehnam%2FShift-Forwarder","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/HirbodBehnam%2FShift-Forwarder/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/HirbodBehnam%2FShift-Forwarder/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/HirbodBehnam%2FShift-Forwarder/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/HirbodBehnam","download_url":"https://codeload.github.com/HirbodBehnam/Shift-Forwarder/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":247198466,"owners_count":20900081,"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":["censorship-circumvention","dpi","port-forwarding"],"created_at":"2024-10-30T04:13:51.131Z","updated_at":"2025-04-04T15:17:02.739Z","avatar_url":"https://github.com/HirbodBehnam.png","language":"Go","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Shift Forwarder\nA simple tool to shift all bytes and forward traffic\n## Why this?\nI personally use this with an HTTP Proxy server to bypass censorship. Iran's DPI system is stupid enough to let the traffic get through. You can also use a SOCKS server behind the forwarder.\n\nNo shit guys, I almost went WTF when this worked.\n## Install\nUse the executables from [releases](https://github.com/HirbodBehnam/Shift-Forwarder/releases) and download one for your server and client.\n### Server\n```\n./sf -server -to 127.0.0.1:8888 -interface 127.0.0.1 -port 1080\n```\nRun this command. It will get all traffics from port 1080, shift the bytes back and forwards them to 127.0.0.1:8888.\n### Client\n```\n ./sf -to 1.1.1.1:1080 -port 8080\n```\nThis will get all incoming traffics from port 8080 and forwards them to 1.1.1.1:1080.\n### Building\nJust as easy as\n```bash\ngo build main.go\n```\n## Arguments\n```\nUsage of sf.exe:\n  -bitwise\n        Pass this argument to enable bitwise mode; Otherwise addition mode is used\n  -interface string\n        Binding address. Server's default is 0.0.0.0 and client's is localhost\n  -port string\n        If this is server, the port that proxy listens on it; It this is client, the port that accepts the data\n  -server\n        Pass this argument to run as server application\n  -to string\n        If this is server, the address that the data will be forwarded; If this is client, the server address\n  -verbose\n        More logs\n  -version\n        Show version\n```\n### Bitwise Mode\nBitwise mode, bitwises all bytes before sending them to server or client. So server -\u003e client and client -\u003e server connections are bitwised.\n\nIf you enable bitwise mode on server, it must be enabled on server too.\n### How non bitwise mode works\nWhen client forwards something to server, it adds 1 to all of the bytes. On server, the all the bytes will be subtracted by one. After the subtract, server will forward the traffic to the destination. The server-\u003eclient traffic is also shifted like this.\n## Shadowsocks Plugin\nYou can also run this application as shadowsocks plugin. Here is an example of the server config:\n```json\n{\n    \"server\":\"0.0.0.0\",\n    \"server_port\":2345,\n    \"password\":\"1234\",\n    \"timeout\":60,\n    \"method\":\"chacha20-ietf-poly1305\",\n    \"nameserver\":\"1.1.1.1\",\n    \"plugin\":\"/etc/shadowsocks-libev/sf\",\n    \"plugin_opts\":\"server;bitwise\"\n}\n```\n`plugin_opts` supports 3 different values:\n* server: When this key exists, application will run as server mode\n* bitwise: When this key exists, application will use bitwise mode to obfuscate data. Otherwise addition is used.\n* verbose: Show more logs\n\nKeys must be separated with `;`\n\nAndroid application is coming soon","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fhirbodbehnam%2Fshift-forwarder","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fhirbodbehnam%2Fshift-forwarder","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fhirbodbehnam%2Fshift-forwarder/lists"}