forward or forwarded

This commit is contained in:
bashrc committed 2021-06-09 17:35:22 +01:00
1 parent bb3847481f
commit ec61f16d2e
1 file changed
+2
+2
View File
@@ -1441,6 +1441,8 @@ class PubServer(BaseHTTPRequestHandler):
createBasicAuthHeader(loginNickname, loginPassword)
if self.headers.get('X-Forward-For'):
ipAddress = self.headers['X-Forward-For']
elif self.headers.get('X-Forwarded-For'):
ipAddress = self.headers['X-Forwarded-For']
else:
ipAddress = self.client_address[0]
if not domain.endswith('.onion'):