Sziasztok! Van egy ilyen class-unk: class HttpPublicDirector(PublicHttpProxyBase): def config(self): PublicHttpProxyBase.config(self) def filterURL(self, method, url, version): # little http filter if (url.count("http") > 1): log('http.info', 3, "Public http access denied (worm activity?): %s: %s" % (method, url)) return HTTP_REQ_ABORT if self.request_url_host == 'www.xyz.hu': self.session.setServer(SockAddrInet('192.168.168.25', 0)) elif self.request_url_host == 'test.xyz.hu': self.session.setServer(SockAddrInet('192.168.168.26', 0)) elif self.request_url_host == 'intranet.xyz.hu': self.session.setServer(SockAddrInet('192.168.168.27', 0)) else: log('http.info', 3, "Public http access denied: %s: %s" % (method, url)) return HTTP_REQ_ABORT log('http.info', 3, "%s: %s" % (method, url)) return HTTP_REQ_ACCEPT def filterError(self, method, url, version, response): self.error_status = 404 self.error_msg = 'not found' return HTTP_RSP_DENY def __destroy__(self): log(self.session.session_id, CORE_DEBUG, 3, "Accounting data: client_address='%s', server_address='%s', client_stream_recvd='%s', client_strea m_sent='%s'", (self.session.client_address, self.session.server_address, self.session.client_stream.bytes_recvd,self.session.client_stream.bytes_sent)) PublicHttpProxyBase.__destroy__(self) Van egy olyan igény, hogy az intranet.xyz.hu-ra az internet irányából csak egy-két tartományból lehessen hozzáférni. Tudom, hogy nem elegáns megoldás, de van arra lehetőség a python-nál, hogy itt a class-on belül hasonlítsam össze a kliens IP-jét egy tartománnyal? Létezik ilyen függvény? A válaszokat előre is köszönöm. Üdvözlettel: Csányi Krisztián