diff --git a/debian/control b/debian/control index a47e6d28..aa90e2d2 100644 --- a/debian/control +++ b/debian/control @@ -69,6 +69,8 @@ Depends: apg, ${misc:Depends}, ${shlibs:Depends}, +Suggests: + libcap2-bin Description: lightweight and secure socks5 proxy Shadowsocks-libev is a lightweight and secure socks5 proxy for embedded devices and low end boxes. diff --git a/debian/shadowsocks-libev.postinst b/debian/shadowsocks-libev.postinst index 58451ed8..a96cfad2 100755 --- a/debian/shadowsocks-libev.postinst +++ b/debian/shadowsocks-libev.postinst @@ -2,6 +2,13 @@ set -e +if [ -f /sbin/setcap ]; then + setcap cap_net_bind_service+ep /usr/bin/ss-local 2>/dev/null + setcap cap_net_bind_service+ep /usr/bin/ss-server 2>/dev/null + setcap cap_net_bind_service+ep /usr/bin/ss-tunnel 2>/dev/null + setcap cap_net_bind_service+ep /usr/bin/ss-redir 2>/dev/null +fi + case "$1" in configure|reconfigure) if [ ! -f /etc/shadowsocks-libev/config.json ]; then