Scripting

nmap/nbtscan scan for å finne pc med åpen port

Dette scriptet scanner IP-er fra ei fil og finner ut hvem som har en spesiell port åpen.Lim inn følgende script kode i fila portLookup.sh #!/bin/bashNETWORKTARGET=$1PORT=$2FN=”port”# Scan Network Input File for active hosts saving IPS to $FNips.txtnmap -sS -p $PORT -n -iL $NETWORKTARGET -oG – | grep open | awk ‘/[1-9].[1-9]/ {print $2}’ > ${FN}ips.txt# use […]

Read More
Security

Open a range of ports with iptables

In RedHat/Fedora you can define firewall rules in the file /etc/sysconfig/iptables. By adding this line you open ports in the range 5920-5960 -A RH-Firewall-1-INPUT -p tcp –destination-port 5920:5960 -j ACCEPT

Read More
Scripting

Create ISO file with mkisofs

The AUDIO_TS/ and VIDEO_TS/ directories are required by the dvd video standard, and contain all of the menus and video that will be used when you put this dvd into your home dvd player. # mkisofs -dvd-video -udf -o dvd.iso dvd_fs This will create the iso image dvd.iso that you can burn to a real […]

Read More
Linux

dvd-slideshow

DVD-slideshow is a tool you can use to create a slideshow DVD with images. Create a file that describes the DVD content # dir2slideshow -T -t 5 -c 1 -n slideshow_name bilder/ Transform the content to DVD format # dvd-slideshow -mp2 -p -n “Tina’s 9 mnd” slideshow_name.txt Create the DVD content and a ISO file […]

Read More