Skip to content

Network 25411: TLS inspection is enabled and correctly configured for outbound traffic - Spec Update#1083

Open
ashwinikarke wants to merge 3 commits intodevfrom
Feature-25411
Open

Network 25411: TLS inspection is enabled and correctly configured for outbound traffic - Spec Update#1083
ashwinikarke wants to merge 3 commits intodevfrom
Feature-25411

Conversation

@ashwinikarke
Copy link
Collaborator

PR Contains below changes:

  1. Collect all linked profiles for table display regardless of state (previously only enabled profiles were collected, causing disabled entries to silently disappear from tables)
  2. Tables now show profiles with ❌ Disabled state so users can see misconfigured entries
  3. Added TLSPolicyLinkState -eq 'enabled' check to Baseline Profile pass/fail logic (previously a disabled policy link would incorrectly count as a pass)
  4. Added TLSPolicyLinkState -eq 'enabled' check to Security Profile pass/fail logic for consistency
  5. Renamed $enabledBaseLineProfiles collection variable to $baselineProfileResults to reflect it now holds all linked baseline profiles, not only passing ones
  6. Pass/fail filtering now derived post-collection via Where-Object on $baselineProfileResults and $securityProfileResults

@peresys13 peresys13 requested a review from Copilot March 18, 2026 11:21
Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Updates assessment/reporting for TLS inspection linked profiles so disabled links/profiles remain visible in tables, while pass/fail logic only counts enabled links/profiles.

Changes:

  • Collect baseline/security profile links regardless of profile/link state for table rendering.
  • Update report tables to display ✅ Enabled / ❌ Disabled states for profile and policy link.
  • Tighten pass/fail filtering to require enabled policy link state (and enabled profile state), derived post-collection.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

@ashwinikarke ashwinikarke self-assigned this Mar 19, 2026
@ashwinikarke ashwinikarke added the ready for review PR is ready for review and merging label Mar 19, 2026
@ashwinikarke ashwinikarke changed the title Feature 25411 Network 25411: TLS inspection is enabled and correctly configured for outbound traffic Mar 19, 2026
@ashwinikarke ashwinikarke changed the title Network 25411: TLS inspection is enabled and correctly configured for outbound traffic Network 25411: TLS inspection is enabled and correctly configured for outbound traffic - Spec Update Mar 19, 2026
Copy link
Collaborator

@alexandair alexandair left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@ashwinikarke Please, address my feedback.

Write-ZtProgress -Activity $activity -Status 'Querying filtering profiles and policies'
$filteringProfiles = Invoke-ZtGraphRequest -RelativeUri 'networkAccess/filteringProfiles' -QueryParameters @{
'$select' = 'id,name,description,state,version,priority'
'$expand' = 'policies($select=id,state;$expand=policy($select=id,name,version)),conditionalAccessPolicies($select=id,displayName)'
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Unused $expand=conditionalAccessPolicies in filteringProfiles query**

The filteringProfiles request includes:

'$expand' = 'policies(...),conditionalAccessPolicies($select=id,displayName)'

However, Find-ZtProfilesLinkedToPolicy never reads the conditionalAccessPolicies data from the expand. CA policy matching is done entirely by querying $allCAPolicies and filtering by sessionControls.globalSecureAccessFilteringProfile.profileId. This fetches data that is silently discarded. The expand should be removed to reduce payload size and avoid confusion.

# Step 2: List all policies in the Baseline Profile and in each Security Profile
Write-ZtProgress -Activity $activity -Status 'Querying filtering profiles and policies'
$filteringProfiles = Invoke-ZtGraphRequest -RelativeUri 'networkAccess/filteringProfiles' -QueryParameters @{
'$select' = 'id,name,description,state,version,priority'
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

version property in filteringProfiles $select is unused**

The $select includes version for filteringProfiles:

'$select' = 'id,name,description,state,version,priority'

version is not referenced anywhere in the code and is not required by the spec's query definition. It should be removed.

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

Labels

ready for review PR is ready for review and merging

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants