Skip to content

reconFTW is a tool designed to perform automated recon on a target domain by running the best set of tools to perform scanning and finding out vulnerabilities

skip golang installation

six2dezbeb548181f71
diff --git a/install.sh b/install.sh
index aa9b684..10d8e81 100755
--- a/install.sh
+++ b/install.sh
@@ -196,36 +196,37 @@ fi
version=$(curl -L -s https://golang.org/VERSION?m=text)
#version="go1.17.6"
printf "${bblue} Running: Installing/Updating Golang ${reset}\n\n"
-if [[ $(eval type go $DEBUG_ERROR | grep -o 'go is') == "go is" ]] && [ "$version" = $(go version | cut -d " " -f3) ]
- then
- printf "${bgreen} Golang is already installed and updated ${reset}\n\n"
- else
- eval $SUDO rm -rf /usr/local/go $DEBUG_STD
- if [ "True" = "$IS_ARM" ]; then
- if [ "True" = "$RPI_3" ]; then
- eval wget https://dl.google.com/go/${version}.linux-armv6l.tar.gz $DEBUG_STD
- eval $SUDO tar -C /usr/local -xzf ${version}.linux-armv6l.tar.gz $DEBUG_STD
- elif [ "True" = "$RPI_4" ]; then
- eval wget https://dl.google.com/go/${version}.linux-arm64.tar.gz $DEBUG_STD
- eval $SUDO tar -C /usr/local -xzf ${version}.linux-arm64.tar.gz $DEBUG_STD
- fi
- elif [ "True" = "$IS_MAC" ]; then
+if [ "$install_golang" = "true" ]; then
+ if [[ $(eval type go $DEBUG_ERROR | grep -o 'go is') == "go is" ]] && [ "$version" = $(go version | cut -d " " -f3) ]
+ then
+ printf "${bgreen} Golang is already installed and updated ${reset}\n\n"
+ else
+ eval $SUDO rm -rf /usr/local/go $DEBUG_STD
if [ "True" = "$IS_ARM" ]; then
- eval wget https://dl.google.com/go/${version}.darwin-arm64.tar.gz $DEBUG_STD
- eval $SUDO tar -C /usr/local -xzf ${version}.darwin-arm64.tar.gz $DEBUG_STD
+ if [ "True" = "$RPI_3" ]; then
+ eval wget https://dl.google.com/go/${version}.linux-armv6l.tar.gz $DEBUG_STD
+ eval $SUDO tar -C /usr/local -xzf ${version}.linux-armv6l.tar.gz $DEBUG_STD
+ elif [ "True" = "$RPI_4" ]; then
+ eval wget https://dl.google.com/go/${version}.linux-arm64.tar.gz $DEBUG_STD
+ eval $SUDO tar -C /usr/local -xzf ${version}.linux-arm64.tar.gz $DEBUG_STD
+ fi
+ elif [ "True" = "$IS_MAC" ]; then
+ if [ "True" = "$IS_ARM" ]; then
+ eval wget https://dl.google.com/go/${version}.darwin-arm64.tar.gz $DEBUG_STD
+ eval $SUDO tar -C /usr/local -xzf ${version}.darwin-arm64.tar.gz $DEBUG_STD
+ else
+ eval wget https://dl.google.com/go/${version}.darwin-amd64.tar.gz $DEBUG_STD
+ eval $SUDO tar -C /usr/local -xzf ${version}.darwin-amd64.tar.gz $DEBUG_STD
+ fi
else
- eval wget https://dl.google.com/go/${version}.darwin-amd64.tar.gz $DEBUG_STD
- eval $SUDO tar -C /usr/local -xzf ${version}.darwin-amd64.tar.gz $DEBUG_STD
+ eval wget https://dl.google.com/go/${version}.linux-amd64.tar.gz $DEBUG_STD
+ eval $SUDO tar -C /usr/local -xzf ${version}.linux-amd64.tar.gz $DEBUG_STD
fi
- else
- eval wget https://dl.google.com/go/${version}.linux-amd64.tar.gz $DEBUG_STD
- eval $SUDO tar -C /usr/local -xzf ${version}.linux-amd64.tar.gz $DEBUG_STD
- fi
- eval $SUDO ln -sf /usr/local/go/bin/go /usr/local/bin/
- #rm -rf $version*
- export GOROOT=/usr/local/go
- export GOPATH=$HOME/go
- export PATH=$GOPATH/bin:$GOROOT/bin:$HOME/.local/bin:$PATH
+ eval $SUDO ln -sf /usr/local/go/bin/go /usr/local/bin/
+ #rm -rf $version*
+ export GOROOT=/usr/local/go
+ export GOPATH=$HOME/go
+ export PATH=$GOPATH/bin:$GOROOT/bin:$HOME/.local/bin:$PATH
cat << EOF >> ~/${profile_shell}
# Golang vars
@@ -233,7 +234,9 @@ export GOROOT=/usr/local/go
export GOPATH=\$HOME/go
export PATH=\$GOPATH/bin:\$GOROOT/bin:\$HOME/.local/bin:\$PATH
EOF
-
+fi
+else
+ printf "${byellow} Golang will not be configured according to the user's prefereneces (reconftw.cfg install_golang var)${reset}\n";
fi
[ -n "$GOPATH" ] || { printf "${bred} GOPATH env var not detected, add Golang env vars to your \$HOME/.bashrc or \$HOME/.zshrc:\n\n export GOROOT=/usr/local/go\n export GOPATH=\$HOME/go\n export PATH=\$GOPATH/bin:\$GOROOT/bin:\$PATH\n\n"; exit 1; }
diff --git a/reconftw.cfg b/reconftw.cfg
index 1082cb6..6c6c174 100644
--- a/reconftw.cfg
+++ b/reconftw.cfg
@@ -10,6 +10,7 @@ reconftw_version=$(git rev-parse --abbrev-ref HEAD)-$(git describe --tags) # Fet
generate_resolvers=false # Generate custom resolvers with dnsvalidator
update_resolvers=true # Fetch and rewrite resolvers from trickest/resolvers before DNS resolution
proxy_url="http://127.0.0.1:8080/" # Proxy url
+install_golang=true
#dir_output=/custom/output/path
# Golang Vars (Comment or change on your own)