summarylogtreecommitdiffstats
diff options
context:
space:
mode:
authorDct Mei2021-02-12 02:43:53 +0800
committerDct Mei2021-02-12 02:43:53 +0800
commit24823e5063bdd251a4000b1972f0e140ed99dcba (patch)
tree247cf22ebdb14a5e73757a68d3639662faf17480
downloadaur-24823e5063bdd251a4000b1972f0e140ed99dcba.tar.gz
feat: v4.1.2-1
-rw-r--r--.SRCINFO52
-rw-r--r--PKGBUILD95
-rw-r--r--geph4-binder.default11
-rw-r--r--geph4-binder.service15
-rw-r--r--geph4-bridge.default12
-rw-r--r--geph4-bridge.service15
-rw-r--r--geph4-client.default46
-rw-r--r--geph4-client.service16
-rw-r--r--geph4-exit.default13
-rw-r--r--geph4-exit.service15
-rw-r--r--geph4-vpn-helper.service13
11 files changed, 303 insertions, 0 deletions
diff --git a/.SRCINFO b/.SRCINFO
new file mode 100644
index 000000000000..a095eb5c9ab9
--- /dev/null
+++ b/.SRCINFO
@@ -0,0 +1,52 @@
+pkgbase = geph4
+ pkgdesc = A command-line Geph4 toolset
+ pkgver = 4.1.2
+ pkgrel = 1
+ url = https://github.com/geph-official/geph4
+ arch = x86_64
+ groups = geph4
+ license = GPL3
+ makedepends = rust
+ depends = gcc-libs
+ source = geph4-4.1.2.tar.gz::https://github.com/geph-official/geph4/archive/v4.1.2.tar.gz
+ source = geph4-binder.default
+ source = geph4-bridge.default
+ source = geph4-client.default
+ source = geph4-exit.default
+ source = geph4-binder.service
+ source = geph4-bridge.service
+ source = geph4-client.service
+ source = geph4-exit.service
+ source = geph4-vpn-helper.service
+ sha256sums = 7b2a9a7532cf1780b8b3c7a421ae6def63ad0948570813bd251dd50befb3ff77
+ sha256sums = 96e495d1f5d6cb61c7953c70035125febf0063fa0e8d0bb47bc314d326c93b55
+ sha256sums = 3def2cd4cce25ad38cadc3b20913d3c45df16b89d0903b7cd88da77d57f86938
+ sha256sums = 01b1ec9c4a5fe499d015cc5da62b46245f6bb9acc30afa5ec1f982650e331223
+ sha256sums = 2daf5117a98d4529225712cb9f4828f4f5269a591565745497df0eb10068ba2a
+ sha256sums = 7c8c2b2e2f24a45a2d216af90d1b370a25d1f4fe3501f341bf18b7b68a7fa93a
+ sha256sums = 08bcd5c7d8a44f7ee05315ce745658a59bf48f0c5475b231c75120858ddf39ef
+ sha256sums = 3599ecabf51e9405eb3afdc0c653060e8da9d6cbe83a4f4ce14c46017f520022
+ sha256sums = 04b096c9e99f655c7f7e9e13082be2a487e255c2366471ad9c9e3216be389774
+ sha256sums = 806ed9538c92e659e2c0f70f8f5620f37e2f7df15b39a9bdea301b65c5cbcf5f
+
+pkgname = geph4-binder
+ conflicts = geph4-binder-git
+ backup = etc/default/geph4-binder
+
+pkgname = geph4-bridge
+ conflicts = geph4-bridge-git
+ backup = etc/default/geph4-bridge
+
+pkgname = geph4-client
+ conflicts = geph4-client-git
+ backup = etc/default/geph4-client
+
+pkgname = geph4-exit
+ conflicts = geph4-exit-git
+ backup = etc/default/geph4-exit
+
+pkgname = geph4-vpn-helper
+ depends = gcc-libs
+ depends = geph4-client
+ conflicts = geph4-vpn-helper-git
+
diff --git a/PKGBUILD b/PKGBUILD
new file mode 100644
index 000000000000..9d16606e9689
--- /dev/null
+++ b/PKGBUILD
@@ -0,0 +1,95 @@
+# Maintainer: Dct Mei <dctxmei@yandex.com>
+
+pkgbase=geph4
+pkgname=('geph4-binder'
+ 'geph4-bridge'
+ 'geph4-client'
+ 'geph4-exit'
+ 'geph4-vpn-helper')
+pkgver=4.1.2
+pkgrel=1
+pkgdesc="A command-line Geph4 toolset"
+arch=('x86_64')
+url="https://github.com/geph-official/geph4"
+license=('GPL3')
+groups=('geph4')
+depends=('gcc-libs')
+makedepends=('rust')
+source=("${pkgbase}-${pkgver}.tar.gz::${url}/archive/v${pkgver}.tar.gz"
+ "geph4-binder.default"
+ "geph4-bridge.default"
+ "geph4-client.default"
+ "geph4-exit.default"
+ "geph4-binder.service"
+ "geph4-bridge.service"
+ "geph4-client.service"
+ "geph4-exit.service"
+ "geph4-vpn-helper.service")
+sha256sums=('7b2a9a7532cf1780b8b3c7a421ae6def63ad0948570813bd251dd50befb3ff77'
+ '96e495d1f5d6cb61c7953c70035125febf0063fa0e8d0bb47bc314d326c93b55'
+ '3def2cd4cce25ad38cadc3b20913d3c45df16b89d0903b7cd88da77d57f86938'
+ '01b1ec9c4a5fe499d015cc5da62b46245f6bb9acc30afa5ec1f982650e331223'
+ '2daf5117a98d4529225712cb9f4828f4f5269a591565745497df0eb10068ba2a'
+ '7c8c2b2e2f24a45a2d216af90d1b370a25d1f4fe3501f341bf18b7b68a7fa93a'
+ '08bcd5c7d8a44f7ee05315ce745658a59bf48f0c5475b231c75120858ddf39ef'
+ '3599ecabf51e9405eb3afdc0c653060e8da9d6cbe83a4f4ce14c46017f520022'
+ '04b096c9e99f655c7f7e9e13082be2a487e255c2366471ad9c9e3216be389774'
+ '806ed9538c92e659e2c0f70f8f5620f37e2f7df15b39a9bdea301b65c5cbcf5f')
+
+build() {
+ cd "${srcdir}"/"${pkgbase}-${pkgver}"/
+ cargo build --release --manifest-path=geph4-binder/Cargo.toml
+ cargo build --release --manifest-path=geph4-bridge/Cargo.toml
+ cargo build --release --manifest-path=geph4-client/Cargo.toml
+ cargo build --release --manifest-path=geph4-exit/Cargo.toml
+ cargo build --release --manifest-path=geph4-vpn-helper/Cargo.toml
+}
+
+package_geph4-binder() {
+ conflicts=('geph4-binder-git')
+ backup=('etc/default/geph4-binder')
+ cd "${srcdir}"/"${pkgbase}-${pkgver}"/
+ install -Dm 644 LICENSE.md "${pkgdir}"/usr/share/licenses/geph4-binder/LICENSE
+ install -Dm 755 target/release/geph4-binder -t "${pkgdir}"/usr/bin/
+ install -Dm 644 "${srcdir}"/geph4-binder.default "${pkgdir}"/etc/default/geph4-binder
+ install -Dm 644 "${srcdir}"/geph4-binder.service -t "${pkgdir}"/usr/lib/systemd/system/
+}
+
+package_geph4-bridge() {
+ conflicts=('geph4-bridge-git')
+ backup=('etc/default/geph4-bridge')
+ cd "${srcdir}"/"${pkgbase}-${pkgver}"/
+ install -Dm 644 LICENSE.md "${pkgdir}"/usr/share/licenses/geph4-bridge/LICENSE
+ install -Dm 755 target/release/geph4-bridge -t "${pkgdir}"/usr/bin/
+ install -Dm 644 "${srcdir}"/geph4-bridge.default "${pkgdir}"/etc/default/geph4-bridge
+ install -Dm 644 "${srcdir}"/geph4-bridge.service -t "${pkgdir}"/usr/lib/systemd/system/
+}
+
+package_geph4-client() {
+ conflicts=('geph4-client-git')
+ backup=('etc/default/geph4-client')
+ cd "${srcdir}"/"${pkgbase}-${pkgver}"/
+ install -Dm 644 LICENSE.md "${pkgdir}"/usr/share/licenses/geph4-client/LICENSE
+ install -Dm 755 target/release/geph4-client -t "${pkgdir}"/usr/bin/
+ install -Dm 644 "${srcdir}"/geph4-client.default "${pkgdir}"/etc/default/geph4-client
+ install -Dm 644 "${srcdir}"/geph4-client.service -t "${pkgdir}"/usr/lib/systemd/system/
+}
+
+package_geph4-exit() {
+ conflicts=('geph4-exit-git')
+ backup=('etc/default/geph4-exit')
+ cd "${srcdir}"/"${pkgbase}-${pkgver}"/
+ install -Dm 644 LICENSE.md "${pkgdir}"/usr/share/licenses/geph4-exit/LICENSE
+ install -Dm 755 target/release/geph4-exit -t "${pkgdir}"/usr/bin/
+ install -Dm 644 "${srcdir}"/geph4-exit.default "${pkgdir}"/etc/default/geph4-exit
+ install -Dm 644 "${srcdir}"/geph4-exit.service -t "${pkgdir}"/usr/lib/systemd/system/
+}
+
+package_geph4-vpn-helper() {
+ depends+=('geph4-client')
+ conflicts=('geph4-vpn-helper-git')
+ cd "${srcdir}"/"${pkgbase}-${pkgver}"/
+ install -Dm 644 LICENSE.md "${pkgdir}"/usr/share/licenses/geph4-vpn-helper/LICENSE
+ install -Dm 755 target/release/geph4-vpn-helper -t "${pkgdir}"/usr/bin/
+ install -Dm 644 "${srcdir}"/geph4-vpn-helper.service -t "${pkgdir}"/usr/lib/systemd/system/
+}
diff --git a/geph4-binder.default b/geph4-binder.default
new file mode 100644
index 000000000000..fa7f2c901348
--- /dev/null
+++ b/geph4-binder.default
@@ -0,0 +1,11 @@
+# The default settings for Geph4 binder Service
+
+# Fill in some options here, you can run
+# `geph4-binder -h` to view:
+# --captcha-endpoint: captcha service (default: https://single-verve-156821.ew.r.appspot.com)
+# --listen-http: HTTP listening port (default: 127.0.0.1:18080)
+OPTIONS=""
+# Please enter the database you want to use:
+DATABASE=
+# Please enter the database CA file you want to use:
+DATABASE_CA_CERT=
diff --git a/geph4-binder.service b/geph4-binder.service
new file mode 100644
index 000000000000..c05f24d255b6
--- /dev/null
+++ b/geph4-binder.service
@@ -0,0 +1,15 @@
+[Unit]
+Description=Geph4 binder Service
+After=network.target nss-lookup.target
+
+[Service]
+DynamicUser=true
+CapabilityBoundingSet=CAP_NET_BIND_SERVICE
+AmbientCapabilities=CAP_NET_BIND_SERVICE
+NoNewPrivileges=true
+EnvironmentFile=/etc/default/geph4-binder
+ExecStart=/usr/bin/geph4-binder $OPTIONS --database $DATABASE --database-ca-cert $DATABASE_CA_CERT
+Restart=on-abort
+
+[Install]
+WantedBy=multi-user.target
diff --git a/geph4-bridge.default b/geph4-bridge.default
new file mode 100644
index 000000000000..528820b7d2a5
--- /dev/null
+++ b/geph4-bridge.default
@@ -0,0 +1,12 @@
+# The default settings for Geph4 bridge Service
+
+# Fill in some options here, you can run
+# `geph4-bridge -h` to view:
+# --binder-http: HTTP(S) address of the binder (default:
+# http://binder-v4.geph.io:8964)
+# --binder-master-pk: x25519 master key of the binder (default:
+# 124526f4e692b589511369687498cce57492bf4da20f8d26019c1cc0c80b6e4b)
+# --bridge-group: bridge group (default: other)
+OPTIONS=""
+# Please enter the bridge secret you want to use:
+BRIDGE_SECRET=
diff --git a/geph4-bridge.service b/geph4-bridge.service
new file mode 100644
index 000000000000..026de5f321a9
--- /dev/null
+++ b/geph4-bridge.service
@@ -0,0 +1,15 @@
+[Unit]
+Description=Geph4 bridge Service
+After=network.target nss-lookup.target
+
+[Service]
+DynamicUser=true
+CapabilityBoundingSet=CAP_NET_BIND_SERVICE
+AmbientCapabilities=CAP_NET_BIND_SERVICE
+NoNewPrivileges=true
+EnvironmentFile=/etc/default/geph4-bridge
+ExecStart=/usr/bin/geph4-bridge $OPTIONS --bridge-secret $BRIDGE_SECRET
+Restart=on-abort
+
+[Install]
+WantedBy=multi-user.target
diff --git a/geph4-client.default b/geph4-client.default
new file mode 100644
index 000000000000..d1115110c2c8
--- /dev/null
+++ b/geph4-client.default
@@ -0,0 +1,46 @@
+# The default settings for Geph4 client Service
+
+# Fill in the subcommand here, you can run
+# `geph4-client -h` to view:
+# binder-proxy | connect | sync
+SUBCOMMAND=connect
+# Fill in some flags here, you can run
+# `geph4-client connect -h` to view:
+# --stdio-vpn: whether or not to wait for VPN commands on stdio
+# --use-bridges: whether or not to use bridges
+FLAGS="--use-bridges"
+# Fill in some options here, you can run
+# `geph4-client connect -h` to view:
+# --credential-cache:
+# /var/cache/geph4-client/geph4-credentials.db
+# --dns-listen:
+# where to listen for proxied DNS requests
+# --exit-server:
+# ca-mtl-01.exits.geph.io
+# fi-hel-01.exits.geph.io
+# sg-sgp-02.exits.geph.io
+# sosistab-jp-test.labooyah.be
+# tw-rmq-01.exits.geph.io
+# us-hio-01.exits.geph.io (default)
+# --http-listen:
+# where to listen for HTTP proxy connections (default: 127.0.0.1:9910)
+# --nettest-name:
+# a name for this test instance
+# --nettest-server:
+# an endpoint to send test results
+# --socks5-listen:
+# where to listen for SOCKS5 connections (default: 127.0.0.1:9909)
+# --stats-listen:
+# where to listen for REST-based local connections (default: 127.0.0.1:9809)
+OPTIONS="--exit-server us-hio-01.exits.geph.io"
+# Please enter the password you want to use:
+PASSWORD=password
+# Please enter the username you want to use:
+USERNAME=username
+
+# geph4-vpn-helper
+VPN_SUBCOMMAND=connect
+VPN_FLAGS="--stdio-vpn --use-bridges"
+VPN_OPTIONS="--dns-listen 127.0.0.1:15353 --exit-server us-hio-01.exits.geph.io"
+VPN_PASSWORD=password
+VPN_USERNAME=username
diff --git a/geph4-client.service b/geph4-client.service
new file mode 100644
index 000000000000..c57caa70b156
--- /dev/null
+++ b/geph4-client.service
@@ -0,0 +1,16 @@
+[Unit]
+Description=Geph4 client Service
+After=network.target nss-lookup.target
+
+[Service]
+DynamicUser=true
+CacheDirectory=geph4-client
+CapabilityBoundingSet=CAP_NET_BIND_SERVICE
+AmbientCapabilities=CAP_NET_BIND_SERVICE
+NoNewPrivileges=true
+EnvironmentFile=/etc/default/geph4-client
+ExecStart=/usr/bin/geph4-client $SUBCOMMAND $FLAGS $OPTIONS --credential-cache /var/cache/geph4-client/geph4-credentials.db --password $PASSWORD --username $USERNAME
+Restart=on-abort
+
+[Install]
+WantedBy=multi-user.target
diff --git a/geph4-exit.default b/geph4-exit.default
new file mode 100644
index 000000000000..d59290aa2454
--- /dev/null
+++ b/geph4-exit.default
@@ -0,0 +1,13 @@
+# The default settings for Geph4 exit Service
+
+# Fill in some flags here, you can run
+# `geph4-exit -h` to view:
+# --port-whitelist: whether or not to use port whitelist
+FLAGS="--port-whitelist"
+# Fill in some options here, you can run
+# `geph4-exit -h` to view:
+OPTIONS=
+# Please enter the bridge secret you want to use:
+BRIDGE_SECRET=
+# Please enter the hostname of this exit you want to use:
+EXIT_HOSTNAME=
diff --git a/geph4-exit.service b/geph4-exit.service
new file mode 100644
index 000000000000..f07f433631a9
--- /dev/null
+++ b/geph4-exit.service
@@ -0,0 +1,15 @@
+[Unit]
+Description=Geph4 exit Service
+After=network.target nss-lookup.target
+
+[Service]
+DynamicUser=true
+CapabilityBoundingSet=CAP_NET_BIND_SERVICE
+AmbientCapabilities=CAP_NET_BIND_SERVICE
+NoNewPrivileges=true
+EnvironmentFile=/etc/default/geph4-exit
+ExecStart=/usr/bin/geph4-exit $FLAGS $OPTIONS --bridge-secret $BRIDGE_SECRET --exit-hostname $EXIT_HOSTNAME
+Restart=on-abort
+
+[Install]
+WantedBy=multi-user.target
diff --git a/geph4-vpn-helper.service b/geph4-vpn-helper.service
new file mode 100644
index 000000000000..4034b359e8f3
--- /dev/null
+++ b/geph4-vpn-helper.service
@@ -0,0 +1,13 @@
+[Unit]
+Description=Geph4 VPN Service
+After=network.target nss-lookup.target
+Conflicts=geph4-client.service
+
+[Service]
+EnvironmentFile=/etc/default/geph4-client
+ExecStart=/usr/bin/geph4-vpn-helper /usr/bin/geph4-client $VPN_SUBCOMMAND $VPN_FLAGS $VPN_OPTIONS --credential-cache /tmp/geph4-credentials.db --password $VPN_PASSWORD --username $VPN_USERNAME
+ExecStop=/usr/bin/geph4-vpn-helper
+Restart=on-abort
+
+[Install]
+WantedBy=multi-user.target