Open rc5hack opened 9 months ago
Just in case, that shell script does not fix the issue, but helps to still run slrp by picking up the interface with default route:
#!/bin/sh
_term() {
echo "Caught SIGTERM signal!"
kill -TERM "$child" 2>/dev/null
}
default_iface=$(awk '$2 == 00000000 { print $1 }' /proc/net/route)
listen_ip=$(ip addr show dev "$default_iface" | awk '$1 == "inet" { sub("/.*", "", $2); print $2 }')
echo "Chose IP: ${listen_ip}"
SLRP_MITM_ADDR="${listen_ip}:${MITM_PORT}" SLRP_SERVER_ADDR="${listen_ip}:${SERVER_PORT}" ./slrp
child=$!
wait "$child"
@tired-engineer Could you try to make a PR to go code?
@nfx, I'll try, probably next week.
Sorry for the delay. I am failing to even simply build the project after just checking out the code, some dependency mess, so I'll pass.
@tired-engineer where's dependency mess? Go or JavaScript?
Heya! I think its the golang I'm getting this:
go build -ldflags "-s -w" main.go
package command-line-arguments
imports github.com/nfx/slrp/dialer
imports golang.zx2c4.com/wireguard/tun/netstack
imports gvisor.dev/gvisor/pkg/bufferv2
imports gvisor.dev/gvisor/pkg/atomicbitops
imports gvisor.dev/gvisor/pkg/cpuid
imports gvisor.dev/gvisor/pkg/state
imports gvisor.dev/gvisor/pkg/state/wire
imports gvisor.dev/gvisor/pkg/gohacks: build constraints exclude all Go files in /workspaces/slrp/vendor/gvisor.dev/gvisor/pkg/gohacks
make: *** [Makefile:21: build] Error 1
Heya, I think I've managed to fix this in #191 (see this change https://github.com/nfx/slrp/pull/191/files#diff-0044895293462530ca67e310abd6815b9e0570f2bd192dd3cecd51f899df2d79R253)
Seems like some ipv6/ipv4 backward compatibility problem: