1
0
Fork 0

Usage example

logger
Armon Dadgar 2014-06-27 13:39:00 +08:00
parent 4ead3ac2f3
commit e586115c2d
1 changed files with 20 additions and 0 deletions

View File

@ -23,3 +23,23 @@ The package still needs the following:
* Support for the BIND command
* Support for the ASSOCIATE command
Example
=======
Below is a simple example of usage
```go
// Create a SOCKS5 server
conf := &socks5.Config{}
server, err := socks5.New(conf)
if err != nil {
panic(err)
}
// Create SOCKS5 proxy on localhost port 8000
if err := server.ListenAndServe("tcp", "127.0.0.1:8000"); err != nil {
panic(err)
}
```