> 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/de/sicherheit/enterprise-security/ws-federation.md).

# WS-Federation

Konfigurieren Sie die WS-Federation-Authentifizierung in PowerShell Universal mit ADFS oder Azure Active Directory, einschließlich der Einrichtung einer Vertrauensstellung der vertrauenden Seite.

{% hint style="info" %}
WS-Federation erfordert eine [Lizenz](https://store.devolutions.net/package#psu).
{% endhint %}

WS-Federation unterstützt sowohl Active Directory Federation Services als auch Azure Active Directory.

Sie müssen zunächst ADFS oder AzureAD so konfigurieren, dass Universal unterstützt wird.

## ADFS für Universal konfigurieren <a href="#configuring-adfs-for-universal-dashboard" id="configuring-adfs-for-universal-dashboard"></a>

### Diensteinstellungen <a href="#service-settings" id="service-settings"></a>

Zuerst müssen Sie die Federation Service Properties von ADFS ermitteln. Öffnen Sie die AD FS-App (Microsoft.IdentityServer.msc). Klicken Sie anschließend auf Service und dann auf Edit Federation Service Properties.

Dadurch wird ein Dialog mit den Werten für Ihren ADFS-Dienst geöffnet. Sie benötigen diese Werte für die Konfiguration von PowerShell Universal.

### Vertrauende Seiten <a href="#relying-parties" id="relying-parties"></a>

Wenn keine Relying Party Trusts konfiguriert sind, klicken Sie auf Add Relying Party Trust. Wählen Sie Claims aware.

Wählen Sie Enter data about the relying party manually.

Geben Sie einen Namen für die vertrauende Seite an.

Aktivieren Sie das WS-Federation Passive-Protokoll. Geben Sie die URL des PowerShell Universal-Servers mit einem abschließenden Schrägstrich ein.

Geben Sie die URL Ihres PowerShell Universal-Servers ein.

Nach Abschluss der Konfiguration Ihres Relying Party Trust müssen Sie eine Claim Issuance Policy einrichten. Erstellen Sie eine Issuance Transform Rule, die mindestens den Name und die Name ID an Universal sendet.

Sie können zusätzliche Claims konfigurieren, die Sie verwenden möchten, wenn Sie Richtlinien in Universal einsetzen.

### Fehlerbehebung

MSIS7065: There are no registered protocol handlers on path /adfs/ls to process the incoming request.

Dieses Problem kann auftreten, wenn die Seite IDP Initiated Sign On deaktiviert ist. Dies ist die Standardeinstellung. Führen Sie den folgenden Befehl in einer administrativen Konsole aus.

{% code collapsedlinecount="10" %}

```powershell
 Set-AdfsProperties -EnableIdPInitiatedSignonPage $true
```

{% endcode %}

MSIS7001: The passive protocol context was not found or not valid. If the context was stored in cookies, the cookies that were presented by the client were not valid. Ensure that the client browser is configured to accept cookies from this website and retry this request.

## Konfiguration für Azure Active Directory <a href="#configuring-for-azure-active-directory" id="configuring-for-azure-active-directory"></a>

Folgen Sie der Dokumentation für die Azure Active Directory-Konfiguration in diesem [Microsoft-Dokument](https://docs.microsoft.com/en-us/aspnet/core/security/authentication/ws-federation?view=aspnetcore-2.2#azure-active-directory).

## Universal konfigurieren <a href="#configuring-universal-dashboard" id="configuring-universal-dashboard"></a>

### Appsettings.json verwenden

Nach der Konfiguration von ADFS oder AAD können Sie Universal nun die Eigenschaften für MetadataAddress und Wtrealm bereitstellen. Informationen zu diesen Einstellungen finden Sie auf unserer Seite [Einstellungen](/powershell-universal/de/config/settings.md).

Hier ist ein Beispiel dafür, wie Sie die Datei `appsettings.json` aktualisieren, um die richtigen Einstellungen für WS-Federation zu übernehmen.

{% code collapsedlinecount="10" %}

```javascript
{
  "Kestrel": {
    "Endpoints": {
      "HTTP": {
        "Url": "http://*:5000"
      }
    },
    "RedirectToHttps": "false"
  },
  "ApplicationInsights": {
    "InstrumentationKey": ""
  },
  "Logging": {
    "Path": "%PROGRAMDATA%/PowerShellUniversal/log.txt",
    "RetainedFileCountLimit": 31,
    "LogLevel": {
      "Default": "Information",
      "Microsoft": "Warning",
      "Microsoft.Hosting.Lifetime": "Information"
    }
  },
  "AllowedHosts": "*",
  "CorsHosts": "",
  "Data": {
    "RepositoryPath": "%ProgramData%\\UniversalAutomation\\Repository",
    "ConnectionString": "%ProgramData%\\UniversalAutomation\\database.db",
    "GitRemote": "",
    "GitUserName": "",
    "GitPassword": "", 
    "ConfigurationScript": ""
  },
  "Api": {
    "Url": ""
  },
  "Authentication" : {
    "Windows": {
      "Enabled": "false"
    },
    "WSFed": {
        "Enabled": "true",
        "MetadataAddress": "https://ironman.local:443/FederationMetadata/2007-06/FederationMetadata.xml",
        "Wtrealm": "https://ironman.local:12345",
        "CallbackPath": "/auth/signin-wsfed"
    },
    "OIDC": {
      "Enabled": "false",
      "CallbackPath": "/auth/signin-oidc",
      "ClientID": "",
      "ClientSecret": "",
      "Resource": "",
      "Authority": "",
      "ResponseType": "",
      "SaveTokens": "false"
    },
    "SessionTimeout": "25"
  },
  "Jwt": {  
    "SigningKey": "PleaseUseYourOwnSigningKeyHere",  
    "Issuer": "IronmanSoftware",
    "Audience": "PowerShellUniversal"
  },
  "UniversalDashboard": {
    "AssetsFolder": "%ProgramData%\\PowerShellUniversal\\Dashboard"
  },
  "ShowDevTools": false,
  "HideAdminConsole": false
}
```

{% endcode %}

Wenn Sie Ihren Server ausführen, sollten Sie nun entweder über das Single-Sign-On-System von Internet Explorer zur Eingabe Ihrer Anmeldeinformationen aufgefordert oder zur WS-Fed-Anmeldeseite weitergeleitet werden.

### Authentication.ps1 verwenden

Sie können die WS-Federation-Authentifizierung in der Administrationskonsole konfigurieren. Navigieren Sie dazu zu Secure > Authentication. Fügen Sie den WS-Federation-Anbieter hinzu, indem Sie ihn im Dropdown-Menü oben rechts auswählen.

Bearbeiten Sie anschließend die Eigenschaften des Authentifizierungsanbieters und geben Sie die Konfigurationsdetails für Ihr ADFS-Setup an.

Aktivieren Sie nach der Konfiguration den WS-Federation-Anbieter. Melden Sie sich dann ab und navigieren Sie zu `/admin`. Sie werden aufgefordert, sich bei Ihrem WS-Federation-Anbieter anzumelden.


---

# 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 dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter, and the optional `goal` query parameter:

```
GET https://docs.devolutions.net/powershell-universal/de/sicherheit/enterprise-security/ws-federation.md?ask=<question>&goal=<endgoal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is optional and describes the broader end goal you are ultimately trying to accomplish on behalf of the user. GitBook uses it to tailor the answer towards what is most useful for that goal.

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.
