> For the complete documentation index, see [llms.txt](https://docs.devolutions.net/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.devolutions.net/powershell-universal/it/sicurezza/enterprise-security/openid-connect/client-certificate-authentication.md).

# Autenticazione con certificato client

Autentichi i client OpenID Connect in PowerShell Universal con un certificato RSA utilizzando un'asserzione private\_key\_jwt invece di un client secret.

I client OpenID Connect (OIDC) possono autenticarsi presso un provider con un certificato RSA invece che con un client secret. PowerShell Universal crea un'asserzione `private_key_jwt` di breve durata utilizzando PS256 quando riscatta il codice di autorizzazione.

## Requisiti

* Il provider di identità deve supportare l'autenticazione client `private_key_jwt`.
* Il file del certificato deve essere un PFX che includa una chiave privata RSA.
* La registrazione del client presso il provider di identità deve essere configurata per il certificato utilizzato da PowerShell Universal.

## Configurare OIDC

Nell'editor di autenticazione OIDC in **Secure > Autenticazione**, indichi il percorso del certificato. Facoltativamente, ne indichi la password. Se il valore della password è il nome di una variabile secret di PSU, PowerShell Universal risolve tale secret in fase di esecuzione.

Il flusso OIDC esistente basato su client secret rimane invariato. Configuri un client secret oppure un certificato client in base al metodo di autenticazione client richiesto dal suo provider.

Utilizzi `Set-PSUAuthenticationMethod` per configurare le stesse impostazioni da PowerShell:

```powershell
Set-PSUAuthenticationMethod -Type OIDC `
    -CallbackPath '/auth/signin-oidc' `
    -ClientId '00000000-0000-0000-0000-000000000000' `
    -Authority 'https://login.microsoftonline.com/contoso.onmicrosoft.com/v2.0' `
    -ClientCertificate 'C:\certificates\psu-oidc.pfx' `
    -ClientCertificatePassword 'PsuOidcCertificatePassword'
```

Mantenga il file del certificato leggibile dall'account che esegue PowerShell Universal. Non memorizzi una password del certificato in testo normale quando è disponibile una variabile secret di PSU.


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation by asking a question.

Perform an HTTP GET request on the following URL with the `ask` and `goal` query parameters:

```
GET https://docs.devolutions.net/powershell-universal/it/sicurezza/enterprise-security/openid-connect/client-certificate-authentication.md?ask=<question>&goal=<user_goal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is what the user is ultimately trying to achieve, the reason they need the answer. Sharing it helps GitBook give you a better, more relevant answer. A goal is most helpful when it describes the outcome the user wants rather than restating the question. For example, with `ask=how do I create an API token`, a goal like `automate deployments from our CI pipeline` lets GitBook tailor the answer to that use case.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
