gRPC status 16: UNAUTHENTICATED
UNAUTHENTICATED is gRPC status code 16. The request has no valid credentials for the operation.
Updated
Usual causes
- No
authorizationmetadata was sent. - The token has expired, or was issued for another environment.
- The metadata key or format is wrong, such as a missing
Bearerprefix. - Mutual TLS is required and no client certificate was presented.
What to check
- The metadata actually sent: key
authorization, valueBearer <token>. gRPC metadata keys are lowercase. - The token's expiry and audience.
- For mTLS, that the client certificate and key are configured and signed by a CA the server trusts.
Not to be confused with
Valid credentials without the right to do something get PERMISSION_DENIED.
What it looks like
A typical error, as a Go client prints it: rpc error: code = Unauthenticated desc = invalid token: token is expired
Retry, and the HTTP equivalent
| UNAUTHENTICATED | |
|---|---|
| Code | 16 |
| Name | UNAUTHENTICATED |
| In istek's status bar | unauthenticated |
| Retry | After refreshing the credentials, yes; with the same ones, no. |
| HTTP status | 401 |
istek names the status of every call it makes, unauthenticated included, and explains transport failures in plain words. See istek.