https://snyk.io/learn/kubernetes-security/
https://kubernetes.io/docs/tasks/administer-cluster/securing-a-cluster/
https://snyk.io/learn/kubernetes-security/
https://kubernetes.io/docs/tasks/administer-cluster/securing-a-cluster/
constrain pod resources:
https://kubernetes.io/docs/concepts/configuration/manage-resources-containers/
to manually exceed the ephermal storage limit run:
1 | fallocate -l 10G /bigfile |
the pod will be evicted, volume and container will be purged, but the record is not automatically removed.
to cleanup the mess one may run a scheduled job like:
1 | while true; |
or configure implementation dependent kube-controller-manager
startup argument terminated-pod-gc-threshold=1
.
for k3s
edit /etc/rancher/k3s/config.yaml
like:
1 | kube-controller-manager-arg: |
for microk8s
, edit /var/snap/microk8s/current/args/kube-controller-manager
references:
https://kubernetes.io/docs/reference/command-line-tools-reference/kube-controller-manager/
https://docs.k3s.io/security/hardening-guide
https://github.com/k3s-io/k3s/issues/10448
make sure you have a networkpolicy enabled cni first. usually included but be careful with minikube since that is a different story
apply these configs with kubectl apply -f <config_path>
interact with kubectl exec <pod_name> -it -- /bin/sh
deployment config:
1 | apiVersion: apps/v1 |
network policy config:
1 | apiVersion: networking.k8s.io/v1 |
ssh port must be secured with pubkey only authentication
search for free frp
or frp 免费
to get free frp providers
use masscan
over these servers to find open ports and candidates
1 | serverAddr = "frp.freefrp.net" |
The default directory after starting parrotsec container is the filesystem root directory, which cannot run msfconsole
. Change to home directory using cd
and run metasploit afterwards.
1 | docker run --rm -it -w /root parrotsec/security |
Symlinked files are not working properly from the start. Taking msfconsole
for example, when running container from image parrotsec/security
, it will get stuck if we immediately execute msfconsole
once logged in, but we can mitigate the problem by first change into the directory where msfconsole
really locates, then execute it from there.
1 | docker run --rm -it parrotsec/security |
captchas are used for public automated turing tests
however, it is not behavior based but rather like capability/skill based.
Invicti is a web application security scanner hacking tool to find SQL Injection, XSS, and vulnerabilities in web applications or services automatically.
It is used to identify security vulnerabilities by allowing it to test the dynamic behavior of running web applications.
It is used to recover the MS Access passwords
Used in port scanning, one of the phases in ethical hacking, is the finest hacking software ever.
Nessus is the world’s most well-known vulnerability scanner, which was designed by tenable network security. It is free and is chiefly recommended for non-enterprise usage.
Checks web servers and identifies over 6400 CGIs or files that are potentially dangerous
Kismet is basically a sniffer and wireless-network detector that works with other wireless cards and supports raw-monitoring mode.
Identifying AP (Access Point) network configuration
Integration of scanner results into other platforms and tools
Uniquely verifies identified vulnerabilities, showing that they are genuine, not false positives
Integrates with Slack, Jira, and major cloud providers
Contains a data transfer, redirection, and debugging tool
Ideal for finding security vulnerabilities
It can crack WEP keys and WPA2-PSK, and check Wi-Fi cards
Allows coloring rules to packet lists to facilitate analysis
OpenVAS has the capabilities of various high and low-level Internet and industrial protocols, backed up by a robust internal programming language.
Supports executing arbitrary commands
Live connections sniffer
Performs real-time information gathering and data mining
Uses out-of-band techniques
Tests different encrypted passwords
This is a free tool for scanning IP addresses and ports
Recognized as one of the best SIEM tools, helping you easily manage memory stick storage
Detects paths changes and alerts you about them
Its packet intelligence provides deep analyses
Responds to real-time threats
Tests dynamic behavior of web applications for the purpose of spotting security vulnerabilities
Supports distributed cracking networks
Fixes weak passwords issues by forcing a password reset or locking out accounts
Rainbow Crack
IKECrack
IKECrack is an authentication cracking tool with the bonus of being open source.
Checks for over two dozen types of web vulnerabilities
One of the best tools for thread-based parallel testing and brute-force testing
uncovers password fields, sniffs networks, recovers MS Access passwords, and cracks encrypted passwords using brute-force, dictionary, and cryptanalysis attacks.
Administrators can track new hosts or services that appear on their networks and track existing downed services
warning: could be dangerous cause adb remote connections seem without any password. consider protect that with some proxy.
turning on:
1 | setprop service.adb.tcp.port 5555 |
turning off:
1 | setprop service.adb.tcp.port -1 |
set things under /data/adb/services.d/
and make them executable
1 | mount -o remount,rw / |
create this under /system/etc/init.d/
1 | service adb_wifi_enable /system/bin/adb_wifi_enable.sh |