title: services is forbidden: User \"system:anonymous\" cannot list services in the namespace \"kube-system\
body: <p>I have created a fresh kubernetes cluster on VirtualBox. I have one master node and two worker nodes. I want to use the dashboard but I get error. When I run <code>kubectl proxy</code> the master start listening on port 8001:</p>
  
  <pre><code>Starting to serve on 127.0.0.1:8001
  </code></pre>
  
  <p>and then I create a SSH tunnel on my host:</p>
  
  <pre><code>ssh user@10.10.10.50 -N -L 8001:127.0.0.1:8001
  </code></pre>
  
  <p>but when I type <code>localhost:8001/ui</code> on the browser I get this:</p>
  
  <pre><code>{
    "paths": [
      "/apis",
      "/apis/",
      "/apis/apiextensions.k8s.io",
      "/apis/apiextensions.k8s.io/v1beta1",
      "/healthz",
      "/healthz/etcd",
      "/healthz/ping",
      "/healthz/poststarthook/generic-apiserver-start-informers",
      "/healthz/poststarthook/start-apiextensions-controllers",
      "/healthz/poststarthook/start-apiextensions-informers",
      "/metrics",
      "/openapi/v2",
      "/swagger-2.0.0.json",
      "/swagger-2.0.0.pb-v1",
      "/swagger-2.0.0.pb-v1.gz",
      "/swagger.json",
      "/swaggerapi",
      "/version"
    ]
  }
  </code></pre>
  
  <p>And if I want to get into the dashboard through api directly :</p>
  
  <pre><code>https://10.10.10.50:6443/api/v1/namespaces/kube-system/services
  </code></pre>
  
  <p>I get this error:</p>
  
  <pre><code>{
    "kind": "Status",
    "apiVersion": "v1",
    "metadata": {
  
    },
    "status": "Failure",
    "message": "services is forbidden: User \"system:anonymous\" cannot list services in the namespace \"kube-system\"",
    "reason": "Forbidden",
    "details": {
      "kind": "services"
    },
    "code": 403
  }
  </code></pre>
  
  <p>I know this is related to authentication but I don't know how should I define username/password on my cluster or share keys among master nodes and my host. Or how should I use the keys inside .kube/config file.</p>