diff --git a/CHANGELOG.md b/CHANGELOG.md index 433edc5..bc0f7d5 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -5,6 +5,12 @@ All notable changes to this project will be documented in this file. The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.1.0/), and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html). +## 0.3.1 (2026-04-11) + +### Fixed + +- Users with eligble assignments that has been activated are no longer present twice in output. + ## 0.3.0 (2026-04-05) ### Added diff --git a/EntraReporter/EntraReporter.psd1 b/EntraReporter/EntraReporter.psd1 index 7d2a15c..bcb2efc 100644 --- a/EntraReporter/EntraReporter.psd1 +++ b/EntraReporter/EntraReporter.psd1 @@ -4,7 +4,7 @@ RootModule = 'EntraReporter.psm1' # Version number of this module. - ModuleVersion = '0.3.0' + ModuleVersion = '0.3.1' # Supported PSEditions CompatiblePSEditions = @('Core', 'Desktop') diff --git a/EntraReporter/functions/Get-EntraIdRoleAssignment.ps1 b/EntraReporter/functions/Get-EntraIdRoleAssignment.ps1 index 94a7d9a..e5ce865 100644 --- a/EntraReporter/functions/Get-EntraIdRoleAssignment.ps1 +++ b/EntraReporter/functions/Get-EntraIdRoleAssignment.ps1 @@ -34,6 +34,10 @@ function Get-EntraIdRoleAssignment { $RoleName ) + # TODO: Add switch to include expired assigments. These are not included by default and may require additional API calls to fetch historical assignment data, so we will implement this as an optional switch to avoid unnecessary API calls for users who do not need this information. + + # TODO: Consider options for adding a property showing whether accounts have sign-in disabled, stop showing them default, and add switch to include them. This will require fetching additional information about the principal (user/service principal) for each assignment to check the sign-in status, which may lead to a significant increase in API calls. + #region Internal functions # Resolve-AssignmentWindow: compute the effective assignment window from principal and user time windows @@ -174,6 +178,10 @@ function Get-EntraIdRoleAssignment { } foreach ($scheduleEntry in $scheduleEntries ) { + # Ignore eligble entries that has been activated to avoid emitting duplicate entries for the same user that would show up as both eligible and assigned. + if ($scheduleEntry.assignmentType -eq 'activated') { + continue + } if ($scheduleEntry.principal.'@odata.type' -eq '#microsoft.graph.user') { # User member found; create normalized assignment entry $roleEntrySplat = @{