keyAuth by Vault get 401 over and over again #12749
-
|
I deployed my apisix in k8s with apisix-ingress-controller.Trying to make Vault as a key manager,I deployed httpbin as backend service and opened keyAuth func. Here is my apisixConsumer.yaml , and helm values.yaml setting apisixConsumer.yaml Here is my apisix config.yaml The kv version of Vault is set to be kv=1 , but still can't looking for correct key, here is my testing cmds and responses apisix logs: Pls help me figure out if I missed something |
Beta Was this translation helpful? Give feedback.
Replies: 4 comments 16 replies
-
|
Hi @rongcheng-000! I'm Dosu and I’m helping the apisix team. Your Vault secret reference syntax in
Your current reference ( Update your Vault secret and consumer reference, then retest. If you still get 401, check APISIX logs for Vault retrieval errors and confirm your consumer is applied in the cluster. To reply, just mention @dosu. How did I do? Good | Irrelevant | Incorrect | Verbose | Hallucination | Report 🐛 | Other |
Beta Was this translation helpful? Give feedback.
-
|
Hi @rongcheng-000, you can refer to https://docs.api7.ai/apisix/how-to-guide/security/secrets-management/manage-secrets-in-hashicorp-vault/ If the problem persists, please submit an issue with a detailed description of your problem. |
Beta Was this translation helpful? Give feedback.
-
|
Does it really work that APISIX CRD - ApisixConsumer can send secret_uri request to Vault for getting keys ? |
Beta Was this translation helpful? Give feedback.
-
I found this issue also in the apisix monolithic, I have been trying to configure the secret manager using vault like in the documentation but also got 401 like yours. but while consuming an api using the key like $secret://vault/1/jack/key-auth its got 200. Meaning apisix doesn't look up the value as a reference but as a key |
Beta Was this translation helpful? Give feedback.
After reviewing the relevant code, it was found that the ApisixConsumer CRD currently only supports Kubernetes secret references and does not support vault references.