Closed santikris2003 closed 3 years ago
Thanks, @santikris2003 for the suggestions :pray:
I have added both kube-hunter
and kubeletctl
to the Hacker Container.
For now kube-hunter
added as using k8s manifests and if required we have to use it via python virtual environment. In the future will update with the proper package manager.
Thank you!
thanks for adding those , I tried on the latest hacker-container , Im getting kubeletctl not found I installed the updated hacker-container using kubectl run -it hacker-container --image=madhuakula/hacker-container (root) /usr/bin # uname -a Linux hacker-container 5.4.0-1045-aws #47-Ubuntu SMP Tue Apr 13 07:02:25 UTC 2021 x86_64 GNU/Linux (root) /usr/bin # kube kube-bench kubeaudit kubectl kubectl-who-can kubeletctl kubesec (root) /usr/bin # kubeletctl /bin/sh: kubeletctl: not found (root) /usr/bin # not sure if Im missing anything
ERROR: Command errored out with exit status 1: /root/bin/python3 -u -c 'import io, os, sys, setuptools, tokenize; sys.argv[0] = '"'"'/tmp/pip-install-zkpsiahw/netifaces_c74b3c6e92f541dda5c56ea7c1c4a32a/setup.py'"'"'; file='"'"'/tmp/pip-install-zkpsiahw/netifaces_c74b3c6e92f541dda5c56ea7c1c4a32a/setup.py'"'"';f = getattr(tokenize, '"'"'open'"'"', open)(file) if os.path.exists(file) else io.StringIO('"'"'from setuptools import setup; setup()'"'"');code = f.read().replace('"'"'\r\n'"'"', '"'"'\n'"'"');f.close();exec(compile(code, file, '"'"'exec'"'"'))' install --record /tmp/pip-record-40jii5fm/install-record.txt --single-version-externally-managed --compile --install-headers /root/include/site/python3.8/netifaces Check the logs for full command output. (root) ~/kube-hunter #
Sorry about that. Looks like some issue with kubeletctl
when it's downloading from the official release. Fixed by building from multi-stage build container.
Regarding the kube-hunter
currently, it only works using YAML manifests. Due to the python environment with dependencies were breaking.
Thank you so much once again!
Add Kube-Hunter and Kubeletctl to the Hacker-Container