Merge branch 'g0tmi1k-searchsploit'

This commit is contained in:
Offensive Security 2016-08-18 16:07:28 +00:00
commit 37ddb2eb21

View file

@ -11,8 +11,8 @@
# Exit code '6' means updated from GitHub
## OS settings
gitpath="${0%/*}"
## OS settings (get the path of where the script is stored + database file)
gitpath="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )"
csvpath="${gitpath}/files.csv"
@ -42,7 +42,7 @@ SEARCH=""
LANG=C
## If we cannot find files.csv in ${gitpath}
## If we cannot find files.csv
if [[ ! -f "${csvpath}" ]]; then
echo '[!] Could not find: ' ${csvpath}
exit 1
@ -376,12 +376,12 @@ elif [[ "${JSON}" -eq 1 ]]; then
| sed '$ s/,$//g' )"
## Default view
else
OUTPUT=$OUTPUT"$(awk -F "\"*,\"*" '{ printf "%-'${FORMAT}'s | %s\n", $3, $2}' "${csvpath}" \
OUTPUT="$( awk -F "\"*,\"*" '{ printf "%-'${FORMAT}'s | %s\n", $3, $2}' "${csvpath}" \
| eval "${SEARCH}" \
| sed "s/| platforms/| ./" )"
fi
echo $OUTPUT
echo "${OUTPUT}"
## Print footer if not in JSON
if [[ "${JSON}" -eq 0 ]]; then