apiVersion: "config.istio.io/v1alpha2"
kind: denier
metadata:
  name: handler
  namespace: istio-system
spec:
  status:
    code: 7
    message: Not allowed
---
apiVersion: "config.istio.io/v1alpha2"
kind: checknothing
metadata:
  name: denyrequest
  namespace: istio-system
spec:
 
---
apiVersion: "config.istio.io/v1alpha2"
kind: rule
metadata:
  name: denyreviewsv3
  namespace: istio-system
spec:
  #FIXME match: destination.labels["app"]=="productpage" && request.headers["x-user"] == ""
  match: request.headers["x-user"] == "john"
  actions:
  - handler: handler.denier.istio-system
    instances: [ denyrequest.checknothing.istio-system ]
