Commit Graph
919 Commits
Author SHA1 Message Date
Max Lv f308ddeda6 Fix #1522 2017-06-08 15:39:18 +08:00
Xiandong e2f717e9fb Add list API to list service ports (#1521)
* Fix #1518 config file with wrong json format

Removing trailing "," to make the configuration file compliant with JSON specification

* Remove extra "," in json file

* server_port should be integer instead of string 

server_port in generated json configuration file should be integer instead of string

* Add list active service ports feature

A new management API has been added to list all active service ports.

* Make list API output JSON compliant 

In the following format:
[
{ "server_port":"8388","password":"password"},
...
]
Note that server_port value is string instead of integer for easy display on the console.

* Make safe room for the new list entry

"\n\t{\"server_port\":\"%s\",\"password\":\"%s\"}," 
Reserve 50 char spaces for the extra characters in the above.
2017-06-07 22:10:52 -05:00
Xiandong 195a961e97 server_port in json file should be integer (#1520)
* Fix #1518 config file with wrong json format

Removing trailing "," to make the configuration file compliant with JSON specification

* Remove extra "," in json file

* server_port should be integer instead of string 

server_port in generated json configuration file should be integer instead of string
2017-06-06 04:27:22 -05:00
Xiandong b9085c2e32 Remove extra "," in json file 2017-06-06 02:55:50 -05:00
Xiandong ae156c6aeb Fix #1518 config file with wrong json format
Removing trailing "," to make the configuration file compliant with JSON specification
2017-06-06 02:55:50 -05:00
Vladimir Olteanu 0b2dce5fe9 ss-redir: fix memleak in remote_send_cb 2017-06-05 19:09:38 -05:00
Max Lv 4b1550626f Update specs 2017-05-27 09:34:55 +08:00
Aaron LI e65b3b1505 Move <sys/socket.h> inclusion to fix build on DFlyBSD
The ``<sys/socket.h>`` header should be included in ``src/netutils.h``
before the usage of ``struct sockaddr_storage``, otherwise build failed
with errors such as:

```
In file included from udprelay.c:53:0:
netutils.h:68:22: error: 'struct sockaddr_storage' declared inside parameter list [-Werror]
                      int ipv6first);
                      ^
netutils.h:68:22: error: its scope is only this definition or declaration, which is probably not what you want [-Werror]
```

Tested on DragonFly BSD 4.9-development and Debian Linux testing.
2017-05-24 20:00:53 +08:00
Lucas BEE 44feddd4f6 ss-redir: Add option to disable SNI feature
Add an option 'disable_sni' in the config file to allow clients running
ss-redir to disable the HTTP/SNI feature
2017-05-23 06:23:53 +08:00
Max Lv b7bb4358e1 Clean up 2017-05-22 17:11:59 +08:00
Max Lv b7bdb16338 Fix #1502 2017-05-19 12:27:19 +08:00
Mygod 72622a3e3d Use standard __ANDROID__ preprocessor macro 2017-05-17 07:08:41 +08:00
Max Lv 33fe5adc19 Remove debug info 2017-05-06 07:30:30 +08:00
Max Lv 0313c8bcc6 Fix stat_update_cb for UDP packets 2017-05-06 07:24:12 +08:00
Max Lv 3f0d39aee6 Fix #1491 2017-05-03 15:36:58 +08:00
Zou Yong eb30a3d161 Fix losing data issue of SALSA20 cipher
If nonce received in more than one packet under some network condition, the salsa20 cipher decryption will lose cipher->nonce_len - left_len bytes of data.
2017-04-30 21:01:15 +08:00
Zou Yong 0559d8ce2e Fix decryption failed issue by nonce overwrite
If the first packet is less than nonce length, then the chunk nonce data will be overwrote by next packet and result in decrypt failed
2017-04-28 19:35:42 +08:00
Vladimir Olteanu c6bc21bc1a Make use of struct when parsing method select requests 2017-04-27 07:45:26 +08:00
Vladimir Olteanu 8065d2f0cf Make SOCKS5 fields unsigned 2017-04-27 07:45:26 +08:00
Daniel b918fd7a77 aviod twice resolving when domain has bypassed ip 2017-04-25 07:13:27 +08:00
Daniel 81006d4690 resolve when acl_match_host failed 2017-04-23 16:46:23 +08:00
Daniel 54acbba2a7 resolve domain so we can bypass domain with geoip 2017-04-23 16:46:23 +08:00
zzzdong 9db9df5f4d Add a option in CMakeLists.txt for switch build with static libraries or not 2017-04-23 07:16:22 +08:00
Max Lv d252da8d83 Fix another potential out of bound access. #1465 2017-04-19 12:46:59 +08:00
Max Lv 9ee82a9a89 Fix a potential out of bound access. #1465 2017-04-19 12:16:41 +08:00
V.E.O 0de794f0db avoid blocking requests from local plugins server
When ss-server wrapped in a plugin server, every peer_name are 127.0.0.1, black list seems not working.
If large requests sent from the plugin server, ss-server would in DoS.
Maybe when in plugin mode, disable black list in ss-server and move it to plugin server?
2017-04-14 19:02:48 +08:00
Max Lv 490b9cbcdc Fix #1430 2017-04-05 15:12:37 +08:00
Max Lv 2ee9fc6417 Refine IPV6_RECVORIGDSTADDR 2017-03-27 13:29:17 +08:00
Max Lv 2867252303 Allow to receive IPv6 address. #1368 2017-03-27 13:16:14 +08:00
Max Lv 5b2fb72b14 Refine interface 2017-03-27 13:09:29 +08:00
Paizhuo.Chen 7ffaa9f33e fix shadowsocks/shadowsocks-libev#1408 2017-03-26 22:12:23 +08:00
wener 6be1761efa Install shadowsocks-libev libs only, install shadowsocks.h header 2017-03-26 21:20:33 +08:00
wener 619ae880c9 Recommend to use shared binary 2017-03-26 21:20:33 +08:00
wener 1f91fbc69a 1. Fix incorrect install path.
2. set CMP0048 to OLD to prevent warning
2017-03-26 21:20:33 +08:00
wener 88ef344262 Add document build 2017-03-26 21:20:33 +08:00
Paizhuo.Chen 233cf15834 Add method, fast_open, mode, plugin options to ss-manager 2017-03-25 21:39:25 +08:00
Max Lv 7101086d47 Output the entropy hints as info 2017-03-22 11:08:48 +08:00
Max Lv e2c24d6ac8 Refine TFO in ss-redir 2017-03-20 22:59:14 +08:00
Max Lv e4884b5f21 Fix IPV6_RECVORIGDSTADDR. #1368 2017-03-20 09:05:12 +08:00
Syrone Wong 836d2f3859 fix header
Signed-off-by: Syrone Wong <wong.syrone@gmail.com>
2017-03-19 17:37:07 +08:00
Max Lv 087bfe7f91 Stop the timer properly 2017-03-19 17:19:49 +08:00
Syrone Wong 1e91b6a1f6 On Linux, warn when we are running low on entropy
Based on https://github.com/jedisct1/dnscrypt-proxy/commit/a255d2908305739b54dafb01ae0285f6016869ab

Signed-off-by: Syrone Wong <wong.syrone@gmail.com>
2017-03-19 17:16:19 +08:00
Syrone Wong b74108db09 drop redundant sodium_init() call
It is done in crypto.c

Signed-off-by: Syrone Wong <wong.syrone@gmail.com>
2017-03-19 17:16:19 +08:00
Max Lv cfe830405f Fix #1376 2017-03-18 16:14:03 +08:00
Max Lv fa82628dd9 Add delayed connect to ss-local as well 2017-03-17 09:54:20 +08:00
Max Lv fb53630b20 Fix some building issues 2017-03-16 14:04:05 +08:00
Max Lv 88007b403e Add delayed connecting in ss-tunnel 2017-03-16 13:06:12 +08:00
Felix Yan 3b9ac7e81e Use system libbloom on USE_SYSTEM_SHARED_LIB 2017-03-16 13:06:12 +08:00
zhou0 74167f3688 restore version_info to 2.0.0 2017-03-16 13:06:12 +08:00
zhou0 13842ea566 fix wrong version_info 2017-03-16 13:06:12 +08:00