SpoofDPI/spoof-dpi.go

29 lines
456 B
Go
Raw Normal View History

2021-12-27 07:43:03 +00:00
package main
import (
"net"
"log"
"SpoofDPI/handler"
)
func main() {
log.Println("##### Listening 8080..")
listener, err := net.Listen("tcp", ":8080")
if err != nil {
panic(err)
}
for {
connClient, err := listener.Accept()
if err != nil {
log.Println("error accepting connection", err)
continue
}
log.Println("##### New connection", connClient.RemoteAddr())
go handler.HandleClientRequest(connClient)
}
}