Harden Azure Key Vault trusted endpoint matching
I maintainer di solito rispondono entro 2 giorni
@apoorvdeshmukh ci sta già lavorando.
Dal 13/10/2026.
Valutazione
- Difficoltà
- 5/5
- Tempo stimato
- Più di una settimana
- Idoneità per principianti
- 35/100
Direzione di ricerca
Start by locating SqlColumnEncryptionAzureKeyVaultProvider and reading its trusted-endpoint validation and constructor behavior, then inspect the related tests. Add coverage for the listed DNS, scheme, port, normalization, and input-mutation cases; done means endpoint validation follows the requested structured rules while preserving the described compatibility path.
Scritto dal modello di indicizzazione a partire dal testo della issue.
Descrizione
Is your feature request related to a problem? Please describe.
SqlColumnEncryptionAzureKeyVaultProvider validates an Azure Key Vault key URI by checking whether Uri.Host ends with one of its trusted endpoint strings. Raw suffix matching does not require a DNS-label boundary, so a hostname can match a trusted suffix without being that domain or one of its subdomains.
The trusted-endpoint representation also does not express whether an entry is an exact host, a DNS suffix, or a complete origin. This makes it difficult to apply clear scheme and port rules to application-supplied endpoints while preserving compatibility with custom Azure environments and development endpoints.
Describe the solution you'd like
Harden and clarify trusted endpoint validation:
- Match built-in domain suffixes only when the host is exactly the suffix or ends with
"." + suffix, using ordinal case-insensitive comparison. - Normalize DNS hosts consistently, including IDN and terminal-dot handling.
- Require HTTPS for built-in Azure Key Vault and Managed HSM endpoints.
- Validate and normalize application-supplied trusted endpoints when the provider is constructed.
- Provide structured semantics for custom endpoints, distinguishing exact origins from entries that intentionally include DNS subdomains.
- Defensively copy trusted endpoint collections so validation policy cannot be changed by mutating the constructor input.
- Preserve reasonable compatibility for existing custom endpoints, with diagnostics and an explicit migration path for ambiguous legacy entries.
Add tests covering:
- Valid exact hosts and subdomains.
- Lookalike suffixes that do not share a DNS-label boundary.
- Hosts that append another DNS suffix after a trusted name.
- Mixed-case, IDN, and terminal-dot hostnames.
- HTTP, HTTPS, default ports, and explicit custom ports.
- Mutation of the input trusted-endpoint array after construction.
Describe alternatives you've considered
- Keep raw
EndsWithmatching. This retains ambiguous behavior and does not accurately model DNS domain membership. - Require exact host matching for every entry. This would not work for the built-in Azure Key Vault domains, where each vault has its own subdomain.
- Immediately reject every legacy custom endpoint format. This would provide simpler rules but could unnecessarily disrupt applications using private clouds, proxies, or development services. A compatibility-conscious migration to structured endpoint rules is preferable.
Additional context
The current built-in list covers Azure Key Vault and Managed HSM domains in public and sovereign clouds. DNS-label-boundary matching should preserve valid hostnames beneath those domains while making the allowlist behavior precise.
- Lingua principale
- C#
- Stelle
- 996
- Fork
- 348
- Merge medio
- 6g 3h
- PR unite (30g)
- 58
Preparare l'ambiente
Avvia il container di sviluppo del progetto nel browser, con il tuo account GitHub.
- Nessun Dockerfile né file Docker Compose
- Ha un modello di pull request
- Leggi la guida per i contributori
Come iniziare
- Leggi tutta la issue e poi la guida ai contributi del progetto.
- Commenta sulla issue per dire che te ne occupi tu — evita che due persone facciano lo stesso lavoro.
- Fai un fork del repository e lavora su un branch.
- Apri una pull request che faccia riferimento al numero della issue.
Altre issue di dotnet/SqlClient
-
SqlBatch.ValidateExecuteCommandBehavior XML comment says NotSupportedException but code throws ArgumentOutOfRangeExceptionForse già presa @apoorvdeshmukh l’ha presa 3 giorni fa. Aperta
Difficoltà 1/5 Meno di un'ora Idoneità per principianti 90/100
dotnet/SqlClient#4823 · 1 commento · 1 assegnatario ·
I maintainer di solito rispondono entro 2 giorni
-
Sync ExecuteReader on an STA thread deadlocks against a StateChange handler that marshals to the UI thread (OpenAsyncRetry path)Forse di nuovo libera @mdaigle l’ha presa 28 giorni fa e non c’è nessuna pull request aperta. ApertaExternal :link:
Difficoltà 2/5 1-3 ore Idoneità per principianti 64/100
dotnet/SqlClient#4534 · 2 commenti · 1 assegnatario ·
I maintainer di solito rispondono entro 2 giorni
-
Area\Tests
Difficoltà 2/5 1-3 ore Idoneità per principianti 68/100
dotnet/SqlClient#4377 · 2 commenti ·
I maintainer di solito rispondono entro 2 giorni
-
[7.0] Backport #4843Aperta:new: Triage Needed
Difficoltà 3/5 Mezza giornata Idoneità per principianti 15/100
I maintainer di solito rispondono entro 2 giorni
-
[7.1] Backport #4843Forse già presa @LaurensVergote l’ha presa 2 giorni fa. Aperta:new: Triage Needed
Difficoltà 3/5 Mezza giornata Idoneità per principianti 18/100
dotnet/SqlClient#4846 · 1 commento ·
I maintainer di solito rispondono entro 2 giorni
Tutte le issue di dotnet/SqlClient
Issue simili
-
ASP.NET Core container quickstart: `docker-run: debug` task sample is missing its closing braceAperta
Difficoltà 1/5 Meno di un'ora Idoneità per principianti 88/100
microsoft/vscode-docs#10499 ·
I maintainer di solito rispondono entro 1 giorno
-
Difficoltà 2/5 1-3 ore Idoneità per principianti 72/100
I maintainer di solito rispondono entro 1 giorno
-
Difficoltà 2/5 1-3 ore Idoneità per principianti 78/100
-
python triage
Difficoltà 2/5 1-3 ore Idoneità per principianti 72/100
microsoft/semantic-kernel#14615 ·
I maintainer di solito rispondono entro 3 giorni
-
Difficoltà 2/5 1-3 ore Idoneità per principianti 75/100
vzeol/DeployCraft#125 ·
I maintainer di solito rispondono entro 1 giorno