mirror of
				https://github.com/nadoo/glider.git
				synced 2025-11-04 15:52:38 +08:00 
			
		
		
		
	doc: update spell mistakes
This commit is contained in:
		
							parent
							
								
									2ae76999f7
								
							
						
					
					
						commit
						5451b202d0
					
				
							
								
								
									
										12
									
								
								README.md
									
									
									
									
									
								
							
							
						
						
									
										12
									
								
								README.md
									
									
									
									
									
								
							@ -103,11 +103,11 @@ glider v0.5.2 usage:
 | 
				
			|||||||
  -dnsserver value
 | 
					  -dnsserver value
 | 
				
			||||||
        remote dns server
 | 
					        remote dns server
 | 
				
			||||||
  -forward value
 | 
					  -forward value
 | 
				
			||||||
        forward url, format: SCHEMA://[USER|METHOD:PASSWORD@][HOST]:PORT?PARAMS[,SCHEMA://[USER|METHOD:PASSWORD@][HOST]:PORT?PARAMS]
 | 
					        forward url, format: SCHEME://[USER|METHOD:PASSWORD@][HOST]:PORT?PARAMS[,SCHEME://[USER|METHOD:PASSWORD@][HOST]:PORT?PARAMS]
 | 
				
			||||||
  -ipset string
 | 
					  -ipset string
 | 
				
			||||||
        ipset name
 | 
					        ipset name
 | 
				
			||||||
  -listen value
 | 
					  -listen value
 | 
				
			||||||
        listen url, format: SCHEMA://[USER|METHOD:PASSWORD@][HOST]:PORT?PARAMS
 | 
					        listen url, format: SCHEME://[USER|METHOD:PASSWORD@][HOST]:PORT?PARAMS
 | 
				
			||||||
  -rulefile value
 | 
					  -rulefile value
 | 
				
			||||||
        rule file path
 | 
					        rule file path
 | 
				
			||||||
  -rules-dir string
 | 
					  -rules-dir string
 | 
				
			||||||
@ -117,7 +117,7 @@ glider v0.5.2 usage:
 | 
				
			|||||||
  -verbose
 | 
					  -verbose
 | 
				
			||||||
        verbose mode
 | 
					        verbose mode
 | 
				
			||||||
 | 
					
 | 
				
			||||||
Available Schemas:
 | 
					Available Schemes:
 | 
				
			||||||
  mixed: serve as a http/socks5 proxy on the same port. (default)
 | 
					  mixed: serve as a http/socks5 proxy on the same port. (default)
 | 
				
			||||||
  ss: ss proxy
 | 
					  ss: ss proxy
 | 
				
			||||||
  socks5: socks5 proxy
 | 
					  socks5: socks5 proxy
 | 
				
			||||||
@ -129,18 +129,18 @@ Available Schemas:
 | 
				
			|||||||
  uottun: udp over tcp tunnel
 | 
					  uottun: udp over tcp tunnel
 | 
				
			||||||
  dnstun: listen on udp port and forward all dns requests to remote dns server via forwarders(tcp)
 | 
					  dnstun: listen on udp port and forward all dns requests to remote dns server via forwarders(tcp)
 | 
				
			||||||
 | 
					
 | 
				
			||||||
Available schemas for different modes:
 | 
					Available schemes for different modes:
 | 
				
			||||||
  listen: mixed ss socks5 http redir tcptun udptun uottun dnstun
 | 
					  listen: mixed ss socks5 http redir tcptun udptun uottun dnstun
 | 
				
			||||||
  forward: ss socks5 http ssr
 | 
					  forward: ss socks5 http ssr
 | 
				
			||||||
 | 
					
 | 
				
			||||||
SS schema:
 | 
					SS scheme:
 | 
				
			||||||
  ss://method:pass@host:port
 | 
					  ss://method:pass@host:port
 | 
				
			||||||
 | 
					
 | 
				
			||||||
Available methods for ss:
 | 
					Available methods for ss:
 | 
				
			||||||
  AEAD_AES_128_GCM AEAD_AES_192_GCM AEAD_AES_256_GCM AEAD_CHACHA20_POLY1305 AES-128-CFB AES-128-CTR AES-192-CFB AES-192-CTR AES-256-CFB AES-256-CTR CHACHA20-IETF XCHACHA20
 | 
					  AEAD_AES_128_GCM AEAD_AES_192_GCM AEAD_AES_256_GCM AEAD_CHACHA20_POLY1305 AES-128-CFB AES-128-CTR AES-192-CFB AES-192-CTR AES-256-CFB AES-256-CTR CHACHA20-IETF XCHACHA20
 | 
				
			||||||
  NOTE: chacha20-ietf-poly1305 = AEAD_CHACHA20_POLY1305
 | 
					  NOTE: chacha20-ietf-poly1305 = AEAD_CHACHA20_POLY1305
 | 
				
			||||||
 | 
					
 | 
				
			||||||
SSR schema:
 | 
					SSR scheme:
 | 
				
			||||||
  ssr://method:pass@host:port?protocol=xxx&protocol_param=yyy&obfs=zzz&obfs_param=xyz
 | 
					  ssr://method:pass@host:port?protocol=xxx&protocol_param=yyy&obfs=zzz&obfs_param=xyz
 | 
				
			||||||
 | 
					
 | 
				
			||||||
Available forward strategies:
 | 
					Available forward strategies:
 | 
				
			||||||
 | 
				
			|||||||
							
								
								
									
										14
									
								
								conf.go
									
									
									
									
									
								
							
							
						
						
									
										14
									
								
								conf.go
									
									
									
									
									
								
							@ -34,8 +34,8 @@ func confInit() {
 | 
				
			|||||||
	flag.StringVar(&conf.Strategy, "strategy", "rr", "forward strategy, default: rr")
 | 
						flag.StringVar(&conf.Strategy, "strategy", "rr", "forward strategy, default: rr")
 | 
				
			||||||
	flag.StringVar(&conf.CheckWebSite, "checkwebsite", "www.apple.com", "proxy check HTTP(NOT HTTPS) website address, format: HOST[:PORT], default port: 80")
 | 
						flag.StringVar(&conf.CheckWebSite, "checkwebsite", "www.apple.com", "proxy check HTTP(NOT HTTPS) website address, format: HOST[:PORT], default port: 80")
 | 
				
			||||||
	flag.IntVar(&conf.CheckDuration, "checkduration", 30, "proxy check duration(seconds)")
 | 
						flag.IntVar(&conf.CheckDuration, "checkduration", 30, "proxy check duration(seconds)")
 | 
				
			||||||
	flag.StringSliceUniqVar(&conf.Listen, "listen", nil, "listen url, format: SCHEMA://[USER|METHOD:PASSWORD@][HOST]:PORT?PARAMS")
 | 
						flag.StringSliceUniqVar(&conf.Listen, "listen", nil, "listen url, format: SCHEME://[USER|METHOD:PASSWORD@][HOST]:PORT?PARAMS")
 | 
				
			||||||
	flag.StringSliceUniqVar(&conf.Forward, "forward", nil, "forward url, format: SCHEMA://[USER|METHOD:PASSWORD@][HOST]:PORT?PARAMS[,SCHEMA://[USER|METHOD:PASSWORD@][HOST]:PORT?PARAMS]")
 | 
						flag.StringSliceUniqVar(&conf.Forward, "forward", nil, "forward url, format: SCHEME://[USER|METHOD:PASSWORD@][HOST]:PORT?PARAMS[,SCHEME://[USER|METHOD:PASSWORD@][HOST]:PORT?PARAMS]")
 | 
				
			||||||
	flag.StringSliceUniqVar(&conf.RuleFile, "rulefile", nil, "rule file path")
 | 
						flag.StringSliceUniqVar(&conf.RuleFile, "rulefile", nil, "rule file path")
 | 
				
			||||||
	flag.StringVar(&conf.RulesDir, "rules-dir", "", "rule file folder")
 | 
						flag.StringVar(&conf.RulesDir, "rules-dir", "", "rule file folder")
 | 
				
			||||||
 | 
					
 | 
				
			||||||
@ -106,7 +106,7 @@ func NewRuleConfFromFile(ruleFile string) (*RuleConf, error) {
 | 
				
			|||||||
	p := &RuleConf{name: ruleFile}
 | 
						p := &RuleConf{name: ruleFile}
 | 
				
			||||||
 | 
					
 | 
				
			||||||
	f := conflag.NewFromFile("rule", ruleFile)
 | 
						f := conflag.NewFromFile("rule", ruleFile)
 | 
				
			||||||
	f.StringSliceUniqVar(&p.Forward, "forward", nil, "forward url, format: SCHEMA://[USER|METHOD:PASSWORD@][HOST]:PORT?PARAMS[,SCHEMA://[USER|METHOD:PASSWORD@][HOST]:PORT?PARAMS]")
 | 
						f.StringSliceUniqVar(&p.Forward, "forward", nil, "forward url, format: SCHEME://[USER|METHOD:PASSWORD@][HOST]:PORT?PARAMS[,SCHEME://[USER|METHOD:PASSWORD@][HOST]:PORT?PARAMS]")
 | 
				
			||||||
	f.StringVar(&p.Strategy, "strategy", "rr", "forward strategy, default: rr")
 | 
						f.StringVar(&p.Strategy, "strategy", "rr", "forward strategy, default: rr")
 | 
				
			||||||
	f.StringVar(&p.CheckWebSite, "checkwebsite", "www.apple.com", "proxy check HTTP(NOT HTTPS) website address, format: HOST[:PORT], default port: 80")
 | 
						f.StringVar(&p.CheckWebSite, "checkwebsite", "www.apple.com", "proxy check HTTP(NOT HTTPS) website address, format: HOST[:PORT], default port: 80")
 | 
				
			||||||
	f.IntVar(&p.CheckDuration, "checkduration", 30, "proxy check duration(seconds)")
 | 
						f.IntVar(&p.CheckDuration, "checkduration", 30, "proxy check duration(seconds)")
 | 
				
			||||||
@ -134,7 +134,7 @@ func usage() {
 | 
				
			|||||||
	flag.PrintDefaults()
 | 
						flag.PrintDefaults()
 | 
				
			||||||
	fmt.Fprintf(os.Stderr, "\n")
 | 
						fmt.Fprintf(os.Stderr, "\n")
 | 
				
			||||||
 | 
					
 | 
				
			||||||
	fmt.Fprintf(os.Stderr, "Available Schemas:\n")
 | 
						fmt.Fprintf(os.Stderr, "Available Schemes:\n")
 | 
				
			||||||
	fmt.Fprintf(os.Stderr, "  mixed: serve as a http/socks5 proxy on the same port. (default)\n")
 | 
						fmt.Fprintf(os.Stderr, "  mixed: serve as a http/socks5 proxy on the same port. (default)\n")
 | 
				
			||||||
	fmt.Fprintf(os.Stderr, "  ss: ss proxy\n")
 | 
						fmt.Fprintf(os.Stderr, "  ss: ss proxy\n")
 | 
				
			||||||
	fmt.Fprintf(os.Stderr, "  socks5: socks5 proxy\n")
 | 
						fmt.Fprintf(os.Stderr, "  socks5: socks5 proxy\n")
 | 
				
			||||||
@ -147,12 +147,12 @@ func usage() {
 | 
				
			|||||||
	fmt.Fprintf(os.Stderr, "  dnstun: listen on udp port and forward all dns requests to remote dns server via forwarders(tcp)\n")
 | 
						fmt.Fprintf(os.Stderr, "  dnstun: listen on udp port and forward all dns requests to remote dns server via forwarders(tcp)\n")
 | 
				
			||||||
	fmt.Fprintf(os.Stderr, "\n")
 | 
						fmt.Fprintf(os.Stderr, "\n")
 | 
				
			||||||
 | 
					
 | 
				
			||||||
	fmt.Fprintf(os.Stderr, "Available schemas for different modes:\n")
 | 
						fmt.Fprintf(os.Stderr, "Available schemes for different modes:\n")
 | 
				
			||||||
	fmt.Fprintf(os.Stderr, "  listen: mixed ss socks5 http redir tcptun udptun uottun dnstun\n")
 | 
						fmt.Fprintf(os.Stderr, "  listen: mixed ss socks5 http redir tcptun udptun uottun dnstun\n")
 | 
				
			||||||
	fmt.Fprintf(os.Stderr, "  forward: ss socks5 http ssr\n")
 | 
						fmt.Fprintf(os.Stderr, "  forward: ss socks5 http ssr\n")
 | 
				
			||||||
	fmt.Fprintf(os.Stderr, "\n")
 | 
						fmt.Fprintf(os.Stderr, "\n")
 | 
				
			||||||
 | 
					
 | 
				
			||||||
	fmt.Fprintf(os.Stderr, "SS schema:\n")
 | 
						fmt.Fprintf(os.Stderr, "SS scheme:\n")
 | 
				
			||||||
	fmt.Fprintf(os.Stderr, "  ss://method:pass@host:port\n")
 | 
						fmt.Fprintf(os.Stderr, "  ss://method:pass@host:port\n")
 | 
				
			||||||
	fmt.Fprintf(os.Stderr, "\n")
 | 
						fmt.Fprintf(os.Stderr, "\n")
 | 
				
			||||||
 | 
					
 | 
				
			||||||
@ -162,7 +162,7 @@ func usage() {
 | 
				
			|||||||
	fmt.Fprintf(os.Stderr, "  NOTE: chacha20-ietf-poly1305 = AEAD_CHACHA20_POLY1305\n")
 | 
						fmt.Fprintf(os.Stderr, "  NOTE: chacha20-ietf-poly1305 = AEAD_CHACHA20_POLY1305\n")
 | 
				
			||||||
	fmt.Fprintf(os.Stderr, "\n")
 | 
						fmt.Fprintf(os.Stderr, "\n")
 | 
				
			||||||
 | 
					
 | 
				
			||||||
	fmt.Fprintf(os.Stderr, "SSR schema:\n")
 | 
						fmt.Fprintf(os.Stderr, "SSR scheme:\n")
 | 
				
			||||||
	fmt.Fprintf(os.Stderr, "  ssr://method:pass@host:port?protocol=xxx&protocol_param=yyy&obfs=zzz&obfs_param=xyz\n")
 | 
						fmt.Fprintf(os.Stderr, "  ssr://method:pass@host:port?protocol=xxx&protocol_param=yyy&obfs=zzz&obfs_param=xyz\n")
 | 
				
			||||||
	fmt.Fprintf(os.Stderr, "\n")
 | 
						fmt.Fprintf(os.Stderr, "\n")
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
				
			|||||||
@ -52,5 +52,5 @@ func DialerFromURL(s string, dialer Dialer) (Dialer, error) {
 | 
				
			|||||||
		return NewSSR(addr, user, pass, u.RawQuery, dialer)
 | 
							return NewSSR(addr, user, pass, u.RawQuery, dialer)
 | 
				
			||||||
	}
 | 
						}
 | 
				
			||||||
 | 
					
 | 
				
			||||||
	return nil, errors.New("unknown schema '" + u.Scheme + "'")
 | 
						return nil, errors.New("unknown scheme '" + u.Scheme + "'")
 | 
				
			||||||
}
 | 
					}
 | 
				
			||||||
 | 
				
			|||||||
@ -61,5 +61,5 @@ func ServerFromURL(s string, dialer Dialer) (Server, error) {
 | 
				
			|||||||
		return NewUoTTun(d[0], d[1], dialer)
 | 
							return NewUoTTun(d[0], d[1], dialer)
 | 
				
			||||||
	}
 | 
						}
 | 
				
			||||||
 | 
					
 | 
				
			||||||
	return nil, errors.New("unknown schema '" + u.Scheme + "'")
 | 
						return nil, errors.New("unknown scheme '" + u.Scheme + "'")
 | 
				
			||||||
}
 | 
					}
 | 
				
			||||||
 | 
				
			|||||||
		Loading…
	
		Reference in New Issue
	
	Block a user