mirror of
https://github.com/Matir/skel.git
synced 2026-05-26 05:29:09 -07:00
Add support for gef.
This commit is contained in:
@@ -237,6 +237,16 @@ case ${TOOL} in
|
|||||||
# capstone package is broken
|
# capstone package is broken
|
||||||
cp ${PY_PACKAGES}/usr/lib/*/dist-packages/capstone/libcapstone.so ${PY_PACKAGES}/capstone
|
cp ${PY_PACKAGES}/usr/lib/*/dist-packages/capstone/libcapstone.so ${PY_PACKAGES}/capstone
|
||||||
;;
|
;;
|
||||||
|
gef)
|
||||||
|
if ! which gdb > /dev/null 2>&1 ; then
|
||||||
|
echo 'No gdb available!' >/dev/stderr
|
||||||
|
exit 1
|
||||||
|
fi
|
||||||
|
mkdir -p ${DESTDIR}
|
||||||
|
download \
|
||||||
|
https://github.com/hugsy/gef/raw/master/gef.py \
|
||||||
|
${DESTDIR}/gef.py
|
||||||
|
;;
|
||||||
*)
|
*)
|
||||||
echo "Unknown tool: ${TOOL}" >/dev/stderr
|
echo "Unknown tool: ${TOOL}" >/dev/stderr
|
||||||
echo "Options:" >/dev/stderr
|
echo "Options:" >/dev/stderr
|
||||||
|
|||||||
@@ -26,9 +26,12 @@ end
|
|||||||
python
|
python
|
||||||
import sys
|
import sys
|
||||||
import os.path
|
import os.path
|
||||||
|
gef = os.path.expanduser('~/tools/gef/gef.py')
|
||||||
pwndbg = os.path.expanduser('~/tools/pwndbg/gdbinit.py')
|
pwndbg = os.path.expanduser('~/tools/pwndbg/gdbinit.py')
|
||||||
peda = os.path.expanduser('~/.peda/peda.py')
|
peda = os.path.expanduser('~/.peda/peda.py')
|
||||||
if os.path.isfile(pwndbg):
|
if os.path.isfile(gef):
|
||||||
|
gdb.execute('source {}'.format(gef))
|
||||||
|
elif os.path.isfile(pwndbg):
|
||||||
sys.path.insert(0, os.path.expanduser('~/tools/pwndbg/vendor'))
|
sys.path.insert(0, os.path.expanduser('~/tools/pwndbg/vendor'))
|
||||||
gdb.execute('source {}'.format(pwndbg))
|
gdb.execute('source {}'.format(pwndbg))
|
||||||
elif os.path.isfile(peda):
|
elif os.path.isfile(peda):
|
||||||
|
|||||||
Reference in New Issue
Block a user