Giter Club home page Giter Club logo

automation-of-port-scanning-pentesting-project's Introduction

Automation of Port Scanning Pentesting Project

diagram

Description

In this project, I create an automation of a Python Script that performs port scanning to automate pentesting for any IP address and desired port to check if its open or closed. We code using Virtual Studio Code (any python environment can be used) and the socket library. Lets get right into this step by step guide!

Languages and Utilities Used

  • Python
  • JSON

Environments Used

  • Virtual Studio Code

Program walk-through:

Here is the completed code, we import the socket library which is used to specify we are using IPv4 via the "AF_INET" method and "SOCK_STREAM" which specifies it being TCP and that there will be a TCP Handshake:
set up
We create a function which scans the port using the socket variable we created and it checks to see if the socket does not connect using "connect_ex" print that its closed. Else print that its open if it connects:
set up

We will be scanning the ports of this site "www.hackthissite.org" as an example, to get the ip we ping the site in our command prompt:
set up

Now we run the code and follow the input instructions we made, we add the IP which we got from the cmd:
set up

And then we input the port we want to scan to see if its open or closed, in this case we will check port 21 and it appears to be open:
set up set up

This Concludes This Automation Python Script Project! NOTE: You can add onto this and make it more complex, or use these methonds to automate other tasks!

automation-of-port-scanning-pentesting-project's People

Contributors

anwarsyed1 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.