bettercap: add package

This commit is contained in:
Henrik Grimler 2019-07-19 22:07:01 +02:00 committed by Yaksh Bariya
parent 7f27beffdd
commit 1ecf76ab95
No known key found for this signature in database
GPG Key ID: F7486BA7D3D27581
2 changed files with 56 additions and 0 deletions

View File

@ -0,0 +1,20 @@
TERMUX_PKG_HOMEPAGE=https://www.bettercap.org
TERMUX_PKG_DESCRIPTION="The Swiss Army knife for 802.11, BLE and Ethernet networks reconnaissance and MITM attacks"
TERMUX_PKG_LICENSE="GPL-3.0"
TERMUX_PKG_VERSION=2.24.1
TERMUX_PKG_SRCURL=https://github.com/bettercap/bettercap/archive/v${TERMUX_PKG_VERSION}.tar.gz
TERMUX_PKG_SHA256=590cef2b2b24fd9f67c57c8cb19ab8ff08b11d43bfc23b468013ddad907bb8b8
TERMUX_PKG_DEPENDS="libpcap, libusb"
TERMUX_PKG_BUILD_IN_SRC=yes
termux_step_configure() {
termux_setup_golang
}
termux_step_make() {
make build
}
termux_step_make_install() {
install bettercap $TERMUX_PREFIX/bin/
}

View File

@ -0,0 +1,36 @@
diff -u -r ../modules.orig/https_proxy/https_proxy.go ./modules/https_proxy/https_proxy.go
--- ../modules.orig/https_proxy/https_proxy.go 2019-07-19 21:29:31.672237775 +0200
+++ ./modules/https_proxy/https_proxy.go 2019-07-19 21:26:42.776456311 +0200
@@ -43,12 +43,12 @@
"URL, path or javascript code to inject into every HTML page."))
mod.AddParam(session.NewStringParameter("https.proxy.certificate",
- "~/.bettercap-ca.cert.pem",
+ "@TERMUX_HOME@/.bettercap-ca.cert.pem",
"",
"HTTPS proxy certification authority TLS certificate file."))
mod.AddParam(session.NewStringParameter("https.proxy.key",
- "~/.bettercap-ca.key.pem",
+ "@TERMUX_HOME@/.bettercap-ca.key.pem",
"",
"HTTPS proxy certification authority TLS key file."))
diff -u -r ../modules.orig/https_server/https_server.go ./modules/https_server/https_server.go
--- ../modules.orig/https_server/https_server.go 2019-07-19 21:29:41.980474175 +0200
+++ ./modules/https_server/https_server.go 2019-07-19 21:28:13.267671735 +0200
@@ -42,12 +42,12 @@
"Port to bind the http server to."))
mod.AddParam(session.NewStringParameter("https.server.certificate",
- "~/.bettercap-httpd.cert.pem",
+ "@TERMUX_HOME@/.bettercap-httpd.cert.pem",
"",
"TLS certificate file (will be auto generated if filled but not existing)."))
mod.AddParam(session.NewStringParameter("https.server.key",
- "~/.bettercap-httpd.key.pem",
+ "@TERMUX_HOME@/.bettercap-httpd.key.pem",
"",
"TLS key file (will be auto generated if filled but not existing)."))