Skip to content

[System.DirectoryServices] Fixed possible NRE in SAMStoreCtx.cs#118123

Merged
jeffhandley merged 2 commits intodotnet:mainfrom
sancheolz:patch-2
Dec 31, 2025
Merged

[System.DirectoryServices] Fixed possible NRE in SAMStoreCtx.cs#118123
jeffhandley merged 2 commits intodotnet:mainfrom
sancheolz:patch-2

Conversation

@sancheolz
Copy link
Contributor

The principalSid may well have a null value if you create an instance of Principal without initializing _sid in it. The check at 652 confirms this.

Found by Linux Verification Center (linuxtesting.org) with SVACE.

@jeffhandley jeffhandley self-assigned this Sep 1, 2025
@jeffhandley jeffhandley enabled auto-merge (squash) September 1, 2025 22:08
auto-merge was automatically disabled September 9, 2025 06:33

Head branch was pushed to by a user without write access

@sancheolz
Copy link
Contributor Author

@jeffhandley The trailing whitespace warning has been fixed.

The principalSid may well have a null value if you create an instance of Principal without initializing _sid in it. The check at 652 confirms this.
@jeffhandley jeffhandley merged commit c3302f5 into dotnet:main Dec 31, 2025
86 checks passed
@sancheolz sancheolz deleted the patch-2 branch December 31, 2025 16:48
@github-actions github-actions bot locked and limited conversation to collaborators Jan 31, 2026
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

area-System.DirectoryServices community-contribution Indicates that the PR has been added by a community member

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants