From 1064f81b81112d9d797d25149b67a30ead8fa97b Mon Sep 17 00:00:00 2001 From: Jonathan Claudius Date: Thu, 5 Jul 2018 16:42:01 -0400 Subject: [PATCH] Fix a few more code review items --- cron/createFDQNBlockList.py | 8 ++++---- meteor/app/client/blockFDQN.js | 2 +- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/cron/createFDQNBlockList.py b/cron/createFDQNBlockList.py index fc67097f..ba5797ae 100644 --- a/cron/createFDQNBlockList.py +++ b/cron/createFDQNBlockList.py @@ -104,12 +104,12 @@ def main(): ]}, }, {"$project":{"address":1}}, - {"$limit": options.iplimit} + {"$limit": options.fqdnlimit} ]) FQDNList=[] for fqdn in fqdnCursor: # TODO: figure out what to do here - FQDNList.append(ip['address']) + FQDNList.append(fqdn['address']) # to text with open(options.outputfile, 'w') as outputfile: for fqdn in FQDNList: @@ -121,7 +121,7 @@ def main(): except ValueError as e: - logger.error("Exception %r generating IP block list" % e) + logger.error("Exception %r generating FQDN block list" % e) def initConfig(): @@ -152,7 +152,7 @@ def initConfig(): options.expireage = getConfig('expireage',1,options.configfile) # Max FQDNs to emit - options.iplimit = getConfig('fqdnlimit', 1000, options.configfile) + options.fqdnlimit = getConfig('fqdnlimit', 1000, options.configfile) # AWS creds options.aws_access_key_id=getConfig('aws_access_key_id','',options.configfile) #aws credentials to use to connect to mozilla_infosec_blocklist diff --git a/meteor/app/client/blockFDQN.js b/meteor/app/client/blockFDQN.js index 43184684..87eb6e57 100644 --- a/meteor/app/client/blockFDQN.js +++ b/meteor/app/client/blockFDQN.js @@ -7,7 +7,7 @@ Copyright (c) 2014 Mozilla Corporation if (Meteor.isClient) { - Template.blockIPform.rendered = function() { + Template.blockFQDNform.rendered = function() { $('#fqdn')[0].value = Session.get('blockFQDN'); };