00001 # Copyright (C) 2008-2009 Mark Hanegraaff 00002 # 00003 # This program is free software: you can redistribute it and/or modify 00004 # it under the terms of the GNU General Public License as published by 00005 # the Free Software Foundation, either version 3 of the License, or 00006 # (at your option) any later version. 00007 # 00008 # This program is distributed in the hope that it will be useful, 00009 # but WITHOUT ANY WARRANTY; without even the implied warranty of 00010 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 00011 # GNU General Public License for more details. 00012 # 00013 # You should have received a copy of the GNU General Public License 00014 # along with this program. If not, see <http://www.gnu.org/licenses/>. 00015 00016 00017 00018 00019 00020 ## The filter dictionary contains all items from a networkEntity which are filterable. 00021 # The class is essentially a lookup object containing a list of tuples in the 00022 # following format: 00023 00024 # dict["UserFriendlyName"] ("networkEntityAttribName", "TypeString"). 00025 # I.e. 00026 # 00027 # ("Application Name", "procName"). 00028 ## ("Port Number", "foreignPortNumber"). 00029 00030 class filterDictionary(): 00031 def __init__(self): 00032 self.filter = dict() 00033 00034 # dictionary of filterable items 00035 self.filter["IP Address"] = ("foreignIPAddress", "S") 00036 self.filter["Port"] = ("foreignPort", "D") 00037 self.filter["Process Name"] = ("processName", "S") 00038 self.filter["Process ID"] = ("Pid", "D") 00039 self.filter["City"] = ("foreignCity", "S") 00040 self.filter["State/Prov"] = ("foreignStateProv", "S") 00041 self.filter["Country"] = ("foreignCountry", "S") 00042 self.filter["Organization"] = ("foreignOrganization", "S") 00043 self.filter["ISP"] = ("foreignISP", "S") 00044 00045
1.5.8