Skip to content

Latest commit

 

History

History
 
 

bad-ingress-scanner

Folders and files

NameName
Last commit message
Last commit date

parent directory

..
 
 
 
 
 
 
 
 
 
 

Docker Pulls Build Status

Bad ingress scanner

This tool is designed to scan for misbehaving ingresses. An example being an ingress that was deployed referencing a non-existent SSL cert or an ingress with an empty/missing backend service.

Running report - remotely

wget -o ingress-scanner.sh https://raw.githubusercontent.com/rancherlabs/support-tools/master/bad-ingress-scanner/run.sh
chmod +x ./ingress-scanner.sh
./ingress-scanner.sh

Running report - in-cluster

kubectl -n ingress-nginx delete job ingress-scanner
kubectl apply -f deployment.yaml
kubectl -n ingress-nginx logs -l app=ingress-scanner

Example output

Pod: nginx-ingress-controller-r8kkz
####################################################################
Found bad endpoints.
default/ingress-75f627ce3d0ccd29dd268e0ab2b37008
default/test-01-example-com
default/test-02-example-com
####################################################################
Found bad certs.
default/test-01-example-com
default/test-02-example-com

Removing

kubectl delete -f deployment.yaml

Deploying test ingress rules

Note: These rules are designed to be broken/invalid and are deployed to the default namespace.

kubectl apply -f bad-ingress.yaml

Removing test ingress rules

kubectl delete -f bad-ingress.yaml