Skip to content

Commit

Permalink
Rename --mibpaths to more adequate --mibcache
Browse files Browse the repository at this point in the history
  • Loading branch information
srenfo committed Jun 18, 2020
1 parent be6d1aa commit bb118d9
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 5 deletions.
4 changes: 2 additions & 2 deletions bin/conpot
Original file line number Diff line number Diff line change
Expand Up @@ -163,8 +163,8 @@ def main():
help="The logfile to use",
default="conpot.log"
)
parser.add_argument("-m", "--mibpaths",
help="Path to compiled PySNMP MIB files."
parser.add_argument("-m", "--mibcache",
help="Cache directory for compiled PySNMP MIB files"
)
parser.add_argument("--temp_dir",
help="Directory where all conpot vfs related files would be kept.",
Expand Down
2 changes: 1 addition & 1 deletion conpot/protocols/snmp/snmp_server.py
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@ def __init__(self, template, template_directory, args):
self.dom = etree.parse(template)
self.cmd_responder = None

self.compiled_mibs = args.mibpaths
self.compiled_mibs = args.mibcache
self.raw_mibs = os.path.join(template_directory, 'snmp', 'mibs')

def xml_general_config(self, dom):
Expand Down
4 changes: 2 additions & 2 deletions conpot/tests/test_snmp_server.py
Original file line number Diff line number Diff line change
Expand Up @@ -40,8 +40,8 @@ def setUp(self):
# get the current directory
self.dir_name = os.path.dirname(conpot.__file__)
databus.initialize(self.dir_name + '/templates/default/template.xml')
args = namedtuple('FakeArgs', 'mibpaths')
args.mibpaths = self.tmp_dir
args = namedtuple('FakeArgs', 'mibcache')
args.mibcache = self.tmp_dir
self.snmp_server = SNMPServer(self.dir_name + '/templates/default/snmp/snmp.xml', 'none', args)
self.server_greenlet = gevent.spawn(self.snmp_server.start, self.host, 0)
gevent.sleep(1)
Expand Down

0 comments on commit bb118d9

Please sign in to comment.