lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [day] [month] [year] [list]
Message-ID: <200211300226.gAU2QTAe022608@mailserver2.hushmail.com>
From: es at hush.com (es@...h.com)
Subject: [ElectronicSouls] - SSH Scanner

-----BEGIN PGP SIGNED MESSAGE-----

Dear List,

We are trying to get Theo to add this to OpenBSD -- it is up to par with
the rest of their superb operating system!@#

#!/bin/bash
# Provos did a great work on scanssh, here is kind of a tool for easier use
# If libcap and scanssh are not installed yet, this script will do it :)
#
# Tested on RH 7 and RH 6.2 (Zoot)
#
# By changing the ESDBC config lines, you can let this software automatically upload
# the results to a remote ESDBS after the scans :)
#
# Coded by CraigTM [ElectronicSouls]

ESDBS=
useESDBS=false
useFILTER=false

echo ""
echo -e "     \033[1;37m[ \033[32mElectronicSouls\033[1;37m ]\033[0m"
echo -e "       \033[1;34m scanssh tool    \033[0m"
echo ""

if [ "$1" = "" ]
 then
  echo -e "\033[35musage\033[0m: $0 [\033[33mB-Net\033[0m] [\033[33mC-Net\033[0m]"
  echo -e "       $0 \033[33m192.168\033[0m \033[33m0\033[0m"
  echo ""
  exit 1
fi

if [ -e scan ]
 then
  echo ""
  echo -e "\033[1;30m[\033[1;34m*\033[1;30m]\033[0m scanssh is installed"

 else
  echo -e "\033[1;30m[\033[31mx\033[1;30m]\033[0m scanssh is not installed"

  l=`which lynx`

# download libcap stuff and install

  if [ ! -e /usr/local/lib/libpcap.a ]
   then
    echo -e "\033[1;30m[\033[31mx\033[1;30m]\033[0m libcap not found, installing now..."

     if [ "$l" = "" ]
      then
       echo -e "\033[1;30m[\033[31mx\033[1;30m]\033[0m lynx not installed, trying to download libcap with wget"
        wget http://192.139.46.44/release/libpcap-0.6.2.tar.gz
       else
        echo -e "\033[1;30m[\033[31m \033[1;30m]\033[0m  trying to download libcap with lynx"
        $l -dump http://192.139.46.44/release/libpcap-0.6.2.tar.gz>libpcap-0.6.2.tar.gz
     fi

    if [ -e libpcap-0.6.2.tar.gz ]
     then
      echo -e "\033[1;30m[\033[1;34m*\033[1;30m]\033[0m libcap downloaded, compiling..."
      tar xfvz libpcap-0.6.2.tar.gz > /dev/null
      rm -f libpcap-0.6.2.tar.gz
      cd libpcap-0.6.2
      ./configure > /dev/null
      make > /dev/null
      make install > /dev/null
      cd ..
      rm -fr libpcap-0.6.2


      if [ -e /usr/local/lib/libpcap.a ]
       then
        echo -e "\033[1;30m[\033[1;34m*\033[1;30m]\033[0m libcap was installed properly"
       else
        echo -e "\033[1;30m[\033[31mx\033[1;30m]\033[0m libcap could not be installed properly"
        echo ""
        exit 1
      fi

     else
      echo -e "\033[1;30m[\033[31mx\033[1;30m]\033[0m libcap could not be downloaded"
      echo ""
      exit 1
    fi



   else
    echo -e "\033[1;30m[\033[1;34m*\033[1;30m]\033[0m libcap found"
  fi



# download scanssh and install

  if [ "$l" = "" ]
   then
    echo -e "\033[1;30m[\033[31mx\033[1;30m]\033[0m lynx not installed, trying to download scanssh with wget"
     wget http://204.181.64.9/~provos/scanssh-1.6.tar.gz
    else
     echo -e "\033[1;30m[\033[31m \033[1;30m]\033[0m  trying to download scanssh with lynx"
     $l -dump http://204.181.64.9/~provos/scanssh-1.6.tar.gz>scanssh-1.6.tar.gz
  fi

  if [ ! -e scanssh-1.6.tar.gz ]
   then
    echo -e "\033[1;30m[\033[31mx\033[1;30m]\033[0m Could not download scanssh"
    echo ""
    exit 1
   else
    echo -e "\033[1;30m[\033[1;34m*\033[1;30m]\033[0m scanssh package downloaded, compiling..."
  fi

  tar xfvz scanssh-1.6.tar.gz > /dev/null
  rm -f scanssh-1.6.tar.gz
  cd scanssh
  ./configure > /dev/null
  make > /dev/null
  mv scanssh ../scan
  cd ..
  rm -fr scanssh

  if [ ! -e scan ]
   then
    echo -e "\033[1;30m[\033[31mx\033[1;30m]\033[0m scanssh could not be installed properly"
    echo ""
    exit 1
   else
    echo -e "\033[1;30m[\033[1;34m*\033[1;30m]\033[0m scanssh installed"
  fi

fi

if [ "$useESDBS" = "true" ]
then
 echo -e "\033[1;30m[\033[1;34m*\033[1;30m]\033[0m upload to ESDBS $ESDBS enabled"
fi


if [ "$2" = "" ]
then
 echo -e "\033[1;30m[\033[1;34m*\033[1;30m]\033[0m starting class b scan"
 echo ""
 seq 0 254 | while read cnet
  do
   ./scan $1.$cnet.0/24 | grep SSH- >>log
    echo -e "    $1.$cnet.* \033[36mfinished\033[0m"
  done
 echo ""

else
 echo -e "\033[1;30m[\033[1;34m*\033[1;30m]\033[0m starting class c scan"
 ./scan $1.$2.0/24 | grep SSH- >>log

fi



if [ "$useFILTER" = "true" ]
then
 cat log | grep "SSH-1.5-1.2.26" >>l
 cat log | grep "SSH-1.5-1.2.27" >>l
 cat log | grep "SSH-1.5-1.2.31" >>l
 cat log | grep "SSH-1.5-1.3.07" >>l
 cat log | grep "SSH-1.5-OpenSSH-1.2.3" >>l
 cat log | grep "SSH-1.5-1.3.6_F-SECURE_SSH" >>l
 cat log | grep "SSH-1.99-OpenSSH_2.2.0p1" >>l
 cat log | grep "SSH-1.99-OpenSSH_2.1.1" >>l
 mv -f l log
fi


if [ -e log ]
then

 if grep -i "SSH-" log > /dev/null
  then
   echo -e "\033[1;30m[\033[1;34m*\033[1;30m]\033[0m scan finished"
   echo -e "\033[1;30m[\033[1;34m*\033[1;30m]\033[0m results saved in log"

   if [ "$useESDBS" = "true" ]
    then
     ./ESDBC upload $ESDBS thx ssh log
     echo ""
   fi

  else
   echo -e "\033[1;30m[\033[1;34m*\033[1;30m]\033[0m scan finished"
   echo -e "\033[1;30m[\033[31mx\033[1;30m]\033[0m no servers found"
 fi

fi
echo ""

#

The Electronic Souls Crew
[ElectronicSouls] (c) 2002

"Yes, we want jobs."
-----BEGIN PGP SIGNATURE-----
Version: Hush 2.2 (Java)
Note: This signature can be verified at https://www.hushtools.com/verify

wlMEARECABMFAj3oIegMHGVzQGh1c2guY29tAAoJEN5nGqhGcjltfy8An0VktKdf8PWA
M7XOy1wuy5kSL2dlAKCWIyqjICrbyCuF4Ty+qXKY2EtNPQ==
=Dm4x
-----END PGP SIGNATURE-----




Concerned about your privacy? Follow this link to get
FREE encrypted email: https://www.hushmail.com/?l=2 

Big $$$ to be made with the HushMail Affiliate Program: 
https://www.hushmail.com/about.php?subloc=affiliate&l=427

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ