Monday, June 16, 2014

Compare 2 Lists of IP Addresses

Created this python script to look for an IP Address in one list and find it in a reputation IP list.

#!/usr/bin/python

import os


with open("tempIP.list", "r") as f1:
        lines1 = f1.readlines()

with open("reputation.list", "r") as f2:
        lines2 = f2.readlines()

for line in lines1:
        for item in lines2:
                if line.strip('\n') in item.strip('\n'):
                        print item

No comments:

Post a Comment

Powershell - Gather Mapped Drives from a List of Computer Names

I created the following Powershell script to gather remotely the mapped drives that users had in their profiles.  I had to create the script...