{"id":20645197,"url":"https://github.com/czbix/wslhostpatcher","last_synced_at":"2025-04-13T02:20:20.945Z","repository":{"id":39494374,"uuid":"344187111","full_name":"CzBiX/WSLHostPatcher","owner":"CzBiX","description":"Dynamic patch WSL2 to listen port on any interface.","archived":false,"fork":false,"pushed_at":"2024-04-07T12:14:11.000Z","size":28,"stargazers_count":748,"open_issues_count":1,"forks_count":51,"subscribers_count":15,"default_branch":"master","last_synced_at":"2025-04-04T04:12:01.842Z","etag":null,"topics":["wsl","wsl2","wsl2-forwarding-port"],"latest_commit_sha":null,"homepage":"","language":"C++","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/CzBiX.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":"2021-03-03T16:15:48.000Z","updated_at":"2025-04-02T11:05:51.000Z","dependencies_parsed_at":"2024-11-16T16:19:40.314Z","dependency_job_id":"d2579076-40e9-4a42-b33e-cedcb68ebeff","html_url":"https://github.com/CzBiX/WSLHostPatcher","commit_stats":null,"previous_names":[],"tags_count":4,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/CzBiX%2FWSLHostPatcher","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/CzBiX%2FWSLHostPatcher/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/CzBiX%2FWSLHostPatcher/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/CzBiX%2FWSLHostPatcher/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/CzBiX","download_url":"https://codeload.github.com/CzBiX/WSLHostPatcher/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":248654637,"owners_count":21140334,"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":["wsl","wsl2","wsl2-forwarding-port"],"created_at":"2024-11-16T16:19:07.333Z","updated_at":"2025-04-13T02:20:20.920Z","avatar_url":"https://github.com/CzBiX.png","language":"C++","funding_links":[],"categories":[],"sub_categories":[],"readme":"# WSLHostPatcher\nDynamic patch WSL2 to listen port on any interfaces.\n\n# Updates\nCheck out experimental bridge solution at https://github.com/microsoft/WSL/issues/4150#issuecomment-1018524753.\n\nAlso [MS official config](https://docs.microsoft.com/en-us/windows/wsl/wsl-config#configuration-setting-for-wslconfig) for WSL 2 in Windows Build 19041 and later.\n\n# How it work\nThe localhost port actually forward by `wslhost.exe` on Windows, but it listen on localhost only.\n\nWSLHostPatcher will scan all `wslhost.exe` processes, then inject into it to hook `bind` API  listen on any IP.\nThere is no any background processes neither cost any performance.\n\n# How to use\nDownload [release](https://github.com/CzBiX/WSLHostPatcher/releases/latest) and unzip it on Windows. Run `WSLHostPatcher.exe` after WSL2 started.\nThis patch needs to running on every time WSL starts, and only the ports listening after running patch will work.\nYou can also do one of the following two things to make it run automatically:\n1. put it in your `.profile` - see [#1](https://github.com/CzBiX/WSLHostPatcher/issues/1).\n2. put it in `/etc/wsl.conf` (suitable for auto-run services like ssh - runs on boot):\n```\n[boot]\ncommand=\u003cpath to WSLHostPatcher.exe\u003e\n```\n\n# How to restore\n`wsl --shutdown` or Reboot system.\n\n# Security Consideration\nListen port on any interfaces may cause some security problems. You are on your own.\n\nAnti-virus software may alert, see [discussion](https://github.com/CzBiX/WSLHostPatcher/discussions/16).\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fczbix%2Fwslhostpatcher","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fczbix%2Fwslhostpatcher","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fczbix%2Fwslhostpatcher/lists"}