Archives
Trending
Support
Login
clear text
XML
Django
JavaScript
MATLAB
C
C++
C#
Python
SQL
Shell
Bash
Markdown
YAML
JSON
HTML
CSS
PHP
Java
Ruby
Go
Rust
Swift
Kotlin
Arduino
TypeScript
Perl
Autohotkey
Lua
SQF
R
Scala
Haskell
Groovy
Dart
Clojure
VB.NET
Objective-C
PowerShell
Bash
CoffeeScript
Verilog
#!/bin/bash #created by Kris Occhipinti #http://filmsbykris.com #Copyright Jan 2019 #GPLv3 https://www.gnu.org/licenses/gpl-3.0.txt #For use in Termux on Android #quickly scans network based you current device's ip log=$HOME/downloads/scan_$(date +%s).log ip="$(ip addr|grep wlan -A3|grep inet|head -n1 |awk '{print $2}'|cut -d\/ -f1)" ipr="$(echo "$ip"|cut -d\. -f1,2,3)" echo "-------$ip--------" #scan for http and printer servers nmap -v $ipr.0/24 -p 80 |tee -a "$log" nmap -v $ipr.0/24 -p 9100 |tee -a "$log" #create HTML output echo "
HTTP Servers
" > $log.html grep 'Discovered open port 80' "$log"|\ awk '{print $6}'|while read ipaddress do echo "
$ipaddress
" done >> $log.html echo "
" >> $log.html echo "
Printer Servers
" >> $log.html grep 'Discovered open port 9100' "$log"|\ awk '{print $6}'|while read ipaddress do echo "
$ipaddress
" done >> $log.html termux-open $log.html nmap -v $ipr.0/24 |tee -a "$log" grep "Discovered open port" $log
Mark as private (unlisted)
for 30 minutes
for 6 hours
for 1 day
for 1 week
for 1 month
for 1 year
everlasting (like CCCP)