Compare commits

...

10 Commits

Author SHA1 Message Date
Fabian Peter Hammerle db4522974f fix invalid torrc path
introduced in 60bad462e4 (v1.1.0)

> [notice] Configuration file "/etc/tor/torrc" not present, using reasonable defaults.
2020-03-21 21:15:08 +01:00
Fabian Peter Hammerle cf5401be4e release v1.1.0 2020-03-21 21:04:32 +01:00
Fabian Peter Hammerle d2d2f4aaf7 reduce verbosity of entrypoint 2020-03-21 21:03:09 +01:00
Fabian Peter Hammerle 60bad462e4 change SocksTimeout by setting $SOCKS_TIMEOUT_SECONDS 2020-03-21 21:00:07 +01:00
Fabian Peter Hammerle 140ebf8e2e upgrade tor v0.4.1.7->0.4.1.9 (fixes CVE-2020-10592 & CVE-2020-10593) 2020-03-21 20:19:47 +01:00
Fabian Peter Hammerle e49b89c9d7 changelog: fix Unreleased diff link 2020-02-22 11:16:15 +01:00
Fabian Peter Hammerle d6f5c7c769 upgrade alpine 3.10->3.11 to upgrade tor 0.4.1.6->0.4.1.7 2020-02-22 11:07:00 +01:00
Fabian Peter Hammerle fbe6e32e39 readme: fix tags url 2020-02-22 10:49:49 +01:00
Fabian Peter Hammerle d76b221102 readme: fix sample curl command to no longer leak dns request 2020-02-21 10:43:35 +01:00
Fabian Peter Hammerle d75d6c74a5 readme: added iptables isolate cmd 2019-10-12 12:34:36 +02:00
6 changed files with 57 additions and 13 deletions
+17 -1
View File
@@ -4,9 +4,25 @@ All notable changes to this project will be documented in this file.
The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/),
and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).
## [Unreleased]
## [1.1.1] - 2020-03-21
### Fixed
- Fix invalid torrc path
## [1.1.0] - 2020-03-21
### Added
- Change `SocksTimeout` option by setting `$SOCKS_TIMEOUT_SECONDS`
### Fixed
- upgrade default tor version: 0.4.1.6 -> 0.4.1.9
(non-breaking, fixes only, https://gitweb.torproject.org/tor.git/plain/ChangeLog)
## [1.0.0] - 2019-10-12
### Added
- Tor Socks5 & DNS proxy
[Unreleased]: https://github.com/fphammerle/docker-tor-proxy/compare/1.0.0...HEAD
[Unreleased]: https://github.com/fphammerle/docker-tor-proxy/compare/v1.1.1...HEAD
[1.1.1]: https://github.com/fphammerle/docker-tor-proxy/compare/1.0.0...v1.1.1
[1.1.0]: https://github.com/fphammerle/docker-tor-proxy/compare/1.0.0...v1.1.0
[1.0.0]: https://github.com/fphammerle/docker-tor-proxy/releases/tag/1.0.0
+11 -10
View File
@@ -1,24 +1,25 @@
FROM alpine:3.10
FROM alpine:3.11
ARG CURL_PACKAGE_VERSION=7.66.0-r0
ARG BIND_TOOLS_PACKAGE_VERSION=9.14.3-r0
ARG TOR_PACKAGE_VERSION=0.4.1.6-r0
ARG TOR_PACKAGE_REPOSITORY=http://dl-cdn.alpinelinux.org/alpine/edge/community
ARG CURL_PACKAGE_VERSION=7.67.0-r0
ARG BIND_TOOLS_PACKAGE_VERSION=9.14.8-r5
ARG TOR_PACKAGE_VERSION=0.4.1.9-r0
RUN adduser -S onion \
&& apk add --no-cache \
curl=$CURL_PACKAGE_VERSION \
bind-tools=$BIND_TOOLS_PACKAGE_VERSION `# dig` \
&& apk add --no-cache --repository $TOR_PACKAGE_REPOSITORY \
tor=$TOR_PACKAGE_VERSION
# RUN apk add --no-cache man less \
# && apk add --no-cache tor-doc=$TOR_PACKAGE_VERSION \
# --repository $TOR_PACKAGE_REPOSITORY
# RUN apk add --no-cache \
# less \
# man \
# tor-doc=$TOR_PACKAGE_VERSION
# ENV PAGER=less
EXPOSE 9050/tcp
EXPOSE 53/udp
COPY torrc /etc/tor/torrc
COPY torrc.template entrypoint.sh /
ENV SOCKS_TIMEOUT_SECONDS=
ENTRYPOINT ["/entrypoint.sh"]
CMD ["tor"]
+12 -2
View File
@@ -2,7 +2,7 @@
docker hub: https://hub.docker.com/r/fphammerle/tor-proxy
signed tags: https://github.com/fphammerle/tor-proxy/tags
signed tags: https://github.com/fphammerle/docker-tor-proxy/tags
```sh
$ docker run --rm --name tor-proxy \
@@ -18,7 +18,7 @@ $ docker-compose up
test proxies:
```sh
$ curl --socks5 localhost:9050 ipinfo.io
$ curl --proxy socks5h://localhost:9050 ipinfo.io
$ torsocks wget -O - ipinfo.io
$ torsocks lynx -dump https://check.torproject.org/
$ dig @localhost fabian.hammerle.me
@@ -26,3 +26,13 @@ $ ssh -o 'ProxyCommand nc -x localhost:9050 -v %h %p' abcdefghi.onion
# no anonymity!
$ chromium-browser --proxy-server=socks5://localhost:9050 ipinfo.io
```
isolate:
```sh
iptables -A OUTPUT ! -o lo -j REJECT --reject-with icmp-admin-prohibited
```
change `SocksTimeout` option:
```sh
$ docker run -e SOCKS_TIMEOUT_SECONDS=60
```
+2
View File
@@ -7,6 +7,8 @@ services:
ports:
- '127.0.0.1:9050:9050/tcp'
- '127.0.0.1:53:53/udp'
environment:
SOCKS_TIMEOUT_SECONDS: 240
security_opt: ['no-new-privileges']
restart: unless-stopped
cpus: 0.5
Executable
+13
View File
@@ -0,0 +1,13 @@
#!/bin/sh
set -e
# default: 120 sec
# https://github.com/torproject/tor/blob/tor-0.4.1.7/src/core/or/connection_edge.c#L1099
if [ -z "$SOCKS_TIMEOUT_SECONDS" ]; then
sed -e '/{socks_timeout_seconds}/d' /torrc.template > /etc/tor/torrc
else
sed -e "s/{socks_timeout_seconds}/$SOCKS_TIMEOUT_SECONDS/" /torrc.template > /etc/tor/torrc
fi
exec "$@"
+2
View File
@@ -3,5 +3,7 @@ Log notice stdout
SocksPort 0.0.0.0:9050
DNSPort 0.0.0.0:53
SocksTimeout {socks_timeout_seconds}
# try to
HardwareAccel 1