#!/bin/bash
#
# This script is OBSOLETE -- rgb, May 6th, 1998

insmod ipsec.o
tncfg attach ipsec0 eth2
ifconfig ipsec0 10.2.0.143 up netmask 255.255.0.0
route add -net 10.3.0.0 netmask 255.255.0.0 dev ipsec0 gw 10.2.0.139

# forward path

../utils/addrt 10.1.0.0 255.255.0.0 10.3.0.0 255.255.0.0 10.2.0.139 103
echo sleeping after addrt
sleep 1

../utils/setsa 10.2.0.139 103 ip4 10.2.0.143 10.2.0.139
# ../utils/setsa 10.2.0.139 105 esp des-cbc 66306630 6630663066303132
# ../utils/setsa 10.2.0.139 106 ah md5 66306630663031326630663066303132

# ../utils/spigrp 10.2.0.139 103 10.2.0.139 105 10.2.0.139 106

# return path

# ../utils/setsa 10.2.0.143 115 esp des-cbc 66306630 6630663066303132
# ../utils/setsa 10.2.0.143 116 ah md5 66306630663031326630663066303132

