update
This commit is contained in:
@@ -339,15 +339,15 @@ Http (s) agent, SPS agent, intranet penetration, tcp agent support the connectio
|
||||
The parameters are: --jumper, all the formats are as follows:
|
||||
|
||||
```text
|
||||
http://username:password@host:port
|
||||
http://host:port
|
||||
https://username:password@host:port
|
||||
https://host:port
|
||||
socks5://username:password@host:port
|
||||
socks5://host:port
|
||||
socks5s://username:password@host:port
|
||||
socks5s://host:port
|
||||
ss://method:password@host:port
|
||||
http://username:password@host:port
|
||||
http://host:port
|
||||
https://username:password@host:port
|
||||
https://host:port
|
||||
socks5://username:password@host:port
|
||||
socks5://host:port
|
||||
socks5s://username:password@host:port
|
||||
socks5s://host:port
|
||||
ss://method:password@host:port
|
||||
```
|
||||
|
||||
Http,socks5 represents the normal http and socks5 proxy.
|
||||
@@ -1489,13 +1489,13 @@ Sps supports http(s)\socks5 proxy authentication, which can be cascaded and has
|
||||
4: The authentication information `auth-info-to-parent` that is finally sent to the upstream.
|
||||
Their situation is as follows:
|
||||
|
||||
User-auth | local-auth | parent-auth | auth-info-to-paren
|
||||
| ------ | ------ | ------ | ------
|
||||
| Yes / No | Yes | Yes | From parent-auth
|
||||
| Yes / No | No | Yes | From parent-auth
|
||||
| Yes / No | Yes | No | No
|
||||
| No | No | No | No
|
||||
| Yes | No | No | From user-auth
|
||||
| User-auth | local-auth | parent-auth | auth-info-to-paren |
|
||||
|-----------| ------ | ------ |--------------------- |
|
||||
| Yes / No | Yes | Yes | From parent-auth |
|
||||
| Yes / No | No | Yes | From parent-auth |
|
||||
| Yes / No | Yes | No | No |
|
||||
| No | No | No | No |
|
||||
| Yes | No | No | From user-auth |
|
||||
|
||||
For the sps proxy we can perform username and password authentication. The authenticated username and password can be specified on the command line.
|
||||
`proxy sps -S http -T tcp -P 127.0.0.1:8080 -t tcp -p ":33080" -a "user1:pass1:0:0:" -a "user2:pass2:0:0: "`
|
||||
@@ -2011,33 +2011,42 @@ The proxy will report the traffic used for this connection to this address.Speci
|
||||
There are two reporting modes, which can be specified by the `--traffic-mode` parameter. It can be reported in the normal mode or in the fast mode.
|
||||
|
||||
1. Report in `normal` normal mode
|
||||
When the connection is released, the proxy will report the traffic used for this connection to this `--traffic-url` address.
|
||||
When the connection is released, the proxy will report the traffic used for this connection to this `--traffic-url`
|
||||
address.
|
||||
|
||||
2. Report in `fast` mode
|
||||
For each connection that has been established, the proxy will `timely` report the traffic generated by this connection to this` --traffic-url` address.
|
||||
`Timing` defaults to 5 seconds, and you can modify` Timing` to the appropriate number of seconds via the parameter `--traffic-interval`.
|
||||
For each connection that has been established, the proxy will `timely` report the traffic generated by this
|
||||
connection to this` --traffic-url` address.
|
||||
`Timing` defaults to 5 seconds, and you can modify` Timing` to the appropriate number of seconds via the
|
||||
parameter `--traffic-interval`.
|
||||
|
||||
3. Report in `fast` global mode
|
||||
3. Report in `fast` global mode
|
||||
By default, if the API can't handle high concurrency report access, you can use the fast global mode,
|
||||
Use the parameter `--fast-global` to open, this parameter is only valid when `--traffic-mode=fast`. In fast global mode, for a `--traffic-url`,
|
||||
Use the parameter `--fast-global` to open, this parameter is only valid when `--traffic-mode=fast`. In fast global
|
||||
mode, for a `--traffic-url`,
|
||||
no matter how many concurrent connections there are, only have one reporter, and the reporting interval is 5 seconds.
|
||||
In this mode, the reporting request method is `POST`, `Content-Type` is `application/json`, the post body data is `JSON Array`, example: `[{},{}]`, the keys of object in the array are same with the following `Please parameter description`.
|
||||
4. The traffic reporting function combined with the above API authentication function can control the user's traffic usage in real time. The traffic is reported to the interface. The interface writes the traffic data to the database, and then the authentication API queries the database to determine the traffic usage and determine whether the user can be successfully authenticated.
|
||||
In this mode, the reporting request method is `POST`, `Content-Type` is `application/json`, the post body data
|
||||
is `JSON Array`, example: `[{},{}]`, the keys of object in the array are same with the
|
||||
following `Reqeust parameter description`.
|
||||
4. The traffic reporting function combined with the above API authentication function can control the user's traffic
|
||||
usage in real time. The traffic is reported to the interface. The interface writes the traffic data to the database,
|
||||
and then the authentication API queries the database to determine the traffic usage and determine whether the user
|
||||
can be successfully authenticated.
|
||||
|
||||
The following is a complete URL request example:
|
||||
|
||||
`http://127.0.0.1:33088/user/traffic?bytes=337&client_addr=127.0.0.1%3A51035&id=http&server_addr =127.0.0.1%3A33088&target_addr=myip.ipip.net%3A80&username=a`
|
||||
|
||||
Request parameter description:
|
||||
id: service id flag.
|
||||
server_addr: proxies's address requested by the client, format: IP: port.
|
||||
client_addr: client address, format: IP: port.
|
||||
target_addr: target address, format: "IP: port", when tcp / udp proxy, this is empty.
|
||||
User name: proxy authentication user name, this is empty when tcp / udp proxy.
|
||||
bytes: the number of traffic bytes used by the user.
|
||||
out_local_addr: outgoing tcp connection's local address,format: IP: port.
|
||||
out_remote_addr: outgoing tcp connection's remote address,format: IP: port.
|
||||
upstream: upstream used by outgoing tcp connection, if none upstream be used, it's empty.
|
||||
**Request parameter description:**
|
||||
`id`: service id flag.
|
||||
`server_addr`: proxies's address requested by the client, format: IP: port.
|
||||
`client_addr`: client address, format: IP: port.
|
||||
`target_addr`: target address, format: "IP: port", when tcp / udp proxy, this is empty.
|
||||
`username`: proxy authentication user name, this is empty when tcp / udp proxy.
|
||||
`bytes`: the number of traffic bytes used by the user.
|
||||
`out_local_addr`: outgoing tcp connection's local address,format: IP: port.
|
||||
`out_remote_addr`: outgoing tcp connection's remote address,format: IP: port.
|
||||
`upstream`: upstream used by outgoing tcp connection, if none upstream be used, it's empty.
|
||||
|
||||
#### Tips
|
||||
|
||||
|
||||
Reference in New Issue
Block a user