mirror of
https://github.com/sshuttle/sshuttle.git
synced 2025-02-06 13:39:56 +01:00
Remove legacy Debian packaging.
This needs to be redone; will do so at a later stage.
This commit is contained in:
parent
4252e81fb0
commit
974f9aee81
@ -1,28 +0,0 @@
|
||||
Package: sshuttle
|
||||
Version: 0+git
|
||||
Architecture: all
|
||||
Maintainer: Jim Wyllie <jwyllie83@gmail.com>
|
||||
Depends: iptables, python (>= 2.6)
|
||||
Suggests: autossh
|
||||
Section: net
|
||||
Priority: optional
|
||||
Homepage: http://github.com/sshuttle/sshuttle
|
||||
Description: "Full-featured" VPN over an SSH tunnel
|
||||
It allows full remote access somewhere where all you have is an SSH
|
||||
connection. It works well if you generally find yourself in the
|
||||
following situation:
|
||||
.
|
||||
- Your client machine (or router) is Linux, FreeBSD, or MacOS.
|
||||
- You have access to a remote network via ssh.
|
||||
- You don't necessarily have admin access on the remote network.
|
||||
- You do not wish to, or can't, use other VPN software
|
||||
- You don't want to create an ssh port forward for every
|
||||
single host/port on the remote network.
|
||||
- You hate openssh's port forwarding because it's randomly
|
||||
slow and/or stupid.
|
||||
- You can't use openssh's PermitTunnel feature because
|
||||
it's disabled by default on openssh servers; plus it does
|
||||
TCP-over-TCP, which has suboptimal performance
|
||||
.
|
||||
It also has hooks for more complicated setups (VPN-in-a-SSH-VPN, etc.) to allow
|
||||
you to set it up as you like.
|
@ -1,46 +0,0 @@
|
||||
#!/bin/bash
|
||||
#
|
||||
# This script puts together a .deb package suitable for installing on an Ubuntu
|
||||
# system
|
||||
|
||||
B="/tmp/sshuttle/build"
|
||||
|
||||
if [ ! -x /usr/bin/dpkg ]; then
|
||||
echo 'Unable to build: dpkg not found on system'
|
||||
exit 1
|
||||
fi
|
||||
|
||||
# Create the new directory structure
|
||||
mkdir -p ${B}/etc/sshuttle/pre-start.d
|
||||
mkdir -p ${B}/etc/sshuttle/post-stop.d
|
||||
mkdir -p ${B}/usr/share/sshuttle
|
||||
mkdir -p ${B}/usr/bin
|
||||
mkdir -p ${B}/etc/init
|
||||
mkdir -p ${B}/DEBIAN
|
||||
|
||||
# Copy over all of the files
|
||||
cp -r ../src/* ${B}/usr/share/sshuttle
|
||||
cp ../src/sshuttle ${B}/usr/bin
|
||||
cp -r sshuttle.conf ${B}/etc/init
|
||||
cp prefixes.conf ${B}/etc/sshuttle
|
||||
cp tunnel.conf ${B}/etc/sshuttle
|
||||
# Remove MacOS X stuff from .deb
|
||||
rm -r ${B}/usr/share/sshuttle/ui-macos
|
||||
|
||||
# Fix path to main.py
|
||||
sed -e 's:^DIR=.*$:DIR=/usr/share/sshuttle/:' -i ${B}/usr/bin/sshuttle
|
||||
|
||||
# Copy the control file over, as well
|
||||
cp control ${B}/DEBIAN
|
||||
|
||||
# Create the md5sum manifest
|
||||
if [ -x /usr/bin/md5sum ]; then
|
||||
cd ${B}
|
||||
find . -type f | egrep -v DEBIAN | sed -re 's/^..//' | xargs md5sum > ${B}/DEBIAN/md5sums
|
||||
cd ${OLDPWD}
|
||||
fi
|
||||
|
||||
# Build the debian package
|
||||
VERSION=$(egrep -e '^Version' control | sed -re 's/^[^:]*: //')
|
||||
dpkg --build ${B} ./sshuttle-${VERSION}.deb
|
||||
rm -rf ${B}
|
@ -1,5 +0,0 @@
|
||||
# Output prefixes here, one per line. Prefix is in:
|
||||
# prefix/netmask format
|
||||
# Like this:
|
||||
# 192.168.0.0/16
|
||||
# 192.0.43.10/32
|
@ -1,90 +0,0 @@
|
||||
description "Create a transparent proxy over SSH"
|
||||
author "Jim Wyllie <jwyllie83@gmail.com>"
|
||||
|
||||
manual
|
||||
nice -5
|
||||
|
||||
# Edit this file with network prefixes that should be loaded through the SSH
|
||||
# tunnel.
|
||||
env PREFIX_LOCATION=/etc/sshuttle/prefixes.conf
|
||||
|
||||
# Routing table; defaults to 100
|
||||
env ROUTE_TABLE=100
|
||||
|
||||
# fwmark; defaults to 1
|
||||
env FWMARK=1
|
||||
|
||||
# SSH tunnel configuration file
|
||||
env SSHUTTLE_TUNNEL_FILE=/etc/sshuttle/tunnel.conf
|
||||
|
||||
# File containing the tunnel proxy name / host / whatever
|
||||
env TUNNEL_PROXY="/etc/sshuttle/tunnel.conf"
|
||||
|
||||
# Any other commands needed to run before or after loading the SSH tunnel.
|
||||
# This is where you can put any of your hacks to set up tunnels-in-tunnels,
|
||||
# etc. Scripts in this directory are executed in order.
|
||||
env MISC_START_DIR=/etc/sshuttle/pre-start.d
|
||||
env MISC_STOP_DIR=/etc/sshuttle/post-stop.d
|
||||
|
||||
start on (local-filesystems and net-device-up IFACE!=lo)
|
||||
stop on stopping network-services
|
||||
|
||||
#respawn
|
||||
|
||||
pre-start script
|
||||
# Make sure we have created the routes
|
||||
sudo ip rule add fwmark ${FWMARK} lookup ${ROUTE_TABLE}
|
||||
logger "Starting sshuttle..."
|
||||
|
||||
if [ -f "${PREFIX_LOCATION}" ]; then
|
||||
cat "${PREFIX_LOCATION}" | while read ROUTE; do
|
||||
|
||||
# Skip comments
|
||||
if [ -n "$(echo ${ROUTE} | egrep "^[ ]*#")" ]; then
|
||||
continue
|
||||
fi
|
||||
|
||||
# Skip empty lines
|
||||
if [ -z "${ROUTE}" ]; then
|
||||
continue
|
||||
fi
|
||||
|
||||
logger "Adding route: ${ROUTE}"
|
||||
ip route add local ${ROUTE} dev lo table ${ROUTE_TABLE}
|
||||
done
|
||||
fi
|
||||
|
||||
for RUNFILE in ${MISC_START_DIR}/*; do
|
||||
logger "Executing ${RUNFILE}"
|
||||
/bin/sh -c "${RUNFILE}"
|
||||
done
|
||||
end script
|
||||
|
||||
post-stop script
|
||||
if [ -f "${PREFIX_LOCATION}" ]; then
|
||||
cat "${PREFIX_LOCATION}" | while read ROUTE; do
|
||||
|
||||
# Skip comments
|
||||
if [ -n "$(echo ${ROUTE} | egrep "^[ ]*#")" ]; then
|
||||
continue
|
||||
fi
|
||||
|
||||
# Skip empty lines
|
||||
if [ -z "${ROUTE}" ]; then
|
||||
continue
|
||||
fi
|
||||
|
||||
logger "Deleting route: ${ROUTE}"
|
||||
ip route del local ${ROUTE} dev lo table ${ROUTE_TABLE}
|
||||
done
|
||||
fi
|
||||
|
||||
ip rule del fwmark ${FWMARK}
|
||||
|
||||
for RUNFILE in "${MISC_STOP_DIR}/*"; do
|
||||
logger "Executing ${RUNFILE}"
|
||||
/bin/sh -c "${RUNFILE}"
|
||||
done
|
||||
end script
|
||||
|
||||
exec /usr/bin/sshuttle --dns --method=tproxy --listen 0.0.0.0 --remote sshuttle_tunnel -s /etc/sshuttle/prefixes.conf -e "ssh -F ${TUNNEL_PROXY}"
|
@ -1,19 +0,0 @@
|
||||
# Here is where you can specify any SSH tunnel options See ssh_config(5) for
|
||||
# details. You need to leave the Host line intact, but everything else can
|
||||
# specify whatever you want
|
||||
Host sshuttle_tunnel
|
||||
|
||||
# REQUIRED: Set this to be the host to which you would like to connect your
|
||||
# tunnel
|
||||
#Hostname localhost
|
||||
|
||||
# REQUIRED: Set this to be the target SSH user on the remote system
|
||||
#User foo
|
||||
|
||||
# ---------------------------------------------------------------------------
|
||||
# The rest are all optional; see ssh_config(5) for the full list of what can
|
||||
# be specified. Some very commonly needed ones are below.
|
||||
# ---------------------------------------------------------------------------
|
||||
|
||||
# SSH key used for connecting
|
||||
#IdentityFile /path/to/key
|
Loading…
Reference in New Issue
Block a user