You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

123 lines
3.4 KiB

8 years ago
  1. .ig
  2. . manual page for shadowsocks-libev
  3. .
  4. . Copyright (c) 2012-2016, by: Max Lv
  5. . All rights reserved.
  6. .
  7. . Permission is granted to copy, distribute and/or modify this document
  8. . under the terms of the GNU Free Documentation License, Version 1.1 or
  9. . any later version published by the Free Software Foundation;
  10. . with no Front-Cover Texts, no Back-Cover Texts, and with the following
  11. . Invariant Sections (and any sub-sections therein):
  12. . all .ig sections, including this one
  13. . STUPID TRICKS Sampler
  14. . AUTHOR
  15. .
  16. . A copy of the Free Documentation License is included in the section
  17. . entitled "GNU Free Documentation License".
  18. .
  19. ..
  20. \# - these two are for chuckles, makes great grammar
  21. .ds Lo \fBss-local\fR
  22. .ds Re \fBss-redir\fR
  23. .ds Se \fBss-server\fR
  24. .ds Tu \fBss-tunnel\fR
  25. .ds Ma \fBss-manager\fR
  26. .ds Na \fBss-nat\fR
  27. .ds Me \fBShadowsocks-libev\fR
  28. .
  29. .TH "SS-NAT" "1" "May 26, 2016" "SHADOWSOCKS-LIBEV"
  30. .SH NAME
  31. ss-nat \- helper script to setup NAT rules for transparent proxy
  32. .SH SYNOPSIS
  33. \*(Na
  34. [\fB\-ouUfh\fR]
  35. [\fB\-s\fR \fIserver_ip\fR] [\fB\-S\fR \fIserver_ip\fR] [\fB\-l\fR \fIlocal_port\fR]
  36. [\fB\-L\fR \fIlocal_port\fR] [\fB\-i\fR \fIip_list_file\fR] [\fB\-a\fR \fIlan_ips\fR]
  37. [\fB\-b\fR \fIwan_ips\fR] [\fB\-w\fR \fIwan_ips\fR] [\fB\-e\fR \fIextra_options\fR]
  38. .SH DESCRIPTION
  39. \*(Me is a lightweight and secure socks5 proxy. It is a port of the original
  40. shadowsocks created by clowwindy. \*(Me is written in pure C and takes advantage
  41. of \fBlibev\fP to achieve both high performance and low resource consumption.
  42. .PP
  43. \*(Na(1) sets up NAT rules for \*(Re(1) to provide traffic redirection. It
  44. requires netfilter's NAT module and \fBiptables\fR(8). For more information,
  45. check out \fBshadowsocks-libev\fR(8) and the following \fBEXAMPLE\fR section.
  46. .SH OPTIONS
  47. .TP
  48. .B \-s \fIserver_ip\fP
  49. IP address of shadowsocks remote server
  50. .TP
  51. .B \-l \fIlocal_port\fP
  52. Port number of shadowsocks local server
  53. .TP
  54. .B \-S \fIserver_ip\fP
  55. IP address of shadowsocks remote UDP server
  56. .TP
  57. .B \-L \fIlocal_port\fP
  58. Port number of shadowsocks local UDP server
  59. .TP
  60. .B \-i \fIip_list_file\fP
  61. a file content is bypassed ip list
  62. .TP
  63. .B \-a \fIlan_ips\fP
  64. LAN IP of access control, need a prefix to define access control mode
  65. .TP
  66. .B \-b \fIwan_ips\fP
  67. WAN IP of will be bypassed
  68. .TP
  69. .B \-w \fIwan_ips\fP
  70. WAN IP of will be forwarded
  71. .TP
  72. .B \-e \fIextra_options\fP
  73. Extra options for iptables
  74. .TP
  75. .B \-o
  76. Apply the rules to the OUTPUT chain
  77. .TP
  78. .B \-u
  79. Enable udprelay mode, TPROXY is required
  80. .TP
  81. .B \-U
  82. Enable udprelay mode, using different IP and ports for TCP and UDP
  83. .TP
  84. .B \-f
  85. Flush the rules
  86. .TP
  87. .B \-h
  88. Show this help message and exit
  89. .TP
  90. .SH EXAMPLE
  91. \*(Na requires \fBiptables\fR(8). Here is an example:
  92. .nf
  93. # Enable NAT rules for shadowsocks,
  94. # with both TCP and UDP redirection enabled,
  95. # and applied for both PREROUTING and OUTPUT chains
  96. root@Wrt:~# ss-nat -s 192.168.1.100 -l 1080 -u -o
  97. # Disable and flush all NAT rules for shadowsocks
  98. root@Wrt:~# ss-nat -f
  99. .fi
  100. .SH SEE ALSO
  101. .BR \*(Lo (1),
  102. .BR \*(Se (1),
  103. .BR \*(Tu (1),
  104. .BR \*(Ma (1),
  105. .BR shadowsocks-libev (8),
  106. .BR iptables (8),
  107. /etc/shadowsocks-libev/config.json
  108. .br
  109. .SH AUTHOR
  110. shadowsocks was created by clowwindy <clowwindy42@gmail.com> and
  111. shadowsocks-libev was maintained by Max Lv <max.c.lv@gmail.com> and Linus Yang
  112. <laokongzi@gmail.com>.
  113. .PP
  114. This manual page was written by Max Lv <max.c.lv@gmail.com>.
  115. .PP
  116. The manual pages were rearranged by hosiet <073plan@gmail.com>.