fix: being able to use empty DNS_ADDRS with docker image - #2866
Conversation
|
I think the problem we have here is that, the arguments passed to Another issue we would possibly face is the environment variable can somehow be code-injected. For example, executing the command below. docker run -it --rm \
-e SERVER_ADDR='0.0.0.0 -p 8080' \
shadowsocks/shadowsocks-libev:v3.3.5The main process would be: ss-server
-s
0.0.0.0
-p
8080
-p
8388
-k
PASSWORD
-m
aes-256-gcm
-t
300
-d
8.8.8.8,8.8.4.4
-uA quick fix would be making every argument be double-quoted. But I'm not sure whether passing empty string to |
|
Just a precision for the reviewers, the goal of this PR is to be able to use the container's default DNS server, meaning the one defined in
Like @predatorray said, it might work with just using |
|
@madeye I am wondering when this change will be released as a stable image so that my next helm chart release can use? |
Hi! First of all, thank you for maintaining this amazing tool.
Issue
Overriding the image's default
$DNS_ADDRSwith an empty string still adds the-doption to the command.Solution
Make sure that we only add the
-doption if$DNS_ADDRSis defined and not empty.