summaryrefslogtreecommitdiff
path: root/dev-db/sqlmap
diff options
context:
space:
mode:
authorV3n3RiX <venerix@koprulu.sector>2022-04-06 22:33:41 +0100
committerV3n3RiX <venerix@koprulu.sector>2022-04-06 22:33:41 +0100
commite68d405c5d712af4387159df07e226217bdda049 (patch)
tree009ab0f3d427f0813e62930d71802cb054c07e30 /dev-db/sqlmap
parent401101f9c8077911929d3f2b60a37098460a5d89 (diff)
gentoo resync : 06.04.2022
Diffstat (limited to 'dev-db/sqlmap')
-rw-r--r--dev-db/sqlmap/Manifest5
-rw-r--r--dev-db/sqlmap/files/sqlmap.bash-completion158
-rw-r--r--dev-db/sqlmap/metadata.xml20
-rw-r--r--dev-db/sqlmap/sqlmap-1.6.2.ebuild60
-rw-r--r--dev-db/sqlmap/sqlmap-9999.ebuild60
5 files changed, 303 insertions, 0 deletions
diff --git a/dev-db/sqlmap/Manifest b/dev-db/sqlmap/Manifest
new file mode 100644
index 000000000000..ef107891edf8
--- /dev/null
+++ b/dev-db/sqlmap/Manifest
@@ -0,0 +1,5 @@
+AUX sqlmap.bash-completion 5757 BLAKE2B f602d99b6b0a30cf405b390eaef355f7a4b4fa4260f0a18fe09a0fa7530af131b75ffc25ca161898f2ed4a93ef9251c0c88cb1ad25d78d870fd2ff19225e0609 SHA512 5024cfb2274a2798fcc7d12e59693253732f66c1389aed36cc31fb8e40d03f7e9a713e93e24711185b5d2d82dd2ac91ec2b6cdc4929c5ca3245fcb4f502d327a
+DIST sqlmap-1.6.2.tar.gz 7258723 BLAKE2B cc972eda5351683904e4c9d4f7e0ab9c127c22de597397e976060808812032b2041f68ab2d737784e499a20a7ca930167427390ca178269d744ee71738e5c270 SHA512 a3057486f5096fb2a242296b4ceeb1c500246fbd322c3e52f71e72cd91d1c676ca6f7746becf887625e45d0b14443a669410b28bd6a995124a6e8006c4534976
+EBUILD sqlmap-1.6.2.ebuild 1331 BLAKE2B 40fdcfd802252b9a996da8be8a90d45925f1a06099a49d3c0cdd5af232b440003483fbc6e001e706149497ae224723fd2e32fd65953bd14074a7f2a82b8a5785 SHA512 31b004012264cc0a58dcfdc611df346382f1b613a90b08aa2a344a2b87b5025b90c10877c666452e5428f9bc8161bc6c78eb0782542fac0dea2e33686c18cf28
+EBUILD sqlmap-9999.ebuild 1331 BLAKE2B 40fdcfd802252b9a996da8be8a90d45925f1a06099a49d3c0cdd5af232b440003483fbc6e001e706149497ae224723fd2e32fd65953bd14074a7f2a82b8a5785 SHA512 31b004012264cc0a58dcfdc611df346382f1b613a90b08aa2a344a2b87b5025b90c10877c666452e5428f9bc8161bc6c78eb0782542fac0dea2e33686c18cf28
+MISC metadata.xml 670 BLAKE2B 3d8b2779a6d7d2eb3b176d525877e748a1ec418376bf330ee13d7854d035ebdf6050cb081484030cdf4ad85f3478eef3c978b856d064d79ebd5c348dc2187e17 SHA512 2973b4a3ca75b92aa9547eae217eb1035c500d262696c86e09226895d96f1a3f1ac7e7e81e1d09c55615cac9c1beed63bded08f9d17764c330d93dce6a4c0458
diff --git a/dev-db/sqlmap/files/sqlmap.bash-completion b/dev-db/sqlmap/files/sqlmap.bash-completion
new file mode 100644
index 000000000000..47e11297ed89
--- /dev/null
+++ b/dev-db/sqlmap/files/sqlmap.bash-completion
@@ -0,0 +1,158 @@
+# bash completion for sqlmap by Korznikov Alexander
+# source: http://www.korznikov.com/2014/12/bash-tab-completion-for-awesome-tool.html
+# cp sqlmap_bash_completion /etc/bash_completion.d/sqlmap
+
+tamper=$(ls /usr/share/sqlmap/tamper|grep -v "__" |sed ':a;N;$!ba;s/\n/ /g')
+
+_sqlmap()
+{
+ local cur prev
+
+ COMPREPLY=()
+ cur=`_get_cword`
+ prev=`_get_pword`
+
+ case $prev in
+
+ # List directory content
+ --tamper)
+ COMPREPLY=( $( compgen -W "$tamper" -- "$cur" ) )
+ return 0
+ ;;
+ --output-dir|-t|-l|-m|-r|--load-cookies|--proxy-file|--sql-file|--shared-lib|--file-write)
+ _filedir
+ return 0
+ ;;
+ -c)
+ _filedir ini
+ return 0
+ ;;
+ --method)
+ COMPREPLY=( $( compgen -W 'GET POST PUT' -- "$cur" ) )
+ return 0
+ ;;
+ --auth-type)
+ COMPREPLY=( $( compgen -W 'Basic Digest NTLM PKI' -- "$cur" ) )
+ return 0
+ ;;
+ --tor-type)
+ COMPREPLY=( $( compgen -W 'HTTP SOCKS4 SOCKS5' -- "$cur" ) )
+ return 0
+ ;;
+ -v)
+ COMPREPLY=( $( compgen -W '1 2 3 4 5 6' -- "$cur" ) )
+ return 0
+ ;;
+ --dbms)
+ COMPREPLY=( $( compgen -W 'mysql mssql access postgres' -- "$cur" ) )
+ return 0
+ ;;
+ --level|--crawl)
+ COMPREPLY=( $( compgen -W '1 2 3 4 5' -- "$cur" ) )
+ return 0
+ ;;
+ --risk)
+ COMPREPLY=( $( compgen -W '0 1 2 3' -- "$cur" ) )
+ return 0
+ ;;
+ --technique)
+ COMPREPLY=( $( compgen -W 'B E U S T Q' -- "$cur" ) )
+ return 0
+ ;;
+ -s)
+ _filedir sqlite
+ return 0
+ ;;
+ --dump-format)
+ COMPREPLY=( $( compgen -W 'CSV HTML SQLITE' -- "$cur" ) )
+ return 0
+ ;;
+ -x)
+ _filedir xml
+ return 0
+ ;;
+ esac
+
+ if [[ "$cur" == * ]]; then
+ COMPREPLY=( $( compgen -W '-h --help -hh --version -v -d -u --url -l -x -m -r -g -c --method \
+ --data --param-del --cookie --cookie-del --load-cookies \
+ --drop-set-cookie --user-agent --random-agent --host --referer \
+ --headers --auth-type --auth-cred --auth-private --ignore-401 \
+ --proxy --proxy-cred --proxy-file --ignore-proxy --tor --tor-port \
+ --tor-type --check-tor --delay --timeout --retries --randomize \
+ --safe-url --safe-freq --skip-urlencode --csrf-token --csrf-url \
+ --force-ssl --hpp --eval -o --predict-output --keep-alive \
+ --null-connection --threads -p --skip --dbms --dbms-cred \
+ --os --invalid-bignum --invalid-logical --invalid-string \
+ --no-cast --no-escape --prefix --suffix --tamper --level \
+ --risk --string --not-string --regexp --code --text-only \
+ --titles --technique --time-sec --union-cols --union-char \
+ --union-from --dns-domain --second-order -f --fingerprint \
+ -a --all -b --banner --current-user --current-db --hostname \
+ --is-dba --users --passwords --privileges --roles --dbs --tables \
+ --columns --schema --count --dump --dump-all --search --comments \
+ -D -T -C -X -U --exclude-sysdbs --where --start --stop \
+ --first --last --sql-query --sql-shell --sql-file --common-tables \
+ --common-columns --udf-inject --shared-lib --file-read --file-write \
+ --file-dest --os-cmd --os-shell --os-pwn --os-smbrelay --os-bof \
+ --priv-esc --msf-path --tmp-path --reg-read --reg-add --reg-del \
+ --reg-key --reg-value --reg-data --reg-type -s -t --batch \
+ --charset --crawl --csv-del --dump-format --eta --flush-session \
+ --forms --fresh-queries --hex --output-dir --parse-errors \
+ --pivot-column --save --scope --test-filter --update \
+ -z --alert --answers --beep --check-waf --cleanup \
+ --dependencies --disable-coloring --gpage --identify-waf \
+ --mobile --page-rank --purge-output --smart \
+ --sqlmap-shell --wizard' -- "$cur" ) )
+ # this removes any options from the list of completions that have
+ # already been specified somewhere on the command line, as long as
+ # these options can only be used once (in a word, "options", in
+ # opposition to "tests" and "actions", as in the find(1) manpage).
+ onlyonce=' -h --help -hh --version -v -d -u --url -l -x -m -r -g -c \
+ --drop-set-cookie --random-agent \
+ --ignore-401 \
+ --ignore-proxy --tor \
+ --check-tor \
+ --skip-urlencode \
+ --force-ssl --hpp -o --predict-output --keep-alive \
+ --null-connection -p \
+ --invalid-bignum --invalid-logical --invalid-string \
+ --no-cast --no-escape \
+ --text-only \
+ --titles \
+ -f --fingerprint \
+ -a --all -b --banner --current-user --current-db --hostname \
+ --is-dba --users --passwords --privileges --roles --dbs --tables \
+ --columns --schema --count --dump --dump-all --search --comments \
+ -D -T -C -X -U --exclude-sysdbs \
+ --sql-shell --common-tables \
+ --common-columns --udf-inject \
+ --os-shell --os-pwn --os-smbrelay --os-bof \
+ --priv-esc --reg-read --reg-add --reg-del \
+ -s -t --batch \
+ --eta --flush-session \
+ --forms --fresh-queries --hex --parse-errors \
+ --save --update \
+ -z --beep --check-waf --cleanup \
+ --dependencies --disable-coloring --identify-waf \
+ --mobile --page-rank --purge-output --smart \
+ --sqlmap-shell --wizard '
+ COMPREPLY=( $( \
+ (while read -d ' ' i; do
+ [[ -z "$i" || "${onlyonce/ ${i%% *} / }" == "$onlyonce" ]] &&
+ continue
+ # flatten array with spaces on either side,
+ # otherwise we cannot grep on word boundaries of
+ # first and last word
+ COMPREPLY=" ${COMPREPLY[@]} "
+ # remove word from list of completions
+ COMPREPLY=( ${COMPREPLY/ ${i%% *} / } )
+ done
+ printf '%s ' "${COMPREPLY[@]}") <<<"${COMP_WORDS[@]}"
+ ) )
+
+# else
+# _filedir bat
+ fi
+} &&
+complete -F _sqlmap sqlmap
diff --git a/dev-db/sqlmap/metadata.xml b/dev-db/sqlmap/metadata.xml
new file mode 100644
index 000000000000..9be066d6c8f4
--- /dev/null
+++ b/dev-db/sqlmap/metadata.xml
@@ -0,0 +1,20 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE pkgmetadata SYSTEM "https://www.gentoo.org/dtd/metadata.dtd">
+<pkgmetadata>
+ <maintainer type="person" proxied="yes">
+ <email>mario.haustein@hrz.tu-chemnitz.de</email>
+ <name>Mario Haustein</name>
+ </maintainer>
+ <maintainer type="person">
+ <email>sam@gentoo.org</email>
+ <name>Sam James</name>
+ </maintainer>
+ <longdescription>
+ sqlmap is an open source penetration testing tool that automates the
+ process of detecting and exploiting SQL injection flaws and taking over
+ of database servers.
+ </longdescription>
+ <upstream>
+ <remote-id type="github">sqlmapproject/sqlmap</remote-id>
+ </upstream>
+</pkgmetadata>
diff --git a/dev-db/sqlmap/sqlmap-1.6.2.ebuild b/dev-db/sqlmap/sqlmap-1.6.2.ebuild
new file mode 100644
index 000000000000..7b33e4568b15
--- /dev/null
+++ b/dev-db/sqlmap/sqlmap-1.6.2.ebuild
@@ -0,0 +1,60 @@
+# Copyright 1999-2022 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=8
+
+PYTHON_COMPAT=( python3_{9..10} )
+PYTHON_REQ_USE="sqlite"
+
+inherit bash-completion-r1 python-single-r1 wrapper
+
+DESCRIPTION="An automatic SQL injection and database takeover tool"
+HOMEPAGE="https://sqlmap.org/"
+
+if [[ ${PV} == 9999 ]] ; then
+ inherit git-r3
+ EGIT_REPO_URI="https://github.com/sqlmapproject/sqlmap"
+else
+ SRC_URI="https://github.com/sqlmapproject/sqlmap/archive/refs/tags/${PV}.tar.gz -> ${P}.tar.gz"
+ KEYWORDS="~amd64 ~x86"
+fi
+
+# sqlmap (GPL-2+)
+# ansitrm (BSD)
+# beautifulsoup (BSD)
+# bottle (MIT)
+# charder (LGPL-2.1+)
+# clientform (BSD)
+# colorama (BSD)
+# fcrypt (BSD-2)
+# identitywaf (MIT)
+# keepalive (LGPL-2.1+)
+# magic (MIT)
+# multipartpost (LGPL-2.1+)
+# ordereddict (MIT)
+# prettyprint (BSD-2)
+# pydes (public-domain)
+# six (MIT)
+# socks (BSD)
+# termcolor (BSD)
+# wininetpton (public-domain)
+LICENSE="BSD BSD-2 GPL-2+ LGPL-2.1+ MIT public-domain"
+SLOT="0"
+
+RDEPEND="${PYTHON_DEPS}"
+REQUIRED_USE="${PYTHON_REQUIRED_USE}"
+
+DOCS=( doc/ README.md )
+
+src_install () {
+ einstalldocs
+
+ insinto /usr/share/${PN}/
+ doins -r *
+ python_optimize "${ED}"/usr/share/${PN}
+
+ make_wrapper ${PN} \
+ "${EPYTHON} ${EPREFIX}/usr/share/${PN}/sqlmap.py"
+
+ newbashcomp "${FILESDIR}"/sqlmap.bash-completion sqlmap
+}
diff --git a/dev-db/sqlmap/sqlmap-9999.ebuild b/dev-db/sqlmap/sqlmap-9999.ebuild
new file mode 100644
index 000000000000..7b33e4568b15
--- /dev/null
+++ b/dev-db/sqlmap/sqlmap-9999.ebuild
@@ -0,0 +1,60 @@
+# Copyright 1999-2022 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=8
+
+PYTHON_COMPAT=( python3_{9..10} )
+PYTHON_REQ_USE="sqlite"
+
+inherit bash-completion-r1 python-single-r1 wrapper
+
+DESCRIPTION="An automatic SQL injection and database takeover tool"
+HOMEPAGE="https://sqlmap.org/"
+
+if [[ ${PV} == 9999 ]] ; then
+ inherit git-r3
+ EGIT_REPO_URI="https://github.com/sqlmapproject/sqlmap"
+else
+ SRC_URI="https://github.com/sqlmapproject/sqlmap/archive/refs/tags/${PV}.tar.gz -> ${P}.tar.gz"
+ KEYWORDS="~amd64 ~x86"
+fi
+
+# sqlmap (GPL-2+)
+# ansitrm (BSD)
+# beautifulsoup (BSD)
+# bottle (MIT)
+# charder (LGPL-2.1+)
+# clientform (BSD)
+# colorama (BSD)
+# fcrypt (BSD-2)
+# identitywaf (MIT)
+# keepalive (LGPL-2.1+)
+# magic (MIT)
+# multipartpost (LGPL-2.1+)
+# ordereddict (MIT)
+# prettyprint (BSD-2)
+# pydes (public-domain)
+# six (MIT)
+# socks (BSD)
+# termcolor (BSD)
+# wininetpton (public-domain)
+LICENSE="BSD BSD-2 GPL-2+ LGPL-2.1+ MIT public-domain"
+SLOT="0"
+
+RDEPEND="${PYTHON_DEPS}"
+REQUIRED_USE="${PYTHON_REQUIRED_USE}"
+
+DOCS=( doc/ README.md )
+
+src_install () {
+ einstalldocs
+
+ insinto /usr/share/${PN}/
+ doins -r *
+ python_optimize "${ED}"/usr/share/${PN}
+
+ make_wrapper ${PN} \
+ "${EPYTHON} ${EPREFIX}/usr/share/${PN}/sqlmap.py"
+
+ newbashcomp "${FILESDIR}"/sqlmap.bash-completion sqlmap
+}