Guest User

Untitled

a guest
Feb 19th, 2018
71
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.15 KB | None | 0 0
  1. file_1=open("lolz.txt","r")
  2. file_2=open("lolz2.txt","r")
  3. a = file_1.readlines()
  4. b = file_2.readlines()
  5. date=[]
  6. ipss=[]
  7. post=[]
  8. date2=[]
  9. kind=[]
  10. ipss2=[]
  11. con=[]
  12. erorr=[]
  13. for i in a:
  14. i = i.split(" - - ")
  15. for x in i:
  16. x = x.split("/")
  17. ipss.append(x[0].strip("[07"))
  18. i = i[1].split(' ')
  19. date.append(i[0].strip("[]-0800"))
  20. for line in a:
  21. q = (line[47::])
  22. post.append(q.strip("GET"" ""n"))
  23. for lins in b:
  24. t = (lins[0:26])
  25. y = (lins[26:34])
  26. u = (lins[34:56])
  27. p = (lins[56:140])
  28. date2.append(t.strip("[ ]"))
  29. kind.append(y.strip("[ ]"))
  30. ipss2.append(u.strip("[ ] ( )"))
  31. con.append(p.strip("n - -- ( ) [ ]"))
  32. for poop in b:
  33. if len(poop) < 138 or len(poop) > 138:
  34. erorr.append(poop.strip("n - [ ] ( )"))
  35.  
  36. [Sun Mar 7 20:58:27 2004] [info] [client 64.242.88.10] (104)Connection reset by peer: client stopped connection before send body completed
  37. [Sun Mar 7 21:16:17 2004] [error] [client 24.70.56.49] File does not exist: /home/httpd/twiki/view/Main/WebHome
  38. [Sun Mar 7 21:20:14 2004] [info] [client 64.242.88.10] (104)Connection reset by peer: client stopped connection before send body completed
Add Comment
Please, Sign In to add comment