Skip to content

Commit

Permalink
Added checks to prevent crash when using unset while no module is sel…
Browse files Browse the repository at this point in the history
…ected or with an option that does not exist
  • Loading branch information
Daniel Crowley authored and Daniel Crowley committed Apr 3, 2017
1 parent 1af1c3a commit 7357b71
Showing 1 changed file with 6 additions and 1 deletion.
7 changes: 6 additions & 1 deletion featherduster.py
Original file line number Diff line number Diff line change
Expand Up @@ -347,7 +347,12 @@ def run(self, line):
print 'Usage: unset <option>'
return False
option = line_split[1]
feathermodules.current_options[option] = feathermodules.selected_attack['options'][option]
try:
feathermodules.current_options[option] = feathermodules.selected_attack['options'][option]
except KeyError:
print '[*] That option doesn\'t exist, sorry!'
except AttributeError:
print '[*] Please select an attack first!'
def args(self):
return feathermodules.selected_attack['options'].keys()

Expand Down

0 comments on commit 7357b71

Please sign in to comment.