AKS icon indicating copy to clipboard operation
AKS copied to clipboard

[BUG] Container Insights does not support the "Resource-level" access with underlying Log Analytics workspace

Open stephaneey opened this issue 4 years ago • 13 comments

Describe the bug When enabling Container Insights, logs are ingested into a Log Analytics workspace. This workspace's access control mode is set to Use resource or workspace permissions. Despites of this, users that don't have direct workspace permissions cannot access Container Insights, which clearly states:

You do not have required permissions to access Container Insights for this cluster. Please check with your administrator regarding access to Azure Log Analytics workspace xxx

The users is being granted the Azure Kubernetes Service Cluster User Role. Any resource-level role does not work.

To Reproduce Steps to reproduce the behavior:

  1. Create a log analytics workspace with resource-level access mode
  2. Create a cluster with Azure AD authentication with Kubernetes RBAC (it seems that none of the options work anyway)
  3. Enable Container Insights
  4. Give users some permissions over the cluster but not in the underlying workspace
  5. Let a user access container insights ==> forbidden

Expected behavior Users should have a limited access to the underlying log analytics workspace through their resource-level permissions.

Screenshots

Environment (please complete the following information):

  • Kubernetes version: 1.23.8

stephaneey avatar Sep 06 '22 16:09 stephaneey

Can confirm this problem - we observed it as well. We had to implement a custom role and assign it to the LAW RG to make Container Insights work, but not expose every table in LAW

tvdvoorde avatar Sep 20 '22 13:09 tvdvoorde

Hi @stephaneey @tvdvoorde , we have added a story for this. I'll message back with more details once it's rolled out. Thank you!

vdiec avatar Sep 21 '22 18:09 vdiec

Action required from @Azure/aks-pm

ghost avatar Mar 26 '23 01:03 ghost

Issue needing attention of @Azure/aks-leads

ghost avatar Apr 10 '23 06:04 ghost

Issue needing attention of @Azure/aks-leads

ghost avatar Apr 25 '23 06:04 ghost

This is currently being worked on, the current ETA we have for this work is end of next month (end of June 2023).

deagraw avatar May 02 '23 20:05 deagraw

Issue needing attention of @Azure/aks-leads

ghost avatar May 18 '23 00:05 ghost

Issue needing attention of @Azure/aks-leads

ghost avatar Jun 02 '23 06:06 ghost

Issue needing attention of @Azure/aks-leads

ghost avatar Jun 17 '23 06:06 ghost

Issue needing attention of @Azure/aks-leads

ghost avatar Jul 02 '23 12:07 ghost

Issue needing attention of @Azure/aks-leads

ghost avatar Jul 17 '23 18:07 ghost

Hi @stephaneey @tvdvoorde, the current eta for this to be publicly available is the end of August. Please reach out to [email protected] if you would like to try a private flight.

vdiec avatar Jul 25 '23 23:07 vdiec

Hi @stephaneey @tvdvoorde , this feature has been rolled out! If you do not have resource-level query access, you will see a warning warner with a link to documentation.

vdiec avatar Sep 28 '23 00:09 vdiec