Commit fe2d3261 authored by cvs2svn's avatar cvs2svn

This commit was manufactured by cvs2svn to create tag 'gtw-protogeni-config-

origin'.

Sprout from gtw-protogeni-config 2008-12-16 00:11:14 UTC cvs2svn <admin@example.com> 'This commit was manufactured by cvs2svn to create branch 'gtw-protogeni-'
Cherrypick from gtw-protogeni-config 2008-12-18 18:56:19 UTC cvs2svn <admin@example.com> 'This commit was manufactured by cvs2svn to create branch 'gtw-protogeni-':
    mfs/linux_mfs/variables.mk
    mfs/linux_mfs/source/linux/bsdlabel.patch
    mfs/linux_mfs/source/linux/dell_optiplex_745_reboot.patch
    mfs/linux_mfs/source/linux/ipod.patch
    mfs/linux_mfs/source/openssl/uclibc_timeb.patch
    delay/freebsd/ipfw_mods/ipfw-FreeBSD-4.10.patch
Cherrypick from gtw-protogeni-config 2008-12-23 19:38:41 UTC cvs2svn <admin@example.com> 'This commit was manufactured by cvs2svn to create branch 'gtw-protogeni-':
    mfs/linux_mfs/source/perl/sysv_ipc.patch
    mfs/linux_mfs/source/perl/Makefile
    mfs/linux_mfs/source/perl/makedepend.patch
    mfs/linux_mfs/source/perl/config.sh
    mfs/linux_mfs/source/perl/install_modules
Cherrypick from master 2008-12-23 21:35:59 UTC Ryan Jackson <rdjackso@flux.utah.edu> '*** empty log message ***':
    protogeni/scripts/getcacerts.in
    mfs/linux_mfs/Makefile
    protogeni/scripts/shutdownslice.in
    mfs/linux_mfs/source/buildroot/buildroot.config
    tmcd/tmcd.c
    tmcd/linux/GNUmakefile.in
    protogeni/scripts/initsite.in
    www/newproject.php3
    tmcd/freebsd/delaysetup
    mfs/linux_mfs/source/target_template/template/etc/init.d/S60frisbee
    event/delay-agent/main.h
    pxe/bootwhat.h
    protogeni/etc/protogeni.sql
    tmcd/linux/get_edd_map
    sql/database-migrate.txt
    os/imagezip/imagezip.c
    mfs/linux_mfs/source/busybox/busybox.config
    event/delay-agent/callback.c
    pxe/bootinfo_mysql.c
    tmcd/linux/rc.frisbee
    tbsetup/ptopgen.in
    www/beginexp_form.php3
    xmlrpc/emulabserver.py.in
    mfs/linux_mfs/source/linux/linux.config
    protogeni/scripts/gencrl.in
    os/imagezip/ntfs/libntfs/Makefile-linux.sa
    tmcd/linux/slicefix
    delay/freebsd/kmods/freebsd-410_Backfill.patch
    sql/database-create.sql
    mfs/linux_mfs/source/testbed/Makefile
    apache/httpd.conf.in
parent 0c52f791
...@@ -1329,7 +1329,7 @@ SSLVerifyClient none ...@@ -1329,7 +1329,7 @@ SSLVerifyClient none
# Reject the unencrypted certs that all users get. # Reject the unencrypted certs that all users get.
<Location /> <Location />
SSLRequire ( %{SSL_CLIENT_S_DN_OU} ne "sslxmlrpc" ) SSLRequire ( %{SSL_CLIENT_S_DN_OU} ne "sslxmlrpc" )
</Location /> </Location>
ScriptAlias /protogeni/xmlrpc/ch @prefix@/protogeni/xmlrpc/protogeni-ch.pl ScriptAlias /protogeni/xmlrpc/ch @prefix@/protogeni/xmlrpc/protogeni-ch.pl
ScriptAlias /protogeni/xmlrpc/cm @prefix@/protogeni/xmlrpc/protogeni-cm.pl ScriptAlias /protogeni/xmlrpc/cm @prefix@/protogeni/xmlrpc/protogeni-cm.pl
......
--- sbin/ipfw.orig/ipfw.c Fri Sep 17 11:14:50 2004
+++ sbin/ipfw/ipfw.c Fri Dec 5 16:15:10 2008
@@ -946,6 +946,7 @@
" pipeconfig:\n"
" {bw|bandwidth} <number>{bit/s|Kbit/s|Mbit/s|Bytes/s|KBytes/s|MBytes/s}\n"
" {bw|bandwidth} interface_name\n"
+" backfill <number>{bit/s|Kbit/s|Mbit/s|Bytes/s|KBytes/s|MBytes/s}\n"
" delay <milliseconds>\n"
" queue <size>{packets|Bytes|KBytes}\n"
" plr <fraction>\n"
@@ -1564,6 +1565,27 @@
pipe.bandwidth *= 8;
}
if (pipe.bandwidth < 0)
+ errx(EX_DATAERR,
+ "bandwidth too large");
+ av += 2;
+ ac -= 2;
+ } else if (!strncmp(*av, "backfill", len)) {
+ pipe.backfill =
+ strtoul(av[1], &end, 0);
+ if (*end == 'K'
+ || *end == 'k') {
+ end++;
+ pipe.backfill *=
+ 1000;
+ } else if (*end == 'M') {
+ end++;
+ pipe.backfill *=
+ 1000000;
+ }
+ if (*end == 'B'
+ || !strncmp(end, "by", 2))
+ pipe.backfill *= 8;
+ if (pipe.backfill < 0)
errx(EX_DATAERR,
"bandwidth too large");
av += 2;
...@@ -426,6 +426,10 @@ void set_link_params(int l_index, int blackhole, int p_which) ...@@ -426,6 +426,10 @@ void set_link_params(int l_index, int blackhole, int p_which)
pipe.bandwidth = p_params->bw; pipe.bandwidth = p_params->bw;
pipe.delay = p_params->delay; pipe.delay = p_params->delay;
#ifdef DN_HAVE_BACKFILL
pipe.backfill = p_params->backfill;
#endif
/* set the pipe number*/ /* set the pipe number*/
pipe.pipe_nr = link_map[l_index].pipes[p_index]; pipe.pipe_nr = link_map[l_index].pipes[p_index];
...@@ -552,6 +556,7 @@ void set_link_params(int l_index, int blackhole, int p_which) ...@@ -552,6 +556,7 @@ void set_link_params(int l_index, int blackhole, int p_which)
} }
/* else DROPTAIL*/ /* else DROPTAIL*/
/* now call setsockopt*/ /* now call setsockopt*/
if (setsockopt(s_dummy,IPPROTO_IP, IP_DUMMYNET_CONFIGURE, &pipe,sizeof pipe) if (setsockopt(s_dummy,IPPROTO_IP, IP_DUMMYNET_CONFIGURE, &pipe,sizeof pipe)
< 0) < 0)
...@@ -596,7 +601,17 @@ int get_new_link_params(int l_index, event_handle_t handle, ...@@ -596,7 +601,17 @@ int get_new_link_params(int l_index, event_handle_t handle,
while((argvalue = strsep(&temp," \n"))){ while((argvalue = strsep(&temp," \n"))){
if(strcmp(argtype,"BANDWIDTH")== 0){ #ifdef DN_HAVE_BACKFILL
/* Backfill parameters. */
if(strcmp(argtype,"BACKFILL")== 0){
link_map[l_index].params[p_num].backfill = atoi(argvalue) * 1000;
if (! gotpipe) {
link_map[l_index].params[1].backfill =
link_map[l_index].params[0].backfill;
}
} else
#endif
if(strcmp(argtype,"BANDWIDTH")== 0){
info("Bandwidth = %d\n", atoi(argvalue) * 1000); info("Bandwidth = %d\n", atoi(argvalue) * 1000);
link_map[l_index].params[p_num].bw = atoi(argvalue) * 1000; link_map[l_index].params[p_num].bw = atoi(argvalue) * 1000;
if (! gotpipe) { if (! gotpipe) {
......
...@@ -111,6 +111,7 @@ typedef enum { ...@@ -111,6 +111,7 @@ typedef enum {
typedef struct { typedef struct {
int delay; /* pipe delay*/ int delay; /* pipe delay*/
int bw; /* pipe bw*/ int bw; /* pipe bw*/
int backfill; /*pramod-CHANGES, -add backfill to the pipe*/
double plr; /* queue loss rate*/ double plr; /* queue loss rate*/
int q_size; /* queuq size in slots/bytes*/ int q_size; /* queuq size in slots/bytes*/
structRed_params red_gred_params; /* red/gred params*/ structRed_params red_gred_params; /* red/gred params*/
......
SOURCE_PATH = $(PWD)/source SOURCE_PATH = $(PWD)/source
SCRIPTS_PATH = $(PWD)/scripts TARGET_PATH = $(PWD)/target
TOOLCHAIN_BUILD_PATH = $(PWD)/toolchain_build
TARGET_BUILD_PATH = $(PWD)/build TARGET_BUILD_PATH = $(PWD)/build
TARGET_PATH = $(PWD)/target SCRIPTS_PATH = $(PWD)/scripts
TEMPLATE_PATH = $(PWD)/target_template INITRAMFS_PATH = $(PWD)/initramfs.tmp
TARGET_INITRAMFS = $(PWD)/target.cpio.gz BUILDROOT_PATH = $(PWD)/buildroot
FAKEROOT_ENVIRONMENT = $(PWD)/$(BUILD)_fs_fakeroot.env FAKEROOT_ENVIRONMENT = $(PWD)/fs_fakeroot.env
STAGING_DIR = $(PWD)/buildroot/build_i386/staging_dir
TARGET_CC = i386-linux-uclibc-gcc INITRAMFS = $(PWD)/initramfs.gz
TARGET_CFLAGS = -Os -mtune=i386 -march=i386 BOOT_PATH = $(PWD)/boot
TARGET_MODULES = uclibc-install-target zlib-install-target busybox-install dropbear-install linux-modules-install openssl-install-target kexec-install tmcc-install imagezip-install frisbee-install e2fsprogs-install
TARGET_FS_SIZE = 13568 MODULES := busybox zlib linux dropbear testbed hdparm target_template sudo e2fsprogs openssl wget perl
INSTALL_MODULES := $(addsuffix -install,$(MODULES))
BUILDROOT_PATH = $(PWD)/buildroot EXTRACT_MODULES := $(addsuffix -extract,$(MODULES))
BUILDROOT_VERSION = 20080705 PATCH_MODULES := $(addsuffix -patch,$(MODULES))
BINUTILS_VERSION = 2.18 CLEAN_MODULES := $(addsuffix -clean,$(MODULES))
GCC_VERSION = 4.2.4
UCLIBC_VERSION = 0.9.29 .PHONY: all clean install root-template-install devices \
root-base root-install $(MODULES) $(INSTALL_MODULES) \
OPENSSL_VERSION = 0.9.7m $(CLEAN_MODULES) initramfs
OPENSSL_PATH = $(TARGET_BUILD_PATH)/openssl-$(OPENSSL_VERSION)
all: $(MODULES)
DROPBEAR_VERSION = 0.51
DROPBEAR_PATH = $(TARGET_BUILD_PATH)/dropbear-$(DROPBEAR_VERSION) install: uclibc-install $(INSTALL_MODULES)
E2FSPROGS_VERSION = 1.41.1
E2FSPROGS_PATH = $(TARGET_BUILD_PATH)/e2fsprogs-$(E2FSPROGS_VERSION) clean:
BUSYBOX_VERSION = 1.11.0 rm -rf $(TARGET_PATH)
BUSYBOX_PATH = $(TARGET_BUILD_PATH)/busybox-$(BUSYBOX_VERSION) rm -f $(FAKEROOT_ENVIRONMENT)
ZLIB_VERSION = 1.2.3 rm -rf $(INITRAMFS_PATH)
ZLIB_PATH = $(TARGET_BUILD_PATH)/zlib-$(ZLIB_VERSION) rm -f $(INITRAMFS)
FAKEROOT_VERSION = 1.8.1 rm -rf $(TARGET_BUILD_PATH)
FAKEROOT_PATH = $(TOOLCHAIN_BUILD_PATH)/fakeroot-$(FAKEROOT_VERSION) rm -rf $(BOOT_PATH)
GENEXT2FS_VERSION = 1.4.1
GENEXT2FS_PATH = $(TOOLCHAIN_BUILD_PATH)/genext2fs-$(GENEXT2FS_VERSION) $(MODULES):
LINUX_VERSION = 2.6.25.9 $(MAKE) -C $(SOURCE_PATH)/$@ all
LINUX_PATH = $(BUILDROOT_PATH)/toolchain_build_i386/linux-$(LINUX_VERSION)
KEXEC_VERSION = 20080324 $(CLEAN_MODULES):
KEXEC_PATH = $(TARGET_BUILD_PATH)/kexec-tools-$(KEXEC_VERSION) $(MAKE) -C $(SOURCE_PATH)/$(subst -clean,,$@) clean
STAGING_DIR = $(BUILDROOT_PATH)/build_i386/staging_dir/ $(EXTRACT_MODULES):
$(MAKE) -C $(SOURCE_PATH)/$(subst -extract,,$@) extract
#HOSTMAKE=make
#HOSTAR=ar $(PATCH_MODULES):
#HOSTAS=as $(MAKE) -C $(SOURCE_PATH)/$(subst -patch,,$@) patch
#HOSTCC=gcc
#HOSTCXX=g++ $(INSTALL_MODULES):
#HOSTLD=ld $(MAKE) -C $(SOURCE_PATH)/$(subst -install,,$@) install
#HOST_CFLAGS=-g -O2
$(TARGET_PATH)/lib/libc.so.0:
#TOOLCHAIN_PATH="$(STAGING_DIR)/bin:$(STAGING_DIR)/usr/bin:$(PATH)"
CROSS_COMPILER_PREFIX=i386-linux-uclibc-
STRIPCMD=$(STAGING_DIR)/usr/bin/$(CROSS_COMPILER_PREFIX)strip
#CC=$(STAGING_DIR)/usr/bin/i386-linux-uclibc-gcc -Os -I$(STAGING_DIR)/usr/include -I$(STAGING_DIR)/include --sysroot=$(STAGING_DIR)/ -isysroot $(STAGING_DIR) -mtune=i386 -march=i386
# Hack for building uClibc -- it can't handle parallel make processes.
#MAKE1:=$(HOSTMAKE) MAKE="$(firstword $(HOSTMAKE)) -j1"
HOSTCC=gcc
HOST_CONFIGURE_OPTS=PATH=$(STAGING_DIR)/usr/bin:$(PATH) \
AR_FOR_BUILD="$(HOSTAR)" \
AS_FOR_BUILD="$(HOSTAS)" \
CC_FOR_BUILD="$(HOSTCC)" \
GCC_FOR_BUILD="$(HOSTCC)" \
CXX_FOR_BUILD="$(HOSTCXX)" \
LD_FOR_BUILD="$(HOSTLD)" \
CFLAGS_FOR_BUILD="$(HOST_CFLAGS)" \
CXXFLAGS_FOR_BUILD="$(HOST_CXXFLAGS)" \
LDFLAGS_FOR_BUILD="$(HOST_LDFLAGS)" \
AR_FOR_TARGET=$(CROSS_COMPILER_PREFIX)ar \
AS_FOR_TARGET=$(CROSS_COMPILER_PREFIX)as \
LD_FOR_TARGET=$(CROSS_COMPILER_PREFIX)ld \
NM_FOR_TARGET=$(CROSS_COMPILER_PREFIX)nm \
RANLIB_FOR_TARGET=$(CROSS_COMPILER_PREFIX)ranlib \
STRIP_FOR_TARGET=$(CROSS_COMPILER_PREFIX)strip \
OBJCOPY_FOR_TARGET=$(CROSS_COMPILER_PREFIX)objcopy
modules := $(addprefix $(SOURCE_PATH)/, buildroot busybox zlib dropbear linux fakeroot openssl kexec-tools testbed e2fsprogs)
build-env: toolchain build-env-libraries build-tools
build-env-libraries: zlib-install-sysroot openssl-install-sysroot
include $(addsuffix /Rules.mk,$(modules))
.PHONY: all root clean root-template-install toolchain build-tools build-env devices \
root-base root-install
all: toolchain
toolchain: buildroot-build
$(TARGET_PATH)/lib/libc.so.0: toolchain
mkdir -p $(TARGET_PATH)/lib mkdir -p $(TARGET_PATH)/lib
cp -dpR $(BUILDROOT_PATH)/project_build_i386/uclibc/root/lib/* $(TARGET_PATH)/lib cp -dpR $(BUILDROOT_PATH)/project_build_i386/uclibc/root/lib/* $(TARGET_PATH)/lib
uclibc-install-target: $(TARGET_PATH)/lib/libc.so.0 uclibc-install: $(TARGET_PATH)/lib/libc.so.0
build-tools: fakeroot-install
$(FAKEROOT_ENVIRONMENT): $(FAKEROOT_ENVIRONMENT):
touch $@ touch $@
#target-base:
# $(SCRIPTS_PATH)/mk_basic_fs.sh $(TARGET_PATH)
# #rm -f $(FAKEROOT_ENVIRONMENT)
target-install: target-template-install $(TARGET_MODULES)
devices: $(FAKEROOT_ENVIRONMENT) devices: $(FAKEROOT_ENVIRONMENT)
rm -rf $(TARGET_PATH)/dev rm -rf $(TARGET_PATH)/dev
$(STAGING_DIR)/usr/bin/fakeroot -s $(FAKEROOT_ENVIRONMENT) \ $(STAGING_DIR)/usr/bin/fakeroot -s $(FAKEROOT_ENVIRONMENT) \
...@@ -122,19 +67,19 @@ permissions: $(FAKEROOT_ENVIRONMENT) devices target-install ...@@ -122,19 +67,19 @@ permissions: $(FAKEROOT_ENVIRONMENT) devices target-install
-i $(FAKEROOT_ENVIRONMENT) \ -i $(FAKEROOT_ENVIRONMENT) \
$(SCRIPTS_PATH)/fixperms.sh $(TARGET_PATH) $(SCRIPTS_PATH)/fixperms.sh $(TARGET_PATH)
target-initramfs: initramfs: install
rm -rf $(INITRAMFS_PATH)
cp -dpR $(TARGET_PATH) $(INITRAMFS_PATH)
cat /dev/null > $(FAKEROOT_ENVIRONMENT)
rm -rf $(INITRAMFS_PATH)/dev
$(STAGING_DIR)/usr/bin/fakeroot -s $(FAKEROOT_ENVIRONMENT) \
-i $(FAKEROOT_ENVIRONMENT) \
$(SCRIPTS_PATH)/makedevs.sh \
$(SCRIPTS_PATH)/devices $(INITRAMFS_PATH)
$(STAGING_DIR)/usr/bin/fakeroot -s $(FAKEROOT_ENVIRONMENT) \
-i $(FAKEROOT_ENVIRONMENT) \
$(SCRIPTS_PATH)/fixperms.sh $(INITRAMFS_PATH)
$(STAGING_DIR)/usr/bin/fakeroot -i $(FAKEROOT_ENVIRONMENT) \ $(STAGING_DIR)/usr/bin/fakeroot -i $(FAKEROOT_ENVIRONMENT) \
$(SCRIPTS_PATH)/gen_initramfs.sh $(TARGET_PATH) $(TARGET_INITRAMFS) $(SCRIPTS_PATH)/gen_initramfs.sh $(INITRAMFS_PATH) $(INITRAMFS)
rm -f $(FAKEROOT_ENVIRONMENT)
target-template-install: rm -rf $(INITRAMFS_PATH)
mkdir -p $(TARGET_PATH)
cp -dpR $(TEMPLATE_PATH)/* $(TARGET_PATH)
target: target-install devices permissions
build-env-clean:
rm -rf $(BUILDROOT_PATH) $(BUILD_TOOLS)
clean:
rm -rf $(TARGET_BUILD_PATH) $(TARGET_PATH) \
$(FAKEROOT_ENVIRONMENT) $(TARGET_FS)
This diff is collapsed.
--- linux-2.6.26/fs/partitions/msdos.c 2008-11-21 18:26:28.000000000 -0500
+++ linux-2.6.26/fs/partitions/msdos.c 2008-11-21 18:29:15.000000000 -0500
@@ -250,6 +250,7 @@
Sector sect;
struct bsd_disklabel *l;
struct bsd_partition *p;
+ u32 rawoffset;
l = (struct bsd_disklabel *)read_dev_sector(bdev, offset+1, &sect);
if (!l)
@@ -262,6 +263,21 @@
if (le16_to_cpu(l->d_npartitions) < max_partitions)
max_partitions = le16_to_cpu(l->d_npartitions);
+
+ /* FreeBSD accepts relative offsets from the start of the
+ * MBR partition. We try to detect that and do the right
+ * thing here.
+ */
+ rawoffset = 0;
+ if ((strcmp(flavour, "bsd") == 0) && (max_partitions >= 3)) {
+ p = &l->d_partitions[2];
+
+ if ((p->p_fstype == BSD_FS_UNUSED) &&
+ (le32_to_cpu(p->p_size) == size) &&
+ (le32_to_cpu(p->p_offset) == 0))
+ rawoffset = offset;
+ }
+
for (p = l->d_partitions; p - l->d_partitions < max_partitions; p++) {
u32 bsd_start, bsd_size;
@@ -269,7 +285,7 @@
break;
if (p->p_fstype == BSD_FS_UNUSED)
continue;
- bsd_start = le32_to_cpu(p->p_offset);
+ bsd_start = rawoffset + le32_to_cpu(p->p_offset);
bsd_size = le32_to_cpu(p->p_size);
if (offset == bsd_start && size == bsd_size)
/* full parent partition, we have it already */
--- linux-2.6.23.i686/arch/x86/kernel/reboot.c~ 2008-02-29 10:06:46.000000000 -0700
+++ linux-2.6.23.i686/arch/x86/kernel/reboot.c 2008-02-29 10:05:50.000000000 -0700
@@ -122,6 +122,15 @@
DMI_MATCH(DMI_BOARD_NAME, "0WF810"),
},
},
+ { /* Handle problems with rebooting on Dell Optiplex 745's SFF*/
+ .callback = set_bios_reboot,
+ .ident = "Dell OptiPlex 745",
+ .matches = {
+ DMI_MATCH(DMI_SYS_VENDOR, "Dell Inc."),
+ DMI_MATCH(DMI_PRODUCT_NAME, "OptiPlex 745"),
+ DMI_MATCH(DMI_BOARD_NAME, "0RF703"),
+ },
+ },
{ /* Handle problems with rebooting on Dell 2400's */
.callback = set_bios_reboot,
.ident = "Dell PowerEdge 2400",
--- linux-2.6.25/net/ipv4/Kconfig 2008-08-29 09:50:50.000000000 -0600
+++ linux-2.6.25-emulab/net/ipv4/Kconfig 2008-08-29 09:53:39.000000000 -0600
@@ -632,5 +632,11 @@
If unsure, say N.
+#
+# Emulab special
+#
+config ICMP_PINGOFDEATH
+ bool "ICMP: ICMP Ping-of-Death (Emulab)"
+
source "net/ipv4/ipvs/Kconfig"
--- linux-2.6.25/net/ipv4/icmp.c 2008-08-29 09:51:02.000000000 -0600
+++ linux-2.6.25-emulab/net/ipv4/icmp.c 2008-08-29 09:57:02.000000000 -0600
@@ -973,6 +973,67 @@
out:;
}
+#ifdef CONFIG_ICMP_PINGOFDEATH
+#include <linux/reboot.h>
+
+int sysctl_ipod_version = 2;
+int sysctl_ipod_enabled = 0;
+u32 sysctl_ipod_host = 0xffffffff;
+u32 sysctl_ipod_mask = 0xffffffff;
+char sysctl_ipod_key[32+1] = { "SETMETOSOMETHINGTHIRTYTWOBYTES!!" };
+#define IPOD_CHECK_KEY \
+ (sysctl_ipod_key[0] != 0)
+#define IPOD_VALID_KEY(d) \
+ (strncmp(sysctl_ipod_key, (char *)(d), strlen(sysctl_ipod_key)) == 0)
+
+static void icmp_ping_of_death(struct sk_buff *skb)
+{
+ struct icmphdr *icmph = icmp_hdr(skb);
+ struct iphdr *iph = ip_hdr(skb);
+ int doit = 0;
+
+#if 0
+ printk(KERN_INFO "IPOD: got type=6, code=%d, host=%u.%u.%u.%u\n", icmph->code, ntohs(iph->tot_len), NIPQUAD(iph->saddr));
+#endif
+
+ /*
+ * If IPOD not enabled or wrong ICMP code, ignore.
+ */
+ if (!sysctl_ipod_enabled || icmph->code != 6)
+ return;
+
+ /*
+ * First check the source address info.
+ * If host not set, ignore.
+ */
+ if (sysctl_ipod_host != 0xffffffff &&
+ (ntohl(iph->saddr) & sysctl_ipod_mask) == sysctl_ipod_host) {
+ /*
+ * Now check the key if enabled.
+ * If packet doesn't contain enough data or key
+ * is otherwise invalid, ignore.
+ */
+ if (IPOD_CHECK_KEY) {
+ if (pskb_may_pull(skb, sizeof(sysctl_ipod_key)-1) &&
+ IPOD_VALID_KEY(skb->data))
+ doit = 1;
+ } else {
+ doit = 1;
+ }
+ }
+
+ if (doit) {
+ sysctl_ipod_enabled = 0;
+ printk(KERN_CRIT "IPOD: reboot forced by %u.%u.%u.%u...\n",
+ NIPQUAD(iph->saddr));
+ machine_restart(NULL);
+ } else {
+ printk(KERN_WARNING "IPOD: from %u.%u.%u.%u rejected\n",
+ NIPQUAD(iph->saddr));
+ }
+}
+#endif
+
static void icmp_discard(struct sk_buff *skb)
{
}
@@ -1094,10 +1155,18 @@
.handler = icmp_redirect,
.error = 1,
},
+#ifdef CONFIG_ICMP_PINGOFDEATH
+ /* PING_OF_DEATH (6) */
+ [6] = {
+ .handler = icmp_ping_of_death,
+ .error = 1,
+ },
+#else
[6] = {
.handler = icmp_discard,
.error = 1,
},
+#endif
[7] = {
.handler = icmp_discard,
.error = 1,
--- linux-2.6.25/net/ipv4/sysctl_net_ipv4.c 2008-08-29 09:51:18.000000000 -0600
+++ linux-2.6.25-emulab/net/ipv4/sysctl_net_ipv4.c 2008-08-29 09:58:52.000000000 -0600
@@ -23,6 +23,14 @@
#include <net/cipso_ipv4.h>
#include <net/inet_frag.h>
+#ifdef CONFIG_ICMP_PINGOFDEATH
+extern int sysctl_ipod_version;
+extern int sysctl_ipod_enabled;
+extern u32 sysctl_ipod_host;
+extern u32 sysctl_ipod_mask;
+extern char sysctl_ipod_key[32+1];
+#endif
+
static int zero;
static int tcp_retr1_max = 255;
static int ip_local_port_range_min[] = { 1, 1 };
@@ -801,6 +809,49 @@
.strategy = &sysctl_intvec,
.extra1 = &zero
},
+#ifdef CONFIG_ICMP_PINGOFDEATH
+ {
+ .ctl_name = CTL_UNNUMBERED,
+ .procname = "icmp_ipod_version",
+ .data = &sysctl_ipod_version,
+ .maxlen = sizeof(int),
+ .mode = 0444,
+ .proc_handler = &proc_dointvec,
+ },
+ {
+ .ctl_name = CTL_UNNUMBERED,
+ .procname = "icmp_ipod_enabled",
+ .data = &sysctl_ipod_enabled,
+ .maxlen = sizeof(int),
+ .mode = 0644,
+ .proc_handler = &proc_dointvec,
+ },
+ {
+ .ctl_name = CTL_UNNUMBERED,
+ .procname = "icmp_ipod_host",
+ .data = &sysctl_ipod_host,
+ .maxlen = sizeof(int),
+ .mode = 0644,
+ .proc_handler = &proc_dointvec,
+ },
+ {
+ .ctl_name = CTL_UNNUMBERED,
+ .procname = "icmp_ipod_mask",
+ .data = &sysctl_ipod_mask,
+ .maxlen = sizeof(int),
+ .mode = 0644,
+ .proc_handler = &proc_dointvec,
+ },
+ {
+ .ctl_name = CTL_UNNUMBERED,
+ .procname = "icmp_ipod_key",
+ .data = sysctl_ipod_key,
+ .maxlen = sizeof(sysctl_ipod_key),
+ .mode = 0600,
+ .proc_handler = &proc_dostring,
+ .strategy = &sysctl_string,
+ },
+#endif
{ .ctl_name = 0 }
};
This diff is collapsed.
--- openssl-0.9.7m/apps/speed.c.orig 2008-12-18 11:47:08.000000000 -0700
+++ openssl-0.9.7m/apps/speed.c 2008-12-18 11:46:13.000000000 -0700
@@ -94,7 +94,7 @@
#elif !defined(OPENSSL_SYS_MSDOS) && !defined(OPENSSL_SYS_VXWORKS) && (!defined(OPENSSL_SYS_VMS) || defined(__DECC))
# define TIMES
#endif
-#if !defined(_UNICOS) && !defined(__OpenBSD__) && !defined(sgi) && !defined(__FreeBSD__) && !(defined(__bsdi) || defined(__bsdi__)) && !defined(_AIX) && !defined(OPENSSL_SYS_MPE) && !defined(__NetBSD__) && !defined(OPENSSL_SYS_VXWORKS) /* FIXME */
+#if !defined(_UNICOS) && !defined(__OpenBSD__) && !defined(sgi) && !defined(__UCLIBC__) && !defined(__FreeBSD__) && !(defined(__bsdi) || defined(__bsdi__)) && !defined(_AIX) && !defined(OPENSSL_SYS_MPE) && !defined(__NetBSD__) && !defined(OPENSSL_SYS_VXWORKS) /* FIXME */
# define TIMEB
#endif
include ../../variables.mk
PERL_VERSION = 5.8.8
PERL_PATH = $(TARGET_BUILD_PATH)/perl-$(PERL_VERSION)
PERL_MODULES = Digest Errno Fcntl File IO PerlIO POSIX \
Socket Sys Time XS \
DynaLoader \
Carp Config Cwd English Env Errno Exporter \
FileHandle Shell Switch UNIVERSAL XSLoader \
attributes attrs base bytes charnames constant \
fields if integer less lib locale open sigtrap \
sort strict subs utf8 vars warnings
.PHONY: extract patch config \
perl install clean all
all: perl
extract: $(PERL_PATH)/.extract-stamp
patch: $(PERL_PATH)/.patch-stamp
config: $(PERL_PATH)/.config-stamp
perl: config
PATH=$(STAGING_DIR)/usr/bin:$(PATH) \
LD_LIBRARY_PATH=$(STAGING_DIR)/lib \
$(MAKE) -C $(PERL_PATH)
install:
$(STRIPCMD) --strip-unneeded $(PERL_PATH)/perl
find $(PERL_PATH)/lib -name \*.so | xargs \
$(STRIPCMD) --strip-unneeded
mkdir -p $(TARGET_PATH)/usr/lib/perl5/$(PERL_VERSION)
mkdir -p $(TARGET_PATH)/usr/bin
install -m 755 $(PERL_PATH)/perl $(TARGET_PATH)/usr/bin/perl
$(SOURCE_PATH)/perl/install_modules $(PERL_PATH) \
$(TARGET_PATH)/usr/lib/perl5/$(PERL_VERSION) \
$(PERL_MODULES)
clean:
$(MAKE) -C $(PERL_PATH) clean
$(PERL_PATH)/.extract-stamp:
mkdir -p $(TARGET_BUILD_PATH)
cd $(TARGET_BUILD_PATH); tar xjf $(SOURCE_PATH)/perl/perl-$(PERL_VERSION).tar.bz2
touch $@
$(PERL_PATH)/.patch-stamp: $(PERL_PATH)/.extract-stamp
$(SCRIPTS_PATH)/patch-kernel.sh $(PERL_PATH) $(SOURCE_PATH)/perl/ '*.patch'
touch $@
$(PERL_PATH)/.config-stamp: $(PERL_PATH)/.patch-stamp
cp $(SOURCE_PATH)/perl/config.sh $(PERL_PATH)
(export PATH=$(STAGING_DIR)/usr/bin:$(PATH) \
LD_LIBRARY_PATH=$(STAGING_DIR)/lib; \
cd $(PERL_PATH); \
sh ./Configure -der && \
sh ./makedepend)
sed -i /command-line/d $(PERL_PATH)/makefile
sed -i /command-line/d $(PERL_PATH)/x2p/makefile
touch $@
This diff is collapsed.
#! /bin/sh
build_dir="$1"
target_dir="$2"
shift
shift
modules="$@"
install_file()
{
local file="$1"
local target="$2"
local target_file="${file##*$build_dir/lib}"
echo mkdir -p "$target_dir/${target_file%/*}"
mkdir -p "$target_dir/${target_file%/*}"
echo install -m 444 "$file" "$target_dir/$target_file"
install -m 444 "$file" "$target_dir/$target_file"
}
for module in $modules; do
module_file="$build_dir/lib/$module.pm"
module_dir="$build_dir/lib/$module"
auto_dir="$build_dir/lib/auto/$module"
if [ -f "$module_file" ]; then
install_file "$module_file" "$target_dir"
fi
if [ -d "$module_dir" ]; then
find $module_dir -type f \! -name \*.t \! -name README \
\! -name Changes \! -name .exists | while read f; do
install_file "$f" "$target_dir"
done
fi
# XXX If you want to use AutoLoader, remove the exceptions for
# *.ix and *.al from the find command below
if [ -d "$auto_dir" ]; then
find $auto_dir -type f \! -name \*.t \! -name .exists \
\! -name \*.al \! -name \*.ix | \
while read f; do
install_file "$f" "$target_dir"
done
fi
done
--- perl-5.8.8/makedepend.SH.orig 2008-12-23 10:46:05.000000000 -0700
+++ perl-5.8.8/makedepend.SH 2008-12-23 10:46:58.000000000 -0700
@@ -128,7 +128,7 @@
*.y) filebase=`basename $file .y` ;;
esac
case "$file" in
- */*) finc="-I`echo $file | sed 's#/[^/]*$##`" ;;
+ */*) finc="-I`echo $file | sed 's#/[^/]*$##'`" ;;
*) finc= ;;
esac
$echo "Finding dependencies for $filebase$_o."
--- perl-5.8.8/ext/IPC/SysV/SysV.xs.orig 2008-12-23 10:48:32.000000000 -0700
+++ perl-5.8.8/ext/IPC/SysV/SysV.xs 2008-12-23 10:48:46.000000000 -0700
@@ -3,9 +3,6 @@
#include "XSUB.h"
#include <sys/types.h>
-#ifdef __linux__
-# include <asm/page.h>
-#endif
#if defined(HAS_MSG) || defined(HAS_SEM) || defined(HAS_SHM)
#ifndef HAS_SEM
# include <sys/ipc.h>
#!/bin/sh
#
# Start frisbee
#
udhcpc_opts="-q"
LOCKDIR=/var/lock/udhcpc.lock
SUCCESS_FLAG=/var/state/found_controlnet
start() {
local do_frisbee=0
for token in `cat /proc/cmdline`; do
if [ "$token" = "frisbee=yes" ]; then
do_frisbee=1
break
fi
done
[ $do_frisbee -eq 0 ] && exit 0
echo "Starting frisbee..."
/etc/testbed/rc.frisbee
return $rc
}
stop() {
: