Open amit-handda opened 4 years ago
after I added following patch, its working
index 6dd35f5e..311c39af 100644
--- a/pkg/proxy/audit/audit.go
+++ b/pkg/proxy/audit/audit.go
@@ -31,6 +31,7 @@ func New(opts *options.AuditOptions, externalAddress string, secureServingInfo *
// This is so watch requests are handled correctly in the audit log.
LongRunningFunc: genericfilters.BasicLongRunningRequestCheck(
sets.NewString("watch"), sets.NewString()),
+ LegacyAPIGroupPrefixes: sets.NewString( "api"),
}```
Hi @amit-handda, thanks for catching this. I will follow up with a fix.
/assign
Hi @amit-handda, apologies for the delay. This is still on my backlog to get to :)
Hello,
Thanks for such a useful tool. want to raise an issue about audit feature not working for
get pods <pod-name>
. I dont see anything in the proxy output console. I have configured the audit as follows:I see that test for this usecase has been written. however, the same doesnt execute because of absence of
./pkg/proxy/audit/audit_test.go
in the code.I debugged the issue further to find the root cause. Its happening due to (misconfigured ?)
serverConfig.RequestInfoResolver
https://github.com/jetstack/kube-oidc-proxy/blob/a8d94c0b669bae9bfc52a6dd51eaa80cfd267506/pkg/proxy/audit/audit.go#L81 Its only resolving/apis/*
as resource requests. While forget pods <pod-name>
the api is/api/v1/...
Hope I am correct. Thanks,