<p>I'm facing with next issue. I'm requesting to kubernetes whether I'm able to make some operation:</p>

<pre><code>$ kubectl auth can-i list secrets --namespace iotdevadm
no - no RBAC policy matched
</code></pre>

<p>Above, I'm asking for listing secrets. According to response, I'm not able to do that.</p>

<p>However:</p>

<pre><code>$ kubectl get secrets
NAME                              TYPE                                  DATA   AGE
builder-dockercfg-9m9rf           kubernetes.io/dockercfg               1      23h
builder-token-6xxdn               kubernetes.io/service-account-token   4      23h
builder-token-qc7q7               kubernetes.io/service-account-token   4      23h
default-dockercfg-qs7sj           kubernetes.io/dockercfg               1      23h
default-token-n4lpw               kubernetes.io/service-account-token   4      23h
default-token-n7rhh               kubernetes.io/service-account-token   4      23h
deployer-dockercfg-nhnps          kubernetes.io/dockercfg               1      23h
deployer-token-5rkb6              kubernetes.io/service-account-token   4      23h
deployer-token-v85wp              kubernetes.io/service-account-token   4      23h
istio.builder                     istio.io/key-and-cert                 3      23h
istio.default                     istio.io/key-and-cert                 3      23h
istio.deployer                    istio.io/key-and-cert                 3      23h
istio.kafka                       istio.io/key-and-cert                 3      16h
istio.zeppelin                    istio.io/key-and-cert                 3      18h
kafka-dockercfg-whltw             kubernetes.io/dockercfg               1      16h
kafka-token-crrxt                 kubernetes.io/service-account-token   4      16h
kafka-token-j5dgd                 kubernetes.io/service-account-token   4      16h
sh.helm.release.v1.kafka.v1       helm.sh/release.v1                    1      16h
sh.helm.release.v1.spark.v1       helm.sh/release.v1                    1      16h
sh.helm.release.v1.zeppelin.v1    helm.sh/release.v1                    1      18h
sh.helm.release.v1.zookeeper.v1   helm.sh/release.v1                    1      16h
spark-secret                      Opaque                                0      16h
zeppelin-dockercfg-7zdkm          kubernetes.io/dockercfg               1      18h
zeppelin-token-85jtc              kubernetes.io/service-account-token   4      18h
zeppelin-token-x4r5c              kubernetes.io/service-account-token   4      18h
</code></pre>

Jordi
<p><code>kubectl get secrets</code> will list secrets from <code>default</code> namespace unless you have set a namespace context for the current cluster in your kubeconfig file.</p>

<p><code>kubectl get secrets -n iotdevadm</code> to list secrets from <code>iotdevadm</code> namespace.</p>
