ipsec: allow registering random ports in tests