Advertisement
Guest User

Untitled

a guest
Jul 6th, 2015
229
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.83 KB | None | 0 0
  1. Get the following data from the poll keys
  2. Time difference load-0 key and last poll key
  3.  
  4. Get the following data out of each UID
  5. URL
  6. If connection was HTTP or HTTPS
  7. IP
  8. Plugins
  9.  
  10. ka=list()
  11. dta=list()
  12. a=False
  13. d = open("redisOutput.txt", "r+")
  14. c= open("HashKeys.txt", 'w')
  15. for line in d.readlines():
  16. if "|" in line:
  17. uid=line.split
  18. h4sh=line[:26]
  19. string=line[line.find(h4sh[1])-1:line.find("|")]
  20. url=partFinder(line, 1, 2)
  21. ip=partFinder(line, 2, 3)
  22. pl=partFinder(line, 19, 20)
  23.  
  24. c.write(string+Q+ip+Q+url+Q+pl+'n')
  25. '''
  26. if "https" in line:
  27. #a=True
  28. if a==True:
  29. #print("Https")
  30. if a==False:
  31. #print("Http")
  32. '''
  33.  
  34. f=open("redisOutput.txt", "r+")
  35. for line in f.readlines():
  36. if "|" in line:
  37. uid=line.split
  38. h4sh=line[:26]
  39. dta.append(h4sh)
  40. string=line[line.find(h4sh[1])-1:line.find("|")]
  41. ka.append(string)
  42. key=line[line.find(line[26])+1:line.find("|")]
  43. f.close()
  44.  
  45.  
  46.  
  47. dictionary = {}
  48. for h4sh in dta:
  49. f=open("redisOutput.txt", "r+")
  50. keys = []
  51. for line in f.readlines():
  52. if h4sh in line:
  53. string=line[line.find(h4sh[1])-1:line.find("|")]
  54. print h4sh
  55. eb=partFinder(line, 1, 31)
  56. keys.append(string + "|"+ eb)
  57.  
  58. dictionary[h4sh] = keys
  59. f.close()
  60. print dictionary[h4sh]
  61.  
  62.  
  63. for h4sh in dta:
  64. nop=line[line.find(line[30])+1:line.find("|")]
  65. loadkey=""
  66. loadtime = ""
  67. highestpoll=""
  68. pollnum = 0
  69. for key in dictionary[h4sh]:
  70. if "load-0" in key:
  71. loadtime = partFinder(line, 0, 1)
  72. if "poll" in key:
  73. keynum = nop
  74. if keynum > pollnum:
  75. highestpoll = key
  76. pollnum = keynum
  77. #print(loadkey,highestpoll)
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement