GithubHelp home page GithubHelp logo

ahnan4arch / fasttunnel Goto Github PK

View Code? Open in Web Editor NEW

This project forked from fasttunnel/fasttunnel

0.0 1.0 0.0 817 KB

expose a local server to the internet. 跨平台的内网穿透工具 远程内网计算机 域名访问内网站点 反向代理内网服务 花生壳 端口转发 http代理

Home Page: https://suidao.io

License: Apache License 2.0

C# 89.20% Batchfile 1.49% HTML 7.88% Dockerfile 0.79% Shell 0.64%

fasttunnel's Introduction

FastTunnel

License Build status Nuget Nuget

README | 中文文档


Official website : https://suidao.io

The penetration platform developed based on this framework, if you need intranet penetration, you can register and use it directly, eliminating the cost of building and maintaining yourself. But do not use this service for important items.

OpenSource:

GitHub : FastTunnel
Gitee: FastTunnel


If helpful, click on Star to support this project, please submit an issue if you have needs and bugs, and welcome coder to PR img1


What is FastTunnel?

  • FastTunnel is a high-performance cross-platform intranet penetration tool. With it, you can expose intranet services to the public network for yourself or anyone to access.
  • Unlike other penetration tools, the FastTunnel project is committed to creating an easy-to-extensible and easy-to-maintain intranet penetration framework.
  • You can build your own penetration application by referencing the nuget package of FastTunnel.Core, and target the business extension functions you need.

What can FastTunel do?

  • Remote intranet computer Windows/Linux/Mac
  • Use a custom domain name to access intranet web services (usually used for WeChat development)
  • Port forwarding/port mapping, access services provided by any port on the intranet mysql, redis, ftp, etc.
  • p2p penetration
  • Support binding multiple domain names to access intranet services
  • Support domain name whitelist restriction
  • Support client identity verification

Quickstart

  1. Download the corresponding program on the releases page
  2. Modify the client and server configuration files according to your needsappsettings.json
  3. Run FastTunnel.Server
  4. Run FastTunnel.Cient

Install FastTunel.Sever using Docker Engine

Configuration files and log files are mounted through volume. If this image has been run before, docker may not update to the latest image. Please delete the existing image manually, and then execute the following command

docker run --detach \
  --publish 1270:1270 --publish 1271:1271 \
  --name FastTunnel \
  --restart always \
  --volume /var/FastTunnel/config:/app/config \
  --volume /var/FastTunnel/Logs:/app/Logs \
  springhgui/fasttunnel:latest

Run on Linux/Mac os?

Windows

Double click directly FastTunnel.Client.exe to run

Linux

chmod +x FastTunnel.Client
./FastTunnel.Client

Mac

click directly FastTunnel.Client to run

Configuration example

1. Use a custom domain name to access intranet web services

  • For example, you have a server with a public IP address of 110.110.110.110, and you have a domain name with a top-level domain name of abc.com, you want to visit a website on the intranet by visiting test.abc.com

  • You need to add a DNS resolution for the domain name address, the type is A, the name is *, and the ipv4 address is 110.110.110.110, so that all domain names of *.abc.com will point to 110.110.110.110’s server, because the default http port of FastTunnel is 1270, so you need to visithttp://test.abc.com:1270

  • If you don't want to bring the port number every time you visit, you can use nginx forwarding.

http {
    # add resolver 
    resolver 8.8.8.8;

    # set *.abc.com to 1270 port
    server {
      server_name  *.abc.com;
      location / {
         proxy_pass http://$host:1270;
         proxy_set_header   Host             $host;
         proxy_set_header   X-Real-IP        $remote_addr;
         proxy_set_header   X-Forwarded-For  $proxy_add_x_forwarded_for;
      }

      # 可选
      error_log /var/log/nginx/error_ft.log error;
    }
}
  • If the domain name configured on the server is ft.suidao.io, then access the local site through the subdomain name test.ft.suidao.io:1270, the IIS configuration is as follows: img1

2. Remote intranet computer Windows/Linux/Mac

The client configuration is as follows, there are two hosts in the intranet, and the ip is as follows: appsettings.json

 "ClientSettings": {
    "Common": {
      "ServerAddr": "xxx.xxx.xxx.xxx",
      "ServerPort": 1271
    },
    "SSH": [
      {
        "LocalIp": "192.168.0.100", // linux pc
        "LocalPort": 22,            // ssh default port
        "RemotePort": 12701
      },
      {
        "LocalIp": "192.168.0.101", // windows pc
        "LocalPort": 3389,          // windows default port for Remote
        "RemotePort": 12702
      }
    ]
  }

remote intranet linux host by ssh (ip:192.168.0.100)

Assuming that the user name of the intranet host is root, the server ip is x.x.x.x, and the two hosts that access the intranet are as follows

ssh -oPort=12701 [email protected]

remote desktop Windows host by mstsc (ip:192.168.0.101)

Controlled terminal setting

  • Open cmd and enter the command sysdm.cpl in the pop-up dialog box and select Allow remote connection to this computer

img1

Control terminal settings

  • Open cmd and enter the command mstsc, open the remote dialog box, enter x.x.x.x:12701 in the computer input box of the dialog box, and then specify the user name and password to remote the windows host of the intranet img1

Development/PR

  • install vs2019 last version
  • install .net5 or higher https://dotnet.microsoft.com/download/dotnet/5.0
  • add test.test.cc 127.0.0.1 in system host file
  • run fasttunnel.server
  • run fasttunnel.client

contributors

Join QQ Group

License

Apache License 2.0

fasttunnel's People

Contributors

cnwzhu avatar ha-ei avatar ioxygen avatar mcq12322 avatar springhgui avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.