Skip to content

AKS Review workbook is incorrectly identifying public api endpoint compliance#1022

Open
johnbilliris wants to merge 2 commits intoAzure:mainfrom
johnbilliris:aks-public-api-endpoint
Open

AKS Review workbook is incorrectly identifying public api endpoint compliance#1022
johnbilliris wants to merge 2 commits intoAzure:mainfrom
johnbilliris:aks-public-api-endpoint

Conversation

@johnbilliris
Copy link
Copy Markdown

@johnbilliris johnbilliris commented Apr 28, 2025

Description

AKS Review workbook is incorrectly identifying public api endpoint compliance #1021

The AKS Review workbook is incorrectly identifying public API endpoint compliance. The query logic is incorrect.

Current (incorrect) logic:
compliant = ((isnull(properties.apiServerAccessProfile.enablePrivateCluster) or properties.apiServerAccessProfile.enablePrivateCluster==false) and isnotnull(properties.apiServerAccessProfile.authorizedIPRanges))

Correct logic:
compliant = tostring(properties.apiServerAccessProfile.enablePrivateCluster)=='true' or isnotnull(properties.apiServerAccessProfile.authorizedIPRanges)

Related Issue

Link to any related issues or discussions here. This helps reviewers understand the context and the need for your changes.

Checklist

  • [x ] I've tested my changes to ensure they are ready for review.
  • I've read the CONTRIBUTING.md guide.
  • I've updated the documentation (if applicable).
  • Resource Graph queries have been included (and tested) for recommendations where ever possible1.
  • Resource Graph queries have NOT been included (please explain below).

Additional Information

Is there any additional context, screenshots, or considerations that might help in the review process? Please include them here.

Reviewer Notes

Is there a specific area you’d like feedback on? Please highlight it here. We're here to help and learn together! 💡

Footnotes

  1. Details on how to add Azure Resource Graph queries to recommendations can be found here.

@mbilalamjad
Copy link
Copy Markdown
Contributor

@sdolgin, @erjosito your review is required

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants