ich hab mir vor längerem zwei url_redirector/url_rewriter für squid programmiert.
Der neuer macht komische Probleme, also hab ich mir ein mini Python Script geschrieben um heraus zu finden warum dieser solche Probleme macht bzw. was Squid eigentlich so weiter sendet.
Code: Alles auswählen
#! /usr/bin/env python
# -*- coding: utf-8 -*-
import sys
sys.stderr = open("/tmp/squid.stderr","a")
output_file = open("/tmp/squid.test", "a")
while True:
line = sys.stdin.readline().strip()
output_file.write("FROM SQUID: " + line + "\n")
tmp = line.split(' ')
if len(tmp) < 2:
continue
sys.stdout.write(tmp[0] + " \n")
sys.stdout.flush()
output_file.close()
Code: Alles auswählen
FROM SQUID:
FROM SQUID:
FROM SQUID:
FROM SQUID:
FROM SQUID:
FROM SQUID:
FROM SQUID:
FROM SQUID:
FROM SQUID:
FROM SQUID:
FROM SQUID:
FROM SQUID:
FROM SQUID:
FROM SQUID:
FROM SQUID:
FROM SQUID:
FROM SQUID:
FROM SQUID:
FROM SQUID:
FROM SQUID:
FROM SQUID:
FROM SQUID:
lg Richi