istio: Istio proxy fais with JWT token missing JWT token
Bug description We are upgrading from istio 1.4.5 to 1.5.5 and the istio-proxy container keeps restarting with error:
2020-06-29T21:45:03.269986Z info JWT policy is third-party-jwt
2020-06-29T21:45:03.270042Z warn Missing JWT token, can't use in process SDS ./var/run/secrets/tokens/istio-tokenstat ./var/run/secrets/tokens/istio-token: no such file or directory
2020-06-29T21:45:03.270052Z fatal Missing JWT, can't authenticate with control plane. Try using plain text (15010)
We have set controlPlaneSecurityEnabled: false
but seems this config is eliminated in istio 1.5. So there is no way to disable proxy to control plane secure communication?
Tried to install with --set values.global.jwtPolicy=first-party-jwt
but this doesn’t seem work, it still use third party token,
And our cluster seems support third party jwt token since when I run kubectl get --raw /api/v1
it returns result contains:
{"name":"serviceaccounts/token","singularName":"","namespaced":true,"group":"authentication.k8s.io","version":"v1","kind":"TokenRequest","verbs":["create"]}
I do managed to set ‘first-party-jwt’ once and I saw from istio-proxy logs that it is using first party token and it works. but next time with same code, it will still use third party jwt, I’m confused here.
we have 1.4.5 running fine for a long time. I’m guessing that’s because we have controlPlaneSecurityEnabled: false
and it works in 1.4.5
[x ] Configuration Infrastructure [ ] Docs [ ] Installation [x] Networking [ ] Performance and Scalability [ ] Policies and Telemetry [ ] Security [ ] Test and Release [x ] User Experience [ ] Developer Infrastructure
Expected behavior
Steps to reproduce the bug
I can reproduce the bug by deploying istio 1.5.5 using istioctl manifest apply
to the k8s cluster
Version (include the output of istioctl version --remote
and kubectl version
and helm version
if you used Helm)
istioctl version 1.5.5
kubectl version 1.5.10
How was Istio installed? we are using istioctl to install istio and istioctl verify install passed
Environment where bug was observed (cloud vendor, OS, etc)
About this issue
- Original URL
- State: closed
- Created 4 years ago
- Reactions: 1
- Comments: 17 (6 by maintainers)
Closing as both issues here are addressed
OP: has incorrect inejctor config Others: have automountServiceAccountToken=false
I resolve this issue after read some ref docs, but I don’t know if it is the right way. I used the “first-party-jwt” and add the property in deployment(template>spec>[Add automountServiceAccountToken: true]) then the pod is running now, I will find out whether it is work later.