def METHOD_NAME(self, address, protocol):
    """
    Check whether we agree to relay.
    The default is to relay for all connections over UNIX
    sockets and all connections from localhost.
    """
    peer = protocol.transport.getPeer()
    return self.authed or isinstance(peer, UNIXAddress) or peer.host == "127.0.0.1"