vde2-2.3.2/ 0000755 0001750 0001750 00000000000 11663222120 011425 5 ustar renzo renzo vde2-2.3.2/libvirt/ 0000755 0001750 0001750 00000000000 11663221165 013110 5 ustar renzo renzo vde2-2.3.2/libvirt/README 0000644 0001750 0001750 00000001052 11663221057 013766 0 ustar renzo renzo This patch defines and manages the syntax:
...
the switch tag can be omitted: vde uses the default switch.
qemu/kvm support: tested.
user-mode linux support is included but not tested yet.
libvirt vde support for virtualbox has not been coded yet.
INSTALL:
download libvirt-0.8.7
..../libvirt-0.8.7$ patch -p 1 < libvirt-0.8.7.vde.patch
..../libvirt-0.8.7$ configure
..../libvirt-0.8.7$ make
..../libvirt-0.8.7$ sudo make install
vde2-2.3.2/libvirt/libvirt-0.8.7.vde.patch 0000644 0001750 0001750 00000010552 11663221057 017034 0 ustar renzo renzo --- a/src/lxc/lxc_driver.c 2011-01-10 11:49:49.000000000 +0100
+++ b/src/lxc/lxc_driver.c 2011-01-10 11:50:03.000000000 +0100
@@ -1083,6 +1083,7 @@
case VIR_DOMAIN_NET_TYPE_INTERNAL:
case VIR_DOMAIN_NET_TYPE_DIRECT:
case VIR_DOMAIN_NET_TYPE_LAST:
+ case VIR_DOMAIN_NET_TYPE_VDE:
break;
}
--- a/src/uml/uml_conf.c 2011-01-10 12:03:54.000000000 +0100
+++ b/src/uml/uml_conf.c 2011-01-10 13:26:08.000000000 +0100
@@ -269,6 +269,14 @@
virBufferVSprintf(&buf, "tuntap,%s", def->ifname);
break;
+ case VIR_DOMAIN_NET_TYPE_VDE:
+ /* ethNNN=vde,vde_switch,macaddr,port,group,mode,description */
+ if (def->data.vde.vdeswitch) {
+ virBufferVSprintf(&buf, "vde,%s", def->data.vde.vdeswitch);
+ } else
+ virBufferAddLit(&buf, "vde");
+ break;
+
case VIR_DOMAIN_NET_TYPE_INTERNAL:
umlReportError(VIR_ERR_INTERNAL_ERROR, "%s",
_("internal networking type not supported"));
--- a/src/conf/domain_conf.h 2011-01-10 11:41:07.000000000 +0100
+++ b/src/conf/domain_conf.h 2011-01-10 13:21:08.000000000 +0100
@@ -288,6 +288,7 @@
VIR_DOMAIN_NET_TYPE_BRIDGE,
VIR_DOMAIN_NET_TYPE_INTERNAL,
VIR_DOMAIN_NET_TYPE_DIRECT,
+ VIR_DOMAIN_NET_TYPE_VDE,
VIR_DOMAIN_NET_TYPE_LAST,
};
@@ -336,6 +337,9 @@
int mode;
virVirtualPortProfileParams virtPortProfile;
} direct;
+ struct {
+ char *vdeswitch;
+ } vde;
} data;
char *ifname;
virDomainDeviceInfo info;
--- a/src/conf/domain_conf.c 2011-01-10 11:42:04.000000000 +0100
+++ b/src/conf/domain_conf.c 2011-01-10 14:49:46.000000000 +0100
@@ -182,7 +182,8 @@
"network",
"bridge",
"internal",
- "direct")
+ "direct",
+ "vde")
VIR_ENUM_IMPL(virDomainChrChannelTarget,
VIR_DOMAIN_CHR_CHANNEL_TARGET_TYPE_LAST,
@@ -598,6 +599,10 @@
VIR_FREE(def->data.direct.linkdev);
break;
+ case VIR_DOMAIN_NET_TYPE_VDE:
+ VIR_FREE(def->data.vde.vdeswitch);
+ break;
+
case VIR_DOMAIN_NET_TYPE_USER:
case VIR_DOMAIN_NET_TYPE_LAST:
break;
@@ -2293,6 +2298,7 @@
char *internal = NULL;
char *devaddr = NULL;
char *mode = NULL;
+ char *vdeswitch = NULL;
virNWFilterHashTablePtr filterparams = NULL;
virVirtualPortProfileParams virtPort;
bool virtPortParsed = false;
@@ -2379,7 +2385,11 @@
xmlStrEqual(cur->name, BAD_CAST "state")) {
/* Legacy back-compat. Don't add any more attributes here */
devaddr = virXMLPropString(cur, "devaddr");
- }
+ } else if ((vdeswitch == NULL) &&
+ def->type == VIR_DOMAIN_NET_TYPE_VDE &&
+ xmlStrEqual(cur->name, BAD_CAST "switch")) {
+ vdeswitch = virXMLPropString(cur, "path");
+ }
}
cur = cur->next;
}
@@ -2529,6 +2539,11 @@
break;
+ case VIR_DOMAIN_NET_TYPE_VDE:
+ def->data.vde.vdeswitch = vdeswitch;
+ vdeswitch = NULL;
+ break;
+
case VIR_DOMAIN_NET_TYPE_USER:
case VIR_DOMAIN_NET_TYPE_LAST:
break;
@@ -6263,6 +6278,12 @@
" ");
break;
+ case VIR_DOMAIN_NET_TYPE_VDE:
+ if (def->data.vde.vdeswitch)
+ virBufferEscapeString(buf, " \n",
+ def->data.vde.vdeswitch);
+ break;
+
case VIR_DOMAIN_NET_TYPE_USER:
case VIR_DOMAIN_NET_TYPE_LAST:
break;
--- a/src/qemu/qemu_command.c 2011-01-10 13:11:17.000000000 +0100
+++ b/src/qemu/qemu_command.c 2011-01-10 13:26:28.000000000 +0100
@@ -1602,12 +1602,21 @@
case VIR_DOMAIN_NET_TYPE_BRIDGE:
case VIR_DOMAIN_NET_TYPE_INTERNAL:
case VIR_DOMAIN_NET_TYPE_DIRECT:
+ case VIR_DOMAIN_NET_TYPE_VDE:
case VIR_DOMAIN_NET_TYPE_LAST:
break;
}
type_sep = ',';
break;
+ case VIR_DOMAIN_NET_TYPE_VDE:
+ virBufferAddLit(&buf, "vde");
+ if (net->data.vde.vdeswitch)
+ virBufferVSprintf(&buf, "%csock=%s",
+ type_sep,
+ net->data.vde.vdeswitch);
+ break;
+
case VIR_DOMAIN_NET_TYPE_USER:
default:
virBufferAddLit(&buf, "user");
vde2-2.3.2/.gitignore 0000644 0001750 0001750 00000001372 11663221057 013430 0 ustar renzo renzo Makefile.in
aclocal.m4
autom4te.cache
compile
config.guess
config.sub
configure
depcomp
include/config.h.in
include/config.h.in~
install-sh
ltmain.sh
m4/libtool.m4
m4/ltoptions.m4
m4/ltsugar.m4
m4/ltversion.m4
m4/lt~obsolete.m4
missing
Makefile
.deps
.libs
*.o
*.a
*.so
*.la
*.lo
config.log
config.status
include/config.h
include/stamp-h1
libtool
man/vdetaplib.1
src/dpipe
src/lib/vdehist.pc
src/lib/vdemgmt.pc
src/lib/vdeplug.pc
src/lib/vdesnmp.pc
src/slirpvde/slirpvde
src/unixcmd
src/unixterm
src/vde_autolink
src/vde_cryptcab/vde_cryptcab
src/vde_l3/vde_l3
src/vde_over_ns/vde_over_ns
src/vde_pcapplug
src/vde_plug
src/vde_plug2tap
src/vde_switch/vde_switch
src/vde_tunctl
src/vdeq
src/vdetaplib/vdetap
src/vdeterm
src/wirefilter
src/kvde_switch/kvde_switch
vde2-2.3.2/config.guess 0000755 0001750 0001750 00000126730 11663221136 013764 0 ustar renzo renzo #! /bin/sh
# Attempt to guess a canonical system name.
# Copyright (C) 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999,
# 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009, 2010,
# 2011 Free Software Foundation, Inc.
timestamp='2011-05-11'
# This file is free software; you can redistribute it and/or modify it
# under the terms of the GNU General Public License as published by
# the Free Software Foundation; either version 2 of the License, or
# (at your option) any later version.
#
# This program is distributed in the hope that it will be useful, but
# WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
# General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# along with this program; if not, write to the Free Software
# Foundation, Inc., 51 Franklin Street - Fifth Floor, Boston, MA
# 02110-1301, USA.
#
# As a special exception to the GNU General Public License, if you
# distribute this file as part of a program that contains a
# configuration script generated by Autoconf, you may include it under
# the same distribution terms that you use for the rest of that program.
# Originally written by Per Bothner. Please send patches (context
# diff format) to and include a ChangeLog
# entry.
#
# This script attempts to guess a canonical system name similar to
# config.sub. If it succeeds, it prints the system name on stdout, and
# exits with 0. Otherwise, it exits with 1.
#
# You can get the latest version of this script from:
# http://git.savannah.gnu.org/gitweb/?p=config.git;a=blob_plain;f=config.guess;hb=HEAD
me=`echo "$0" | sed -e 's,.*/,,'`
usage="\
Usage: $0 [OPTION]
Output the configuration name of the system \`$me' is run on.
Operation modes:
-h, --help print this help, then exit
-t, --time-stamp print date of last modification, then exit
-v, --version print version number, then exit
Report bugs and patches to ."
version="\
GNU config.guess ($timestamp)
Originally written by Per Bothner.
Copyright (C) 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999, 2000,
2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009, 2010, 2011 Free
Software Foundation, Inc.
This is free software; see the source for copying conditions. There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE."
help="
Try \`$me --help' for more information."
# Parse command line
while test $# -gt 0 ; do
case $1 in
--time-stamp | --time* | -t )
echo "$timestamp" ; exit ;;
--version | -v )
echo "$version" ; exit ;;
--help | --h* | -h )
echo "$usage"; exit ;;
-- ) # Stop option processing
shift; break ;;
- ) # Use stdin as input.
break ;;
-* )
echo "$me: invalid option $1$help" >&2
exit 1 ;;
* )
break ;;
esac
done
if test $# != 0; then
echo "$me: too many arguments$help" >&2
exit 1
fi
trap 'exit 1' 1 2 15
# CC_FOR_BUILD -- compiler used by this script. Note that the use of a
# compiler to aid in system detection is discouraged as it requires
# temporary files to be created and, as you can see below, it is a
# headache to deal with in a portable fashion.
# Historically, `CC_FOR_BUILD' used to be named `HOST_CC'. We still
# use `HOST_CC' if defined, but it is deprecated.
# Portable tmp directory creation inspired by the Autoconf team.
set_cc_for_build='
trap "exitcode=\$?; (rm -f \$tmpfiles 2>/dev/null; rmdir \$tmp 2>/dev/null) && exit \$exitcode" 0 ;
trap "rm -f \$tmpfiles 2>/dev/null; rmdir \$tmp 2>/dev/null; exit 1" 1 2 13 15 ;
: ${TMPDIR=/tmp} ;
{ tmp=`(umask 077 && mktemp -d "$TMPDIR/cgXXXXXX") 2>/dev/null` && test -n "$tmp" && test -d "$tmp" ; } ||
{ test -n "$RANDOM" && tmp=$TMPDIR/cg$$-$RANDOM && (umask 077 && mkdir $tmp) ; } ||
{ tmp=$TMPDIR/cg-$$ && (umask 077 && mkdir $tmp) && echo "Warning: creating insecure temp directory" >&2 ; } ||
{ echo "$me: cannot create a temporary directory in $TMPDIR" >&2 ; exit 1 ; } ;
dummy=$tmp/dummy ;
tmpfiles="$dummy.c $dummy.o $dummy.rel $dummy" ;
case $CC_FOR_BUILD,$HOST_CC,$CC in
,,) echo "int x;" > $dummy.c ;
for c in cc gcc c89 c99 ; do
if ($c -c -o $dummy.o $dummy.c) >/dev/null 2>&1 ; then
CC_FOR_BUILD="$c"; break ;
fi ;
done ;
if test x"$CC_FOR_BUILD" = x ; then
CC_FOR_BUILD=no_compiler_found ;
fi
;;
,,*) CC_FOR_BUILD=$CC ;;
,*,*) CC_FOR_BUILD=$HOST_CC ;;
esac ; set_cc_for_build= ;'
# This is needed to find uname on a Pyramid OSx when run in the BSD universe.
# (ghazi@noc.rutgers.edu 1994-08-24)
if (test -f /.attbin/uname) >/dev/null 2>&1 ; then
PATH=$PATH:/.attbin ; export PATH
fi
UNAME_MACHINE=`(uname -m) 2>/dev/null` || UNAME_MACHINE=unknown
UNAME_RELEASE=`(uname -r) 2>/dev/null` || UNAME_RELEASE=unknown
UNAME_SYSTEM=`(uname -s) 2>/dev/null` || UNAME_SYSTEM=unknown
UNAME_VERSION=`(uname -v) 2>/dev/null` || UNAME_VERSION=unknown
# Note: order is significant - the case branches are not exclusive.
case "${UNAME_MACHINE}:${UNAME_SYSTEM}:${UNAME_RELEASE}:${UNAME_VERSION}" in
*:NetBSD:*:*)
# NetBSD (nbsd) targets should (where applicable) match one or
# more of the tupples: *-*-netbsdelf*, *-*-netbsdaout*,
# *-*-netbsdecoff* and *-*-netbsd*. For targets that recently
# switched to ELF, *-*-netbsd* would select the old
# object file format. This provides both forward
# compatibility and a consistent mechanism for selecting the
# object file format.
#
# Note: NetBSD doesn't particularly care about the vendor
# portion of the name. We always set it to "unknown".
sysctl="sysctl -n hw.machine_arch"
UNAME_MACHINE_ARCH=`(/sbin/$sysctl 2>/dev/null || \
/usr/sbin/$sysctl 2>/dev/null || echo unknown)`
case "${UNAME_MACHINE_ARCH}" in
armeb) machine=armeb-unknown ;;
arm*) machine=arm-unknown ;;
sh3el) machine=shl-unknown ;;
sh3eb) machine=sh-unknown ;;
sh5el) machine=sh5le-unknown ;;
*) machine=${UNAME_MACHINE_ARCH}-unknown ;;
esac
# The Operating System including object format, if it has switched
# to ELF recently, or will in the future.
case "${UNAME_MACHINE_ARCH}" in
arm*|i386|m68k|ns32k|sh3*|sparc|vax)
eval $set_cc_for_build
if echo __ELF__ | $CC_FOR_BUILD -E - 2>/dev/null \
| grep -q __ELF__
then
# Once all utilities can be ECOFF (netbsdecoff) or a.out (netbsdaout).
# Return netbsd for either. FIX?
os=netbsd
else
os=netbsdelf
fi
;;
*)
os=netbsd
;;
esac
# The OS release
# Debian GNU/NetBSD machines have a different userland, and
# thus, need a distinct triplet. However, they do not need
# kernel version information, so it can be replaced with a
# suitable tag, in the style of linux-gnu.
case "${UNAME_VERSION}" in
Debian*)
release='-gnu'
;;
*)
release=`echo ${UNAME_RELEASE}|sed -e 's/[-_].*/\./'`
;;
esac
# Since CPU_TYPE-MANUFACTURER-KERNEL-OPERATING_SYSTEM:
# contains redundant information, the shorter form:
# CPU_TYPE-MANUFACTURER-OPERATING_SYSTEM is used.
echo "${machine}-${os}${release}"
exit ;;
*:OpenBSD:*:*)
UNAME_MACHINE_ARCH=`arch | sed 's/OpenBSD.//'`
echo ${UNAME_MACHINE_ARCH}-unknown-openbsd${UNAME_RELEASE}
exit ;;
*:ekkoBSD:*:*)
echo ${UNAME_MACHINE}-unknown-ekkobsd${UNAME_RELEASE}
exit ;;
*:SolidBSD:*:*)
echo ${UNAME_MACHINE}-unknown-solidbsd${UNAME_RELEASE}
exit ;;
macppc:MirBSD:*:*)
echo powerpc-unknown-mirbsd${UNAME_RELEASE}
exit ;;
*:MirBSD:*:*)
echo ${UNAME_MACHINE}-unknown-mirbsd${UNAME_RELEASE}
exit ;;
alpha:OSF1:*:*)
case $UNAME_RELEASE in
*4.0)
UNAME_RELEASE=`/usr/sbin/sizer -v | awk '{print $3}'`
;;
*5.*)
UNAME_RELEASE=`/usr/sbin/sizer -v | awk '{print $4}'`
;;
esac
# According to Compaq, /usr/sbin/psrinfo has been available on
# OSF/1 and Tru64 systems produced since 1995. I hope that
# covers most systems running today. This code pipes the CPU
# types through head -n 1, so we only detect the type of CPU 0.
ALPHA_CPU_TYPE=`/usr/sbin/psrinfo -v | sed -n -e 's/^ The alpha \(.*\) processor.*$/\1/p' | head -n 1`
case "$ALPHA_CPU_TYPE" in
"EV4 (21064)")
UNAME_MACHINE="alpha" ;;
"EV4.5 (21064)")
UNAME_MACHINE="alpha" ;;
"LCA4 (21066/21068)")
UNAME_MACHINE="alpha" ;;
"EV5 (21164)")
UNAME_MACHINE="alphaev5" ;;
"EV5.6 (21164A)")
UNAME_MACHINE="alphaev56" ;;
"EV5.6 (21164PC)")
UNAME_MACHINE="alphapca56" ;;
"EV5.7 (21164PC)")
UNAME_MACHINE="alphapca57" ;;
"EV6 (21264)")
UNAME_MACHINE="alphaev6" ;;
"EV6.7 (21264A)")
UNAME_MACHINE="alphaev67" ;;
"EV6.8CB (21264C)")
UNAME_MACHINE="alphaev68" ;;
"EV6.8AL (21264B)")
UNAME_MACHINE="alphaev68" ;;
"EV6.8CX (21264D)")
UNAME_MACHINE="alphaev68" ;;
"EV6.9A (21264/EV69A)")
UNAME_MACHINE="alphaev69" ;;
"EV7 (21364)")
UNAME_MACHINE="alphaev7" ;;
"EV7.9 (21364A)")
UNAME_MACHINE="alphaev79" ;;
esac
# A Pn.n version is a patched version.
# A Vn.n version is a released version.
# A Tn.n version is a released field test version.
# A Xn.n version is an unreleased experimental baselevel.
# 1.2 uses "1.2" for uname -r.
echo ${UNAME_MACHINE}-dec-osf`echo ${UNAME_RELEASE} | sed -e 's/^[PVTX]//' | tr 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
# Reset EXIT trap before exiting to avoid spurious non-zero exit code.
exitcode=$?
trap '' 0
exit $exitcode ;;
Alpha\ *:Windows_NT*:*)
# How do we know it's Interix rather than the generic POSIX subsystem?
# Should we change UNAME_MACHINE based on the output of uname instead
# of the specific Alpha model?
echo alpha-pc-interix
exit ;;
21064:Windows_NT:50:3)
echo alpha-dec-winnt3.5
exit ;;
Amiga*:UNIX_System_V:4.0:*)
echo m68k-unknown-sysv4
exit ;;
*:[Aa]miga[Oo][Ss]:*:*)
echo ${UNAME_MACHINE}-unknown-amigaos
exit ;;
*:[Mm]orph[Oo][Ss]:*:*)
echo ${UNAME_MACHINE}-unknown-morphos
exit ;;
*:OS/390:*:*)
echo i370-ibm-openedition
exit ;;
*:z/VM:*:*)
echo s390-ibm-zvmoe
exit ;;
*:OS400:*:*)
echo powerpc-ibm-os400
exit ;;
arm:RISC*:1.[012]*:*|arm:riscix:1.[012]*:*)
echo arm-acorn-riscix${UNAME_RELEASE}
exit ;;
arm:riscos:*:*|arm:RISCOS:*:*)
echo arm-unknown-riscos
exit ;;
SR2?01:HI-UX/MPP:*:* | SR8000:HI-UX/MPP:*:*)
echo hppa1.1-hitachi-hiuxmpp
exit ;;
Pyramid*:OSx*:*:* | MIS*:OSx*:*:* | MIS*:SMP_DC-OSx*:*:*)
# akee@wpdis03.wpafb.af.mil (Earle F. Ake) contributed MIS and NILE.
if test "`(/bin/universe) 2>/dev/null`" = att ; then
echo pyramid-pyramid-sysv3
else
echo pyramid-pyramid-bsd
fi
exit ;;
NILE*:*:*:dcosx)
echo pyramid-pyramid-svr4
exit ;;
DRS?6000:unix:4.0:6*)
echo sparc-icl-nx6
exit ;;
DRS?6000:UNIX_SV:4.2*:7* | DRS?6000:isis:4.2*:7*)
case `/usr/bin/uname -p` in
sparc) echo sparc-icl-nx7; exit ;;
esac ;;
s390x:SunOS:*:*)
echo ${UNAME_MACHINE}-ibm-solaris2`echo ${UNAME_RELEASE}|sed -e 's/[^.]*//'`
exit ;;
sun4H:SunOS:5.*:*)
echo sparc-hal-solaris2`echo ${UNAME_RELEASE}|sed -e 's/[^.]*//'`
exit ;;
sun4*:SunOS:5.*:* | tadpole*:SunOS:5.*:*)
echo sparc-sun-solaris2`echo ${UNAME_RELEASE}|sed -e 's/[^.]*//'`
exit ;;
i86pc:AuroraUX:5.*:* | i86xen:AuroraUX:5.*:*)
echo i386-pc-auroraux${UNAME_RELEASE}
exit ;;
i86pc:SunOS:5.*:* | i86xen:SunOS:5.*:*)
eval $set_cc_for_build
SUN_ARCH="i386"
# If there is a compiler, see if it is configured for 64-bit objects.
# Note that the Sun cc does not turn __LP64__ into 1 like gcc does.
# This test works for both compilers.
if [ "$CC_FOR_BUILD" != 'no_compiler_found' ]; then
if (echo '#ifdef __amd64'; echo IS_64BIT_ARCH; echo '#endif') | \
(CCOPTS= $CC_FOR_BUILD -E - 2>/dev/null) | \
grep IS_64BIT_ARCH >/dev/null
then
SUN_ARCH="x86_64"
fi
fi
echo ${SUN_ARCH}-pc-solaris2`echo ${UNAME_RELEASE}|sed -e 's/[^.]*//'`
exit ;;
sun4*:SunOS:6*:*)
# According to config.sub, this is the proper way to canonicalize
# SunOS6. Hard to guess exactly what SunOS6 will be like, but
# it's likely to be more like Solaris than SunOS4.
echo sparc-sun-solaris3`echo ${UNAME_RELEASE}|sed -e 's/[^.]*//'`
exit ;;
sun4*:SunOS:*:*)
case "`/usr/bin/arch -k`" in
Series*|S4*)
UNAME_RELEASE=`uname -v`
;;
esac
# Japanese Language versions have a version number like `4.1.3-JL'.
echo sparc-sun-sunos`echo ${UNAME_RELEASE}|sed -e 's/-/_/'`
exit ;;
sun3*:SunOS:*:*)
echo m68k-sun-sunos${UNAME_RELEASE}
exit ;;
sun*:*:4.2BSD:*)
UNAME_RELEASE=`(sed 1q /etc/motd | awk '{print substr($5,1,3)}') 2>/dev/null`
test "x${UNAME_RELEASE}" = "x" && UNAME_RELEASE=3
case "`/bin/arch`" in
sun3)
echo m68k-sun-sunos${UNAME_RELEASE}
;;
sun4)
echo sparc-sun-sunos${UNAME_RELEASE}
;;
esac
exit ;;
aushp:SunOS:*:*)
echo sparc-auspex-sunos${UNAME_RELEASE}
exit ;;
# The situation for MiNT is a little confusing. The machine name
# can be virtually everything (everything which is not
# "atarist" or "atariste" at least should have a processor
# > m68000). The system name ranges from "MiNT" over "FreeMiNT"
# to the lowercase version "mint" (or "freemint"). Finally
# the system name "TOS" denotes a system which is actually not
# MiNT. But MiNT is downward compatible to TOS, so this should
# be no problem.
atarist[e]:*MiNT:*:* | atarist[e]:*mint:*:* | atarist[e]:*TOS:*:*)
echo m68k-atari-mint${UNAME_RELEASE}
exit ;;
atari*:*MiNT:*:* | atari*:*mint:*:* | atarist[e]:*TOS:*:*)
echo m68k-atari-mint${UNAME_RELEASE}
exit ;;
*falcon*:*MiNT:*:* | *falcon*:*mint:*:* | *falcon*:*TOS:*:*)
echo m68k-atari-mint${UNAME_RELEASE}
exit ;;
milan*:*MiNT:*:* | milan*:*mint:*:* | *milan*:*TOS:*:*)
echo m68k-milan-mint${UNAME_RELEASE}
exit ;;
hades*:*MiNT:*:* | hades*:*mint:*:* | *hades*:*TOS:*:*)
echo m68k-hades-mint${UNAME_RELEASE}
exit ;;
*:*MiNT:*:* | *:*mint:*:* | *:*TOS:*:*)
echo m68k-unknown-mint${UNAME_RELEASE}
exit ;;
m68k:machten:*:*)
echo m68k-apple-machten${UNAME_RELEASE}
exit ;;
powerpc:machten:*:*)
echo powerpc-apple-machten${UNAME_RELEASE}
exit ;;
RISC*:Mach:*:*)
echo mips-dec-mach_bsd4.3
exit ;;
RISC*:ULTRIX:*:*)
echo mips-dec-ultrix${UNAME_RELEASE}
exit ;;
VAX*:ULTRIX*:*:*)
echo vax-dec-ultrix${UNAME_RELEASE}
exit ;;
2020:CLIX:*:* | 2430:CLIX:*:*)
echo clipper-intergraph-clix${UNAME_RELEASE}
exit ;;
mips:*:*:UMIPS | mips:*:*:RISCos)
eval $set_cc_for_build
sed 's/^ //' << EOF >$dummy.c
#ifdef __cplusplus
#include /* for printf() prototype */
int main (int argc, char *argv[]) {
#else
int main (argc, argv) int argc; char *argv[]; {
#endif
#if defined (host_mips) && defined (MIPSEB)
#if defined (SYSTYPE_SYSV)
printf ("mips-mips-riscos%ssysv\n", argv[1]); exit (0);
#endif
#if defined (SYSTYPE_SVR4)
printf ("mips-mips-riscos%ssvr4\n", argv[1]); exit (0);
#endif
#if defined (SYSTYPE_BSD43) || defined(SYSTYPE_BSD)
printf ("mips-mips-riscos%sbsd\n", argv[1]); exit (0);
#endif
#endif
exit (-1);
}
EOF
$CC_FOR_BUILD -o $dummy $dummy.c &&
dummyarg=`echo "${UNAME_RELEASE}" | sed -n 's/\([0-9]*\).*/\1/p'` &&
SYSTEM_NAME=`$dummy $dummyarg` &&
{ echo "$SYSTEM_NAME"; exit; }
echo mips-mips-riscos${UNAME_RELEASE}
exit ;;
Motorola:PowerMAX_OS:*:*)
echo powerpc-motorola-powermax
exit ;;
Motorola:*:4.3:PL8-*)
echo powerpc-harris-powermax
exit ;;
Night_Hawk:*:*:PowerMAX_OS | Synergy:PowerMAX_OS:*:*)
echo powerpc-harris-powermax
exit ;;
Night_Hawk:Power_UNIX:*:*)
echo powerpc-harris-powerunix
exit ;;
m88k:CX/UX:7*:*)
echo m88k-harris-cxux7
exit ;;
m88k:*:4*:R4*)
echo m88k-motorola-sysv4
exit ;;
m88k:*:3*:R3*)
echo m88k-motorola-sysv3
exit ;;
AViiON:dgux:*:*)
# DG/UX returns AViiON for all architectures
UNAME_PROCESSOR=`/usr/bin/uname -p`
if [ $UNAME_PROCESSOR = mc88100 ] || [ $UNAME_PROCESSOR = mc88110 ]
then
if [ ${TARGET_BINARY_INTERFACE}x = m88kdguxelfx ] || \
[ ${TARGET_BINARY_INTERFACE}x = x ]
then
echo m88k-dg-dgux${UNAME_RELEASE}
else
echo m88k-dg-dguxbcs${UNAME_RELEASE}
fi
else
echo i586-dg-dgux${UNAME_RELEASE}
fi
exit ;;
M88*:DolphinOS:*:*) # DolphinOS (SVR3)
echo m88k-dolphin-sysv3
exit ;;
M88*:*:R3*:*)
# Delta 88k system running SVR3
echo m88k-motorola-sysv3
exit ;;
XD88*:*:*:*) # Tektronix XD88 system running UTekV (SVR3)
echo m88k-tektronix-sysv3
exit ;;
Tek43[0-9][0-9]:UTek:*:*) # Tektronix 4300 system running UTek (BSD)
echo m68k-tektronix-bsd
exit ;;
*:IRIX*:*:*)
echo mips-sgi-irix`echo ${UNAME_RELEASE}|sed -e 's/-/_/g'`
exit ;;
????????:AIX?:[12].1:2) # AIX 2.2.1 or AIX 2.1.1 is RT/PC AIX.
echo romp-ibm-aix # uname -m gives an 8 hex-code CPU id
exit ;; # Note that: echo "'`uname -s`'" gives 'AIX '
i*86:AIX:*:*)
echo i386-ibm-aix
exit ;;
ia64:AIX:*:*)
if [ -x /usr/bin/oslevel ] ; then
IBM_REV=`/usr/bin/oslevel`
else
IBM_REV=${UNAME_VERSION}.${UNAME_RELEASE}
fi
echo ${UNAME_MACHINE}-ibm-aix${IBM_REV}
exit ;;
*:AIX:2:3)
if grep bos325 /usr/include/stdio.h >/dev/null 2>&1; then
eval $set_cc_for_build
sed 's/^ //' << EOF >$dummy.c
#include
main()
{
if (!__power_pc())
exit(1);
puts("powerpc-ibm-aix3.2.5");
exit(0);
}
EOF
if $CC_FOR_BUILD -o $dummy $dummy.c && SYSTEM_NAME=`$dummy`
then
echo "$SYSTEM_NAME"
else
echo rs6000-ibm-aix3.2.5
fi
elif grep bos324 /usr/include/stdio.h >/dev/null 2>&1; then
echo rs6000-ibm-aix3.2.4
else
echo rs6000-ibm-aix3.2
fi
exit ;;
*:AIX:*:[4567])
IBM_CPU_ID=`/usr/sbin/lsdev -C -c processor -S available | sed 1q | awk '{ print $1 }'`
if /usr/sbin/lsattr -El ${IBM_CPU_ID} | grep ' POWER' >/dev/null 2>&1; then
IBM_ARCH=rs6000
else
IBM_ARCH=powerpc
fi
if [ -x /usr/bin/oslevel ] ; then
IBM_REV=`/usr/bin/oslevel`
else
IBM_REV=${UNAME_VERSION}.${UNAME_RELEASE}
fi
echo ${IBM_ARCH}-ibm-aix${IBM_REV}
exit ;;
*:AIX:*:*)
echo rs6000-ibm-aix
exit ;;
ibmrt:4.4BSD:*|romp-ibm:BSD:*)
echo romp-ibm-bsd4.4
exit ;;
ibmrt:*BSD:*|romp-ibm:BSD:*) # covers RT/PC BSD and
echo romp-ibm-bsd${UNAME_RELEASE} # 4.3 with uname added to
exit ;; # report: romp-ibm BSD 4.3
*:BOSX:*:*)
echo rs6000-bull-bosx
exit ;;
DPX/2?00:B.O.S.:*:*)
echo m68k-bull-sysv3
exit ;;
9000/[34]??:4.3bsd:1.*:*)
echo m68k-hp-bsd
exit ;;
hp300:4.4BSD:*:* | 9000/[34]??:4.3bsd:2.*:*)
echo m68k-hp-bsd4.4
exit ;;
9000/[34678]??:HP-UX:*:*)
HPUX_REV=`echo ${UNAME_RELEASE}|sed -e 's/[^.]*.[0B]*//'`
case "${UNAME_MACHINE}" in
9000/31? ) HP_ARCH=m68000 ;;
9000/[34]?? ) HP_ARCH=m68k ;;
9000/[678][0-9][0-9])
if [ -x /usr/bin/getconf ]; then
sc_cpu_version=`/usr/bin/getconf SC_CPU_VERSION 2>/dev/null`
sc_kernel_bits=`/usr/bin/getconf SC_KERNEL_BITS 2>/dev/null`
case "${sc_cpu_version}" in
523) HP_ARCH="hppa1.0" ;; # CPU_PA_RISC1_0
528) HP_ARCH="hppa1.1" ;; # CPU_PA_RISC1_1
532) # CPU_PA_RISC2_0
case "${sc_kernel_bits}" in
32) HP_ARCH="hppa2.0n" ;;
64) HP_ARCH="hppa2.0w" ;;
'') HP_ARCH="hppa2.0" ;; # HP-UX 10.20
esac ;;
esac
fi
if [ "${HP_ARCH}" = "" ]; then
eval $set_cc_for_build
sed 's/^ //' << EOF >$dummy.c
#define _HPUX_SOURCE
#include
#include
int main ()
{
#if defined(_SC_KERNEL_BITS)
long bits = sysconf(_SC_KERNEL_BITS);
#endif
long cpu = sysconf (_SC_CPU_VERSION);
switch (cpu)
{
case CPU_PA_RISC1_0: puts ("hppa1.0"); break;
case CPU_PA_RISC1_1: puts ("hppa1.1"); break;
case CPU_PA_RISC2_0:
#if defined(_SC_KERNEL_BITS)
switch (bits)
{
case 64: puts ("hppa2.0w"); break;
case 32: puts ("hppa2.0n"); break;
default: puts ("hppa2.0"); break;
} break;
#else /* !defined(_SC_KERNEL_BITS) */
puts ("hppa2.0"); break;
#endif
default: puts ("hppa1.0"); break;
}
exit (0);
}
EOF
(CCOPTS= $CC_FOR_BUILD -o $dummy $dummy.c 2>/dev/null) && HP_ARCH=`$dummy`
test -z "$HP_ARCH" && HP_ARCH=hppa
fi ;;
esac
if [ ${HP_ARCH} = "hppa2.0w" ]
then
eval $set_cc_for_build
# hppa2.0w-hp-hpux* has a 64-bit kernel and a compiler generating
# 32-bit code. hppa64-hp-hpux* has the same kernel and a compiler
# generating 64-bit code. GNU and HP use different nomenclature:
#
# $ CC_FOR_BUILD=cc ./config.guess
# => hppa2.0w-hp-hpux11.23
# $ CC_FOR_BUILD="cc +DA2.0w" ./config.guess
# => hppa64-hp-hpux11.23
if echo __LP64__ | (CCOPTS= $CC_FOR_BUILD -E - 2>/dev/null) |
grep -q __LP64__
then
HP_ARCH="hppa2.0w"
else
HP_ARCH="hppa64"
fi
fi
echo ${HP_ARCH}-hp-hpux${HPUX_REV}
exit ;;
ia64:HP-UX:*:*)
HPUX_REV=`echo ${UNAME_RELEASE}|sed -e 's/[^.]*.[0B]*//'`
echo ia64-hp-hpux${HPUX_REV}
exit ;;
3050*:HI-UX:*:*)
eval $set_cc_for_build
sed 's/^ //' << EOF >$dummy.c
#include
int
main ()
{
long cpu = sysconf (_SC_CPU_VERSION);
/* The order matters, because CPU_IS_HP_MC68K erroneously returns
true for CPU_PA_RISC1_0. CPU_IS_PA_RISC returns correct
results, however. */
if (CPU_IS_PA_RISC (cpu))
{
switch (cpu)
{
case CPU_PA_RISC1_0: puts ("hppa1.0-hitachi-hiuxwe2"); break;
case CPU_PA_RISC1_1: puts ("hppa1.1-hitachi-hiuxwe2"); break;
case CPU_PA_RISC2_0: puts ("hppa2.0-hitachi-hiuxwe2"); break;
default: puts ("hppa-hitachi-hiuxwe2"); break;
}
}
else if (CPU_IS_HP_MC68K (cpu))
puts ("m68k-hitachi-hiuxwe2");
else puts ("unknown-hitachi-hiuxwe2");
exit (0);
}
EOF
$CC_FOR_BUILD -o $dummy $dummy.c && SYSTEM_NAME=`$dummy` &&
{ echo "$SYSTEM_NAME"; exit; }
echo unknown-hitachi-hiuxwe2
exit ;;
9000/7??:4.3bsd:*:* | 9000/8?[79]:4.3bsd:*:* )
echo hppa1.1-hp-bsd
exit ;;
9000/8??:4.3bsd:*:*)
echo hppa1.0-hp-bsd
exit ;;
*9??*:MPE/iX:*:* | *3000*:MPE/iX:*:*)
echo hppa1.0-hp-mpeix
exit ;;
hp7??:OSF1:*:* | hp8?[79]:OSF1:*:* )
echo hppa1.1-hp-osf
exit ;;
hp8??:OSF1:*:*)
echo hppa1.0-hp-osf
exit ;;
i*86:OSF1:*:*)
if [ -x /usr/sbin/sysversion ] ; then
echo ${UNAME_MACHINE}-unknown-osf1mk
else
echo ${UNAME_MACHINE}-unknown-osf1
fi
exit ;;
parisc*:Lites*:*:*)
echo hppa1.1-hp-lites
exit ;;
C1*:ConvexOS:*:* | convex:ConvexOS:C1*:*)
echo c1-convex-bsd
exit ;;
C2*:ConvexOS:*:* | convex:ConvexOS:C2*:*)
if getsysinfo -f scalar_acc
then echo c32-convex-bsd
else echo c2-convex-bsd
fi
exit ;;
C34*:ConvexOS:*:* | convex:ConvexOS:C34*:*)
echo c34-convex-bsd
exit ;;
C38*:ConvexOS:*:* | convex:ConvexOS:C38*:*)
echo c38-convex-bsd
exit ;;
C4*:ConvexOS:*:* | convex:ConvexOS:C4*:*)
echo c4-convex-bsd
exit ;;
CRAY*Y-MP:*:*:*)
echo ymp-cray-unicos${UNAME_RELEASE} | sed -e 's/\.[^.]*$/.X/'
exit ;;
CRAY*[A-Z]90:*:*:*)
echo ${UNAME_MACHINE}-cray-unicos${UNAME_RELEASE} \
| sed -e 's/CRAY.*\([A-Z]90\)/\1/' \
-e y/ABCDEFGHIJKLMNOPQRSTUVWXYZ/abcdefghijklmnopqrstuvwxyz/ \
-e 's/\.[^.]*$/.X/'
exit ;;
CRAY*TS:*:*:*)
echo t90-cray-unicos${UNAME_RELEASE} | sed -e 's/\.[^.]*$/.X/'
exit ;;
CRAY*T3E:*:*:*)
echo alphaev5-cray-unicosmk${UNAME_RELEASE} | sed -e 's/\.[^.]*$/.X/'
exit ;;
CRAY*SV1:*:*:*)
echo sv1-cray-unicos${UNAME_RELEASE} | sed -e 's/\.[^.]*$/.X/'
exit ;;
*:UNICOS/mp:*:*)
echo craynv-cray-unicosmp${UNAME_RELEASE} | sed -e 's/\.[^.]*$/.X/'
exit ;;
F30[01]:UNIX_System_V:*:* | F700:UNIX_System_V:*:*)
FUJITSU_PROC=`uname -m | tr 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
FUJITSU_SYS=`uname -p | tr 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz' | sed -e 's/\///'`
FUJITSU_REL=`echo ${UNAME_RELEASE} | sed -e 's/ /_/'`
echo "${FUJITSU_PROC}-fujitsu-${FUJITSU_SYS}${FUJITSU_REL}"
exit ;;
5000:UNIX_System_V:4.*:*)
FUJITSU_SYS=`uname -p | tr 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz' | sed -e 's/\///'`
FUJITSU_REL=`echo ${UNAME_RELEASE} | tr 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz' | sed -e 's/ /_/'`
echo "sparc-fujitsu-${FUJITSU_SYS}${FUJITSU_REL}"
exit ;;
i*86:BSD/386:*:* | i*86:BSD/OS:*:* | *:Ascend\ Embedded/OS:*:*)
echo ${UNAME_MACHINE}-pc-bsdi${UNAME_RELEASE}
exit ;;
sparc*:BSD/OS:*:*)
echo sparc-unknown-bsdi${UNAME_RELEASE}
exit ;;
*:BSD/OS:*:*)
echo ${UNAME_MACHINE}-unknown-bsdi${UNAME_RELEASE}
exit ;;
*:FreeBSD:*:*)
case ${UNAME_MACHINE} in
pc98)
echo i386-unknown-freebsd`echo ${UNAME_RELEASE}|sed -e 's/[-(].*//'` ;;
amd64)
echo x86_64-unknown-freebsd`echo ${UNAME_RELEASE}|sed -e 's/[-(].*//'` ;;
*)
echo ${UNAME_MACHINE}-unknown-freebsd`echo ${UNAME_RELEASE}|sed -e 's/[-(].*//'` ;;
esac
exit ;;
i*:CYGWIN*:*)
echo ${UNAME_MACHINE}-pc-cygwin
exit ;;
*:MINGW*:*)
echo ${UNAME_MACHINE}-pc-mingw32
exit ;;
i*:windows32*:*)
# uname -m includes "-pc" on this system.
echo ${UNAME_MACHINE}-mingw32
exit ;;
i*:PW*:*)
echo ${UNAME_MACHINE}-pc-pw32
exit ;;
*:Interix*:*)
case ${UNAME_MACHINE} in
x86)
echo i586-pc-interix${UNAME_RELEASE}
exit ;;
authenticamd | genuineintel | EM64T)
echo x86_64-unknown-interix${UNAME_RELEASE}
exit ;;
IA64)
echo ia64-unknown-interix${UNAME_RELEASE}
exit ;;
esac ;;
[345]86:Windows_95:* | [345]86:Windows_98:* | [345]86:Windows_NT:*)
echo i${UNAME_MACHINE}-pc-mks
exit ;;
8664:Windows_NT:*)
echo x86_64-pc-mks
exit ;;
i*:Windows_NT*:* | Pentium*:Windows_NT*:*)
# How do we know it's Interix rather than the generic POSIX subsystem?
# It also conflicts with pre-2.0 versions of AT&T UWIN. Should we
# UNAME_MACHINE based on the output of uname instead of i386?
echo i586-pc-interix
exit ;;
i*:UWIN*:*)
echo ${UNAME_MACHINE}-pc-uwin
exit ;;
amd64:CYGWIN*:*:* | x86_64:CYGWIN*:*:*)
echo x86_64-unknown-cygwin
exit ;;
p*:CYGWIN*:*)
echo powerpcle-unknown-cygwin
exit ;;
prep*:SunOS:5.*:*)
echo powerpcle-unknown-solaris2`echo ${UNAME_RELEASE}|sed -e 's/[^.]*//'`
exit ;;
*:GNU:*:*)
# the GNU system
echo `echo ${UNAME_MACHINE}|sed -e 's,[-/].*$,,'`-unknown-gnu`echo ${UNAME_RELEASE}|sed -e 's,/.*$,,'`
exit ;;
*:GNU/*:*:*)
# other systems with GNU libc and userland
echo ${UNAME_MACHINE}-unknown-`echo ${UNAME_SYSTEM} | sed 's,^[^/]*/,,' | tr '[A-Z]' '[a-z]'``echo ${UNAME_RELEASE}|sed -e 's/[-(].*//'`-gnu
exit ;;
i*86:Minix:*:*)
echo ${UNAME_MACHINE}-pc-minix
exit ;;
alpha:Linux:*:*)
case `sed -n '/^cpu model/s/^.*: \(.*\)/\1/p' < /proc/cpuinfo` in
EV5) UNAME_MACHINE=alphaev5 ;;
EV56) UNAME_MACHINE=alphaev56 ;;
PCA56) UNAME_MACHINE=alphapca56 ;;
PCA57) UNAME_MACHINE=alphapca56 ;;
EV6) UNAME_MACHINE=alphaev6 ;;
EV67) UNAME_MACHINE=alphaev67 ;;
EV68*) UNAME_MACHINE=alphaev68 ;;
esac
objdump --private-headers /bin/sh | grep -q ld.so.1
if test "$?" = 0 ; then LIBC="libc1" ; else LIBC="" ; fi
echo ${UNAME_MACHINE}-unknown-linux-gnu${LIBC}
exit ;;
arm*:Linux:*:*)
eval $set_cc_for_build
if echo __ARM_EABI__ | $CC_FOR_BUILD -E - 2>/dev/null \
| grep -q __ARM_EABI__
then
echo ${UNAME_MACHINE}-unknown-linux-gnu
else
if echo __ARM_PCS_VFP | $CC_FOR_BUILD -E - 2>/dev/null \
| grep -q __ARM_PCS_VFP
then
echo ${UNAME_MACHINE}-unknown-linux-gnueabi
else
echo ${UNAME_MACHINE}-unknown-linux-gnueabihf
fi
fi
exit ;;
avr32*:Linux:*:*)
echo ${UNAME_MACHINE}-unknown-linux-gnu
exit ;;
cris:Linux:*:*)
echo cris-axis-linux-gnu
exit ;;
crisv32:Linux:*:*)
echo crisv32-axis-linux-gnu
exit ;;
frv:Linux:*:*)
echo frv-unknown-linux-gnu
exit ;;
i*86:Linux:*:*)
LIBC=gnu
eval $set_cc_for_build
sed 's/^ //' << EOF >$dummy.c
#ifdef __dietlibc__
LIBC=dietlibc
#endif
EOF
eval `$CC_FOR_BUILD -E $dummy.c 2>/dev/null | grep '^LIBC'`
echo "${UNAME_MACHINE}-pc-linux-${LIBC}"
exit ;;
ia64:Linux:*:*)
echo ${UNAME_MACHINE}-unknown-linux-gnu
exit ;;
m32r*:Linux:*:*)
echo ${UNAME_MACHINE}-unknown-linux-gnu
exit ;;
m68*:Linux:*:*)
echo ${UNAME_MACHINE}-unknown-linux-gnu
exit ;;
mips:Linux:*:* | mips64:Linux:*:*)
eval $set_cc_for_build
sed 's/^ //' << EOF >$dummy.c
#undef CPU
#undef ${UNAME_MACHINE}
#undef ${UNAME_MACHINE}el
#if defined(__MIPSEL__) || defined(__MIPSEL) || defined(_MIPSEL) || defined(MIPSEL)
CPU=${UNAME_MACHINE}el
#else
#if defined(__MIPSEB__) || defined(__MIPSEB) || defined(_MIPSEB) || defined(MIPSEB)
CPU=${UNAME_MACHINE}
#else
CPU=
#endif
#endif
EOF
eval `$CC_FOR_BUILD -E $dummy.c 2>/dev/null | grep '^CPU'`
test x"${CPU}" != x && { echo "${CPU}-unknown-linux-gnu"; exit; }
;;
or32:Linux:*:*)
echo or32-unknown-linux-gnu
exit ;;
padre:Linux:*:*)
echo sparc-unknown-linux-gnu
exit ;;
parisc64:Linux:*:* | hppa64:Linux:*:*)
echo hppa64-unknown-linux-gnu
exit ;;
parisc:Linux:*:* | hppa:Linux:*:*)
# Look for CPU level
case `grep '^cpu[^a-z]*:' /proc/cpuinfo 2>/dev/null | cut -d' ' -f2` in
PA7*) echo hppa1.1-unknown-linux-gnu ;;
PA8*) echo hppa2.0-unknown-linux-gnu ;;
*) echo hppa-unknown-linux-gnu ;;
esac
exit ;;
ppc64:Linux:*:*)
echo powerpc64-unknown-linux-gnu
exit ;;
ppc:Linux:*:*)
echo powerpc-unknown-linux-gnu
exit ;;
s390:Linux:*:* | s390x:Linux:*:*)
echo ${UNAME_MACHINE}-ibm-linux
exit ;;
sh64*:Linux:*:*)
echo ${UNAME_MACHINE}-unknown-linux-gnu
exit ;;
sh*:Linux:*:*)
echo ${UNAME_MACHINE}-unknown-linux-gnu
exit ;;
sparc:Linux:*:* | sparc64:Linux:*:*)
echo ${UNAME_MACHINE}-unknown-linux-gnu
exit ;;
tile*:Linux:*:*)
echo ${UNAME_MACHINE}-tilera-linux-gnu
exit ;;
vax:Linux:*:*)
echo ${UNAME_MACHINE}-dec-linux-gnu
exit ;;
x86_64:Linux:*:*)
echo x86_64-unknown-linux-gnu
exit ;;
xtensa*:Linux:*:*)
echo ${UNAME_MACHINE}-unknown-linux-gnu
exit ;;
i*86:DYNIX/ptx:4*:*)
# ptx 4.0 does uname -s correctly, with DYNIX/ptx in there.
# earlier versions are messed up and put the nodename in both
# sysname and nodename.
echo i386-sequent-sysv4
exit ;;
i*86:UNIX_SV:4.2MP:2.*)
# Unixware is an offshoot of SVR4, but it has its own version
# number series starting with 2...
# I am not positive that other SVR4 systems won't match this,
# I just have to hope. -- rms.
# Use sysv4.2uw... so that sysv4* matches it.
echo ${UNAME_MACHINE}-pc-sysv4.2uw${UNAME_VERSION}
exit ;;
i*86:OS/2:*:*)
# If we were able to find `uname', then EMX Unix compatibility
# is probably installed.
echo ${UNAME_MACHINE}-pc-os2-emx
exit ;;
i*86:XTS-300:*:STOP)
echo ${UNAME_MACHINE}-unknown-stop
exit ;;
i*86:atheos:*:*)
echo ${UNAME_MACHINE}-unknown-atheos
exit ;;
i*86:syllable:*:*)
echo ${UNAME_MACHINE}-pc-syllable
exit ;;
i*86:LynxOS:2.*:* | i*86:LynxOS:3.[01]*:* | i*86:LynxOS:4.[02]*:*)
echo i386-unknown-lynxos${UNAME_RELEASE}
exit ;;
i*86:*DOS:*:*)
echo ${UNAME_MACHINE}-pc-msdosdjgpp
exit ;;
i*86:*:4.*:* | i*86:SYSTEM_V:4.*:*)
UNAME_REL=`echo ${UNAME_RELEASE} | sed 's/\/MP$//'`
if grep Novell /usr/include/link.h >/dev/null 2>/dev/null; then
echo ${UNAME_MACHINE}-univel-sysv${UNAME_REL}
else
echo ${UNAME_MACHINE}-pc-sysv${UNAME_REL}
fi
exit ;;
i*86:*:5:[678]*)
# UnixWare 7.x, OpenUNIX and OpenServer 6.
case `/bin/uname -X | grep "^Machine"` in
*486*) UNAME_MACHINE=i486 ;;
*Pentium) UNAME_MACHINE=i586 ;;
*Pent*|*Celeron) UNAME_MACHINE=i686 ;;
esac
echo ${UNAME_MACHINE}-unknown-sysv${UNAME_RELEASE}${UNAME_SYSTEM}${UNAME_VERSION}
exit ;;
i*86:*:3.2:*)
if test -f /usr/options/cb.name; then
UNAME_REL=`sed -n 's/.*Version //p' /dev/null >/dev/null ; then
UNAME_REL=`(/bin/uname -X|grep Release|sed -e 's/.*= //')`
(/bin/uname -X|grep i80486 >/dev/null) && UNAME_MACHINE=i486
(/bin/uname -X|grep '^Machine.*Pentium' >/dev/null) \
&& UNAME_MACHINE=i586
(/bin/uname -X|grep '^Machine.*Pent *II' >/dev/null) \
&& UNAME_MACHINE=i686
(/bin/uname -X|grep '^Machine.*Pentium Pro' >/dev/null) \
&& UNAME_MACHINE=i686
echo ${UNAME_MACHINE}-pc-sco$UNAME_REL
else
echo ${UNAME_MACHINE}-pc-sysv32
fi
exit ;;
pc:*:*:*)
# Left here for compatibility:
# uname -m prints for DJGPP always 'pc', but it prints nothing about
# the processor, so we play safe by assuming i586.
# Note: whatever this is, it MUST be the same as what config.sub
# prints for the "djgpp" host, or else GDB configury will decide that
# this is a cross-build.
echo i586-pc-msdosdjgpp
exit ;;
Intel:Mach:3*:*)
echo i386-pc-mach3
exit ;;
paragon:*:*:*)
echo i860-intel-osf1
exit ;;
i860:*:4.*:*) # i860-SVR4
if grep Stardent /usr/include/sys/uadmin.h >/dev/null 2>&1 ; then
echo i860-stardent-sysv${UNAME_RELEASE} # Stardent Vistra i860-SVR4
else # Add other i860-SVR4 vendors below as they are discovered.
echo i860-unknown-sysv${UNAME_RELEASE} # Unknown i860-SVR4
fi
exit ;;
mini*:CTIX:SYS*5:*)
# "miniframe"
echo m68010-convergent-sysv
exit ;;
mc68k:UNIX:SYSTEM5:3.51m)
echo m68k-convergent-sysv
exit ;;
M680?0:D-NIX:5.3:*)
echo m68k-diab-dnix
exit ;;
M68*:*:R3V[5678]*:*)
test -r /sysV68 && { echo 'm68k-motorola-sysv'; exit; } ;;
3[345]??:*:4.0:3.0 | 3[34]??A:*:4.0:3.0 | 3[34]??,*:*:4.0:3.0 | 3[34]??/*:*:4.0:3.0 | 4400:*:4.0:3.0 | 4850:*:4.0:3.0 | SKA40:*:4.0:3.0 | SDS2:*:4.0:3.0 | SHG2:*:4.0:3.0 | S7501*:*:4.0:3.0)
OS_REL=''
test -r /etc/.relid \
&& OS_REL=.`sed -n 's/[^ ]* [^ ]* \([0-9][0-9]\).*/\1/p' < /etc/.relid`
/bin/uname -p 2>/dev/null | grep 86 >/dev/null \
&& { echo i486-ncr-sysv4.3${OS_REL}; exit; }
/bin/uname -p 2>/dev/null | /bin/grep entium >/dev/null \
&& { echo i586-ncr-sysv4.3${OS_REL}; exit; } ;;
3[34]??:*:4.0:* | 3[34]??,*:*:4.0:*)
/bin/uname -p 2>/dev/null | grep 86 >/dev/null \
&& { echo i486-ncr-sysv4; exit; } ;;
NCR*:*:4.2:* | MPRAS*:*:4.2:*)
OS_REL='.3'
test -r /etc/.relid \
&& OS_REL=.`sed -n 's/[^ ]* [^ ]* \([0-9][0-9]\).*/\1/p' < /etc/.relid`
/bin/uname -p 2>/dev/null | grep 86 >/dev/null \
&& { echo i486-ncr-sysv4.3${OS_REL}; exit; }
/bin/uname -p 2>/dev/null | /bin/grep entium >/dev/null \
&& { echo i586-ncr-sysv4.3${OS_REL}; exit; }
/bin/uname -p 2>/dev/null | /bin/grep pteron >/dev/null \
&& { echo i586-ncr-sysv4.3${OS_REL}; exit; } ;;
m68*:LynxOS:2.*:* | m68*:LynxOS:3.0*:*)
echo m68k-unknown-lynxos${UNAME_RELEASE}
exit ;;
mc68030:UNIX_System_V:4.*:*)
echo m68k-atari-sysv4
exit ;;
TSUNAMI:LynxOS:2.*:*)
echo sparc-unknown-lynxos${UNAME_RELEASE}
exit ;;
rs6000:LynxOS:2.*:*)
echo rs6000-unknown-lynxos${UNAME_RELEASE}
exit ;;
PowerPC:LynxOS:2.*:* | PowerPC:LynxOS:3.[01]*:* | PowerPC:LynxOS:4.[02]*:*)
echo powerpc-unknown-lynxos${UNAME_RELEASE}
exit ;;
SM[BE]S:UNIX_SV:*:*)
echo mips-dde-sysv${UNAME_RELEASE}
exit ;;
RM*:ReliantUNIX-*:*:*)
echo mips-sni-sysv4
exit ;;
RM*:SINIX-*:*:*)
echo mips-sni-sysv4
exit ;;
*:SINIX-*:*:*)
if uname -p 2>/dev/null >/dev/null ; then
UNAME_MACHINE=`(uname -p) 2>/dev/null`
echo ${UNAME_MACHINE}-sni-sysv4
else
echo ns32k-sni-sysv
fi
exit ;;
PENTIUM:*:4.0*:*) # Unisys `ClearPath HMP IX 4000' SVR4/MP effort
# says
echo i586-unisys-sysv4
exit ;;
*:UNIX_System_V:4*:FTX*)
# From Gerald Hewes .
# How about differentiating between stratus architectures? -djm
echo hppa1.1-stratus-sysv4
exit ;;
*:*:*:FTX*)
# From seanf@swdc.stratus.com.
echo i860-stratus-sysv4
exit ;;
i*86:VOS:*:*)
# From Paul.Green@stratus.com.
echo ${UNAME_MACHINE}-stratus-vos
exit ;;
*:VOS:*:*)
# From Paul.Green@stratus.com.
echo hppa1.1-stratus-vos
exit ;;
mc68*:A/UX:*:*)
echo m68k-apple-aux${UNAME_RELEASE}
exit ;;
news*:NEWS-OS:6*:*)
echo mips-sony-newsos6
exit ;;
R[34]000:*System_V*:*:* | R4000:UNIX_SYSV:*:* | R*000:UNIX_SV:*:*)
if [ -d /usr/nec ]; then
echo mips-nec-sysv${UNAME_RELEASE}
else
echo mips-unknown-sysv${UNAME_RELEASE}
fi
exit ;;
BeBox:BeOS:*:*) # BeOS running on hardware made by Be, PPC only.
echo powerpc-be-beos
exit ;;
BeMac:BeOS:*:*) # BeOS running on Mac or Mac clone, PPC only.
echo powerpc-apple-beos
exit ;;
BePC:BeOS:*:*) # BeOS running on Intel PC compatible.
echo i586-pc-beos
exit ;;
BePC:Haiku:*:*) # Haiku running on Intel PC compatible.
echo i586-pc-haiku
exit ;;
SX-4:SUPER-UX:*:*)
echo sx4-nec-superux${UNAME_RELEASE}
exit ;;
SX-5:SUPER-UX:*:*)
echo sx5-nec-superux${UNAME_RELEASE}
exit ;;
SX-6:SUPER-UX:*:*)
echo sx6-nec-superux${UNAME_RELEASE}
exit ;;
SX-7:SUPER-UX:*:*)
echo sx7-nec-superux${UNAME_RELEASE}
exit ;;
SX-8:SUPER-UX:*:*)
echo sx8-nec-superux${UNAME_RELEASE}
exit ;;
SX-8R:SUPER-UX:*:*)
echo sx8r-nec-superux${UNAME_RELEASE}
exit ;;
Power*:Rhapsody:*:*)
echo powerpc-apple-rhapsody${UNAME_RELEASE}
exit ;;
*:Rhapsody:*:*)
echo ${UNAME_MACHINE}-apple-rhapsody${UNAME_RELEASE}
exit ;;
*:Darwin:*:*)
UNAME_PROCESSOR=`uname -p` || UNAME_PROCESSOR=unknown
case $UNAME_PROCESSOR in
i386)
eval $set_cc_for_build
if [ "$CC_FOR_BUILD" != 'no_compiler_found' ]; then
if (echo '#ifdef __LP64__'; echo IS_64BIT_ARCH; echo '#endif') | \
(CCOPTS= $CC_FOR_BUILD -E - 2>/dev/null) | \
grep IS_64BIT_ARCH >/dev/null
then
UNAME_PROCESSOR="x86_64"
fi
fi ;;
unknown) UNAME_PROCESSOR=powerpc ;;
esac
echo ${UNAME_PROCESSOR}-apple-darwin${UNAME_RELEASE}
exit ;;
*:procnto*:*:* | *:QNX:[0123456789]*:*)
UNAME_PROCESSOR=`uname -p`
if test "$UNAME_PROCESSOR" = "x86"; then
UNAME_PROCESSOR=i386
UNAME_MACHINE=pc
fi
echo ${UNAME_PROCESSOR}-${UNAME_MACHINE}-nto-qnx${UNAME_RELEASE}
exit ;;
*:QNX:*:4*)
echo i386-pc-qnx
exit ;;
NEO-?:NONSTOP_KERNEL:*:*)
echo neo-tandem-nsk${UNAME_RELEASE}
exit ;;
NSE-?:NONSTOP_KERNEL:*:*)
echo nse-tandem-nsk${UNAME_RELEASE}
exit ;;
NSR-?:NONSTOP_KERNEL:*:*)
echo nsr-tandem-nsk${UNAME_RELEASE}
exit ;;
*:NonStop-UX:*:*)
echo mips-compaq-nonstopux
exit ;;
BS2000:POSIX*:*:*)
echo bs2000-siemens-sysv
exit ;;
DS/*:UNIX_System_V:*:*)
echo ${UNAME_MACHINE}-${UNAME_SYSTEM}-${UNAME_RELEASE}
exit ;;
*:Plan9:*:*)
# "uname -m" is not consistent, so use $cputype instead. 386
# is converted to i386 for consistency with other x86
# operating systems.
if test "$cputype" = "386"; then
UNAME_MACHINE=i386
else
UNAME_MACHINE="$cputype"
fi
echo ${UNAME_MACHINE}-unknown-plan9
exit ;;
*:TOPS-10:*:*)
echo pdp10-unknown-tops10
exit ;;
*:TENEX:*:*)
echo pdp10-unknown-tenex
exit ;;
KS10:TOPS-20:*:* | KL10:TOPS-20:*:* | TYPE4:TOPS-20:*:*)
echo pdp10-dec-tops20
exit ;;
XKL-1:TOPS-20:*:* | TYPE5:TOPS-20:*:*)
echo pdp10-xkl-tops20
exit ;;
*:TOPS-20:*:*)
echo pdp10-unknown-tops20
exit ;;
*:ITS:*:*)
echo pdp10-unknown-its
exit ;;
SEI:*:*:SEIUX)
echo mips-sei-seiux${UNAME_RELEASE}
exit ;;
*:DragonFly:*:*)
echo ${UNAME_MACHINE}-unknown-dragonfly`echo ${UNAME_RELEASE}|sed -e 's/[-(].*//'`
exit ;;
*:*VMS:*:*)
UNAME_MACHINE=`(uname -p) 2>/dev/null`
case "${UNAME_MACHINE}" in
A*) echo alpha-dec-vms ; exit ;;
I*) echo ia64-dec-vms ; exit ;;
V*) echo vax-dec-vms ; exit ;;
esac ;;
*:XENIX:*:SysV)
echo i386-pc-xenix
exit ;;
i*86:skyos:*:*)
echo ${UNAME_MACHINE}-pc-skyos`echo ${UNAME_RELEASE}` | sed -e 's/ .*$//'
exit ;;
i*86:rdos:*:*)
echo ${UNAME_MACHINE}-pc-rdos
exit ;;
i*86:AROS:*:*)
echo ${UNAME_MACHINE}-pc-aros
exit ;;
esac
#echo '(No uname command or uname output not recognized.)' 1>&2
#echo "${UNAME_MACHINE}:${UNAME_SYSTEM}:${UNAME_RELEASE}:${UNAME_VERSION}" 1>&2
eval $set_cc_for_build
cat >$dummy.c <
# include
#endif
main ()
{
#if defined (sony)
#if defined (MIPSEB)
/* BFD wants "bsd" instead of "newsos". Perhaps BFD should be changed,
I don't know.... */
printf ("mips-sony-bsd\n"); exit (0);
#else
#include
printf ("m68k-sony-newsos%s\n",
#ifdef NEWSOS4
"4"
#else
""
#endif
); exit (0);
#endif
#endif
#if defined (__arm) && defined (__acorn) && defined (__unix)
printf ("arm-acorn-riscix\n"); exit (0);
#endif
#if defined (hp300) && !defined (hpux)
printf ("m68k-hp-bsd\n"); exit (0);
#endif
#if defined (NeXT)
#if !defined (__ARCHITECTURE__)
#define __ARCHITECTURE__ "m68k"
#endif
int version;
version=`(hostinfo | sed -n 's/.*NeXT Mach \([0-9]*\).*/\1/p') 2>/dev/null`;
if (version < 4)
printf ("%s-next-nextstep%d\n", __ARCHITECTURE__, version);
else
printf ("%s-next-openstep%d\n", __ARCHITECTURE__, version);
exit (0);
#endif
#if defined (MULTIMAX) || defined (n16)
#if defined (UMAXV)
printf ("ns32k-encore-sysv\n"); exit (0);
#else
#if defined (CMU)
printf ("ns32k-encore-mach\n"); exit (0);
#else
printf ("ns32k-encore-bsd\n"); exit (0);
#endif
#endif
#endif
#if defined (__386BSD__)
printf ("i386-pc-bsd\n"); exit (0);
#endif
#if defined (sequent)
#if defined (i386)
printf ("i386-sequent-dynix\n"); exit (0);
#endif
#if defined (ns32000)
printf ("ns32k-sequent-dynix\n"); exit (0);
#endif
#endif
#if defined (_SEQUENT_)
struct utsname un;
uname(&un);
if (strncmp(un.version, "V2", 2) == 0) {
printf ("i386-sequent-ptx2\n"); exit (0);
}
if (strncmp(un.version, "V1", 2) == 0) { /* XXX is V1 correct? */
printf ("i386-sequent-ptx1\n"); exit (0);
}
printf ("i386-sequent-ptx\n"); exit (0);
#endif
#if defined (vax)
# if !defined (ultrix)
# include
# if defined (BSD)
# if BSD == 43
printf ("vax-dec-bsd4.3\n"); exit (0);
# else
# if BSD == 199006
printf ("vax-dec-bsd4.3reno\n"); exit (0);
# else
printf ("vax-dec-bsd\n"); exit (0);
# endif
# endif
# else
printf ("vax-dec-bsd\n"); exit (0);
# endif
# else
printf ("vax-dec-ultrix\n"); exit (0);
# endif
#endif
#if defined (alliant) && defined (i860)
printf ("i860-alliant-bsd\n"); exit (0);
#endif
exit (1);
}
EOF
$CC_FOR_BUILD -o $dummy $dummy.c 2>/dev/null && SYSTEM_NAME=`$dummy` &&
{ echo "$SYSTEM_NAME"; exit; }
# Apollos put the system type in the environment.
test -d /usr/apollo && { echo ${ISP}-apollo-${SYSTYPE}; exit; }
# Convex versions that predate uname can use getsysinfo(1)
if [ -x /usr/convex/getsysinfo ]
then
case `getsysinfo -f cpu_type` in
c1*)
echo c1-convex-bsd
exit ;;
c2*)
if getsysinfo -f scalar_acc
then echo c32-convex-bsd
else echo c2-convex-bsd
fi
exit ;;
c34*)
echo c34-convex-bsd
exit ;;
c38*)
echo c38-convex-bsd
exit ;;
c4*)
echo c4-convex-bsd
exit ;;
esac
fi
cat >&2 < in order to provide the needed
information to handle your system.
config.guess timestamp = $timestamp
uname -m = `(uname -m) 2>/dev/null || echo unknown`
uname -r = `(uname -r) 2>/dev/null || echo unknown`
uname -s = `(uname -s) 2>/dev/null || echo unknown`
uname -v = `(uname -v) 2>/dev/null || echo unknown`
/usr/bin/uname -p = `(/usr/bin/uname -p) 2>/dev/null`
/bin/uname -X = `(/bin/uname -X) 2>/dev/null`
hostinfo = `(hostinfo) 2>/dev/null`
/bin/universe = `(/bin/universe) 2>/dev/null`
/usr/bin/arch -k = `(/usr/bin/arch -k) 2>/dev/null`
/bin/arch = `(/bin/arch) 2>/dev/null`
/usr/bin/oslevel = `(/usr/bin/oslevel) 2>/dev/null`
/usr/convex/getsysinfo = `(/usr/convex/getsysinfo) 2>/dev/null`
UNAME_MACHINE = ${UNAME_MACHINE}
UNAME_RELEASE = ${UNAME_RELEASE}
UNAME_SYSTEM = ${UNAME_SYSTEM}
UNAME_VERSION = ${UNAME_VERSION}
EOF
exit 1
# Local variables:
# eval: (add-hook 'write-file-hooks 'time-stamp)
# time-stamp-start: "timestamp='"
# time-stamp-format: "%:y-%02m-%02d"
# time-stamp-end: "'"
# End:
vde2-2.3.2/COPYING.slirpvde 0000644 0001750 0001750 00000005704 11663221057 014325 0 ustar renzo renzo Slirp was written by Danny Gasparovski.
Copyright (c), 1995,1996 All Rights Reserved.
Slirp is maintained by Kelly Price
Slirp is free software; "free" as in you don't have to pay for it, and you
are free to do whatever you want with it. I do not accept any donations,
monetary or otherwise, for Slirp. Instead, I would ask you to pass this
potential donation to your favorite charity. In fact, I encourage
*everyone* who finds Slirp useful to make a small donation to their
favorite charity (for example, GreenPeace). This is not a requirement, but
a suggestion from someone who highly values the service they provide.
The copyright terms and conditions:
---BEGIN---
Copyright (c) 1995,1996 Danny Gasparovski. All rights reserved.
Redistribution and use in source and binary forms, with or without
modification, are permitted provided that the following conditions
are met:
1. Redistributions of source code must retain the above copyright
notice, this list of conditions and the following disclaimer.
2. Redistributions in binary form must reproduce the above copyright
notice, this list of conditions and the following disclaimer in the
documentation and/or other materials provided with the distribution.
3. All advertising materials mentioning features or use of this software
must display the following acknowledgment:
This product includes software developed by Danny Gasparovski.
THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES,
INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY
AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL
DANNY GASPAROVSKI OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT,
INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT
NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
(INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
---END---
This basically means you can do anything you want with the software, except
1) call it your own, and 2) claim warranty on it. There is no warranty for
this software. None. Nada. If you lose a million dollars while using
Slirp, that's your loss not mine. So, ***USE AT YOUR OWN RISK!***.
If these conditions cannot be met due to legal restrictions (E.g. where it
is against the law to give out Software without warranty), you must cease
using the software and delete all copies you have.
Slirp uses code that is copyrighted by the following people/organizations:
Juha Pirkola.
Gregory M. Christy.
The Regents of the University of California.
Carnegie Mellon University.
The Australian National University.
RSA Data Security, Inc.
Please read the top of each source file for the details on the various
copyrights.
vde2-2.3.2/man/ 0000755 0001750 0001750 00000000000 11663221165 012210 5 ustar renzo renzo vde2-2.3.2/man/vdeq.1 0000644 0001750 0001750 00000011762 11663221057 013240 0 ustar renzo renzo .TH VDEQ 1 "December 6, 2006" "Virtual Distributed Ethernet"
.SH NAME
vdeq \- Virtual Distributed Ethernet wrapper for QEMU/KVM virtual machines
.SH SYNOPSIS
.B vdeq
.B qemu
[
.B \-\-mod
.I octalmode
]
.I QEMU_OPTIONS
.B -net vde[,vlan=n][,sock=socketpath][,port=n]
.I QEMU_OPTIONS
.br
.B vdeq
.B kvm
[
.B \-\-mod
.I octalmode
]
.I KVM_OPTIONS
.B -net vde[,vlan=n][,sock=socketpath][,port=n]
.I KVM_OPTIONS
.br
.B vde\fP{\fIqemu_name\fP}
[
.B \-\-mod
.I octalmode
]
.I QEMU_OPTIONS
.B -net vde[,vlan=n][,sock=socketpath][,port=n]
.I QEMU_OPTIONS
.br
.SH OLD SYNOPSIS
.B vdeq
.B qemu
[
.B \-\-mod
.I octalmode
]
[
.B \-sock
.I socketpath
[
.I ,socketpath
[
.I ,...
]
]
]
[ qemu_args ]
.br
.B vde\fP{\fIqemu_name\fP}
[
.B \-sock
.I socketpath
[
.I ,socketpath
[
.I ,...
]
]
]
[ qemu_args ]
.br
.SH DESCRIPTION
\fBvdeq\fP
is a wrapper to start a QEMU/KVM virtual machine connected to a VDE network.
It uses the qemu/kvm \fB \-tun-fd \fP parameter to set up the connection with
a vde_switch.
The command
.RS
.br
.B
vdeq qemu -b c -hda=sampledisk
.RE
starts a qemu machine which boots from the sampledisk image and
has a ne2000 ethernet interface connected to the standard vde_switch.
The command
.RS
.br
.B
vdeq kvm -b c -hda=sampledisk
.RE
starts a kvm machine which boots from the sampledisk image and
has a ne2000 ethernet interface connected to the standard vde_switch.
.br
It is also possible to create symbolic links to the vdeq executable to have
a simpler command. If the link has a name that begins with vde the remaining part
of the name is taken as the qemu command. For example if vdeq is linked to
vdeqemu:
.RS
.br
.B
vdeqemu -b c -hda=sampledisk
.RE
starts qemu as above. If vdeq is linked to vdekvm:
.RS
.br
.B
vdekvm -b c -hda=sampledisk
.RE
starts kvm with the same parameters.
The new syntax is consistent with the new Qemu 0.8.0 network parameters.
Using vdeq is possible to specify a vde interface in the same way as
user,tap or socket interfaces.
The \fBsock=\fP parameter can be used to use a specific socket.
Please note that what qemu names as vlan is not related to the
802.1q VLAN managed by the vde_switch.
\fBport=\fP can be used to specify the port of the switch,
otherwise the first allocatable port is assigned.
The following command run a qemu VM with two ethernet interface
connected to the standard switch and
to the switch with local socket "/tmp/my.ctl", port 10, respectively
.RS
.br
.B
vde qemu -net nic,vlan=0 -net nic,vlan=1 -net vde,vlan=0 -net vde,vlan=1,sock=/tmp/my.ctl,port=10
.RE
.RS
.br
.B
vdeqemu -net nic,vlan=0 -net nic,vlan=1 -net vde,vlan=0 -net vde,vlan=1,sock=/tmp/my.ctl,port=10
.RE
The following command run a kvm VM with two ethernet interface
connected to the standard switch and
to the switch with local socket "/tmp/my.ctl", port 10, respectively
.RS
.br
.B
vde kvm -net nic,vlan=0 -net nic,vlan=1 -net vde,vlan=0 -net vde,vlan=1,sock=/tmp/my.ctl,port=10
.RE
.RS
.br
.B
vdekvm -net nic,vlan=0 -net nic,vlan=1 -net vde,vlan=0 -net vde,vlan=1,sock=/tmp/my.ctl,port=10
.RE
The old syntax can be used with Qemu 0.8.0 but all the vde interfaces are assigned to
vlan 0.
.RS
.br
.B
vdeq qemu -sock /tmp/vde.ctl,/tmp/my.ctl -b c -hda=sampledisk
.RE
.RS
.br
.B
vdeqemu -sock /tmp/vde.ctl,/tmp/my.ctl -b c -hda=sampledisk
.RE
both start qemu with \fBone\fP ethernet interface connected both to the standard switch and
to the switch with local socket "/tmp/my.ctl".
.SH OPTIONS
.TP
.B --mod
.I octalmode,
specify the mode for comm socket.
.br
.TP
.B \-sock
.I socketpath,
specify the UNIX socket to be used by local programs for joining the VDE.
The default value is "/tmp/vde.ctl"
It is also possible to indicate several socketpath (comma separated, no blanks):
in this case several interfaces are defined. The first socketpath is connected
to the first ne2k interface and so on.
.br
.TP
.B -h, -help, --help
print a Usage help.
.SH NOTE
Qemu has changed its syntax for networking (cvs Nov.15 2005).
As a temporary solution use vdeoq and vdeoqemu instead of vdeq and vdeqemu
if you are running a qemu with the old syntax.
.br
By default qemu uses the same MAC address for every virtual machine, so if
you plan to use several instances of qemu be sure to explicitly set a different
MAC address for each virtual machine. While generating your address beware to
not use broadcast/multicast reserved MACs, ethernet rules say: the multicast
bit is the low-order bit of the first byte, which is "the first bit on the wire".
For example \fI34:12:de:ad:be:ef\fP is an unicast address, \fI35:12:de:ad:be:ef\fP
is a multicast address (see ETHERNET MULTICAST ADDRESSES section in
http://www.iana.org/assignments/ethernet-numbers for more informations).
.br
.SH NOTICE
Virtual Distributed Ethernet is not related in any way with
www.vde.com ("Verband der Elektrotechnik, Elektronik und Informationstechnik"
i.e. the German "Association for Electrical, Electronic & Information
Technologies").
.SH SEE ALSO
\fBvde_switch\fP(1),
\fBvde_plug\fP(1),
\fBvde_plug2tap\fP(1),
\fBdpipe\fP(1).
.br
.SH AUTHOR
VDE is a project by Renzo Davoli
vde2-2.3.2/man/dpipe.1 0000644 0001750 0001750 00000004260 11663221057 013375 0 ustar renzo renzo .TH DPIPE 1 "December 6, 2006" "Virtual Distributed Ethernet"
.SH NAME
dpipe \- bi-directional pipe command
.SH SYNOPSIS
.B dpipe
[
.I command
[
.I args
]
]
.BI =
[
.I command
[
.I args
]
]
.br
.B dpipe
[
.I command
[
.I args
]
]
.BI =
[
.I command
[
.I args
]
]
[
.BI =
[
.I command
[
.I args
]
]
]
\&...
.br
.SH DESCRIPTION
\fBdpipe\fP is a general tool to run two commands diverting the
standard output of the first command into the standard input of the second
and vice-versa.
It is the bi-directional
extension of the \fB|\fP (pipe) syntax used by all the shells.
The \fB=\fP has been chosen as a metaphor of two parallel communication lines
between the commands.
It is also possible to concatenate several tools. Intermediate programs communicate
using standard input and standard output with the preceding tool and alternate standard input
and output (respectively file descriptors number 3 and 4) towards the following tool.
If an intermediate tool should process only the data flowing in one direction
use \fB{\fP or \fB}\fP
as suffix for the preceding \fB=\fP and prefix of the following one.
.br
This tool has been written as a tool for the Virtual Distributed Ethernet.
.SH EXAMPLE
.B dpipe a = b
.br
processes a and b are bidirectionally connected: stdin of a is connected to stdout of b
and vice-versa
.br
.B dpipe a = b = c
.br
a and b are connected as above. Alternate stdin of b is connected to stdout of c and
alternate stdout of b to stdin of c
.br
.B dpipe a =} b }= c
.br
This is a cycle of pipes: stdout of a is connected to stdin of b, stdout of b with stdin
of c, and stdout of c to stdin of a
.br
.B dpipe a =} b }={ c {= d = e
.br
all the notations can be mixed together.
this is a -> b -> d -> c and back to a; alternate ports of d are connected to e
.SH OPTIONS
no options.
.SH NOTICE
Virtual Distributed Ethernet is not related in any way with
www.vde.com ("Verband der Elektrotechnik, Elektronik und Informationstechnik"
i.e. the German "Association for Electrical, Electronic & Information
Technologies").
.SH SEE ALSO
\fBvde_switch\fP(1),
\fBvde_plug\fP(1),
\fBvde_plug2tap\fP(1),
\fBvdeq\fP(1).
\fBwirefilter\fP(1).
.br
.SH AUTHOR
VDE is a project by Renzo Davoli .
vde2-2.3.2/man/wirefilter.1 0000644 0001750 0001750 00000017504 11663221057 014455 0 ustar renzo renzo .TH WIREFILTER 1 "December 6, 2006" "Virtual Distributed Ethernet"
.SH NAME
wirefilter \- Wire packet filter for Virtual Distributed Ethernet
.SH SYNOPSIS
.B wirefilter
[\fB\-f\fI rcfile\fR]
[\fB\-l\fI loss\fR]
[\fB\-l\fI lostburst\fR]
[\fB\-d\fI delay\fR]
[\fB\-D\fI dup\fR]
[\fB\-b\fI bandwidth\fR]
[\fB\-s\fI interface_speed\fR]
[\fB\-c\fI channel_bufsize\fR]
[\fB\-n\fI noise_factor\fR]
[\fB\-m\fI mtu_size\fR]
[\fB\-M\fI mgmt socket\fR]
[\fB\-v\fI vde_plug1:vde_plug2\fR]
[\fB\--daemon\fI]
[\fB\--pidfile\fI pidfile_path]
[\fB\--blink\fI blink]
[\fB\--blinkid\fI blink_identifier]
[\fB-N\fR]
.br
.SH DESCRIPTION
A
\fBwirefilter\fP
is able to emulate delays and packet loss on virtual wires.
e.g.:
.B
dpipe vde_plug /tmp/s1 = wirefilter -l 10 = vde_plug /tmp/s2
creates a wire between two vde_switches (with sockets /tmp/s1 and /tmp/s2
respectively). This cable looses 10% of the packets in each direction.
The same cable can be created using:
.B
wirefilter -v /tmp/s1:/tmp/s2 -l 10
.SH OPTIONS
.TP
.B \-f "\fIrcfile\fP"
use a startup configuration file. It is useful for complex defitions
such as those for the Markov mode (see below).
The startup configuration file has the same syntax of the management
interface, in other word it is a script of management commands executed
before the first packet is forwarded.
.TP
.B \-l "\fIloss\fP"
percentage of loss as a floating point number. It is possible to specify
different loss percentage for the two channels: LR20.5 means 20.5% of packet
flowing left to right are lost, RL10 means 10% from right to left.
.TP
.B \-L "\fIlostburst\fP"
when this is not zero, wirefilter uses the Gilbert model for bursty errors.
This is the mean length of lost packet bursts. (it is a two state Markov
chain: the probability to exit from the faulty state is \fI1/lostburst\fP, the
probability to enter the faulty state is \fIloss/(lostburst-(1-loss))\fP. The
loss rate converges to the value \fIloss\fR.
.TP
.B \-d "\fIdelay\fP"
Extra delay (in milliseconds). This delay is added to the
real communication delay. Packets are temporarily stored and resent after the
delay. It is possible to specify different values for LR and RL like in the
previous option. When the delay is specified as two numbers with a + in
between, the first is the standard delay and the second is a random variation.
1000+500 means that the delay can be randomly chosen between half second and
1.5 seconds. It is possible to add 'U' or 'N' at the end. 1000+500U means that
the dealys are uniformly distributed, 1000+500N means that the delays follow
a Gaussian normal distribution (more than 98% of the values are inside the
limits).
.TP
.B \-D "\fIdup\fP"
percentage of dup packet. It has the same syntax of -l. Do not use dup factor 100%
because it means that each packet is sent infinite times.
.TP
.B \-b "\fIbandwidth\fP"
Channel bandwidth in Bytes/sec. It has the same syntax of -d. It is also possible to
use suffixes K,M,G to abbreviate 2^10, 2^20, 2^30.
128K means 128KBytes/sec. 128+64K means 64i to 196KBytes/sec.
Sender is not prevented from sending packets, delivery is delayed to limit the bandwidth
to the desired value. (Like a bottleneck along the path)
U and N after the values (e.g. 128+64KN) set the statistic distribution to
use (uniform or normal).
.TP
.B \-s "\fIspeed\fP"
Interface speed in Bytes/sec. It has the same syntax of -b. Input is blocked for
the tramission time of the packet, thus the sender is prevented from sending too fast.
.TP
.B \-c "\fIchannel_bufsize\fP"
Channel buffer size (in Bytes): maximum size of the packet queue. Exceeding packets
are discarded.
.TP
.B \-n "\fInoise factor\fP"
Number of bits damaged/one megabyte.
.TP
.B \-m "\fImtu size\fP"
Packets longer than mtu_size are discarded.
.TP
.B \-N
nofifo. with -N packets can be reordered.
.TP
.B \-M "\fImgmt socket\fP"
the unix socket where the parameters (loss percentage, delay etc) can be checked and
changed runtime. unixterm(1) can be used as a remote terminal for wirefilter.
.TP
.B \-v "\fIvde_plug1:vde_plug2\fP"
If this option is used, the two local vde_plugs (vde_plug1 and vde_plug2) will be connected each other instead of stdin/stdout,
using the libvdeplug libraries. This option activates an interactive
management session on console (stdin/stdout).
.TP
.B \--mgmtmode "\fImode\fP"
this option sets the access mode of the mgmt socket.
The command syntax is quite simple. \fBhelp\fR provides the
list of commands.
It is possible to load a script file using the \fBload\fR management command.
.TP
.B \--daemon\fP
wirefilter becomes a daemon
.TP
.B \--pidfile "\fIpathnamefP"
wirefilter saves its pid into the file.
.TP
.B \--blinkid "\fIname\fP"
This option defines the id sent for each packet to the blink server
(see the --blink option below).
The stardard identifier for a wirefilter is the process pid.
.TP
.B \--blink "\fIsocket\fP"
wirefilter sends a log message to the specified PF_UNIX/DATAGRAM socket
for each packet sent. Each packet has the format: id direction length.
e.g:
.sp
.in +4n
.nf
6768 LR 44
6768 LR 44
6768 RL 100
6768 LR 100
6768 LR 44
.fi
.in
.sp
.SH Markov mode
wirefilter provides also a more complex set of parameters using a Markov
chain to emulate different states of the link and the tranistions between
states. Each state is represented by a node.
Markov chain parameters can be set with management commands or rc files only.
In fact, due to the large number of parameters the command line would have
been unreadable.
.TP
.B markov-numnodes "\fIn\fP"
defines the number of different states. All the parameters of the connection
can be defined node by node. Nodes are numbered starting from zero (to n-1).
e.g.:
.sp
.in +4in
.nf
delay 100+10N[4]
loss 10[2]
.fi
.in
.sp
these command define a delay of 90-110 ms (normal distribution) for the node
number 4 and a 10\% loss for the node 2.
It is possible to resize the Markov chain at run-time.
New nodes are unreachable and do not have any edge to other states (i.e.
each new node has a loopback edge to the node itself with 100% probability).
When reducing the number of nodes, the weight of the edges towards deleted
nodes is added to the loopback edge. When the current node of the
emulation is deleted, node 0 becomes the current node.
(The emulation always starts from node 0).
.TP
.B markov-time "\fIms\fP"
time period (ms) for the markov chain computation. Each \fIms\fR microseconds
a random number generator decides which is the next state (default value=100ms).
.TP
.B markov-name "\fIn,name\fP"
assign a name to a node of the markov chain.
.TP
.B markov-setnode "\fIn\fP"
manually set the current node to the node \fIn\fP.
.TP
.B setedge "\fIn1,n2,w\fP"
define an edge between \fIn1\fR and \fIn2\fR; \fIw\fR is the weight (probability percentage)
of the edge.
The loopback edge (from a node to itself) is always computed as 100% minus
the sum of the weights of outgoing edges.
.TP
.B showedges [ "\fIn\fP" ]
list the edges from node \fIn\fP (or from the current node when the command
has no parameters). Null weight edges are omitted.
.TP
.B showcurrent
show the current Markov state.
.TP
.B showinfo [ \fIn\fP ]
show status and information on state (node) \fIn\fP.
If the parameter is omitted
it shows the status and information on the current state.
.TP
.B markov-debug [ \fIn\fP ]
set the debug level for the current management connection.
In the actual implementation when n is greater than zero each
change of markov node causes the output of a debug trace.
Debug tracing get disabled when \fIn\fP is zero or the parameter is missing.
.SH NOTICE
Virtual Distributed Ethernet is not related in any way with
www.vde.com ("Verband der Elektrotechnik, Elektronik und Informationstechnik"
i.e. the German "Association for Electrical, Electronic & Information
Technologies").
.SH SEE ALSO
\fBvde_switch\fP(1),
\fBvdeq\fP(1).
\fBdpipe\fP(1).
\fBunixterm\fP(1).
.br
.SH AUTHOR
VDE is a project by Renzo Davoli
vde2-2.3.2/man/slirpvde.1 0000644 0001750 0001750 00000012161 11663221057 014123 0 ustar renzo renzo .TH SLIRPVDE 1 "June 15, 2008" "Virtual Distributed Ethernet"
.SH NAME
slirpvde \- Virtual Distributed Ethernet-Slirp interface
.SH SYNOPSIS
.B slirpvde
.I OPTIONS
[
.I socketdir
]
.SH DESCRIPTION
\fBslirpvde\fP
is a slirp interface for a VDE network.
Slirpvde connects all the units (virtual or real machines) to the network
of the host where slirpvde runs as it were a NAT/Masquerading router.
The default route is the node 2 (10.0.2.2 in the default network
configuration) and DNS is re-mapped in node 3 (10.0.2.3).
Slirpvde runs using standard user privileges (no need for root access):
all the connections are re-generated by slirpvde itself.
IPv4 only. IPv6 is still unsupported (will be supported when slirpvde will be
rewritten using the LWIPv6 network stack).
.SH OPTIONS
.TP
\fB-s, --sock, --socket, --vdesock, --unix\fP \fIdirectory\fP
specify the VDE switch directory (default /var/run/vde.ctl).
The VDE switch directory can be also specified at the end of
the command, as illustrated by the optional parameter \fIsocketdir\fP
in the synopsis section, above.
When '-' is used in place of the VDE switch directory, \fBslirpvde\fP
works as a plug (see vde_plug(1)).
The command:
.br
.in +5
.B dpipe vde_plug = ssh remote.machine.org slirpvde -
.in -5
.br
which is the same as:
.br
.in +5
.B dpipe vde_plug = ssh remote.machine.org slirpvde -s -
.in -5
.br
connects the default local switch to a remote slirpvde.
.TP
\fB-p, --pidfile\fP \fIfilename\fP
specify the name of the file which contains the PID of slirpvde.
.TP
\fB-g, --group\fP \fIgroup\fP
specify the UNIX group for the VDE communication socket.
.TP
\fB-m, --mod\fP \fImode\fP
specify the octal UNIX permissions for the VDE communication socket.
.TP
\fB-P, --port\fP \fIport\fP
specify the port of the vde switch whern slirpvde must be connected.
.TP
\fB-d, --daemon\fP
detach from terminal and run \fBslirpvde\fP in background.
.TP
\fB-H, --host\fP \fIaddress\fP \fR[ \fB / \fI masklen \fR]
specify the host address (default 10.0.2.2/24).
This option automatically defines the network.
e.g.
.in +5
\fB -H 192.168.55.1 \fR
.in -5
or:
.in +5
\fB --host 10.1.2.3/16 \fR
.in -5
The default value for \fImasklen\fR is 24.
If the host part of the address is zero this option defines only
the network. The default host addr is addr 2, the default dns proxy is 3.
e.g.
.in +5
\fB -H 10.1.0.0/16 \fR
.in -5
defines the network only. The host address is 10.1.0.2 and the DNS proxy
10.1.0.3.
.TP
\fB-n, --network\fP \fIaddress\fP \fR[ \fB / \fI masklen \fR]
specify the network address (default 10.0.2.0/24).
Deprecated, it has been included for back compatibility only. It is
an alias of \fB-H, --host\fR.
.TP
\fB-N, --dns\fP \fIaddress\fP
Specify the address of the dns server. If this is an address inside
the slirp network, slirvde acts as a dns proxy on that address.
The slirpvde dhcp server sends this dns address to the clients.
By default this is the host number 3 in the slirpvde network. Using the
default network it is 10.0.2.3.
Warning: do not use the same address for host and dns.
.TP
\fB-D, --dhcp\fP
turn on the DHCP server for the network autoconfiguration of
all the units connected to the VDE.
It is possible to specify the start address assigned by the DHCP server
as follows:
.in +5
\fB --dhcp=10.1.1.44 \fR
.in -5
DHCP assign addresses starting at host number 15 by default. Using the
default network it starts from 10.0.2.15
.TP
\fB-L \fIport\fR:\fIvde_host\fR:\fIvde_hostport\fR
specifyes a TCP port redirection.
All the TCP packets received by the host running slirpvde at port \fIport\fR
will be forwarded to \fIvde_host\fR at port \fIvde_hostport\fR.
.TP
\fB-U \fIport\fR:\fIvde_host\fR:\fIvde_hostport\fR
specifyes a UDP port redirection.
All the UDP packets received by the host running slirpvde at port \fIport\fR
will be forwarded to \fIvde_host\fR at port \fIvde_hostport\fR.
.TP
\fB-X \fIvde_host\fR[:\fIdisplay\fR.[\fIscreen\fR]]i
redirect a X window screen of a virtual machine. Slirpvde gets the first unused X display on the
host running slirpvde and redirects all the requests to \fIvde_host\fR.
\fIdisplay\fR and \fIscreen\fR] must be specified when different from :0.0.
.TP
\fB-x \fIport\fR:\fIunix_socket_path\fR]
redirect a port of the virtual router (usually 10.0.2.2) to a unix stream socket.
It is used for example to redirect a X display of the hosting computer on the virtual network. e.g. -x6000:/tmp/.X11-unix/X0. (A suitable xhost configuration is needed (e.g. 'xhost local:').
.TP
\fB-t, --tftp\fP \fIpathname\fR
slirpvde enables a tftp server sharing (read-only) the directory at \fIpathname\fR.
.TP
\fB-q, --quiet\fP
Quiet; do not write anything to standard output.
.SH NOTICE
Virtual Distributed Ethernet is not related in any way with
www.vde.com ("Verband der Elektrotechnik, Elektronik und Informationstechnik"
i.e. the German "Association for Electrical, Electronic & Information
Technologies").
.SH SEE ALSO
\fBvde_switch\fP(1),
\fBvde_plug\fP(1),
\fBvde_plug2tap\fP(1),
\fBdpipe\fP(1).
.br
.SH AUTHOR
VDE is a project by Renzo Davoli .
This tool includes software developed by Danny Gasparovski:
Slirp code is by Danny Gasparovsky.
Bootp/DHCP code is by Fabrice Bellard.
vde2-2.3.2/man/unixterm.1 0000644 0001750 0001750 00000001356 11663221057 014152 0 ustar renzo renzo .TH UNIXTERM 1 "December 6, 2006" "Virtual Distributed Ethernet"
.SH NAME
unixterm \- (simple) Remote terminal for unix sockets
.SH SYNOPSIS
.B unixterm
.I socket
.br
.SH DESCRIPTION
A
\fBunixterm\fP
is a terminal application for a unix stream socket.
It has been created as a part of the vde-2 project: it is used as a remote
console for vde_switch or for the wirefilter application.
.SH NOTICE
Virtual Distributed Ethernet is not related in any way with
www.vde.com ("Verband der Elektrotechnik, Elektronik und Informationstechnik"
i.e. the German "Association for Electrical, Electronic & Information
Technologies").
.SH SEE ALSO
\fBvde_switch\fP(1),
\fBwirefilter\fP(1).
.br
.SH AUTHOR
VDE is a project by Renzo Davoli
vde2-2.3.2/man/vde_plug2tap.1 0000644 0001750 0001750 00000004752 11663221057 014676 0 ustar renzo renzo .TH VDE_PLUG2TAP 1 "December 5, 2006" "Virtual Distributed Ethernet"
.SH NAME
vde_plug2tap \- Virtual Distributed Ethernet plug-to-tap
.SH SYNOPSIS
.B vde_plug2tap
[OPTION]... \fItap_name\fP
.br
.SH DESCRIPTION
.B vde_plug2tap
is a plug to be connected into a VDE switch.
All the data that is catched by the plug is sent to the tap interface
.I tap_name
and everything from that interface is injected in the switch.
.br
Example:
.in +2
.B vde_plug2tap tap4
.in -2
.br
connects the default switch (/var/run/vde.ctl) to the tap4 interface.
.SH OPTIONS
.TP
\fB\-p\fP, \fB\-\-port\fP=\fIportnum\fP
It is possible to decide which port of the switch to use.
When this option is not specified the switch assigns the first
available unused port (if any).
It is possible to connect several cables in the same switch port:
in this way all this cables work concurrently.
It means that packet can result as duplicate but no ARP table loops are
generated.
Is useful when vde is used for mobility. Several physical interfaces can
be used at a time during handoffs to prevent hichups in connectivity.
.TP
\fB\-g\fP, \fB\-\-group\fP=\fIgroup\fP
group ownership of the communication socket. For security when more
want to share a switch it is better to use a unix group to own the comm sockets
so that the network traffic cannot be sniffed.
.TP
\fB\-m\fP, \fB\-\-mod\fP=\fIoctal-mode\fP
octal chmod like permissions for the comm sockets
.TP
\fB\-s\fP, \fB\-\-sock\fP=\fIsocket\fP
specify the UNIX socket to be used by local programs for joining the VDE.
The default value is "/var/run/vde.ctl".
When '-' is used in place of the VDE switch directory, \fBvde_plug2tap\fP
works as a plug (see vde_plug(1)).
The command:
.br
.in +2
.B dpipe vde_plug = ssh remote.machine.org vde_plug2tap -s - tapx
.in -2
.br
connects the default local switch to a remote tapx interface.
.TP
\fB\-d\fP, \fB\-\-daemon\fP
start vde_plug2tap as a background process
.TP
\fB\-P\fP, \fB\-\-pidfile\fP=\fIpidfile\fP
put the process ID of vde_plug2tap in \fIpidfile\fP. Can be used with
\fB\-\-daemon\fP to store the PID for future killing.
.TP
\fB\-h\fP, \fB\-\-help\fP
show a brief help
.SH NOTICE
Virtual Distributed Ethernet is not related in any way with
www.vde.com ("Verband der Elektrotechnik, Elektronik und Informationstechnik"
i.e. the German "Association for Electrical, Electronic & Information
Technologies").
.SH SEE ALSO
\fBvde_switch\fP(1),
\fBvde_plug\fP(1),
\fBvdeq\fP(1),
\fBdpipe\fP(1).
.br
.SH AUTHOR
VDE is a project by Renzo Davoli
vde2-2.3.2/man/vde_l3.1 0000644 0001750 0001750 00000004672 11663221057 013457 0 ustar renzo renzo .TH VDE_L3 1 "May 7, 2007" "Virtual Distributed Ethernet"
.SH NAME
vde_l3 \- Virtual Distributed Ethernet 'Layer 3' Switch.
.SH SYNOPSIS
.B vde_l3
\fB\-v\fI vde_plug:ipaddress/netmask\fR
[\fB\-v\fI...]
[\fB\-r\fI target_network/netmask:gateway\fR]
[\fB\-G\fI default_gw\fR]
[\fB\-M\fI mgmt_socket\fR]
.br
.SH DESCRIPTION
A
\fBvde_l3\fP
connects to one or more vde_switches, performing ip forwarding among its virtual
interfaces. A new interface is created at startup for each \fB-v\fP option given at
command line. Static routes to target networks can be defined using the \fB-r\fP option.
.B
vde_l3 -v /var/run/s1.ctl:192.168.0.1/24
connects to the vde sock at /var/run/s1.ctl with its virtual interface ve0, having
the address 192.168.0.1 and netmask 255.255.255.0.
.B
vde_l3 \\
.B
-v /var/run/s1.ctl:192.168.0.1/24 \\
.B
-v /var/run/s2.ctl:10.0.0.254/255.255.0.0
connects to the two vde socks, with its virtual interfaces ve0 and ve1, having addressess 192.168.1.0 and 10.0.0.254 respectively. Hosts in each network can specify the
\fBvde_l3\fP as their gateway to reach the other one.
.SH OPTIONS
.TP
.B -v\fI vde_plug:ipaddress/netmask\fR
Creates a virtual network interfaces on the \fBvde_l3\fP box, with address \fIipaddress\fP and netmask \fInetmask\fP. Please note that the netmask can be specified either in
the 'classic' A.B.C.D mode, or just by giving the number of leading bits (f.e., /17 for 255.255.128.0).
One can define as many interfaces as she wants.
.TP
.B -r \fItarget_network/netmask:gateway\fR
Specify a static route through \fIgateway\fP to reach hosts in \fItarget_network\fP with netmask \fInetmask\fP.
One can define as many routes as she wants.
.TP
.B -G \fIdefault_gw
Specify a default gateway, to be used whenever no static route
is defined for a target host.
.TP
.B -M \fImgmt_socket
the unix socket where the parameters (interfaces addresses, routes, etc.) can be checked and
changed runtime. \fBunixterm\fP(1) can be used as a remote terminal for wirefilter.
.SH NOTICE
Virtual Distributed Ethernet is not related in any way with
www.vde.com ("Verband der Elektrotechnik, Elektronik und Informationstechnik"
i.e. the German "Association for Electrical, Electronic & Information
Technologies").
.SH SEE ALSO
\fBvde_switch\fP(1),
\fBvdeq\fP(1),
\fBunixterm\fP(1),
\fBvde_cryptcab\fP(1),
\fBwirefilter\fP(1).
.br
.SH AUTHORS
VDE_L3 is a tool by Daniele Lacamera
VDE is a project by Renzo Davoli
vde2-2.3.2/man/vde_plug.1 0000644 0001750 0001750 00000006463 11663221057 014110 0 ustar renzo renzo .TH VDE_PLUG 1 "December 6, 2006" "Virtual Distributed Ethernet"
.SH NAME
vde_plug \- Virtual Distributed Ethernet plug (two plugs creates a vde cable)
.SH SYNOPSIS
.B vde_plug
[
.B \-p
.I portnum
]
[
.B \-g
.I group
]
[
.B \-m
.I octal-mode
]
[
.I socketdir
]
.br
.SH DESCRIPTION
A
\fBvde_plug\fP
is a plug to be connected into a VDE switch.
All the data that is catched by the plug is written in its stdout and
everything from stdin is injected in the switch.
This tool has been designed to be used together with
.B dpipe (1)
to interconnect a second vde_plug to another switch, working as a
virtual ethernet crossed cable between the two switches.
The command
.RS
.br
.B dpipe vde_plug = vde_plug /tmp/vde2.ctl
.RE
connects two local switches: the former is using the standard control socket /tmp/vde.ctl
while the latter is using /tmp/vde2.ctl.
The command
.RS
.br
.B dpipe vde_plug = ssh remote.machine.org vde_plug
.RE
connects two remote switches.
If the two vde_switches run as daemon and they are connected to tap interfaces
a level 2 encrypted tunnel is established.
vde_plug can also be established as a login shell for users.
The following command works as in the previous example
.RS
.br
.B dpipe vde_plug = ssh vdeuser@remote.machine.org vde_plug
.RE
where vdeuser is the user with vde_plug as standard shell.
All the remote accesses are logged by syslog at the beginning and at the
end of each session.
Attempt to login without the command vde_plug at the end or trying to
execute something else are blocked and the attempt is logged into syslog.
.SH OPTIONS
.TP
.B \-p "\fIportnum\fP"
It is possible to decide which port of the switch to use.
When this option is not specified the switch assigns the first
available unused port (if any).
It is possible to connect several cables in the same switch port:
in this way all this cables work concurrently.
It means that packet can result as duplicate but no ARP table loops are
generated.
Is useful when vde is used for mobility. Several physical interfaces can
be used at a time during handoffs to prevent hichups in connectivity.
.TP
.B \-g "\fIgroup\fP"
group ownership of the communication socket. For security when more
want to share a switch it is better to use a unix group to own the comm sockets
so that the network traffic cannot be sniffed.
.TP
.B \-m "\fIoctal-mode\fP"
octal chmod like permissions for the comm sockets
.TP
.B "\fIsocketdir\fP"
(This option can be also set as:
.B -sock "\fIsocketdir\fP"
) specify the directory which contains the UNIX socket to be used by local programs for joining the VDE.
The default value is "/tmp/vde.ctl", which corresponds to the socket
"/tmp/vde.ctl/ctl" (or /var/run/vde.ctl when the vde_switch runs as a
shared daemon).
It is possible for users to redefine their default switch as ".vde-2/stdsock"
in their home directory. If exist, this directory (or symbolic link to
the actual directory) is used as the default value for the user.
.SH NOTICE
Virtual Distributed Ethernet is not related in any way with
www.vde.com ("Verband der Elektrotechnik, Elektronik und Informationstechnik"
i.e. the German "Association for Electrical, Electronic & Information
Technologies").
.SH SEE ALSO
\fBvde_switch\fP(1),
\fBvde_plug2tap\fP(1),
\fBvdeq\fP(1),
\fBdpipe\fP(1).
.br
.SH AUTHOR
VDE is a project by Renzo Davoli
vde2-2.3.2/man/vde_switch.1 0000644 0001750 0001750 00000006130 11663221057 014431 0 ustar renzo renzo .TH VDE_SWITCH 1 "December 6, 2006" "Virtual Distributed Ethernet"
.SH NAME
vde_switch \- Virtual Distributed Ethernet switch
.SH SYNOPSIS
.B vde_switch
[
.B \-hub
]
[
.BI \-sock
.I commdirpath
]
[
.BI \-mod
.I octal-mode
]
[
.BI \-group
.I NAME
]
[
.BI \-tap
.I interface
]
[
.BI \-daemon
]
.br
.SH DESCRIPTION
A
\fBvde_switch\fP
is a virtual switch for the vde architecture.
.br
A vde network can include several vde_switches running on different
(real) computers.
vde_switches can be connected by vde cables (see
\fBvde_plug (1)\fP
).
.br
Supported architecture for VDE end nodes include:
real linux boxes (through the tuntap interface),
bochs, qemu and MPS virtual machines.
.br
VDE is useful to create networks of heterogeneous virtual machines as
well as as a general tunneling tool -- all the ethernet based protocols work
by this kind of tunnel -- and also as a tool for mobility.
In fact VDE creates an overlay network where users can keep their IP
addresses despite of the change of IP addresses on the interfaces.
vde_switch needs root privileges to open a tap interface, can be run by
users when no -tap option is specified.
vde-2 has several features: VLAN, Fast Spanning Tree Protocol, command line management
(on console for foreground switches, on a terminal for daemonized switches).
If a vde_switch run in foreground mode simply type return to have the prompt.
For daemons there is the -M option to specify the management socket. Unixterm is the tool
to start a terminal for the management.
Type "help" at the prompt for a list of possible options.
.SH OPTIONS
.TP
.B \-hub
turn off the switch engine. It operates as a hub.
.TP
.B \-sock "\fIcommdirpath\fP"
specify the directory when comm socket are created.
The default value is "/tmp/vde.ctl"
.TP
.B \-mod "\fIoctalmode\fP"
specify the octal permissions for the comm sockets.
.TP
.B \-group "\fINAME\fP"
specify the group owner for the comm socket.
The default value is the current user's primary group
.TP
.B \-tap "\fIinterface\fP"
connect the specified tuntap interface to this vde_switch (needs root privileges)
It is possible to specify several tap interfaces, comma separated.
.TP
.B \-daemon
Run as a daemon. Use syslog for logging.
.TP
.B \-f rcfile
rc file to set the initial switch configuration. This rc file has the same syntax of
the command line interface.
.TP
.B \-h
help. Please use it for a more complete list of options.
vde_switch is a modular program, options vary depending of the compiled-in modules.
.SH NOTICE
Virtual Distributed Ethernet is not related in any way with
www.vde.com ("Verband der Elektrotechnik, Elektronik und Informationstechnik"
i.e. the German "Association for Electrical, Electronic & Information
Technologies").
.SH SEE ALSO
\fBvde_plug\fP(1),
\fBvde_plug2tap\fP(1),
\fBvdeq\fP(1),
\fBdpipe\fP(1),
\fBunixterm\fP(1).
.br
.SH AUTHOR
VDE is a project by Renzo Davoli
.br
VDE started as an enhancement of uml_switch by Jeff Dike and others.
VDE-2 has been almost completely rewritten but maybe some statements
come from the historical source. So, some copyright and thanks also for Dike&Co.
vde2-2.3.2/man/vde_over_ns.1 0000644 0001750 0001750 00000004255 11663221057 014611 0 ustar renzo renzo .TH VDE_OVER_NS 1 "May 2, 2007" "Virtual Distributed Ethernet"
.SH NAME
vde_over_ns \- Steganographic cable over NS protocol for Virtual Distributed Ethernet
.SH SYNOPSIS
.B vde_over_ns
[\fB\-D\fR]
[\fB\-c\fI server_address\fR]
[\fB\-s\fI vde_plug\fR]
[\fB\-i\fI ip.to.bi.nd\fR]
\fIdomain.name
.br
.SH DESCRIPTION
A
\fBvde_over_ns\fP
allows to connect two remote vde_switches through steganographic NS query/response datagrams.
e.g.:
.B
dpipe vde_plug /tmp/s1 = vde_over_ns tun.mydomain.vde
binds to udp port 53 and listen for incoming steganographic NS queries (server mode).
All the traffic to/from stdout/stdin is redirected to the client via ns responses.
creates a wire between two vde_switches (with sockets /tmp/s1 and /tmp/s2
respectively). This cable looses 10% of the packets in each direction.
The same vde_over_dns server can be created using:
.B
vde_over_ns -s /tmp/s1 tun.mydomain.vde
The syntax is almost identical for the client mode, except that
to have a vde_over_ns client connect to that server, the \fB -c \fIserver\fR
option must be specified.
.SH OPTIONS
.TP
.B \-s "\fIvdeplug\fP"
If specified, the vde_over_ns will connect to the local vde socket \fIvdeplug\fP
instead pf stdin/stdout, using the libvdeplug library.
.TP
.B \-D
Detach console and send the process to background.
.TP
.B \-b "\fIip.to.bind\fP"
The NS server will bind only to the specified ip, instead of any ip.
Only valid in server mode (without -c)
.TP
.B \-c "\fIserver_addr\fP"
If specified, client mode is enabled. Vde_over_ns will try to send NS requests to \fIserver_addr\fP. If not specified, server mode is enabled by default.
.SH NOTICE
Virtual Distributed Ethernet is not related in any way with
www.vde.com ("Verband der Elektrotechnik, Elektronik und Informationstechnik"
i.e. the German "Association for Electrical, Electronic & Information
Technologies").
.SH SEE ALSO
\fBvde_switch\fP(1),
\fBvdeq\fP(1).
\fBdpipe\fP(1).
\fBunixterm\fP(1).
.br
.SH AUTHORS
VDE_OVER_NS is a tool by Daniele Lacamera
VDE is a project by Renzo Davoli
based on nstx, a steganographic ns client/server software by:
Florian Heinz
Julien Oster
vde2-2.3.2/man/Makefile.am 0000644 0001750 0001750 00000002012 11663221057 014237 0 ustar renzo renzo static_mans = dpipe.1 slirpvde.1 unixterm.1 vde_plug.1 vdeq.1 vde_switch.1 wirefilter.1 vde_cryptcab.1 vde_plug2tap.1 vde_over_ns.1 vde_l3.1 vde_tunctl.8 vde_autolink.1 unixcmd.1 vdeterm.1
if ENABLE_PCAP
static_mans += vde_pcapplug.1
endif
generated_mans = vdetaplib.1
man_MANS = $(static_mans) $(generated_mans)
CLEANFILES = $(generated_mans)
EXTRA_DIST = $(static_mans) vdetaplib.1.in vde_pcapplug.1
vdetaplib.1: vdetaplib.1.in
sed 's/%PKGLIBDIR%/$(subst /,\/,$(pkglibdir))/g' \
$(srcdir)/vdetaplib.1.in > $(builddir)/vdetaplib.1
install-data-hook:
rm -f $(DESTDIR)$(mandir)/man1/vdeqemu.1
rm -f $(DESTDIR)$(mandir)/man1/vdekvm.1
rm -f $(DESTDIR)$(mandir)/man1/vdecmd.1
(cd $(DESTDIR)$(mandir)/man1 && $(LN_S) vdeq.1 vdeqemu.1)
(cd $(DESTDIR)$(mandir)/man1 && $(LN_S) vdeq.1 vdekvm.1)
(cd $(DESTDIR)$(mandir)/man1 && $(LN_S) unixcmd.1 vdecmd.1)
uninstall-local:
rm -f $(DESTDIR)$(mandir)/man1/vdeqemu.1
rm -f $(DESTDIR)$(mandir)/man1/vdekvm.1
rm -f $(DESTDIR)$(mandir)/man1/vdecmd.1
#clean:
# rm -f vdetaplib.1
vde2-2.3.2/man/unixcmd.1 0000644 0001750 0001750 00000001244 11663221057 013742 0 ustar renzo renzo .\" DO NOT MODIFY THIS FILE! It was generated by help2man 1.36.
.TH UNIXCMD "1" "January 2008" "Virtual Distributed Ethernet" "User Commands"
.SH NAME
unixcmd \- Simple remote command for unix sockets
.SH SYNOPSIS
.B unixcmd
\fIOPTIONS command\fR
.br
.B vdecmd
\fIOPTIONS command\fR
.SH DESCRIPTION
.TP
\fB\-s\fR sockname
management socket path (default is /var/run/unixcmd)
.TP
\fB\-f\fR rcfile
configuration path (default is /etc/unixcmd)
.TP
\fB\-v\fR
run parse machine in debug mode
.TP
\fB\-s\fR sockname
management socket path (default is /var/run/unixcmd)
.TP
\fB\-f\fR rcfile
configuration path (default is /etc/unixcmd)
.TP
\fB\-v\fR
run parse machine in debug mode
vde2-2.3.2/man/Makefile.in 0000644 0001750 0001750 00000040436 11663221137 014263 0 ustar renzo renzo # Makefile.in generated by automake 1.11.1 from Makefile.am.
# @configure_input@
# Copyright (C) 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002,
# 2003, 2004, 2005, 2006, 2007, 2008, 2009 Free Software Foundation,
# Inc.
# This Makefile.in is free software; the Free Software Foundation
# gives unlimited permission to copy and/or distribute it,
# with or without modifications, as long as this notice is preserved.
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY, to the extent permitted by law; without
# even the implied warranty of MERCHANTABILITY or FITNESS FOR A
# PARTICULAR PURPOSE.
@SET_MAKE@
VPATH = @srcdir@
pkgdatadir = $(datadir)/@PACKAGE@
pkgincludedir = $(includedir)/@PACKAGE@
pkglibdir = $(libdir)/@PACKAGE@
pkglibexecdir = $(libexecdir)/@PACKAGE@
am__cd = CDPATH="$${ZSH_VERSION+.}$(PATH_SEPARATOR)" && cd
install_sh_DATA = $(install_sh) -c -m 644
install_sh_PROGRAM = $(install_sh) -c
install_sh_SCRIPT = $(install_sh) -c
INSTALL_HEADER = $(INSTALL_DATA)
transform = $(program_transform_name)
NORMAL_INSTALL = :
PRE_INSTALL = :
POST_INSTALL = :
NORMAL_UNINSTALL = :
PRE_UNINSTALL = :
POST_UNINSTALL = :
build_triplet = @build@
host_triplet = @host@
@ENABLE_PCAP_TRUE@am__append_1 = vde_pcapplug.1
subdir = man
DIST_COMMON = $(srcdir)/Makefile.am $(srcdir)/Makefile.in
ACLOCAL_M4 = $(top_srcdir)/aclocal.m4
am__aclocal_m4_deps = $(top_srcdir)/m4/libtool.m4 \
$(top_srcdir)/m4/ltoptions.m4 $(top_srcdir)/m4/ltsugar.m4 \
$(top_srcdir)/m4/ltversion.m4 $(top_srcdir)/m4/lt~obsolete.m4 \
$(top_srcdir)/configure.ac
am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \
$(ACLOCAL_M4)
mkinstalldirs = $(install_sh) -d
CONFIG_HEADER = $(top_builddir)/include/config.h
CONFIG_CLEAN_FILES =
CONFIG_CLEAN_VPATH_FILES =
AM_V_GEN = $(am__v_GEN_$(V))
am__v_GEN_ = $(am__v_GEN_$(AM_DEFAULT_VERBOSITY))
am__v_GEN_0 = @echo " GEN " $@;
AM_V_at = $(am__v_at_$(V))
am__v_at_ = $(am__v_at_$(AM_DEFAULT_VERBOSITY))
am__v_at_0 = @
SOURCES =
DIST_SOURCES =
am__vpath_adj_setup = srcdirstrip=`echo "$(srcdir)" | sed 's|.|.|g'`;
am__vpath_adj = case $$p in \
$(srcdir)/*) f=`echo "$$p" | sed "s|^$$srcdirstrip/||"`;; \
*) f=$$p;; \
esac;
am__strip_dir = f=`echo $$p | sed -e 's|^.*/||'`;
am__install_max = 40
am__nobase_strip_setup = \
srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*|]/\\\\&/g'`
am__nobase_strip = \
for p in $$list; do echo "$$p"; done | sed -e "s|$$srcdirstrip/||"
am__nobase_list = $(am__nobase_strip_setup); \
for p in $$list; do echo "$$p $$p"; done | \
sed "s| $$srcdirstrip/| |;"' / .*\//!s/ .*/ ./; s,\( .*\)/[^/]*$$,\1,' | \
$(AWK) 'BEGIN { files["."] = "" } { files[$$2] = files[$$2] " " $$1; \
if (++n[$$2] == $(am__install_max)) \
{ print $$2, files[$$2]; n[$$2] = 0; files[$$2] = "" } } \
END { for (dir in files) print dir, files[dir] }'
am__base_list = \
sed '$$!N;$$!N;$$!N;$$!N;$$!N;$$!N;$$!N;s/\n/ /g' | \
sed '$$!N;$$!N;$$!N;$$!N;s/\n/ /g'
man1dir = $(mandir)/man1
am__installdirs = "$(DESTDIR)$(man1dir)" "$(DESTDIR)$(man8dir)"
man8dir = $(mandir)/man8
NROFF = nroff
MANS = $(man_MANS)
DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST)
ACLOCAL = @ACLOCAL@
AMTAR = @AMTAR@
AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@
AR = @AR@
AUTOCONF = @AUTOCONF@
AUTOHEADER = @AUTOHEADER@
AUTOMAKE = @AUTOMAKE@
AWK = @AWK@
CC = @CC@
CCDEPMODE = @CCDEPMODE@
CFLAGS = @CFLAGS@
CPP = @CPP@
CPPFLAGS = @CPPFLAGS@
CXX = @CXX@
CXXCPP = @CXXCPP@
CXXDEPMODE = @CXXDEPMODE@
CXXFLAGS = @CXXFLAGS@
CYGPATH_W = @CYGPATH_W@
DEFS = @DEFS@
DEPDIR = @DEPDIR@
DLLTOOL = @DLLTOOL@
DSYMUTIL = @DSYMUTIL@
DUMPBIN = @DUMPBIN@
ECHO_C = @ECHO_C@
ECHO_N = @ECHO_N@
ECHO_T = @ECHO_T@
EGREP = @EGREP@
EXEEXT = @EXEEXT@
FGREP = @FGREP@
GREP = @GREP@
INSTALL = @INSTALL@
INSTALL_DATA = @INSTALL_DATA@
INSTALL_PROGRAM = @INSTALL_PROGRAM@
INSTALL_SCRIPT = @INSTALL_SCRIPT@
INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@
LD = @LD@
LDFLAGS = @LDFLAGS@
LIBOBJS = @LIBOBJS@
LIBS = @LIBS@
LIBTOOL = @LIBTOOL@
LIPO = @LIPO@
LN_S = @LN_S@
LTLIBOBJS = @LTLIBOBJS@
MAKEINFO = @MAKEINFO@
MANIFEST_TOOL = @MANIFEST_TOOL@
MKDIR_P = @MKDIR_P@
NM = @NM@
NMEDIT = @NMEDIT@
OBJDUMP = @OBJDUMP@
OBJEXT = @OBJEXT@
OTOOL = @OTOOL@
OTOOL64 = @OTOOL64@
PACKAGE = @PACKAGE@
PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@
PACKAGE_NAME = @PACKAGE_NAME@
PACKAGE_STRING = @PACKAGE_STRING@
PACKAGE_TARNAME = @PACKAGE_TARNAME@
PACKAGE_URL = @PACKAGE_URL@
PACKAGE_VERSION = @PACKAGE_VERSION@
PATH_SEPARATOR = @PATH_SEPARATOR@
PYTHON = @PYTHON@
PYTHON_CFLAGS = @PYTHON_CFLAGS@
PYTHON_CONFIG = @PYTHON_CONFIG@
PYTHON_EXEC_PREFIX = @PYTHON_EXEC_PREFIX@
PYTHON_INCLUDES = @PYTHON_INCLUDES@
PYTHON_LIBS = @PYTHON_LIBS@
PYTHON_PLATFORM = @PYTHON_PLATFORM@
PYTHON_PREFIX = @PYTHON_PREFIX@
PYTHON_VERSION = @PYTHON_VERSION@
RANLIB = @RANLIB@
SED = @SED@
SET_MAKE = @SET_MAKE@
SHELL = @SHELL@
STRIP = @STRIP@
VERSION = @VERSION@
abs_builddir = @abs_builddir@
abs_srcdir = @abs_srcdir@
abs_top_builddir = @abs_top_builddir@
abs_top_srcdir = @abs_top_srcdir@
ac_ct_AR = @ac_ct_AR@
ac_ct_CC = @ac_ct_CC@
ac_ct_CXX = @ac_ct_CXX@
ac_ct_DUMPBIN = @ac_ct_DUMPBIN@
am__include = @am__include@
am__leading_dot = @am__leading_dot@
am__quote = @am__quote@
am__tar = @am__tar@
am__untar = @am__untar@
bindir = @bindir@
build = @build@
build_alias = @build_alias@
build_cpu = @build_cpu@
build_os = @build_os@
build_vendor = @build_vendor@
builddir = @builddir@
datadir = @datadir@
datarootdir = @datarootdir@
docdir = @docdir@
dvidir = @dvidir@
exec_prefix = @exec_prefix@
host = @host@
host_alias = @host_alias@
host_cpu = @host_cpu@
host_os = @host_os@
host_vendor = @host_vendor@
htmldir = @htmldir@
includedir = @includedir@
infodir = @infodir@
install_sh = @install_sh@
libdir = @libdir@
libexecdir = @libexecdir@
localedir = @localedir@
localstatedir = @localstatedir@
mandir = @mandir@
mkdir_p = @mkdir_p@
oldincludedir = @oldincludedir@
pdfdir = @pdfdir@
pkgpyexecdir = @pkgpyexecdir@
pkgpythondir = @pkgpythondir@
prefix = @prefix@
program_transform_name = @program_transform_name@
psdir = @psdir@
pyexecdir = @pyexecdir@
pythondir = @pythondir@
sbindir = @sbindir@
sharedstatedir = @sharedstatedir@
srcdir = @srcdir@
sysconfdir = @sysconfdir@
target_alias = @target_alias@
top_build_prefix = @top_build_prefix@
top_builddir = @top_builddir@
top_srcdir = @top_srcdir@
static_mans = dpipe.1 slirpvde.1 unixterm.1 vde_plug.1 vdeq.1 \
vde_switch.1 wirefilter.1 vde_cryptcab.1 vde_plug2tap.1 \
vde_over_ns.1 vde_l3.1 vde_tunctl.8 vde_autolink.1 unixcmd.1 \
vdeterm.1 $(am__append_1)
generated_mans = vdetaplib.1
man_MANS = $(static_mans) $(generated_mans)
CLEANFILES = $(generated_mans)
EXTRA_DIST = $(static_mans) vdetaplib.1.in vde_pcapplug.1
all: all-am
.SUFFIXES:
$(srcdir)/Makefile.in: $(srcdir)/Makefile.am $(am__configure_deps)
@for dep in $?; do \
case '$(am__configure_deps)' in \
*$$dep*) \
( cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh ) \
&& { if test -f $@; then exit 0; else break; fi; }; \
exit 1;; \
esac; \
done; \
echo ' cd $(top_srcdir) && $(AUTOMAKE) --foreign man/Makefile'; \
$(am__cd) $(top_srcdir) && \
$(AUTOMAKE) --foreign man/Makefile
.PRECIOUS: Makefile
Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status
@case '$?' in \
*config.status*) \
cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh;; \
*) \
echo ' cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__depfiles_maybe)'; \
cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__depfiles_maybe);; \
esac;
$(top_builddir)/config.status: $(top_srcdir)/configure $(CONFIG_STATUS_DEPENDENCIES)
cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
$(top_srcdir)/configure: $(am__configure_deps)
cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
$(ACLOCAL_M4): $(am__aclocal_m4_deps)
cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
$(am__aclocal_m4_deps):
mostlyclean-libtool:
-rm -f *.lo
clean-libtool:
-rm -rf .libs _libs
install-man1: $(man_MANS)
@$(NORMAL_INSTALL)
test -z "$(man1dir)" || $(MKDIR_P) "$(DESTDIR)$(man1dir)"
@list=''; test -n "$(man1dir)" || exit 0; \
{ for i in $$list; do echo "$$i"; done; \
l2='$(man_MANS)'; for i in $$l2; do echo "$$i"; done | \
sed -n '/\.1[a-z]*$$/p'; \
} | while read p; do \
if test -f $$p; then d=; else d="$(srcdir)/"; fi; \
echo "$$d$$p"; echo "$$p"; \
done | \
sed -e 'n;s,.*/,,;p;h;s,.*\.,,;s,^[^1][0-9a-z]*$$,1,;x' \
-e 's,\.[0-9a-z]*$$,,;$(transform);G;s,\n,.,' | \
sed 'N;N;s,\n, ,g' | { \
list=; while read file base inst; do \
if test "$$base" = "$$inst"; then list="$$list $$file"; else \
echo " $(INSTALL_DATA) '$$file' '$(DESTDIR)$(man1dir)/$$inst'"; \
$(INSTALL_DATA) "$$file" "$(DESTDIR)$(man1dir)/$$inst" || exit $$?; \
fi; \
done; \
for i in $$list; do echo "$$i"; done | $(am__base_list) | \
while read files; do \
test -z "$$files" || { \
echo " $(INSTALL_DATA) $$files '$(DESTDIR)$(man1dir)'"; \
$(INSTALL_DATA) $$files "$(DESTDIR)$(man1dir)" || exit $$?; }; \
done; }
uninstall-man1:
@$(NORMAL_UNINSTALL)
@list=''; test -n "$(man1dir)" || exit 0; \
files=`{ for i in $$list; do echo "$$i"; done; \
l2='$(man_MANS)'; for i in $$l2; do echo "$$i"; done | \
sed -n '/\.1[a-z]*$$/p'; \
} | sed -e 's,.*/,,;h;s,.*\.,,;s,^[^1][0-9a-z]*$$,1,;x' \
-e 's,\.[0-9a-z]*$$,,;$(transform);G;s,\n,.,'`; \
test -z "$$files" || { \
echo " ( cd '$(DESTDIR)$(man1dir)' && rm -f" $$files ")"; \
cd "$(DESTDIR)$(man1dir)" && rm -f $$files; }
install-man8: $(man_MANS)
@$(NORMAL_INSTALL)
test -z "$(man8dir)" || $(MKDIR_P) "$(DESTDIR)$(man8dir)"
@list=''; test -n "$(man8dir)" || exit 0; \
{ for i in $$list; do echo "$$i"; done; \
l2='$(man_MANS)'; for i in $$l2; do echo "$$i"; done | \
sed -n '/\.8[a-z]*$$/p'; \
} | while read p; do \
if test -f $$p; then d=; else d="$(srcdir)/"; fi; \
echo "$$d$$p"; echo "$$p"; \
done | \
sed -e 'n;s,.*/,,;p;h;s,.*\.,,;s,^[^8][0-9a-z]*$$,8,;x' \
-e 's,\.[0-9a-z]*$$,,;$(transform);G;s,\n,.,' | \
sed 'N;N;s,\n, ,g' | { \
list=; while read file base inst; do \
if test "$$base" = "$$inst"; then list="$$list $$file"; else \
echo " $(INSTALL_DATA) '$$file' '$(DESTDIR)$(man8dir)/$$inst'"; \
$(INSTALL_DATA) "$$file" "$(DESTDIR)$(man8dir)/$$inst" || exit $$?; \
fi; \
done; \
for i in $$list; do echo "$$i"; done | $(am__base_list) | \
while read files; do \
test -z "$$files" || { \
echo " $(INSTALL_DATA) $$files '$(DESTDIR)$(man8dir)'"; \
$(INSTALL_DATA) $$files "$(DESTDIR)$(man8dir)" || exit $$?; }; \
done; }
uninstall-man8:
@$(NORMAL_UNINSTALL)
@list=''; test -n "$(man8dir)" || exit 0; \
files=`{ for i in $$list; do echo "$$i"; done; \
l2='$(man_MANS)'; for i in $$l2; do echo "$$i"; done | \
sed -n '/\.8[a-z]*$$/p'; \
} | sed -e 's,.*/,,;h;s,.*\.,,;s,^[^8][0-9a-z]*$$,8,;x' \
-e 's,\.[0-9a-z]*$$,,;$(transform);G;s,\n,.,'`; \
test -z "$$files" || { \
echo " ( cd '$(DESTDIR)$(man8dir)' && rm -f" $$files ")"; \
cd "$(DESTDIR)$(man8dir)" && rm -f $$files; }
tags: TAGS
TAGS:
ctags: CTAGS
CTAGS:
distdir: $(DISTFILES)
@list='$(MANS)'; if test -n "$$list"; then \
list=`for p in $$list; do \
if test -f $$p; then d=; else d="$(srcdir)/"; fi; \
if test -f "$$d$$p"; then echo "$$d$$p"; else :; fi; done`; \
if test -n "$$list" && \
grep 'ab help2man is required to generate this page' $$list >/dev/null; then \
echo "error: found man pages containing the \`missing help2man' replacement text:" >&2; \
grep -l 'ab help2man is required to generate this page' $$list | sed 's/^/ /' >&2; \
echo " to fix them, install help2man, remove and regenerate the man pages;" >&2; \
echo " typically \`make maintainer-clean' will remove them" >&2; \
exit 1; \
else :; fi; \
else :; fi
@srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \
topsrcdirstrip=`echo "$(top_srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \
list='$(DISTFILES)'; \
dist_files=`for file in $$list; do echo $$file; done | \
sed -e "s|^$$srcdirstrip/||;t" \
-e "s|^$$topsrcdirstrip/|$(top_builddir)/|;t"`; \
case $$dist_files in \
*/*) $(MKDIR_P) `echo "$$dist_files" | \
sed '/\//!d;s|^|$(distdir)/|;s,/[^/]*$$,,' | \
sort -u` ;; \
esac; \
for file in $$dist_files; do \
if test -f $$file || test -d $$file; then d=.; else d=$(srcdir); fi; \
if test -d $$d/$$file; then \
dir=`echo "/$$file" | sed -e 's,/[^/]*$$,,'`; \
if test -d "$(distdir)/$$file"; then \
find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \
fi; \
if test -d $(srcdir)/$$file && test $$d != $(srcdir); then \
cp -fpR $(srcdir)/$$file "$(distdir)$$dir" || exit 1; \
find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \
fi; \
cp -fpR $$d/$$file "$(distdir)$$dir" || exit 1; \
else \
test -f "$(distdir)/$$file" \
|| cp -p $$d/$$file "$(distdir)/$$file" \
|| exit 1; \
fi; \
done
check-am: all-am
check: check-am
all-am: Makefile $(MANS)
installdirs:
for dir in "$(DESTDIR)$(man1dir)" "$(DESTDIR)$(man8dir)"; do \
test -z "$$dir" || $(MKDIR_P) "$$dir"; \
done
install: install-am
install-exec: install-exec-am
install-data: install-data-am
uninstall: uninstall-am
install-am: all-am
@$(MAKE) $(AM_MAKEFLAGS) install-exec-am install-data-am
installcheck: installcheck-am
install-strip:
$(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \
install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \
`test -z '$(STRIP)' || \
echo "INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'"` install
mostlyclean-generic:
clean-generic:
-test -z "$(CLEANFILES)" || rm -f $(CLEANFILES)
distclean-generic:
-test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES)
-test . = "$(srcdir)" || test -z "$(CONFIG_CLEAN_VPATH_FILES)" || rm -f $(CONFIG_CLEAN_VPATH_FILES)
maintainer-clean-generic:
@echo "This command is intended for maintainers to use"
@echo "it deletes files that may require special tools to rebuild."
clean: clean-am
clean-am: clean-generic clean-libtool mostlyclean-am
distclean: distclean-am
-rm -f Makefile
distclean-am: clean-am distclean-generic
dvi: dvi-am
dvi-am:
html: html-am
html-am:
info: info-am
info-am:
install-data-am: install-man
@$(NORMAL_INSTALL)
$(MAKE) $(AM_MAKEFLAGS) install-data-hook
install-dvi: install-dvi-am
install-dvi-am:
install-exec-am:
install-html: install-html-am
install-html-am:
install-info: install-info-am
install-info-am:
install-man: install-man1 install-man8
install-pdf: install-pdf-am
install-pdf-am:
install-ps: install-ps-am
install-ps-am:
installcheck-am:
maintainer-clean: maintainer-clean-am
-rm -f Makefile
maintainer-clean-am: distclean-am maintainer-clean-generic
mostlyclean: mostlyclean-am
mostlyclean-am: mostlyclean-generic mostlyclean-libtool
pdf: pdf-am
pdf-am:
ps: ps-am
ps-am:
uninstall-am: uninstall-local uninstall-man
uninstall-man: uninstall-man1 uninstall-man8
.MAKE: install-am install-data-am install-strip
.PHONY: all all-am check check-am clean clean-generic clean-libtool \
distclean distclean-generic distclean-libtool distdir dvi \
dvi-am html html-am info info-am install install-am \
install-data install-data-am install-data-hook install-dvi \
install-dvi-am install-exec install-exec-am install-html \
install-html-am install-info install-info-am install-man \
install-man1 install-man8 install-pdf install-pdf-am \
install-ps install-ps-am install-strip installcheck \
installcheck-am installdirs maintainer-clean \
maintainer-clean-generic mostlyclean mostlyclean-generic \
mostlyclean-libtool pdf pdf-am ps ps-am uninstall uninstall-am \
uninstall-local uninstall-man uninstall-man1 uninstall-man8
vdetaplib.1: vdetaplib.1.in
sed 's/%PKGLIBDIR%/$(subst /,\/,$(pkglibdir))/g' \
$(srcdir)/vdetaplib.1.in > $(builddir)/vdetaplib.1
install-data-hook:
rm -f $(DESTDIR)$(mandir)/man1/vdeqemu.1
rm -f $(DESTDIR)$(mandir)/man1/vdekvm.1
rm -f $(DESTDIR)$(mandir)/man1/vdecmd.1
(cd $(DESTDIR)$(mandir)/man1 && $(LN_S) vdeq.1 vdeqemu.1)
(cd $(DESTDIR)$(mandir)/man1 && $(LN_S) vdeq.1 vdekvm.1)
(cd $(DESTDIR)$(mandir)/man1 && $(LN_S) unixcmd.1 vdecmd.1)
uninstall-local:
rm -f $(DESTDIR)$(mandir)/man1/vdeqemu.1
rm -f $(DESTDIR)$(mandir)/man1/vdekvm.1
rm -f $(DESTDIR)$(mandir)/man1/vdecmd.1
#clean:
# rm -f vdetaplib.1
# Tell versions [3.59,3.63) of GNU make to not export all variables.
# Otherwise a system limit (for SysV at least) may be exceeded.
.NOEXPORT:
vde2-2.3.2/man/vde_tunctl.8 0000644 0001750 0001750 00000002727 11663221057 014460 0 ustar renzo renzo .TH "VDE_TUNCTL" "8"
.SH "NAME"
vde_tunctl \(em create and manage persistent TUN/TAP interfaces
.SH "SYNOPSIS"
.PP
\fBvde_tunctl\fR [\fB-f\fP \fItun-clone-device\fR] [\fB-u\fP \fIowner\fR] [\fB-t\fP \fIdevice-name\fR]
.PP
\fBvde_tunctl\fR [\fB-f\fP \fItun-clone-device\fR] \fB-d\fP \fIdevice-name\fR
.SH "DESCRIPTION"
.PP
\fBvde_tunctl\fR allows the host sysadmin to
preconfigure a TUN/TAP device for use by a particular user. That
user may open and use the device, but may not change any aspects
of the host side of the interface.
.PP
vde_tunctl is a simple copy of \fBtunctl\fR done for practical purposes.
.SH "USAGE"
.PP
To create an interface for use by a particular user, invoke
tunctl without the \-d option:
.PP
.nf
# \fBvde_tunctl \-u someuser\fP
Set 'tap0' persistent and owned by uid 500
.fi
.PP
Then, configure the interface as normal:
.PP
.nf
# \fBifconfig tap0 192.168.0.254 up\fP
# \fBroute add \-host 192.168.0.253 dev tap0\fP
# \fBbash \-c 'echo 1 > /proc/sys/net/ipv4/conf/tap0/proxy_arp'\fP
# \fBarp \-Ds 192.168.0.253 eth0 pub\fP
.fi
.PP
To delete the interface, use the \-d option:
.PP
.nf
# \fBvde_tunctl \-d tap0\fP
Set 'tap0' nonpersistent
.fi
.SH "SEE ALSO"
.PP
\fBvde_switch\fP(1)
\fBvde_plug2tap\fP(1)
.SH "AUTHOR"
.PP
tunctl was written by Jeff Dike jdike@karaya.com
.PP
This manual page is based on tunctl manual page written by Matt Zimmerman mdz@debian.org for
the \fBDebian GNU/Linux\fP system.
vde2-2.3.2/man/vde_cryptcab.1 0000644 0001750 0001750 00000010134 11663221057 014736 0 ustar renzo renzo .TH VDE_CRYPTCAB 1 "December 6, 2006" "Virtual Distributed Ethernet"
.SH NAME
vde_cryptcab \- Virtual Distributed Ethernet encrypted cable manager
.SH SYNOPSIS
.B vde_cryptcab
[
.B \-p
.I portnum
]
[
.B \-s
.I socketpath
]
[
.B \-c
.I [remote_user@]host[:remote_portnum]
]
[
.B \-P
.I pre_shared.key
]|
[
.B \-x
]
[
.B \-v
.I [v][v][v]
]
[
.B \-k
]
[
.B \-d
]
.br
.SH DESCRIPTION
A
\fBvde_cryptcab\fP
is a distributed cable manager for VDE switches.
It allows two VDE switches on two machines to communicate
using a blowfish encrypted channel.
When used in client mode (i.e., with -c option), it generates a random
blowfish key, and uses
.B scp (1)
to transfer the key to the remote server.
On the client side, the environment variable SCP_EXTRA_OPTIONS may be set in order
to append options to the scp command line (this is useful for example when dropbear or
another non-standard ssh client is used to transfer the blowfish key).
After a 4-way handshake phase to verify client credentials, server and
client will exchange VDE datagrams encapsulating them into cryptograms
that are sent via udp to each remote host.
On server side, one could run:
.RS
.br
.B vde_cryptcab -s /tmp/vde2.ctl -p 2100
.RE
To start a multi-peer cryptcab server, accepting udp datagrams on port
2100, that connects each authenticated remote client to a different
port of the switch. In fact, a new instance of
.B vde_plug (1)
is started and connected to the switch through local unix socket.
The command
.RS
.br
.B vde_cryptcab -s /tmp/vde2.ctl -c foo@remote.machine.org:2100
.RE
will connect a client to the remote server, running on udp port 2100.
At this point, on server side a verify for user "foo" credentials is required,
typically it could be: host-based authentication, password challenge
or public key authentication. See
.B ssh (1)
for more details about it.
If the two vde_switches run as daemon and they are connected to tap interfaces
a level 2 encrypted tunnel is established.
.SH OPTIONS
.TP
.B \-p "\fIportnum\fP"
It is possible to decide which local udp port to use.
When this option is not specified, cryptcab will use default udp port number,
7667.
.TP
.B \-c "\fI[remote_user@]host[:remote_portnum]\fP"
run vde_cryptcab in client mode, trying to connect to
.B host .
Both
.B remote_user
and
.B remote_portnum
parameters are not required.
If not specified, the same user running vde_cryptcab is used for
authentication on server, and default udp port 7667 is used.
.TP
.B \-s "\fIsocketpath\fP"
specify the UNIX socket to be used by local programs for joining the VDE.
The default value is "/tmp/vde.ctl".
.TP
.B \-P "\fIpre_shared.keypath\fP"
if specified, vde_cryptcab will run in pre-shared key mode, instead of generating a
random key to transmit with ssh.
Given option is the path to the pre-shared symmetric key file to use for data encryption.
The same key has to be used on both client and server.
.TP
.B \-x
Disable symmetric key encryption.
.TP
.B \-k
Send periodic "keepalive" packets to avoid server timeouts. Useful when you want to keep a low-traffic link available.
.TP
.B \-d
Run as daemon.
.TP
.B \-v
Verbose. (Use -vv -vvv or -vvvv for more verbosity)
.SH KNOWN ISSUES
Encapsulating IP packets into session+udp layer results in real datagrams larger
than tap device mtu. Since vde_cryptcab gets confused by packet fragmentation, the
tap device mtu must be set to a smaller value than real interface mtu. Use
.BR ip (8)
or
.BR ifconfig (8)
to set up your tap device mtu.
Explicitly disabling encryption leads to obvious security problems. It is advised to avoid unencrypted mode (-x) in non-controlled networks.
.SH NOTICE
Virtual Distributed Ethernet is not related in any way with
www.vde.com ("Verband der Elektrotechnik, Elektronik und Informationstechnik"
i.e. the German "Association for Electrical, Electronic & Information
Technologies").
.SH SEE ALSO
\fBvde_switch\fP(1),
\fBvdeq\fP(1),
\fBvde_plug\fP(1),
\fBvde_plug2tap\fP(1),
\fBscp\fP(1),
\fBssh\fP(1).
.br
.SH AUTHORS
VDE is a project by Renzo Davoli .
vde_cryptcab is a VDE component by Daniele Lacamera
vde2-2.3.2/man/vde_autolink.1 0000644 0001750 0001750 00000003563 11663221057 014765 0 ustar renzo renzo .\" DO NOT MODIFY THIS FILE! It was generated by help2man 1.36.
.TH VDE_AUTOLINK "1" "November 2007" "vde_autolink 2.2.0-pre1" "User Commands"
.SH NAME
vde_autolink \- automatically create and maintain vde connections
.SH DESCRIPTION
.TP
\fB\-h\fR, \fB\-\-help\fR
Display this help
.TP
\fB\-f\fR, \fB\-\-rcfile\fR
Configuration file (overrides /etc/vde_autolink.rc and ~/.vde_autolinkrc)
.TP
\fB\-d\fR, \fB\-\-daemon\fR
Daemonize vde_autolink once run
.TP
\fB\-p\fR, \fB\-\-pidfile\fR PIDFILE
Write pid of daemon to PIDFILE
.TP
\fB\-M\fR, \fB\-\-mgmt\fR SOCK
Path of the management UNIX socket
.TP
\fB\-\-mgmtmode\fR MODE
Management UNIX socket access mode (octal)
.TP
\fB\-s\fR, \fB\-\-sock\fR
[*] Attach to this vde_switch socket
.TP
\fB\-S\fR, \fB\-\-switchmgmt\fR
[*] Attach to this vde_switch management socket
.IP
[*] == Required option!
\fB\-h\fR, \fB\-\-help\fR Display this help
\fB\-f\fR, \fB\-\-rcfile\fR Configuration file (overrides /etc/vde_autolink.rc and ~/.vde_autolinkrc)
\fB\-d\fR, \fB\-\-daemon\fR Daemonize vde_autolink once run
\fB\-p\fR, \fB\-\-pidfile\fR PIDFILE Write pid of daemon to PIDFILE
\fB\-M\fR, \fB\-\-mgmt\fR SOCK Path of the management UNIX socket
.TP
\fB\-\-mgmtmode\fR MODE
Management UNIX socket access mode (octal)
.TP
\fB\-s\fR, \fB\-\-sock\fR
[*] Attach to this vde_switch socket
.TP
\fB\-S\fR, \fB\-\-switchmgmt\fR
[*] Attach to this vde_switch management socket
.IP
[*] == Required option!
.SH NOTICE
Virtual Distributed Ethernet is not related in any way with
www.vde.com ("Verband der Elektrotechnik, Elektronik und Informationstechnik"
i.e. the German "Association for Electrical, Electronic & Information
Technologies").
.SH SEE ALSO
\fBvde_switch\fP(1),
\fBvde_plug\fP(1),
.br
.SH AUTHORS
VDE is a project by Renzo Davoli .
vde_autolink is a VDE component by Luca Bigliardi
vde2-2.3.2/man/vde_pcapplug.1 0000644 0001750 0001750 00000004116 11663221057 014745 0 ustar renzo renzo .TH VDE_PCAPPLUG 1 "August 20, 2008" "Virtual Distributed Ethernet"
.SH NAME
vde_pcapplug \- Virtual Distributed Ethernet libpcap cable
.SH SYNOPSIS
.B vde_pcapplug
[OPTION]... \fIinterface\fP
.br
.SH DESCRIPTION
.B vde_pcapplug
is a plug to be connected into a VDE switch.
All the data that is catched by the plug is injected into
.I interface
and everything from that interface is sent in the switch.
.SH OPTIONS
.TP
\fB\-p\fP, \fB\-\-port\fP=\fIportnum\fP
It is possible to decide which port of the switch to use.
When this option is not specified the switch assigns the first
available unused port (if any).
It is possible to connect several cables in the same switch port:
in this way all this cables work concurrently.
It means that packet can result as duplicate but no ARP table loops are
generated.
Is useful when vde is used for mobility. Several physical interfaces can
be used at a time during handoffs to prevent hichups in connectivity.
.TP
\fB\-g\fP, \fB\-\-group\fP=\fIgroup\fP
group ownership of the communication socket. For security when more
want to share a switch it is better to use a unix group to own the comm sockets
so that the network traffic cannot be sniffed.
.TP
\fB\-m\fP, \fB\-\-mod\fP=\fIoctal-mode\fP
octal chmod like permissions for the comm sockets
.TP
\fB\-s\fP, \fB\-\-sock\fP=\fIsocket\fP
specify the UNIX socket to be used by local programs for joining the VDE.
The default value is "/tmp/vde.ctl".
.TP
\fB\-d\fP, \fB\-\-daemon\fP
start vde_plug2tap as a background process
.TP
\fB\-P\fP, \fB\-\-pidfile\fP=\fIpidfile\fP
put the process ID of vde_plug2tap in \fIpidfile\fP. Can be used with
\fB\-\-daemon\fP to store the PID for future killing.
.TP
\fB\-h\fP, \fB\-\-help\fP
show a brief help
.SH NOTICE
Virtual Distributed Ethernet is not related in any way with
www.vde.com ("Verband der Elektrotechnik, Elektronik und Informationstechnik"
i.e. the German "Association for Electrical, Electronic & Information
Technologies").
.SH SEE ALSO
\fBvde_switch\fP(1),
\fBvde_plug\fP(1),
\fBvdeq\fP(1),
\fBdpipe\fP(1).
.br
.SH AUTHOR
VDE is a project by Renzo Davoli
vde2-2.3.2/man/vdeterm.1 0000644 0001750 0001750 00000001630 11663221057 013740 0 ustar renzo renzo .TH VDETERM 1 "July 29, 2008" "Virtual Distributed Ethernet"
.SH NAME
vdeterm \- (simple) Remote terminal for vde management sockets
.SH SYNOPSIS
.B vdeterm
.I socket
.br
.SH DESCRIPTION
A
\fBvdeterm\fP
is a terminal application for a vde tools stream socket.
It has been created as a part of the vde-2 project: it is used as a remote
console for vde_switch or for the wirefilter application.
vdeterm provides command editing, history of previous commands, command completion.
Debug asynchronous messages do not interfere with the command editing line.
.SH NOTICE
Virtual Distributed Ethernet is not related in any way with
www.vde.com ("Verband der Elektrotechnik, Elektronik und Informationstechnik"
i.e. the German "Association for Electrical, Electronic & Information
Technologies").
.SH SEE ALSO
\fBvde_switch\fP(1),
\fBwirefilter\fP(1).
.br
.SH AUTHOR
VDE is a project by Renzo Davoli
vde2-2.3.2/man/vdetaplib.1.in 0000644 0001750 0001750 00000004502 11663221057 014652 0 ustar renzo renzo .TH VDETAPLIB 1 "December 6, 2006" "Virtual Distributed Ethernet"
.SH NAME
vdetaplib \- Virtual Distributed Ethernet tap emulation library
.SH SYNOPSIS
No synopsis
.br
.SH DESCRIPTION
\fBvdetaplib\fP
is a library that emulates tap (tuntap level2 interface, see
in kernel sources Documentation/networking/tun.c) and connects
tap virtual interfaces to vde networks.
To use it, the libvdetab.so library must be preloaded
(sh, ksh or bash syntax):
.RS
.br
.B
export LD_PRELOAD=%PKGLIBDIR%/libvdetap.so
.RE
(csh, tchs syntax):
.RS
.br
.B
setenv LD_PRELOAD %PKGLIBDIR%/libvdetap.so
.RE
If you want to divert all tap requests to a single vde_switch set the
variable VDEALLTAP to the vde socket.
.br
(sh, ksh or bash syntax):
.RS
.br
.B
export VDEALLTAP=/tmp/vde.ctl
.RE
(csh, tchs syntax):
.RS
.br
.B
setenv VDEALLTAP /tmp/vde.ctl
.RE
It is possible to set each single interface to different vde_switches
by setting the environment variable with the same name of the interface.
.br
(sh, ksh or bash syntax):
.RS
.br
.B
export tap0=/tmp/vde.ctl
.br
.B
export tap1=/tmp/myvde.ctl
.br
.B
export ppc=/tmp/ppc.ctl
.RE
(csh, tchs syntax):
.RS
.br
.B
setenv tap0 /tmp/vde.ctl
.br
.B
setenv tap1 /tmp/myvde.ctl
.br
.B
setenv ppc /tmp/ppc.ctl
.RE
.br
It is also possible to specify \fBport\fP, \fBgroup\fP or \fBmode\fP for a given
interface setting environment variables as in the following example.
.br
(sh, ksh or bash syntax):
.RS
.br
.B
export tap0_port=5
.br
.B
export tap0_group=vde-net
.br
.B
export tap0_mode=0660
.RE
(csh, tchs, syntax):
.RS
.br
.B
setenv tap0_port 5
.br
.B
setenv tap0_group vde-net
.br
.B
setenv tap0_mode 0660
.RE
.br
The variable to set the specific interface is checked first then
VDEALLTAP. VDEALLTAP thus works as a default choice for the vde switch
to be used.
If VDEALLTAP is not set and there is no specific environment variable
(and for tun -- IFF_TUN interfaces) the kernel provided interface is used.
In this latter case access to /dev/net/tun is required, generally root access.
.br
.SH NOTICE
Virtual Distributed Ethernet is not related in any way with
www.vde.com ("Verband der Elektrotechnik, Elektronik und Informationstechnik"
i.e. the German "Association for Electrical, Electronic & Information
Technologies").
.SH SEE ALSO
\fBvde_switch\fP(1),
\fBvdeq\fP(1).
.br
.SH AUTHOR
VDE is a project by Renzo Davoli
vde2-2.3.2/README 0000644 0001750 0001750 00000017361 11663221057 012325 0 ustar renzo renzo VDEv2: Virtual Distributed Ethernet.
(c) 2003/2004/2005/2006 Renzo Davoli
Long long time ago based on uml-router Copyright 2002 Yon Uriarte and Jeff Dike
qemu-vde-HOWTO is (c) by Jim Brown
Notice: Virtual Distributed Ethernet is not related in any way with
www.vde.com ("Verband der Elektrotechnik, Elektronik und Informationstechnik"
i.e. the German "Association for Electrical, Electronic & Information
Technologies").
Components of the VDE architecture:
- VDE switches: virtual counterpart of ethernet switches.
- VDE cables: virtual counterpart of a crossed-cable used to connect two switches.
- VDE 2 includes:
- switch management both from console and from a "unix socket terminal"
- VLAN 801.1q *almost* compatible
- FSTP (fast spanning tree) already incomplete and currently not tested for 802.1d/w/s
compatibility. under development. (vde_switch must be compiled with the FSTP flag on)
Using VDE:
- All units connected to the VDE see each other as they were on a real ethernet.
- A real Linux box can be connected to the VDE using a tap interface (TUNTAP)
(packets can be further routed using standard linux methods).
- It is possible to join two VDE switches -- also running on different
real conputers -- using virtual VDE cables
- UML (user-mode-linux) virtual machines can be connected to the VDE
- MPS (MIPS emulated machines (c) Morsiani/Davoli) can be connected
to the virtual VDE.
Examples of VDE uses:
- With VDE it is possible to create a virtual network of UML machines running
on several real computer
- VDE can be used to create tunnels (even crossing masquerated networks)
- VDE can provide mobility support. Changing a VDE cable with another does not
affect the communications in place. The new VDE cable can use a completely
different path on the real net. VDE supports also multiple concurrent VDE cables
between a pair of VDE-switches during the hand-off. This eliminates when possible
hich-ups of communications due to hand-offs.
HOWTO and basic command syntax (for a complete explanation RTM):
vde-switch [ -unix control-socket ] [ -tap tuntap-device ] [ -hub ] [-daemon]
This command creates a VDE switch.
-unix control-socket
The control socket is the socket used for local processes to create a new
connection. The default value is /tmp/vde.ctl.
User-mode-linux default value is /tmp/uml.ctl, so if you want to use vde
with UML you can: (1) use "-unix /tmp/uml.ctl" for vde-switch (2) use
"eth0=daemon,,/tmp/vde.ctl" for UML
-tap tuntap-device
the vde-switch is connected to the specified tap interface.
Ususally it is reserved for root as /dev/net/tun is not writable.
(It is dangerous to have /dev/net/tun writable by ordinary users).
-hub
the vde-switch works as a hub (all packets are broadcast on all interfaces.
-daemon
the switch works as a daemon: it runs in background, it uses syslog
for error management.
vde-plug [-p port] [socketname]
A vde-cable is composed by two vde-plug and a "cable". A vde-plug connects its
standard input and output to a switch.
socketname is the control-socket of the switch the plug must be connected to
(default value /tmp/vde.ctl).
-p port. To use a specific port of the switch. The first available port is
assaigned when not specified. It is possibl eto connect several cables to the
same prot: Cables connected to the same port represent several path
for the same destination.
dpipe cmd1 [arg1] = cmd2 [arg2]
it is the double pipe command (it is here just becouse it is not provided by
shells).
cmd1 and cmd2 are executed, the stdout of cmd1 if pipe connected to the stdin of
cmd2 and viceversa. (the symbol = is intended as a pair of communication pipes
between the two processes.
HOW TO:
- (1) SETUP A DAEMON:
(as root)
# vde_switch -tap tap0 -mod 777 -daemon
# ifconfig tap0 192.168.0.254
if you want to have routing to the Internet you can use standard routing
commands on the host machine e.g.:
# echo "1" > /proc/sys/net/ipv4/ip_forward
# iptables -t nat -A POSTROUTING -o eth0 -j MASQUERADE
for ipv6
# echo "1" > /proc/sys/net/ipv6/conf/eth0/forwarding
# radvd
radvd must be configured to broadcast the correct prefix for the tap0 subnet
----- example of /etc/radvd.conf file
interface tap0
{
AdvSendAdvert on;
MaxRtrAdvInterval 120;
#put here your prefix.
prefix 1111:2222:3333:4444::/64
{
AdvOnLink on;
AdvAutonomous on;
AdvRouterAddr on;
};
};
------ end of example
- (2) SETUP A SECOND DAEMON
(no need for root access)
% vde_switch /tmp/my.ctl
(add - daemon if you want to run it in background)
- (3) CONNECT TWO LOCAL SWITCHES TOGETHER
% dpipe vde_plug = vde_plug /tmp/my.ctl
(or
% dpipe vde_plug /tmp/my.ctl = vde_plug
)
connects the vde_switch with ctl socket /tmp/vde.ctl with the other using
/tmp/my.ctl.
- (3) CONNECT TWO REMOTE SWITCHES TOGETHER
You need a tool to interconnect stdin stdout of two remote processes.
e.g.
% dpipe vde_plug /tmp/my.ctl = ssh remote_machine vde_plug
connects the vde_switch with ctl socket /tmp/vde.ctl on the remote_machine
with the local switch using /tmp/my.ctl.
It is possible to use other tools in place of ssh like netcat.
In this latter case the communication is not secure.
- (4) CREATION OF TUNNELS.
(it needs kernel support for policy routing)
Setup two daemon as described in (1).
In this example 192.168.0.1 is the tap0 address on the server side.
Route the traffic to the Internet on the tunnel server side.
On the tunnel client side:
- in the example 100.200.201.202 is the IP address on eth0
and 100.200.201.254 is the default gateway.
- create a specific rule for the eth0 routing
ip rule add from 100.200.201.202 table eth0-table
(please note that eth0-table must be listed in /etc/iproute2/rt_tables)
ip route del default via 100.200.201.254
ip route add default via 100.200.201.254 table eth0-table
the previous default route will be the def. route just for the
packets originated with the eth0 inteface address.
- connect the two vde-switch together:
dpipe vde-plug = ssh -b 100.200.201.202 server-machine vde-plug
- setup an appropriate IP address for tap0 interface (or get it by dhcp
if set up on server side). (e.g. 192.168.0.10)
- use tap0 as the default interface:
ip route add default via 192.168.0.1
- (5) SUPPORT FOR MOBILITY
Create a tunnel like in 4 using a group number on the vde-cable:
dpipe vde-plug -g 1 = ssh -b 100.200.201.202 server-machine vde-plug -g 1
Create a second tunnel (say on ppp0 addr. 100.100.101.102 gateway 100.100.101.254)
# ip rule add from 100.100.101.102 table ppp0-table
# ip route add default via 100.100.101.254 table ppp0-table
Connect the a second cable using the same group number:
# dpipe vde-plug -g 1 = ssh -b 100.100.101.102 server-machine vde-plug -g 1
Disconnect the first cable (kill the processes of the first cable)
All the traffic get rerouted on the new vde-cable (thus to another path
on the rel network. Connections in place are unaffected by the change.
Several cables of the same group can be in place during the handoff phase
but note that this ends up in duplicated packets that can slow down
the communication.
Please note also that the vde-switches do not manage (yet) the minimum spanning
tree protocol thus a loop in the topology can lead to inconsistent MAC forward
tables and to network saturation.
Copyright 2003/2004/2005/2006/2011 Renzo Davoli
This product includes software developed by Danny Gasparovski and Fabrice
Ballard (slirp support).
Acknowlegments:
Thanks to Marco Giordani, Leonardo Macchia for their useful help for debugging.
Imported code by Danny Gasparovsky, Fabrice Ballard.
Thanks to Giuseppe Della Bianca for many bug reports, and
patch proposals.
Thanks to Daniel P. Barrange for several patches
and the management of group ownership.
Code organization, bugfixes, autotool support Mattia Belletti.
vde2-2.3.2/install-sh 0000755 0001750 0001750 00000032537 11663221136 013451 0 ustar renzo renzo #!/bin/sh
# install - install a program, script, or datafile
scriptversion=2009-04-28.21; # UTC
# This originates from X11R5 (mit/util/scripts/install.sh), which was
# later released in X11R6 (xc/config/util/install.sh) with the
# following copyright and license.
#
# Copyright (C) 1994 X Consortium
#
# Permission is hereby granted, free of charge, to any person obtaining a copy
# of this software and associated documentation files (the "Software"), to
# deal in the Software without restriction, including without limitation the
# rights to use, copy, modify, merge, publish, distribute, sublicense, and/or
# sell copies of the Software, and to permit persons to whom the Software is
# furnished to do so, subject to the following conditions:
#
# The above copyright notice and this permission notice shall be included in
# all copies or substantial portions of the Software.
#
# THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
# IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
# FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
# X CONSORTIUM BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN
# AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNEC-
# TION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
#
# Except as contained in this notice, the name of the X Consortium shall not
# be used in advertising or otherwise to promote the sale, use or other deal-
# ings in this Software without prior written authorization from the X Consor-
# tium.
#
#
# FSF changes to this file are in the public domain.
#
# Calling this script install-sh is preferred over install.sh, to prevent
# `make' implicit rules from creating a file called install from it
# when there is no Makefile.
#
# This script is compatible with the BSD install script, but was written
# from scratch.
nl='
'
IFS=" "" $nl"
# set DOITPROG to echo to test this script
# Don't use :- since 4.3BSD and earlier shells don't like it.
doit=${DOITPROG-}
if test -z "$doit"; then
doit_exec=exec
else
doit_exec=$doit
fi
# Put in absolute file names if you don't have them in your path;
# or use environment vars.
chgrpprog=${CHGRPPROG-chgrp}
chmodprog=${CHMODPROG-chmod}
chownprog=${CHOWNPROG-chown}
cmpprog=${CMPPROG-cmp}
cpprog=${CPPROG-cp}
mkdirprog=${MKDIRPROG-mkdir}
mvprog=${MVPROG-mv}
rmprog=${RMPROG-rm}
stripprog=${STRIPPROG-strip}
posix_glob='?'
initialize_posix_glob='
test "$posix_glob" != "?" || {
if (set -f) 2>/dev/null; then
posix_glob=
else
posix_glob=:
fi
}
'
posix_mkdir=
# Desired mode of installed file.
mode=0755
chgrpcmd=
chmodcmd=$chmodprog
chowncmd=
mvcmd=$mvprog
rmcmd="$rmprog -f"
stripcmd=
src=
dst=
dir_arg=
dst_arg=
copy_on_change=false
no_target_directory=
usage="\
Usage: $0 [OPTION]... [-T] SRCFILE DSTFILE
or: $0 [OPTION]... SRCFILES... DIRECTORY
or: $0 [OPTION]... -t DIRECTORY SRCFILES...
or: $0 [OPTION]... -d DIRECTORIES...
In the 1st form, copy SRCFILE to DSTFILE.
In the 2nd and 3rd, copy all SRCFILES to DIRECTORY.
In the 4th, create DIRECTORIES.
Options:
--help display this help and exit.
--version display version info and exit.
-c (ignored)
-C install only if different (preserve the last data modification time)
-d create directories instead of installing files.
-g GROUP $chgrpprog installed files to GROUP.
-m MODE $chmodprog installed files to MODE.
-o USER $chownprog installed files to USER.
-s $stripprog installed files.
-t DIRECTORY install into DIRECTORY.
-T report an error if DSTFILE is a directory.
Environment variables override the default commands:
CHGRPPROG CHMODPROG CHOWNPROG CMPPROG CPPROG MKDIRPROG MVPROG
RMPROG STRIPPROG
"
while test $# -ne 0; do
case $1 in
-c) ;;
-C) copy_on_change=true;;
-d) dir_arg=true;;
-g) chgrpcmd="$chgrpprog $2"
shift;;
--help) echo "$usage"; exit $?;;
-m) mode=$2
case $mode in
*' '* | *' '* | *'
'* | *'*'* | *'?'* | *'['*)
echo "$0: invalid mode: $mode" >&2
exit 1;;
esac
shift;;
-o) chowncmd="$chownprog $2"
shift;;
-s) stripcmd=$stripprog;;
-t) dst_arg=$2
shift;;
-T) no_target_directory=true;;
--version) echo "$0 $scriptversion"; exit $?;;
--) shift
break;;
-*) echo "$0: invalid option: $1" >&2
exit 1;;
*) break;;
esac
shift
done
if test $# -ne 0 && test -z "$dir_arg$dst_arg"; then
# When -d is used, all remaining arguments are directories to create.
# When -t is used, the destination is already specified.
# Otherwise, the last argument is the destination. Remove it from $@.
for arg
do
if test -n "$dst_arg"; then
# $@ is not empty: it contains at least $arg.
set fnord "$@" "$dst_arg"
shift # fnord
fi
shift # arg
dst_arg=$arg
done
fi
if test $# -eq 0; then
if test -z "$dir_arg"; then
echo "$0: no input file specified." >&2
exit 1
fi
# It's OK to call `install-sh -d' without argument.
# This can happen when creating conditional directories.
exit 0
fi
if test -z "$dir_arg"; then
trap '(exit $?); exit' 1 2 13 15
# Set umask so as not to create temps with too-generous modes.
# However, 'strip' requires both read and write access to temps.
case $mode in
# Optimize common cases.
*644) cp_umask=133;;
*755) cp_umask=22;;
*[0-7])
if test -z "$stripcmd"; then
u_plus_rw=
else
u_plus_rw='% 200'
fi
cp_umask=`expr '(' 777 - $mode % 1000 ')' $u_plus_rw`;;
*)
if test -z "$stripcmd"; then
u_plus_rw=
else
u_plus_rw=,u+rw
fi
cp_umask=$mode$u_plus_rw;;
esac
fi
for src
do
# Protect names starting with `-'.
case $src in
-*) src=./$src;;
esac
if test -n "$dir_arg"; then
dst=$src
dstdir=$dst
test -d "$dstdir"
dstdir_status=$?
else
# Waiting for this to be detected by the "$cpprog $src $dsttmp" command
# might cause directories to be created, which would be especially bad
# if $src (and thus $dsttmp) contains '*'.
if test ! -f "$src" && test ! -d "$src"; then
echo "$0: $src does not exist." >&2
exit 1
fi
if test -z "$dst_arg"; then
echo "$0: no destination specified." >&2
exit 1
fi
dst=$dst_arg
# Protect names starting with `-'.
case $dst in
-*) dst=./$dst;;
esac
# If destination is a directory, append the input filename; won't work
# if double slashes aren't ignored.
if test -d "$dst"; then
if test -n "$no_target_directory"; then
echo "$0: $dst_arg: Is a directory" >&2
exit 1
fi
dstdir=$dst
dst=$dstdir/`basename "$src"`
dstdir_status=0
else
# Prefer dirname, but fall back on a substitute if dirname fails.
dstdir=`
(dirname "$dst") 2>/dev/null ||
expr X"$dst" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
X"$dst" : 'X\(//\)[^/]' \| \
X"$dst" : 'X\(//\)$' \| \
X"$dst" : 'X\(/\)' \| . 2>/dev/null ||
echo X"$dst" |
sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
s//\1/
q
}
/^X\(\/\/\)[^/].*/{
s//\1/
q
}
/^X\(\/\/\)$/{
s//\1/
q
}
/^X\(\/\).*/{
s//\1/
q
}
s/.*/./; q'
`
test -d "$dstdir"
dstdir_status=$?
fi
fi
obsolete_mkdir_used=false
if test $dstdir_status != 0; then
case $posix_mkdir in
'')
# Create intermediate dirs using mode 755 as modified by the umask.
# This is like FreeBSD 'install' as of 1997-10-28.
umask=`umask`
case $stripcmd.$umask in
# Optimize common cases.
*[2367][2367]) mkdir_umask=$umask;;
.*0[02][02] | .[02][02] | .[02]) mkdir_umask=22;;
*[0-7])
mkdir_umask=`expr $umask + 22 \
- $umask % 100 % 40 + $umask % 20 \
- $umask % 10 % 4 + $umask % 2
`;;
*) mkdir_umask=$umask,go-w;;
esac
# With -d, create the new directory with the user-specified mode.
# Otherwise, rely on $mkdir_umask.
if test -n "$dir_arg"; then
mkdir_mode=-m$mode
else
mkdir_mode=
fi
posix_mkdir=false
case $umask in
*[123567][0-7][0-7])
# POSIX mkdir -p sets u+wx bits regardless of umask, which
# is incompatible with FreeBSD 'install' when (umask & 300) != 0.
;;
*)
tmpdir=${TMPDIR-/tmp}/ins$RANDOM-$$
trap 'ret=$?; rmdir "$tmpdir/d" "$tmpdir" 2>/dev/null; exit $ret' 0
if (umask $mkdir_umask &&
exec $mkdirprog $mkdir_mode -p -- "$tmpdir/d") >/dev/null 2>&1
then
if test -z "$dir_arg" || {
# Check for POSIX incompatibilities with -m.
# HP-UX 11.23 and IRIX 6.5 mkdir -m -p sets group- or
# other-writeable bit of parent directory when it shouldn't.
# FreeBSD 6.1 mkdir -m -p sets mode of existing directory.
ls_ld_tmpdir=`ls -ld "$tmpdir"`
case $ls_ld_tmpdir in
d????-?r-*) different_mode=700;;
d????-?--*) different_mode=755;;
*) false;;
esac &&
$mkdirprog -m$different_mode -p -- "$tmpdir" && {
ls_ld_tmpdir_1=`ls -ld "$tmpdir"`
test "$ls_ld_tmpdir" = "$ls_ld_tmpdir_1"
}
}
then posix_mkdir=:
fi
rmdir "$tmpdir/d" "$tmpdir"
else
# Remove any dirs left behind by ancient mkdir implementations.
rmdir ./$mkdir_mode ./-p ./-- 2>/dev/null
fi
trap '' 0;;
esac;;
esac
if
$posix_mkdir && (
umask $mkdir_umask &&
$doit_exec $mkdirprog $mkdir_mode -p -- "$dstdir"
)
then :
else
# The umask is ridiculous, or mkdir does not conform to POSIX,
# or it failed possibly due to a race condition. Create the
# directory the slow way, step by step, checking for races as we go.
case $dstdir in
/*) prefix='/';;
-*) prefix='./';;
*) prefix='';;
esac
eval "$initialize_posix_glob"
oIFS=$IFS
IFS=/
$posix_glob set -f
set fnord $dstdir
shift
$posix_glob set +f
IFS=$oIFS
prefixes=
for d
do
test -z "$d" && continue
prefix=$prefix$d
if test -d "$prefix"; then
prefixes=
else
if $posix_mkdir; then
(umask=$mkdir_umask &&
$doit_exec $mkdirprog $mkdir_mode -p -- "$dstdir") && break
# Don't fail if two instances are running concurrently.
test -d "$prefix" || exit 1
else
case $prefix in
*\'*) qprefix=`echo "$prefix" | sed "s/'/'\\\\\\\\''/g"`;;
*) qprefix=$prefix;;
esac
prefixes="$prefixes '$qprefix'"
fi
fi
prefix=$prefix/
done
if test -n "$prefixes"; then
# Don't fail if two instances are running concurrently.
(umask $mkdir_umask &&
eval "\$doit_exec \$mkdirprog $prefixes") ||
test -d "$dstdir" || exit 1
obsolete_mkdir_used=true
fi
fi
fi
if test -n "$dir_arg"; then
{ test -z "$chowncmd" || $doit $chowncmd "$dst"; } &&
{ test -z "$chgrpcmd" || $doit $chgrpcmd "$dst"; } &&
{ test "$obsolete_mkdir_used$chowncmd$chgrpcmd" = false ||
test -z "$chmodcmd" || $doit $chmodcmd $mode "$dst"; } || exit 1
else
# Make a couple of temp file names in the proper directory.
dsttmp=$dstdir/_inst.$$_
rmtmp=$dstdir/_rm.$$_
# Trap to clean up those temp files at exit.
trap 'ret=$?; rm -f "$dsttmp" "$rmtmp" && exit $ret' 0
# Copy the file name to the temp name.
(umask $cp_umask && $doit_exec $cpprog "$src" "$dsttmp") &&
# and set any options; do chmod last to preserve setuid bits.
#
# If any of these fail, we abort the whole thing. If we want to
# ignore errors from any of these, just make sure not to ignore
# errors from the above "$doit $cpprog $src $dsttmp" command.
#
{ test -z "$chowncmd" || $doit $chowncmd "$dsttmp"; } &&
{ test -z "$chgrpcmd" || $doit $chgrpcmd "$dsttmp"; } &&
{ test -z "$stripcmd" || $doit $stripcmd "$dsttmp"; } &&
{ test -z "$chmodcmd" || $doit $chmodcmd $mode "$dsttmp"; } &&
# If -C, don't bother to copy if it wouldn't change the file.
if $copy_on_change &&
old=`LC_ALL=C ls -dlL "$dst" 2>/dev/null` &&
new=`LC_ALL=C ls -dlL "$dsttmp" 2>/dev/null` &&
eval "$initialize_posix_glob" &&
$posix_glob set -f &&
set X $old && old=:$2:$4:$5:$6 &&
set X $new && new=:$2:$4:$5:$6 &&
$posix_glob set +f &&
test "$old" = "$new" &&
$cmpprog "$dst" "$dsttmp" >/dev/null 2>&1
then
rm -f "$dsttmp"
else
# Rename the file to the real destination.
$doit $mvcmd -f "$dsttmp" "$dst" 2>/dev/null ||
# The rename failed, perhaps because mv can't rename something else
# to itself, or perhaps because mv is so ancient that it does not
# support -f.
{
# Now remove or move aside any old file at destination location.
# We try this two ways since rm can't unlink itself on some
# systems and the destination file might be busy for other
# reasons. In this case, the final cleanup might fail but the new
# file should still install successfully.
{
test ! -f "$dst" ||
$doit $rmcmd -f "$dst" 2>/dev/null ||
{ $doit $mvcmd -f "$dst" "$rmtmp" 2>/dev/null &&
{ $doit $rmcmd -f "$rmtmp" 2>/dev/null; :; }
} ||
{ echo "$0: cannot unlink or rename $dst" >&2
(exit 1); exit 1
}
} &&
# Now rename the file to the real destination.
$doit $mvcmd "$dsttmp" "$dst"
}
fi || exit 1
trap '' 0
fi
done
# Local variables:
# eval: (add-hook 'write-file-hooks 'time-stamp)
# time-stamp-start: "scriptversion="
# time-stamp-format: "%:y-%02m-%02d.%02H"
# time-stamp-time-zone: "UTC"
# time-stamp-end: "; # UTC"
# End:
vde2-2.3.2/doc/ 0000755 0001750 0001750 00000000000 11663221165 012202 5 ustar renzo renzo vde2-2.3.2/doc/README.qemu 0000644 0001750 0001750 00000001326 11663221057 014032 0 ustar renzo renzo vdeq is an execution shell for qemu.
vdeq starts qemu interfacing it to vde by using the -tun-fd option.
vdeq can be started in two ways:
- explicetely:
vdeq qemu image.bin
or
vdeq -vdesock /tmp/my.ctl qemu-softmmu disk.bin
This latter example starts qemu-softmmu with eth0 connected to the vde_switch
having /tmp/my.ctl as control socket.
- implicitely:
ln -s vdeq vdeqemu
...
vdeqemu image.bin
starts "qemu image.bin" (connected to the vde switch having the standard
control socket /tmp/vde.ctl).
when vdeq is invoked as vdexxxx (argv[0] is vdexxxx), it runs xxxx using
the current definition of path.
Everything runs at user-level, all the executables are not setuid so there are
no dangers for system security.
vde2-2.3.2/doc/libvdemgmt/ 0000755 0001750 0001750 00000000000 11663221165 014334 5 ustar renzo renzo vde2-2.3.2/doc/libvdemgmt/asyncrecv.rc 0000644 0001750 0001750 00000000152 11663221057 016655 0 ustar renzo renzo TIMEOUT 1000
1 IN '\n' 100
2 IF '30' 10
3 GOTO 100
10 COPY
11 SKIP 2
12 RVATOI 8
13 EXITRV
100 EXIT -1
vde2-2.3.2/doc/libvdemgmt/sendcmd.rc 0000644 0001750 0001750 00000000637 11663221057 016305 0 ustar renzo renzo TIMEOUT 1000
1 SEND '$*\n'
2 THROW
3 IN '\n' 100
4 IF '30' 10
5 IF '10' 20
6 IF '0000 DATA END WITH \'.\'' 30
7 GOTO 2
10 SKIP 5
11 COPY
13 OUTTAG 3
14 OUTSHIFT
15 GOTO 2
20 SKIP 2
21 RVATOI
22 THROW
23 IN '$ ' 100
24 IF '30' 40
25 EXITRV
30 THROW
31 IN '\n' 100
32 IF '.\n' 35
33 COPY
34 GOTO 30
35 OUTTAG 1
36 OUTSHIFT
37 GOTO 2
40 SKIP 5
41 COPY
42 OUTTAG 3
43 OUTSHIFT
44 SKIP '\n'
45 GOTO 24
100 EXIT -1
vde2-2.3.2/doc/libvdemgmt/openmachine.rc 0000644 0001750 0001750 00000000070 11663221057 017145 0 ustar renzo renzo TIMEOUT 1000
1 IN '$ ' 100
2 COPY
3 EXIT 0
100 EXIT -1
vde2-2.3.2/doc/libvdemgmt/closemachine.rc 0000644 0001750 0001750 00000000033 11663221057 017310 0 ustar renzo renzo 1 SEND 'logout\n'
2 EXIT 0
vde2-2.3.2/doc/README.UML 0000644 0001750 0001750 00000000214 11663221057 013513 0 ustar renzo renzo VDE-switch is already compatible with UML-switch (from which it was originally
derived).
linux ubd0=.... eth0=daemon,,,/tmp/vde.ctl ....
vde2-2.3.2/doc/vdeqemu-HOWTO 0000644 0001750 0001750 00000025471 11663221057 014502 0 ustar renzo renzo Using VDE with Qemu HOWTO
by Jim Brown
5 Oct 2004
Version 0.2
-----------------------------------------------------------------------------
Introduction
Copyright
What is qemu?
What is VDE?
Configuring and Installing VDE
Installation
vdeq & vdeqemu
User-mode networking
How to enable user-mode networking
Firewall configuration
Slirp (rootless) networking
What is slirp networking?
How to enable slirp networking?
Setting up qemu
How to set up the guest OS
Credits
-----------------------------------------------------------------------------
Introduction
Copyright
Copyright (c) 2004 Jim Brown.
Permission is granted to copy, distribute and/or modify this document
under the terms of the GNU Free Documentation License, Version 1.2
or any later version published by the Free Software Foundation;
with no Invariant Sections, no Front-Cover Texts, and no Back-Cover
Texts. A copy of the license is available at http://www.gnu.org/licenses/fdl.txt
What is qemu?
Qemu is a FAST! processor emulator by Fabrice Bellard, available at
http://fabrice.bellard.free.fr/qemu/. It is capable of emulationg the x86 and
PowerPC processors with support for other processors on the way. The original
purpose of qemu was to allow running x86-specific Linux applications, such as
WINE or DosEmu, on non-x86 systems. However, qemu has expanded into becoming
a full-fledged emulator. On the x86 side, it is capable of running Linux,
MS-DOS, Windows 95/98/Me, Windows NT/2k, Windows XP, Solaris, OpenBSD, and
FreeBSD. See http://fabrice.bellard.free.fr/qemu/ossupport.html for the full
listing.
This howto assumes that you have already installed and set up qemu.
What is VDE?
VDE is short for Virtual Distributed Ethernet. VDE, written by
Renzo Davoli, is based off of uml_switch by Jeff Dike. It is available at
http://sourceforge.net/projects/vde/. It has many uses, the main one providing
support for networking with emulated computers. (Not just qemu, but support
for user-mode linux and Bochs also exists). VDE must be set up and installed by
root, but the programs which use it do not need root privligies.
This howto will walk you through the simple process of installing
VDE and setting up qemu to use it.
-----------------------------------------------------------------------------
Configuring and Installing VDE
Installation
You may obtain the source code at http://sourceforge.net/projects/vde/.
The version of VDE which I used was 1.4.1, but this HOWTO should apply to all
versions.
Once you have downloaded the source code, extract it. I assume you
will have extracted it to /space/vde. Go into that directory, and simply type
"make" followed by "make install". Now you should have vde_switch in /usr/bin.
vdeq & vdeqemu
Now cd into the qemu directory. Type "make". This will build vdeq.
Qemu on its own only supports full networking with tuntap, which requires
root priviliges or an exposed /dev/net/tun. There is a -user-net option, but
that is not as useful as full networking. In order for qemu to use VDE, it must
be passed the file descriptor for a tun device. Futhermore the tun device itself
must already be configured to use VDE. vdeq sets this up and passes it to qemu
via the -tun-fd switch.
There is no "make install". Instead, you just manually copy vdeq to
/usr/bin. It might also be helpful to copy or link vdeq to vdeqemu. vdeq
requires that the location of the qemu binary be passes to it as the first
command line parameter, but vdeqemu only needs the options you want to pass to
qemu. vdeqemu will locate the qemu binary itself (this requires that you install
qemu system-wide or have the qemu directory in your PATH).
For example if you have:
vdeq qemu -hda /mnt/myimage -m 64 -boot a
you can shorten this into
vdeqemu -hda /mnt/myimage -m 64 -boot a
-----------------------------------------------------------------------------
User-mode Networking
How to enable user-mode networking
The following commands will need to be run as root:
# vde_switch -tap tap0 -daemon
If you need to run a sniffer, just in case you want to analyze the traffic,
you can also run it like this:
# vde_switch -hub -tap tap0 -daemon
(The -hub option is not available for version 1.4.1 of VDE, you will need a
later version. I don't know what the minimal version is but 1.5.1 does support
this option.)
Then you must run this:
# ifconfig tap0
# chmod 755 /tmp/vde.ctl
The vde_switch command will run VDE in the background. The -tap tap0
parameter tells VDE to set up the device tap0 using tuntap. -daemon runs
vde_switch in the background. -hub tells VDE to broadcast the message to all
segment, just like real hub that you use on real network.
is the ip address of the gateway you want to use for the guest
OS(es). For example:
# ifconfig tap0 192.168.254.254
will make 192.168.254.254 the gateway between guest and host, and your
guest OS(es) will belong to the subnet 192.168.254.0 with a netmask of 255.255.255.0
and an ip address of 192.168.254.XXX (where you get to pick the XXX). You must have
the IP of the qemu guest and the IP of the gateway on the same subnet! While it
may be possible to have them on separate subnets, it will certainly be harder
to configure (and you won't like the way your routing tables will look either).
[Sidebar: The "gateway" is actually the host OS itself on the tap0 interface.
The host on the tap0 interface, aka 192.168.254.254, routes between the guest
OS and the host's eth0 interface (which on is the real network). The host on the
eth0 interface (ex. 192.168.0.2) can then route between the tap0 interface and
the real network / the internet.]
(Note that you might be required to do this:
# ifconfig tap0 192.168.254.254 netmask 255.255.255.0
Normally ifconfig should pick the correct netmask for you, but if it doesn't
for some reason then you will have to specify it manually. See ifconfig(8) for
details.
)
Note that you must run this before you run your firewall. I found it helpful
to put this into a script, and have the script load before the firewall does.
Firewall configuration
You will need to enable masquerading between tap0 and your local area
network (for example, eth0). You will also need to enable masquerading between
tap0 and ppp0 if you use a dialup connection to the internet. The commands
# echo "1" > /proc/sys/net/ipv4/ip_forward
# iptables -t nat -A POSTROUTING -o eth0 -j MASQUERADE
# iptables -t nat -A POSTROUTING -o ppp0 -j MASQUERADE
will allow you to enable this manually.
-----------------------------------------------------------------------------
Slirp networking
What is slirp networking?
Slirp was an early program that existed before the masses knew of the internet.
Back then, those who knew of it could access it only in one way: through a
Unix shell account (or other such terminal account). This meant that one had to
do all the things they wanted to in that terminal window. Back then, there were
two dial up protocols: PPP and SLIP. PPP is now the standard but back then SLIP
was more common (as it was cheaper).
Slirp was designed to turn those shell accounts into SLIP connections. It worked
by converting SLIP packets into socket connections. What you had to do was to
run slirp on the computer you had the shell account on, and then connect your
SLIP driver/dialer to the terminal slirp was running on (normally this
'terminal' was in fact a modem). Slirp would then interpret the data that SLIP
sent and transfer the data between the user's computer and the internet. To
the user, it looked like they were actually connected directly to the internet
through a firewall.
Slirp is not used today (to the best of my knowledge) but the innovative idea it
had is used by both qemu and vde. Instead of converting SLIP packets however,
they convert ethernet packets. qemu's slirp networking is similar to vde's
but it is simpler to use and also limited to a single qemu instance (you can
not link multiple guest OSes together on the same network with slirp networking
unless you use VDE).
How to enable slirp networking?
This is very similar to TUNTAP networking in the previous section, but the
commands are slightly different. In addition, you do not need to set up
routing or firewall rules.
First off, you load vde_switch (no parameters are required for this case,
although you can pass the -unix parameter if you want to use a different
socket - required if you already have tuntap networking on the default
socket).
vde_switch
or
vde_switch -unix /tmp/unx.ctl
The latter is required if you are running both slirp and tuntap or multiple
slirp networks (for that matter, if you are running multiple tuntap networks).
More on that later.
Now you need the slirpvde command. slirpvde is the utilitry that provides the
slirp functionality - it intercepts ethernet packets on the network and
forwards them through the real network via emulation. To use it, you want
to do this:
slirpvde -s /tmp/unx.ctl -n 192.168.2.0 -d
The -s tells slirpvde that vde_switch is running on /tmp/unx.ctl [this switch
can be omitted if you called vde_switch by itself]. The -d switch tells
slirpvde to emulate a DHCP server. This is not required but it allows for
automatic configuration of the guest OS (it is basicly the same as qemu's
builtin DHCP server). Depending on your needs, you may be better off running
a real DHCP server in one of the guest OSes.
The last option, -n, tells slirpvde
what subnet the network should be on (this is also used by the DHCP server to
figure out what ip addresses to assign). The gateway ip when using slirpvde
is X.X.X.2 (where X.X.X equals the first 3 parts of the subnet you passed to
it via -n, in this example 192.168.2) and the default DNS server is X.X.X.3
You can not change the gateway ip to something other than .2 and the DNS ip
to something other than .3 unless you change the source in slirpvde and
recompile.
-----------------------------------------------------------------------------
Setting up qemu
How to set up the guest OS
Set up the guest OS so that the default route is through the gateway
ip, (for example 192.168.254.254). Also set up the subnet and netmask
parameters as appropriate (for example 192.168.254.0 and 255.255.255.0).
The guest OS should see the ethernet device and be able to use it to access
the gateway. (Caveat: I haven't been able to do this for MS-DOS, and for Minix
2.0.4 I had to apply a patch to qemu since Minix is broken. Uodate: Minix 2.0.4
is still broken but a patch has been released to fix it. Using this patch,
Minix works on a vanilla qemu.) Also don't forget to set up the IP of the guest
OS itself (for example 192.168.254.1).
-----------------------------------------------------------------------------
Credits
This HOWTO relied heavily on the documentation that Renzo wrote for
vde-1.4.1.
Thanks to Mulyadi Santosa for helping with the first revision of
this document, and to Renzo for his input. (P.S. Will add info for ale4net
and slirpvde as soon as I figure out how to use it ;)
vde2-2.3.2/doc/freebsd_tap-HOWTO 0000644 0001750 0001750 00000001411 11663221057 015276 0 ustar renzo renzo HOWTO START VDE WITH TAP BY NON-ROOT USERS
(tested on FreeBSD 6.2)
- Look at output of "kldstat" for module "if_tap.ko",
if you can't find it do "kldload if_tap.ko".
Remember to do
# echo "if_tap_load=YES" >> /boot/loader.conf
to load it automatically at startup.
- Allow users to open tap interfaces:
# sysctl net.link.tap.user_open=1
Remember to do
# echo "net.link.tap.user_open=1" >> /etc/sysctl.conf
to enable it automatically at startup.
- Adjust devfs rules (assuming your users belong to 'vde' group):
# echo "own tapN root:vde" >> /etc/devfs.conf
# echo "perm tapN 0660" >> /etc/devfs.conf
N is interface number, use tap* if you want the same behaviour
for each interface.
- Create an interface:
# ls /dev/tap0
# /etc/rc.d/devfs restart
vde2-2.3.2/doc/README.vde_over_ns 0000644 0001750 0001750 00000001645 11663221057 015400 0 ustar renzo renzo VDE over NS
Notice: this code was derived from nstx, a steganographic client/server performing
IP-over-DNS.
Original authors:
Florian Heinz
Julien Oster
Start the server on one end, and attach it to an existing vde_switch with vde_plug cmd:
dpipe vde_plug /tmp/vde.ctl = vde_over_ns tun.virtual.vde
do the same with the client on the other end:
dpipe vde_plug /tmp/vde.ctl = vde_over_ns -c 125.23.53.12 tun.virtual.vde
125.23.53.12 has to be a DNS-server which can be reached by the client-side.
The server *must* run on a server where an NS-record for tun.virtual.vde points
to. So if the server has the IP 1.2.3.4 there must exist an entry in the
zonefile of virtual.vde: tun IN NS 1.2.3.4
Now the switches on the two boxes should be plugged.
Note: the flow is optimized from client to server. server to client too works
fine, but it's not as good
Daniele Lacamera
vde2-2.3.2/doc/vdecmd 0000644 0001750 0001750 00000000351 11663221057 013366 0 ustar renzo renzo TIMEOUT 1000
1 IN '$ ' 100
3 SEND '$*\n'
5 THROW
6 IN '\n' 100
7 IF '0000 DATA END WITH \'.\'' 10
8 IF '10' 20
9 GOTO 100
10 THROW
11 IN '\n' 100
12 IF '.\n' 5
13 COPY
14 GOTO 10
20 SKIP 2
21 SEND 'logout\n'
22 EXITATOI
100 EXIT -1
vde2-2.3.2/doc/README.bochs 0000644 0001750 0001750 00000000605 11663221057 014160 0 ustar renzo renzo The eth_vde interface is already in the cvs of the mainstream bochs distribution.
See bochs.sf.net.
eth.cc.diff is a patch file for eth.cc.
eth_vde.cc is the driver.
The makefile of the iodev directory must be changed as well.
In the bochrc file the configuration lines for vde should sound like this:
ne2k: ioaddr=0x280, irq=9, mac=fe:fd:00:00:00:01, ethmod=vde, ethdev=/tmp/vde.ctl
vde2-2.3.2/doc/README.slirpvde 0000644 0001750 0001750 00000000320 11663221057 014704 0 ustar renzo renzo slirpvde is based upon:
slirp by Danny Gasparovsky
slirp support for Qemu by Fabrice Bellard
slirp-vde interface by Renzo Davoli
This product includes software developed by Danny Gasparovski.
2004.05.03
vde2-2.3.2/doc/Makefile.am 0000644 0001750 0001750 00000001150 11663221057 014233 0 ustar renzo renzo EXTRA_DIST = \
libvdemgmt/asyncrecv.rc \
libvdemgmt/sendcmd.rc \
libvdemgmt/openmachine.rc \
libvdemgmt/closemachine.rc \
vde_autolink-HOWTO \
vdeqemu-HOWTO \
vdecmd \
freebsd_tap-HOWTO \
bochs/eth_vde.cc \
bochs/eth.cc.diff \
README.UML \
README.bochs \
README.qemu \
README.slirpvde \
README.vde_over_ns \
README.VirtualBox \
VirtualBox-3.1.6_OSE_VDE.patch
vdecmddir = $(sysconfdir)/vde2/
dist_vdecmd_DATA = vdecmd
libvdemgmtdir = $(sysconfdir)/vde2/libvdemgmt/
dist_libvdemgmt_DATA = libvdemgmt/asyncrecv.rc libvdemgmt/closemachine.rc \
libvdemgmt/openmachine.rc libvdemgmt/sendcmd.rc
vde2-2.3.2/doc/README.VirtualBox 0000644 0001750 0001750 00000001353 11663221057 015162 0 ustar renzo renzo VDE is a standard feature of Virtual Box 3.2.0.
The "VDE Adapter" option automatically appears when VirtualBox runs on a
host with VDE support (i.e. if VirtualBox can load the libvdeplug library).
(Renzo Davoli, May 08 2010).
----
Obsolete info for 3.1.6
This directory contains a preliminary patch to add a native support for VDE
in VirtualBox.
How to compile VirtualBox+VDE support.
Download VirtualBox source code from here:
http://download.virtualbox.org/virtualbox/
Expand the source tar.bz2.
Apply the patch (in the root dir of the source hierarchy):
$ patch -p 1