-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
- Loading branch information
There are no files selected for viewing
Large diffs are not rendered by default.
Large diffs are not rendered by default.
Large diffs are not rendered by default.
Large diffs are not rendered by default.
Large diffs are not rendered by default.
Large diffs are not rendered by default.
Large diffs are not rendered by default.
Large diffs are not rendered by default.
Large diffs are not rendered by default.
Large diffs are not rendered by default.
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
#!/bin/bash | ||
|
||
LD_PRELOAD=/home/tcp_nanqinlang/tcp_nanqinlang.so LKL_HIJACK_NET_QDISC="root|fq" LKL_HIJACK_SYSCTL="net.ipv4.tcp_congestion_control=nanqinlang;net.ipv4.tcp_fastopen=3;net.ipv4.tcp_wmem=4096 87380 2147483647" LKL_HIJACK_OFFLOAD="0x9983" LKL_HIJACK_NET_IFTYPE=tap LKL_HIJACK_NET_IFPARAMS=lkl-tap LKL_HIJACK_NET_IP=10.0.0.2 LKL_HIJACK_NET_NETMASK_LEN=24 LKL_HIJACK_NET_GATEWAY=10.0.0.1 haproxy -f /home/tcp_nanqinlang/haproxy.cfg |
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,8 @@ | ||
#!/bin/bash | ||
|
||
ip tuntap add lkl-tap mode tap | ||
ip addr add 10.0.0.1/24 dev lkl-tap | ||
ip link set lkl-tap up | ||
sysctl -w net.ipv4.ip_forward=1 | ||
iptables -P FORWARD ACCEPT | ||
iptables -t nat -A POSTROUTING -o venet0 -j MASQUERADE |
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
#!/bin/bash | ||
cd /home/tcp_nanqinlang | ||
nohup bash load.sh & | ||
bash redirect.sh |
Large diffs are not rendered by default.
Large diffs are not rendered by default.
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,15 @@ | ||
obj-m := tcp_nanqinlang.o | ||
|
||
all: | ||
make -C /lib/modules/`uname -r`/build M=`pwd` modules CC=/usr/bin/gcc | ||
|
||
clean: | ||
make -C /lib/modules/`uname -r`/build M=`pwd` clean | ||
|
||
install: | ||
install tcp_nanqinlang.ko /lib/modules/`uname -r`/kernel/net/ipv4 | ||
insmod /lib/modules/`uname -r`/kernel/net/ipv4/tcp_nanqinlang.ko | ||
depmod -a | ||
|
||
uninstall: | ||
rm /lib/modules/`uname -r`/kernel/net/ipv4/tcp_nanqinlang.ko |
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,15 @@ | ||
obj-m := tcp_nanqinlang.o | ||
|
||
all: | ||
make -C /lib/modules/`uname -r`/build M=`pwd` modules CC=/usr/bin/gcc-4.9 | ||
|
||
clean: | ||
make -C /lib/modules/`uname -r`/build M=`pwd` clean | ||
|
||
install: | ||
install tcp_nanqinlang.ko /lib/modules/`uname -r`/kernel/net/ipv4 | ||
insmod /lib/modules/`uname -r`/kernel/net/ipv4/tcp_nanqinlang.ko | ||
depmod -a | ||
|
||
uninstall: | ||
rm /lib/modules/`uname -r`/kernel/net/ipv4/tcp_nanqinlang.ko |
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,15 @@ | ||
obj-m := tcp_nanqinlang.o | ||
|
||
all: | ||
make -C /lib/modules/`uname -r`/build M=`pwd` modules CC=/usr/bin/gcc-6 | ||
|
||
clean: | ||
make -C /lib/modules/`uname -r`/build M=`pwd` clean | ||
|
||
install: | ||
install tcp_nanqinlang.ko /lib/modules/`uname -r`/kernel/net/ipv4 | ||
insmod /lib/modules/`uname -r`/kernel/net/ipv4/tcp_nanqinlang.ko | ||
depmod -a | ||
|
||
uninstall: | ||
rm /lib/modules/`uname -r`/kernel/net/ipv4/tcp_nanqinlang.ko |