Skip to content

Commit

Permalink
Merge pull request #71 from CaptainFreak/master
Browse files Browse the repository at this point in the history
Fixed bugs in choosing payload length and format
  • Loading branch information
codingo committed Oct 14, 2018
2 parents 3f3442e + 4aebe34 commit 9f9890f
Showing 1 changed file with 5 additions and 4 deletions.
9 changes: 5 additions & 4 deletions nsmweb.py
Expand Up @@ -125,7 +125,8 @@ def getApps(webPort,victim,uri,https,verb,requestHeaders, args = None):
else:
injectSize = int(args.injectSize)
format = args.injectFormat


injectSize = int(injectSize)
injectString = build_random_string(format, injectSize)

print "Using " + injectString + " for injection testing.\n"
Expand Down Expand Up @@ -869,13 +870,13 @@ def randInjString(size):
print "2-Letters only"
print "3-Numbers only"
print "4-Email address"
format = True

while format:
while True:
format = raw_input("Select an option: ")
if format not in ["1", "2", "3", "4"]:
format = True
print "Invalid selection."
else:
break
return format

def build_random_string(format, size):
Expand Down

0 comments on commit 9f9890f

Please sign in to comment.