From 2b2a51dccc04814b3e18d83e0f78b2b367dac308 Mon Sep 17 00:00:00 2001 From: OneDeadMachine Date: Fri, 14 Aug 2026 15:26:27 +0300 Subject: [PATCH 1/2] =?UTF-8?q?feat:=20deliver=20Pair=20Repair=20Wizard=20?= =?UTF-8?q?v3.1=20beta=20/=20=D0=B2=D1=8B=D0=BF=D1=83=D1=81=D1=82=D0=B8?= =?UTF-8?q?=D1=82=D1=8C=20=D0=BC=D0=B0=D1=81=D1=82=D0=B5=D1=80=20=D0=BF?= =?UTF-8?q?=D0=B0=D1=80=D0=BD=D0=BE=D0=B3=D0=BE=20=D1=80=D0=B5=D0=BC=D0=BE?= =?UTF-8?q?=D0=BD=D1=82=D0=B0?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit RU: Добавлен рабочий WPF-мастер для доменного WinRM/Kerberos, live TLS pairing и подписанного offline-обмена. Реализованы общий диагностический план, host/client saga, явный abort, таймауты, точечные Firewall/SMB/RPC/Spooler/queue/ACL действия, интерактивный контекст доменного клиента, Credential Manager и физическая тестовая страница. Обновлены privacy/security/architecture, beta template и двуязычные руководства. EN: Add a functional WPF wizard for domain WinRM/Kerberos, live TLS pairing, and signed offline exchange. Implement shared diagnostics, host/client saga, explicit aborts, timeouts, narrow Firewall/SMB/RPC/Spooler/queue/ACL actions, the domain client's interactive context, Credential Manager, and physical test-page verification. Update privacy/security/architecture, beta reporting, and bilingual guides. --- .github/ISSUE_TEMPLATE/beta-report.yml | 4 +- CODE_SIGNING_POLICY.md | 15 + PRIVACY.md | 2 + README.md | 7 +- SECURITY.md | 2 + docs/architecture.en.md | 16 + docs/architecture.md | 17 + docs/pair-repair.en.md | 39 ++ docs/pair-repair.md | 39 ++ docs/releases/v3.1.0-beta.1.md | 31 + src/W-Fix.App/App.xaml.cs | 25 + src/W-Fix.App/MainWindow.xaml | 7 +- src/W-Fix.App/MainWindow.xaml.cs | 7 + src/W-Fix.App/PairRepairWindow.xaml | 213 +++++++ src/W-Fix.App/PairRepairWindow.xaml.cs | 67 +++ .../ViewModels/PairRepairViewModel.cs | 528 ++++++++++++++++++ src/W-Fix.App/W-Fix.App.csproj | 2 +- .../Abstractions/PairRepairContracts.cs | 2 + src/W-Fix.Core/Models/PairRepairModels.cs | 5 +- src/W-Fix.Core/Pairing/PairDiagnostics.cs | 14 + .../Pairing/PairInventoryService.cs | 19 +- .../Pairing/PairInvitationValidator.cs | 3 + .../Pairing/PairProtocolSerializer.cs | 22 +- src/W-Fix.Core/Pairing/PairRepairActions.cs | 61 +- src/W-Fix.Core/Pairing/PairRepairExecutor.cs | 11 +- src/W-Fix.Core/Pairing/PairRepairPlanner.cs | 1 + .../Pairing/PairSessionActionDispatcher.cs | 52 +- .../Pairing/TlsPairSessionTransport.cs | 17 +- src/W-Fix.Core/W-Fix.Core.csproj | 2 +- tests/W-Fix.Core.Tests/PairRepairCoreTests.cs | 50 +- 30 files changed, 1239 insertions(+), 41 deletions(-) create mode 100644 docs/pair-repair.en.md create mode 100644 docs/pair-repair.md create mode 100644 docs/releases/v3.1.0-beta.1.md create mode 100644 src/W-Fix.App/PairRepairWindow.xaml create mode 100644 src/W-Fix.App/PairRepairWindow.xaml.cs create mode 100644 src/W-Fix.App/ViewModels/PairRepairViewModel.cs diff --git a/.github/ISSUE_TEMPLATE/beta-report.yml b/.github/ISSUE_TEMPLATE/beta-report.yml index d0aaacd..d12970e 100644 --- a/.github/ISSUE_TEMPLATE/beta-report.yml +++ b/.github/ISSUE_TEMPLATE/beta-report.yml @@ -13,7 +13,7 @@ body: id: version attributes: label: W-Fix version / Версия W-Fix - placeholder: v3.0.0-beta.1 + placeholder: v3.1.0-beta.1 validations: required: true - type: dropdown @@ -35,6 +35,8 @@ body: - Local repair / Локальный ремонт - Active Directory domain - Workgroup / Одноранговая сеть + - Pair Repair live / Парный ремонт по сети + - Pair Repair offline / Парный ремонт через файлы validations: required: true - type: textarea diff --git a/CODE_SIGNING_POLICY.md b/CODE_SIGNING_POLICY.md index 3a82766..a9efb16 100644 --- a/CODE_SIGNING_POLICY.md +++ b/CODE_SIGNING_POLICY.md @@ -28,3 +28,18 @@ Free code signing provided by [SignPath.io](https://signpath.io/), certificate b Until SignPath approval, public beta releases remain explicitly marked unsigned and include SHA-256 checksums. For internal testing, a separately documented self-signed certificate may be trusted manually on managed test computers; it is never presented as publicly trusted. See also [Privacy Policy](PRIVACY.md) and [Security Policy](SECURITY.md). + +## One-time catalog key bootstrap / Первичная настройка ключа каталога + +Владелец релиза выполняет это локально один раз. Закрытый файл не коммитится и удаляется сразу после записи секрета: + +```powershell +dotnet run --project tools/W-Fix.CatalogSigner -- generate private.pem public.pem +Get-Content private.pem -Raw | gh secret set KNOWN_ISSUES_PRIVATE_KEY_PEM --repo OneDeadMachine-Dev/W-FIX +Copy-Item public.pem src/W-Fix.Core/Catalog/known-issues-public.pem +Remove-Item private.pem, public.pem -Force +``` + +После обновления публичного ключа требуется обычный PR и проверка `verify` на тестовой подписи. SignPath identifiers добавляются как repository variables, а `SIGNPATH_API_TOKEN` — только как Environment secret `release`. Окружение `release` требует ручного подтверждения владельца и принимает только теги `v*`. + +The release owner performs this once on a trusted local machine. The private file is never committed and is deleted immediately after the secret is stored. Updating the public key requires a normal PR and a test `verify` run. SignPath identifiers are repository variables; `SIGNPATH_API_TOKEN` is restricted to the `release` Environment secret. The `release` environment requires manual owner approval and accepts only `v*` tags. diff --git a/PRIVACY.md b/PRIVACY.md index 7f4c773..71defbf 100644 --- a/PRIVACY.md +++ b/PRIVACY.md @@ -10,6 +10,7 @@ W-Fix не содержит телеметрии, рекламы и автома - Альтернативные учётные данные сохраняются только после явного согласия в Windows Credential Manager. Пароли не записываются в конфигурацию, аргументы процессов, логи и отчёты. - При диагностике W-Fix может загрузить декларативный каталог известных проблем с официального GitHub Release проекта. Загруженный каталог проверяется цифровой подписью и не может содержать исполняемый код. - W-Fix не передаёт сведения третьим лицам, если пользователь сам не экспортировал и не отправил отчёт или support bundle. +- Pair Repair обменивается данными только между двумя явно выбранными ПК. Приглашение и offline-снимок не содержат паролей; live-listener и временное правило Firewall удаляются после сессии. Сообщить о проблеме конфиденциальности можно через [Private vulnerability reporting](https://github.com/OneDeadMachine-Dev/W-FIX/security/advisories/new). @@ -23,5 +24,6 @@ W-Fix contains no telemetry, advertising, or automatic report uploads. It operat - Alternate credentials are saved only with explicit consent in Windows Credential Manager. Passwords are never written to configuration, process arguments, logs, or reports. - During diagnostics W-Fix may download a declarative known-issues catalog from the project's official GitHub Release. The catalog is signature-verified and cannot contain executable code. - W-Fix sends no information to third parties unless the user explicitly exports and shares a report or support bundle. +- Pair Repair exchanges data only between two explicitly selected PCs. Invitations and offline snapshots contain no passwords; the live listener and temporary Firewall rule are removed after the session. Report a privacy concern through [Private vulnerability reporting](https://github.com/OneDeadMachine-Dev/W-FIX/security/advisories/new). diff --git a/README.md b/README.md index 9dad730..f2cc9d3 100644 --- a/README.md +++ b/README.md @@ -8,7 +8,7 @@ [![Platform](https://img.shields.io/badge/platform-Windows%2010%2F11-blue?logo=windows)](https://www.microsoft.com/windows) [![.NET](https://img.shields.io/badge/.NET-8.0-purple?logo=dotnet)](https://dotnet.microsoft.com/) -[![Release](https://img.shields.io/badge/version-3.0.0--beta.1-blue)](https://github.com/OneDeadMachine-Dev/W-FIX/releases) +[![Release](https://img.shields.io/badge/version-3.1.0--beta.1-blue)](https://github.com/OneDeadMachine-Dev/W-FIX/releases) [![License](https://img.shields.io/badge/license-MIT-orange)](LICENSE) [![Author](https://img.shields.io/badge/author-OneDeadMachine-red)](https://github.com/OneDeadMachine) @@ -45,6 +45,7 @@ ### Плюс: - 🌐 **Remote Repair Center v3** — несколько доменных ПК, preflight, инвентаризация, автоматический план, проверка и изолированный rollback +- 🔗 **Pair Repair Wizard v3.1** — ремонт общего принтера между двумя ПК: TLS pairing, общий диагноз, двусторонний rollback и offline fallback - 🧠 **Диагностические правила** — вывод по наблюдаемым фактам, уверенность и официальный источник известной проблемы - 🔐 **Credential Manager** — альтернативная доменная учётная запись без пароля в конфигурации, CLI или логах - 📊 **Отчёты** — JSON/HTML для каждого запуска и обезличенный ZIP support bundle @@ -70,6 +71,8 @@ 3. Запусти **Диагностику**, проверь факты и сформированный план. 4. Подтверди пакетный ремонт. Сбой одной машины не останавливает остальные; обратимые шаги неуспешной цели откатываются. +Если общий принтер подключён к другому ПК, открой **Pair Repair** на обеих машинах. Хост создаёт одноразовый `.wfixpair`, оба пользователя сверяют код, а клиент формирует и выполняет общий план. Подробная инструкция: [Pair Repair на русском](docs/pair-repair.md) / [English guide](docs/pair-repair.en.md). + > ⚠️ Права администратора обязательны — фиксеры изменяют реестр и службы Windows. --- @@ -111,6 +114,7 @@ W-Fix/ │ │ ├── Remote/ # WinRM preflight и инвентаризация │ │ ├── Diagnostics/ # Evidence-based правила │ │ ├── Repair/ # Планировщик, legacy-адаптер и batch executor +│ │ ├── Pairing/ # TLS pairing, SMB/RPC diagnostics и двухузловая saga │ │ ├── Catalog/ # Подписанный каталог Windows known issues │ │ ├── Fixers/ # 12 фиксеров (FixerBase → IFixer) │ │ ├── Services/ @@ -123,6 +127,7 @@ W-Fix/ │ └── W-Fix.App/ # WPF UI (MVVM + CommunityToolkit) │ ├── ViewModels/ │ ├── RemoteCenterWindow.xaml +│ ├── PairRepairWindow.xaml │ ├── Views/ │ └── Assets/icon.ico └── publish/W-Fix.exe # Готовый портативный файл diff --git a/SECURITY.md b/SECURITY.md index ec3d991..db7eda1 100644 --- a/SECURITY.md +++ b/SECURITY.md @@ -18,5 +18,7 @@ Include the W-Fix version, Windows version, expected and actual behavior, and mi - W-Fix требует административных прав, потому что изменяет службы, реестр, политики печати и драйверы. - Remote Center выполняет действия только на явно выбранных целях. +- Pair Repair использует TLS 1.2+, временный ECDSA-ключ, pinning, одинаковый код и подтверждение на обоих ПК. По каналу разрешены только типизированные DTO и встроенные `pair.*` действия. +- Pair listener не открывается на Public-профиле; SMB1 не поддерживается. - Загружаемый known-issues catalog декларативен, подписан ECDSA и ссылается только на встроенные действия. - Private keys, GitHub tokens and SignPath tokens must never be committed to the repository. diff --git a/docs/architecture.en.md b/docs/architecture.en.md index 0fab4ac..2d99485 100644 --- a/docs/architecture.en.md +++ b/docs/architecture.en.md @@ -23,3 +23,19 @@ short-lived `PSCredential`; it is never embedded in a PowerShell script, process The known-issues catalog is declarative. A valid ECDSA signature does not grant code execution: catalog entries can only reference action IDs compiled into W-Fix. Microsoft source URLs are restricted to `learn.microsoft.com` and `support.microsoft.com`. + +## Pair Repair v3.1 pipeline + +`IPairSessionTransport` creates a one-time TLS session with a temporary ECDSA P-256 certificate. The client checks +the public-key pin from `.wfixpair`; both windows show the derived six-digit code, and application messages remain +blocked until both users approve. The protocol accepts only versioned DTOs and built-in `pair.*` identifiers. It +cannot carry PowerShell source or passwords. + +`IPairInventoryService` checks only the explicitly named peer. `IPairRepairExecutor` runs the shared plan as a +two-node saga: remote host steps go through `PairAgentCommandLoop`, while client steps use the local dispatcher. +Every mutation has a checkpoint. Failure, cancellation, timeout, or connection loss triggers reverse rollback and +an explicit `abort`; `commit` is sent only after every verification passes. + +The host Firewall lease is scoped to the current executable, exact port, `LocalSubnet`, and Private/Domain profiles. +Offline ECDSA-signed snapshots detect tampering, but each side repairs independently and therefore cannot offer +cross-machine automatic rollback. A `HOST\\User` password is written directly to Windows Credential Manager. diff --git a/docs/architecture.md b/docs/architecture.md index b381ab4..3a38614 100644 --- a/docs/architecture.md +++ b/docs/architecture.md @@ -11,6 +11,7 @@ - `W-Fix.Core.Diagnostics` — правила, формирующие находки только из наблюдаемых фактов. - `W-Fix.Core.Repair` — планирование, адаптер двенадцати v2-фиксеров и ограниченное пакетное выполнение. - `W-Fix.Core.Catalog` — встроенный и подписанный онлайн-каталог известных проблем Windows. +- `W-Fix.Core.Pairing` — TLS-транспорт, подписанный offline-обмен, парная диагностика и двухузловая saga. UI не должен самостоятельно определять успешность системной команды. Источником истины является `PowerShellExecutionResult`, а итог многошагового фиксера вычисляется из результатов всех выполненных шагов. @@ -95,6 +96,22 @@ PowerShell Remoting выполняет команды в сервисном ко Каталог известных проблем декларативен и не содержит скриптов. Даже корректно подписанная запись может выбрать только действие, уже скомпилированное и зарегистрированное в W-Fix. +## Конвейер Pair Repair v3.1 + +`IPairSessionTransport` создаёт одноразовую TLS-сессию с временным ECDSA P-256 сертификатом. Клиент проверяет +pin публичного ключа из `.wfixpair`, оба окна показывают вычисленный шестизначный код, а прикладные сообщения +разрешаются только после двух подтверждений. Протокол принимает только версионированные DTO и встроенные +идентификаторы `pair.*`; строки PowerShell и пароли через него не передаются. + +`IPairInventoryService` проверяет только явно названного соседа. `IPairRepairExecutor` выполняет общий план как +двухузловую saga: remote host-side шаги проходят через `PairAgentCommandLoop`, local client-side шаги выполняются +локальным dispatcher. До каждого изменения создаётся checkpoint. Ошибка, отмена, timeout или потеря соединения +вызывают обратный rollback и явный `abort`; `commit` отправляется только после повторной проверки всех шагов. + +На хосте действует временное Firewall-правило для текущего EXE, точного порта, `LocalSubnet` и Private/Domain. +В offline-режиме ECDSA-подписанный снимок защищён от изменения, но обе стороны ремонтируются раздельно, поэтому +общий автоматический rollback недоступен. Пароль `HOST\\User` сохраняется напрямую в Windows Credential Manager. + ## Риски и подтверждения - `Reversible` — обычное подтверждение плана и обязательный снимок. diff --git a/docs/pair-repair.en.md b/docs/pair-repair.en.md new file mode 100644 index 0000000..66185ed --- /dev/null +++ b/docs/pair-repair.en.md @@ -0,0 +1,39 @@ +# Pair Repair Wizard v3.1 + +Pair Repair fixes a shared printer between two explicitly selected PCs. It is neither a network scanner nor a persistent agent: W-Fix checks only the named peer and removes its temporary listener after the PairRun. + +In a domain, Host and Client can be entered in one window. W-Fix uses the current Kerberos identity and existing WinRM transport. Queue connection and test-page operations run in the signed-in Client user's session through a temporary Task Scheduler job instead of the administrator service account's HKCU. + +## Live mode + +1. Run W-Fix as administrator on both PCs. +2. On the PC physically hosting the printer, open **Pair Repair**, choose **Host**, and enter the client name and exact local printer name. +3. Create and save a `.wfixpair` invitation. It expires after 15 minutes and is accepted once. +4. Select **Wait for client**. On the other PC choose **Client** and open the invitation. +5. Compare the six-digit code in both windows and approve on both PCs. Mutations remain disabled until dual approval succeeds. +6. The client gathers both snapshots and displays evidence plus the shared repair plan. Expert actions are excluded by default. +7. Execute the plan. Snapshots precede every mutation, verification determines success, and reversible steps roll back on both endpoints after a failure. +8. Send a Windows test page and confirm the physical output. + +The live session uses TLS 1.2/1.3, a temporary ECDSA P-256 certificate, and public-key pinning. Its temporary Firewall rule is restricted to the current executable, exact port, Private/Domain profiles, and `LocalSubnet`. A listener is never opened on a Public profile. + +## Workgroup credentials + +When Windows requires authentication, the client can save an existing `HOST\User` credential scoped to that host. The password goes directly to Windows Credential Manager and is excluded from PairRun, invitations, support bundles, and W-Fix logs. + +W-Fix never synchronizes primary-user passwords. SMB1 cannot be enabled. Insecure guest, disabled SMB signing, and reduced RPC protection remain expert-only actions with separate warnings and rollback. + +## Offline fallback + +If the live port is blocked, export a signed snapshot on one side and import it on the other. Each PC runs only its local plan. The file contains no credentials, but cross-machine automatic rollback is unavailable in offline mode. + +## Collected diagnostics + +- Windows version, domain/workgroup, and network profile; +- DNS for the selected peer, SMB 445, and RPC 135; +- Function Discovery, Spooler, and narrow Firewall rules; +- SMB signing, guest restrictions, and conflicting SMB sessions; +- shared queue, ShareName, driver, Point and Print, and RPC policies; +- PrintService/SMBClient errors without document names or content. + +PairRun reports are stored under `%ProgramData%\W-Fix\Runs\pair-`. diff --git a/docs/pair-repair.md b/docs/pair-repair.md new file mode 100644 index 0000000..8aee156 --- /dev/null +++ b/docs/pair-repair.md @@ -0,0 +1,39 @@ +# Pair Repair Wizard v3.1 + +Pair Repair устраняет проблемы общего принтера между двумя конкретными ПК. Это не сетевой сканер и не постоянный агент: W-Fix проверяет только указанного соседа и закрывает временный listener после PairRun. + +В домене можно указать Host и Client в одном окне: W-Fix использует текущую Kerberos-учётную запись и существующий WinRM-транспорт. Подключение очереди и тестовая страница выполняются во вошедшем интерактивном сеансе Client через временную Task Scheduler задачу, а не в сервисном HKCU администратора. + +## Live-режим + +1. Запустите W-Fix от администратора на обоих ПК. +2. На ПК с физически подключённым принтером откройте **Pair Repair**, выберите **Хост**, укажите имя клиента и точное имя локального принтера. +3. Создайте и сохраните приглашение `.wfixpair`. Оно действует 15 минут и используется один раз. +4. Нажмите **Ждать подключение**. На клиенте выберите **Клиент** и откройте приглашение. +5. Сверьте шестизначный код в обоих окнах и подтвердите его на обеих машинах. До двойного подтверждения изменения запрещены. +6. Клиент соберёт снимки обеих сторон и покажет доказательства и общий план. Экспертные действия по умолчанию исключены. +7. Запустите план. Снимки создаются до первого изменения; успех определяется повторной проверкой. При сбое обратимые шаги откатываются на обеих сторонах. +8. Отправьте Windows test page и подтвердите физическую печать. + +Live-сессия использует TLS 1.2/1.3, временный ECDSA P-256 сертификат и pinning публичного ключа. Временное Firewall-правило ограничено текущим EXE, портом, профилями Private/Domain и `LocalSubnet`. На Public-профиле listener не открывается. + +## Workgroup и учётные данные + +Если Windows требует аутентификацию, на клиенте можно сохранить существующую `HOST\User` только для выбранного хоста. Пароль передаётся Windows Credential Manager напрямую и не попадает в PairRun, приглашение, support bundle или лог W-Fix. + +W-Fix не делает пароли основных пользователей одинаковыми. SMB1 не включается. Insecure guest, отключение SMB signing и ослабление RPC доступны только в экспертном режиме с отдельным предупреждением и rollback. + +## Offline fallback + +Если live-порт заблокирован, экспортируйте подписанный снимок первой стороны и импортируйте его на второй. Каждый ПК выполняет только собственную часть плана. Файл не содержит credentials, но общий автоматический rollback между двумя машинами в этом режиме невозможен. + +## Что диагностируется + +- версия Windows, домен/workgroup и сетевой профиль; +- DNS выбранного соседа, SMB 445 и RPC 135; +- Function Discovery, Spooler и точечные правила Firewall; +- SMB signing, guest restrictions и конфликтующие SMB-сессии; +- общая очередь, ShareName, драйвер, Point and Print и RPC policies; +- события PrintService/SMBClient без имён и содержимого документов. + +Отчёты PairRun сохраняются в `%ProgramData%\W-Fix\Runs\pair-`. diff --git a/docs/releases/v3.1.0-beta.1.md b/docs/releases/v3.1.0-beta.1.md new file mode 100644 index 0000000..28e6e8c --- /dev/null +++ b/docs/releases/v3.1.0-beta.1.md @@ -0,0 +1,31 @@ +# W-Fix v3.1.0-beta.1 + +## RU + +Первый публичный beta-выпуск Pair Repair Wizard. + +- рабочий мастер ролей Host/Client, приглашения, проверки, общего плана, выполнения и физической проверки; +- live-канал TLS 1.2/1.3 с временным ECDSA-ключом, pinning и подтверждением одного кода на двух ПК; +- временное Firewall-правило только для Private/Domain, `LocalSubnet`, текущего EXE и одного порта; +- диагностика DNS, SMB, RPC, Function Discovery, Spooler, очереди, драйвера и политик Windows 10/11; +- реальные repair actions и двухузловой rollback; +- подписанный offline fallback без credentials; +- точечная `HOST\User` запись в Windows Credential Manager; +- SMB1 не поддерживается; ослабляющие безопасность действия остаются экспертными. + +Это beta: перед массовым применением проверьте Windows 10 → 11, Windows 11 → 10, домен и workgroup на лабораторных ПК. + +## EN + +The first public beta of Pair Repair Wizard. + +- functional Host/Client wizard covering invitation, checks, shared plan, execution, and physical verification; +- TLS 1.2/1.3 live channel with a temporary ECDSA key, pinning, and matching-code approval on both PCs; +- temporary Firewall rule scoped to Private/Domain, `LocalSubnet`, the current executable, and one port; +- DNS, SMB, RPC, Function Discovery, Spooler, queue, driver, and Windows 10/11 policy diagnostics; +- real repair actions with two-node rollback; +- signed credential-free offline fallback; +- host-scoped `HOST\User` entry in Windows Credential Manager; +- SMB1 is unsupported; security-reducing changes remain expert-only. + +This is a beta. Validate Windows 10 → 11, Windows 11 → 10, domain, and workgroup scenarios on lab PCs before broad use. diff --git a/src/W-Fix.App/App.xaml.cs b/src/W-Fix.App/App.xaml.cs index 1879de3..124eca9 100644 --- a/src/W-Fix.App/App.xaml.cs +++ b/src/W-Fix.App/App.xaml.cs @@ -8,6 +8,7 @@ using WFix.Core.Catalog; using WFix.Core.Diagnostics; using WFix.Core.Infrastructure; +using WFix.Core.Pairing; using WFix.Core.Remote; using WFix.Core.Repair; using WFix.Core.Reporting; @@ -60,6 +61,9 @@ protected override void OnStartup(StartupEventArgs e) public RemoteCenterWindow CreateRemoteCenterWindow() => Services.GetRequiredService(); + public PairRepairWindow CreatePairRepairWindow() => + Services.GetRequiredService(); + protected override void OnExit(ExitEventArgs e) { Log.Information("W-Fix завершён"); @@ -76,6 +80,7 @@ private static IServiceProvider ConfigureServices() services.AddSingleton(); services.AddSingleton(); services.AddSingleton(); + services.AddSingleton(); services.AddSingleton(); services.AddSingleton(); @@ -96,11 +101,31 @@ private static IServiceProvider ConfigureServices() services.AddSingleton(); services.AddSingleton(); + services.AddSingleton(); + services.AddSingleton(); + services.AddSingleton(); + services.AddSingleton(); + services.AddSingleton(); + services.AddSingleton(); + services.AddSingleton(); + services.AddSingleton(); + services.AddSingleton(); + services.AddSingleton(); + services.AddSingleton(); + services.AddSingleton(); + services.AddSingleton(); + services.AddSingleton(); + services.AddTransient(); + services.AddSingleton(); + services.AddSingleton(); + services.AddSingleton(); services.AddSingleton(); services.AddTransient(); + services.AddTransient(); services.AddSingleton(); services.AddTransient(); + services.AddTransient(); return services.BuildServiceProvider(new ServiceProviderOptions { diff --git a/src/W-Fix.App/MainWindow.xaml b/src/W-Fix.App/MainWindow.xaml index 0ff8354..2413a67 100644 --- a/src/W-Fix.App/MainWindow.xaml +++ b/src/W-Fix.App/MainWindow.xaml @@ -41,7 +41,7 @@ - + @@ -51,6 +51,9 @@