Add modules to repository

This commit is contained in:
Sebastian Kinne
2017-11-16 16:42:22 +11:00
commit d0aa1e38ef
707 changed files with 96750 additions and 0 deletions

33
nmap/scripts/dependencies.sh Executable file
View File

@@ -0,0 +1,33 @@
#!/bin/sh
#2015 - Whistle Master
export LD_LIBRARY_PATH=$LD_LIBRARY_PATH:/sd/lib:/sd/usr/lib
export PATH=$PATH:/sd/usr/bin:/sd/usr/sbin
[[ -f /tmp/nmap.progress ]] && {
exit 0
}
touch /tmp/nmap.progress
if [ "$1" = "install" ]; then
if [ "$2" = "internal" ]; then
opkg update
opkg install nmap
elif [ "$2" = "sd" ]; then
opkg update
opkg install nmap --dest sd
fi
touch /etc/config/nmap
echo "config nmap 'module'" > /etc/config/nmap
uci set nmap.module.installed=1
uci commit nmap.module.installed
elif [ "$1" = "remove" ]; then
opkg remove nmap
rm -rf /etc/config/nmap
fi
rm /tmp/nmap.progress

18
nmap/scripts/nmap.sh Executable file
View File

@@ -0,0 +1,18 @@
#!/bin/sh
#2015 - Whistle Master
export LD_LIBRARY_PATH=$LD_LIBRARY_PATH:/sd/lib:/sd/usr/lib
export PATH=$PATH:/sd/usr/bin:/sd/usr/sbin
MYTIME=`date +%s`
MYCMD=`cat /tmp/nmap.run`
if [ "$1" = "start" ]; then
eval ${MYCMD}
mv /tmp/nmap.scan /pineapple/modules/nmap/scan/scan_${MYTIME}
rm -rf /tmp/nmap.run
elif [ "$1" = "stop" ]; then
killall nmap
rm -rf /tmp/nmap.run
rm -rf /tmp/nmap.scan
fi