well, for once, i'm against paranoia. unless your rpyc servers are open to the internet, i don't see why you would want to go filtering specific ips -- either you trust your network, i.e., behind a DMZ/FW, etc., or you don't. then again, if your place uses NFS (which authenticates based on the client's uid) or windows, chances are you're compromised already :)
anyway, that's none of my business, so here's a sketch:
def ip_authenticator(sock):
ip, port = sock.getpeername()
if ip not in allowed_ips:
raise AuthenticationError()
return sock
you'll need to chain it with the VDB authenticator, but that's trivial.
hope it helps,
-tomer
An NCO and a Gentleman