{"id":19963872,"url":"https://github.com/thefcraft/linkifyr","last_synced_at":"2025-03-01T17:12:42.859Z","repository":{"id":229472049,"uuid":"776830438","full_name":"thefcraft/Linkifyr","owner":"thefcraft","description":"Linkifyr is a Python script that enables port forwarding functionality. It allows users to forward network traffic from one port to another, facilitating various network-related tasks such as proxying, tunneling, and redirecting traffic between different hosts or processes.","archived":false,"fork":false,"pushed_at":"2024-05-19T20:13:53.000Z","size":396,"stargazers_count":3,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-01-12T08:20:16.364Z","etag":null,"topics":["fastapi","ngrok-alternative","port-forwarding","winsock"],"latest_commit_sha":null,"homepage":"https://linkifyr.thefcraft.site/","language":"Python","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/thefcraft.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,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2024-03-24T15:11:51.000Z","updated_at":"2024-12-16T18:22:02.000Z","dependencies_parsed_at":"2024-05-18T10:43:13.871Z","dependency_job_id":null,"html_url":"https://github.com/thefcraft/Linkifyr","commit_stats":null,"previous_names":["thefcraft/portforwardpy","thefcraft/linkifyr"],"tags_count":1,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/thefcraft%2FLinkifyr","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/thefcraft%2FLinkifyr/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/thefcraft%2FLinkifyr/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/thefcraft%2FLinkifyr/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/thefcraft","download_url":"https://codeload.github.com/thefcraft/Linkifyr/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":241396777,"owners_count":19956408,"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":["fastapi","ngrok-alternative","port-forwarding","winsock"],"created_at":"2024-11-13T02:17:45.160Z","updated_at":"2025-03-01T17:12:42.829Z","avatar_url":"https://github.com/thefcraft.png","language":"Python","readme":"# Linkifyr Tunnel\n\nThis project implements a tunnel service similar to Ngrok, allowing users to expose their local servers to the internet securely. The implementation consists of a client-side application (`client.py`) and a server-side application (`app.py`) using FastAPI for handling WebSocket connections and HTTP requests.\n\n## Download\n\n[linkifyr.exe](https://github.com/thefcraft/Linkifyr/releases/download/v1.0.0/linkifyr.exe)\n\nto run open cmd and `./linkifyr.exe --url http://127.0.0.1:5000/` --server_url linkifyr.thefcraft.site --server_protocol https\n\n## Features\n\n- Dynamic urls like https://{client_id}.linkifyr.thefcraft.site\n- Securely exposes local servers to the internet.\n- Handles HTTP/HTTPS requests and forwards them to the local server.\n- Displays connection status and information using Rich for a better CLI experience.\n\n## DEMO\n```bash\npython client.py --url http://127.0.0.1:5000/\n```\n```bash\n╭─────────────────────────────────────────────────────── Linkifyr Tunnel ──────────────────────────────────────────────────────────╮\n│ Session Status: online                                                                                                           │\n│ Account: User                                                                                                                    │\n│ Version: 1.0.0                                                                                                                   │\n│ Region: Unknown                                                                                                                  │\n│ Latency: Unknown                                                                                                                 │\n│ Web Interface: Under development                                                                                                 │\n│ Forwarding: https://62dc-f9-d0-9f65.dev.thefcraft.site -\u003e http://127.0.0.1:5000/                                                 │\n╰──────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────╯\nClient ID: 62dc-f9-d0-9f65\nConnection established\nYour site http://127.0.0.1:5000/ is live at https://62dc-f9-d0-9f65.linkifyr.thefcraft.site\n```\n\n## Getting Started\n\n### Prerequisites\n\n- Python 3.7+\n- `aiohttp`\n- `requests`\n- `fastapi`\n- `uvicorn`\n- `rich`\n- `cryptography`\n\nInstall the required packages using pip:\n\n```bash\npip install aiohttp requests fastapi uvicorn rich cryptography\n```\n\n### Client-Side Application\n\nThe client-side application (`client.py`) connects to the server, retrieves a unique client ID, and establishes a WebSocket connection for forwarding requests.\n\n#### Usage\n\nRun the client-side application with the following command:\n\n```bash\npython client.py --url http://127.0.0.1:5000/ --server_url Ilinkifyr.thefcraft.site --server_protocol https\n```\n\n#### Arguments\n\n- `--url`: The local URL to be exposed (default: `http://127.0.0.1:5000/`).\n- `--server_url`: The server URL to connect to (default: `dev.thefcraft.site`).\n- `--server_protocol`: The protocol to use for server connection (`http` or `https`, default: `https`).\n\n### Server-Side Application\n\nThe server-side application (`app.py`) uses FastAPI to handle incoming WebSocket connections and HTTP requests, forwarding them to the appropriate client.\n\n#### Running the Server\n\nRun the server-side application with the following command:\n\n```bash\nuvicorn app:app --host 0.0.0.0 --port 8080\n```\n\n#### dns config\n\nuse [wildcard domain](https://developers.cloudflare.com/dns/manage-dns-records/reference/wildcard-dns-records/)\n\n[adding a wildcard custom domain](https://docs.render.com/custom-domains#adding-a-wildcard-custom-domain) on onrender\n\n### Workflow\n\n1. **Client Connection**: The client connects to the server and retrieves a unique client ID.\n2. **WebSocket Connection**: The client establishes a WebSocket connection using the retrieved client ID.\n3. **Request Forwarding**: The server forwards incoming HTTP requests to the connected client, which processes them and returns the response.\n\n## Project Structure\n\n```\n.\n├── client.py\n├── app.py\n└── README.md\n```\n\n- `client.py`: Contains the client-side logic for connecting to the server and forwarding requests.\n- `app.py`: Contains the server-side logic for handling WebSocket connections and HTTP requests.\n- `README.md`: Project documentation.\n\n## License\n\nThis project is licensed under the MIT License. See the [LICENSE](LICENSE) file for details.\n\n## Acknowledgments\n\n- [Ngrok](https://ngrok.com/) for the inspiration.\n- [FastAPI](https://fastapi.tiangolo.com/) for the excellent web framework.\n- [Rich](https://github.com/Textualize/rich) for the beautiful CLI components.\n\nFor more details, visit the [GitHub repository](https://github.com/thefcraft/PortForwardPy).\n","funding_links":[],"categories":[],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fthefcraft%2Flinkifyr","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fthefcraft%2Flinkifyr","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fthefcraft%2Flinkifyr/lists"}