To compare nmap scans use 'ndiff' https://operationsbynumbers.wordpress.com/2011/08/24/use-nmap-to-track-network-changes/
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
FILE SPACING: | |
# double space a file | |
sed G | |
# double space a file which already has blank lines in it. Output file | |
# should contain no more than one blank line between lines of text. | |
sed '/^$/d;G' |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
#From http://brakertech.com/linux-find-large-files/ | |
# find large files | |
echo "find files over 100MB" | |
find / -type f -size +100000k -exec ls -lh {} \; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#From http://unix.stackexchange.com/questions/88702/change-chkconfig-used-by-centos-6-3-to-print-on-in-bright-green-like-ubuntus/88706#88706 | |
alias chkconfig="chkconfig | perl -pe 'use Term::ANSIColor; s/\bon\b/color(\"green\").on.color(\"reset\")/ige;'" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
#################################### | |
# Exit if program echo does not exist (this allows us to do one line if statements) | |
[ ! -x "$(which echo)" ] && exit 1 | |
######################################## | |
# pretty printing functions | |
function print_status { echo -e "\x1B[01;34m[*]\x1B[0m $1"; } | |
function print_good { echo -e "\x1B[01;32m[*]\x1B[0m $1"; } |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
############################################################################### | |
# USAGE: idc-certadd | |
# | |
# Allows user to: | |
# 1. Create a new certificate to be kept in OSCARS.jks | |
# 2. Import a signed certificate into OSCARS.jks | |
# 3. Import a trusted certificate into OSCARS.jks or ssl-keystore.jks | |
############################################################################### |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/sh | |
if [ "$1" ] | |
then | |
find "$1" -name '*.flac' | while read fn; | |
do | |
basename=$(basename "$fn" .flac).mp3 | |
dirname=$(dirname "$fn") | |
outfile="$dirname/$basename" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
# get_amis.sh | |
# Return a list of all ami's in use in aws | |
aws ec2 describe-instances --query 'Reservations[*].Instances[*].[ImageId,Tags[*]]' | grep ami | perl -pi -e "s/,//g;" | perl -pi -e "s/\"//g;" | perl -pi -e "s/\s+/\n/g;" | grep -v "^$" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# ediscovery_search_exported_msg_files.ps1 | |
# Search through exported .msg files from content search (exchange compliance center) and return a spreadsheet of email addresses and matched URLs | |
# Kill outlook | |
cmd.exe /c "taskkill /F /IM outlook.exe /T 2> nul" | |
$scriptPath = $(split-path $myinvocation.mycommand.definition) | |
$inputPath = "$($scriptPath)\inputMails" | |
# Find all .msg files recursively |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
######################################################################### | |
# # | |
# # | |
# NATO String converter # | |
# # | |
# Description: converts string (first parameter given) # | |
# to NATO phonetics-alphabet # | |
# # |
OlderNewer