From 9ff01614fb9b86668875e8607a4de677d82e34e6 Mon Sep 17 00:00:00 2001 From: CodyCarey2026 Date: Wed, 30 Sep 2026 11:50:35 -0500 Subject: [PATCH 1/8] Add step to locate Windows assemblies in build workflow Added a step to locate required Windows assemblies for Group Policy and Bitlocker. --- .github/workflows/build.yml | 16 +++++++++++++++- 1 file changed, 15 insertions(+), 1 deletion(-) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index e3230f0..8334663 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -27,7 +27,21 @@ jobs: - name: Install .NET Framework 4.5.2 Developer Pack run: choco install netfx-4.5.2-devpack -y - + + - name: Locate required Windows assemblies + shell: powershell + run: | + Write-Host "=== Group Policy ===" + Get-ChildItem "C:\" -Recurse -ErrorAction SilentlyContinue ` + -Filter "Microsoft.GroupPolicy.Management.dll" | + Select-Object -ExpandProperty FullName + + Write-Host "=== Bitlocker ===" + Get-ChildItem "C:\Windows\System32\WindowsPowerShell\v1.0\Modules" ` + -Recurse -ErrorAction SilentlyContinue ` + -Filter "Microsoft.BitLocker.Structures.dll" | + Select-Object -ExpandProperty FullName + - name: Build solution run: msbuild AutomateBitlockerPlugin\AutomateBitlockerPlugin.csproj /p:Configuration=Release From a07ad2f39dd53cf94d00645c5d8567ec7517c086 Mon Sep 17 00:00:00 2001 From: CodyCarey2026 Date: Wed, 30 Sep 2026 12:12:44 -0500 Subject: [PATCH 2/8] Update workflow to prepare Windows build dependencies Updated build workflow to prepare Windows build dependencies and copy required assemblies. --- .github/workflows/build.yml | 32 +++++++++++++++++++------------- 1 file changed, 19 insertions(+), 13 deletions(-) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 8334663..1c025c9 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -27,23 +27,29 @@ jobs: - name: Install .NET Framework 4.5.2 Developer Pack run: choco install netfx-4.5.2-devpack -y - - - name: Locate required Windows assemblies + + - name: Prepare Windows build dependencies shell: powershell run: | - Write-Host "=== Group Policy ===" - Get-ChildItem "C:\" -Recurse -ErrorAction SilentlyContinue ` - -Filter "Microsoft.GroupPolicy.Management.dll" | - Select-Object -ExpandProperty FullName - - Write-Host "=== Bitlocker ===" - Get-ChildItem "C:\Windows\System32\WindowsPowerShell\v1.0\Modules" ` - -Recurse -ErrorAction SilentlyContinue ` - -Filter "Microsoft.BitLocker.Structures.dll" | - Select-Object -ExpandProperty FullName + New-Item -ItemType Directory -Force -Path "$env:GITHUB_WORKSPACE\build-deps" + + $groupPolicy = Get-ChildItem "C:\Windows\WinSxS" -Recurse -ErrorAction Stop ` + -Filter "Microsoft.GroupPolicy.Management.dll" | + Select-Object -First 1 + + $bitLocker = Get-ChildItem "C:\Windows\System32\WindowsPowerShell\v1.0\Modules\BitLocker" + -Recurse -ErrorAction Stop ` + -Filter "Microsoft.BitLocker.Structures.dll" | + Select-Object -First 1 + + Copy-Item $groupPolicy.FullName "$env:GITHUB_WORKSPACE\build-deps\Microsoft.GroupPolicy.Management.dll" + Copy-Item $bitLocker.FullName "$env:GITHUB_WORKSPACE\build-deps\Microsoft.BitLocker.Structures.dll" + + Get-ChildItem "$env:GITHUB_WORKSPACE\build-deps" + - name: Build solution - run: msbuild AutomateBitlockerPlugin\AutomateBitlockerPlugin.csproj /p:Configuration=Release + run: msbuild AutomateBitlockerPlugin\AutomateBitlockerPlugin.csproj /p:Configuration=Release /p:ReferencePath="${{ github.workspace }}\build-deps" - name: Upload compiled plugin uses: actions/upload-artifact@v4 From ace0eaef9d717b64114bbba18824551704742058 Mon Sep 17 00:00:00 2001 From: CodyCarey2026 Date: Wed, 30 Sep 2026 12:18:24 -0500 Subject: [PATCH 3/8] Fix formatting of BitLocker module retrieval command --- .github/workflows/build.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 1c025c9..bfc24bf 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -37,7 +37,7 @@ jobs: -Filter "Microsoft.GroupPolicy.Management.dll" | Select-Object -First 1 - $bitLocker = Get-ChildItem "C:\Windows\System32\WindowsPowerShell\v1.0\Modules\BitLocker" + $bitLocker = Get-ChildItem "C:\Windows\System32\WindowsPowerShell\v1.0\Modules\BitLocker" ` -Recurse -ErrorAction Stop ` -Filter "Microsoft.BitLocker.Structures.dll" | Select-Object -First 1 From 22c351783d84d37e2a2dba7b58e9cb74e5f56d3b Mon Sep 17 00:00:00 2001 From: CodyCarey2026 Date: Wed, 30 Sep 2026 12:27:52 -0500 Subject: [PATCH 4/8] Modify Windows Dependency preparation to use correct group policy --- .github/workflows/build.yml | 1 + 1 file changed, 1 insertion(+) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index bfc24bf..01e8ac7 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -35,6 +35,7 @@ jobs: $groupPolicy = Get-ChildItem "C:\Windows\WinSxS" -Recurse -ErrorAction Stop ` -Filter "Microsoft.GroupPolicy.Management.dll" | + Where-Object { $_.FullName -like "*10.0.26100.1*" } | Select-Object -First 1 $bitLocker = Get-ChildItem "C:\Windows\System32\WindowsPowerShell\v1.0\Modules\BitLocker" ` From 749728186157a0913a070c29efd0dad9074ca4cd Mon Sep 17 00:00:00 2001 From: Cody Carey Date: Wed, 30 Sep 2026 12:44:21 -0500 Subject: [PATCH 5/8] Update: Updated BitLocker and GroupPolicy Hintpaths --- .../AutomateBitlockerPlugin.csproj | 17 +++++++++-------- 1 file changed, 9 insertions(+), 8 deletions(-) diff --git a/AutomateBitlockerPlugin/AutomateBitlockerPlugin.csproj b/AutomateBitlockerPlugin/AutomateBitlockerPlugin.csproj index 6f10e57..e82d4e7 100644 --- a/AutomateBitlockerPlugin/AutomateBitlockerPlugin.csproj +++ b/AutomateBitlockerPlugin/AutomateBitlockerPlugin.csproj @@ -44,14 +44,15 @@ ..\References\Interfaces.dll - - ..\..\..\..\..\Windows\SysWOW64\WindowsPowerShell\v1.0\Modules\BitLocker\Microsoft.BitLocker.Structures.dll - False - - - True - False - + + ..\build-deps\Microsoft.BitLocker.Structures.dll + False + + + ..\build-deps\Microsoft.GroupPolicy.Management.dll + True + False + False False From 78ef0bd4f1c7a35d73269e4e09c072ddcea87cd7 Mon Sep 17 00:00:00 2001 From: CodyCarey2026 Date: Wed, 30 Sep 2026 12:51:17 -0500 Subject: [PATCH 6/8] Update GroupPolicy.Management reference in project file --- AutomateBitlockerPlugin/AutomateBitlockerPlugin.csproj | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/AutomateBitlockerPlugin/AutomateBitlockerPlugin.csproj b/AutomateBitlockerPlugin/AutomateBitlockerPlugin.csproj index e82d4e7..4075b81 100644 --- a/AutomateBitlockerPlugin/AutomateBitlockerPlugin.csproj +++ b/AutomateBitlockerPlugin/AutomateBitlockerPlugin.csproj @@ -48,7 +48,8 @@ ..\build-deps\Microsoft.BitLocker.Structures.dll False - + + False ..\build-deps\Microsoft.GroupPolicy.Management.dll True False @@ -221,4 +222,4 @@ - \ No newline at end of file + From 932e7ddcd3c009a1e6c437095e2168ba512a7f72 Mon Sep 17 00:00:00 2001 From: CodyCarey2026 Date: Wed, 30 Sep 2026 13:01:19 -0500 Subject: [PATCH 7/8] Add installation step for Group Policy Management --- .github/workflows/build.yml | 15 +++++++++------ 1 file changed, 9 insertions(+), 6 deletions(-) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 01e8ac7..3a1efe0 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -1,3 +1,4 @@ + name: Build Plugin on: @@ -27,25 +28,27 @@ jobs: - name: Install .NET Framework 4.5.2 Developer Pack run: choco install netfx-4.5.2-devpack -y + + - name: Install Group Policy Management + shell: powershell + run: Install-WindowsFeature -Name GPMC -IncludeManagementTools - name: Prepare Windows build dependencies shell: powershell run: | New-Item -ItemType Directory -Force -Path "$env:GITHUB_WORKSPACE\build-deps" - $groupPolicy = Get-ChildItem "C:\Windows\WinSxS" -Recurse -ErrorAction Stop ` - -Filter "Microsoft.GroupPolicy.Management.dll" | - Where-Object { $_.FullName -like "*10.0.26100.1*" } | - Select-Object -First 1 + $groupPolicy = Get-ChildItem "C:\Windows" -Recurse -ErrorAction SilentlyContinue ` + -Filter "Microsoft.GroupPolicy.Management.dll" | + Select-Object -First 1 $bitLocker = Get-ChildItem "C:\Windows\System32\WindowsPowerShell\v1.0\Modules\BitLocker" ` -Recurse -ErrorAction Stop ` -Filter "Microsoft.BitLocker.Structures.dll" | Select-Object -First 1 - Copy-Item $groupPolicy.FullName "$env:GITHUB_WORKSPACE\build-deps\Microsoft.GroupPolicy.Management.dll" Copy-Item $bitLocker.FullName "$env:GITHUB_WORKSPACE\build-deps\Microsoft.BitLocker.Structures.dll" - + Copy-item $groupPolicy.FullName "$env:GITHUB_WORKSPACE\build-deps\Microsoft.GroupPolicy.Management.dll" Get-ChildItem "$env:GITHUB_WORKSPACE\build-deps" From 37857a5b555d6567561911c75c4be9b71d82c735 Mon Sep 17 00:00:00 2001 From: CodyCarey2026 Date: Wed, 30 Sep 2026 13:14:45 -0500 Subject: [PATCH 8/8] Update Group Policy to use specific version --- AutomateBitlockerPlugin/AutomateBitlockerPlugin.csproj | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/AutomateBitlockerPlugin/AutomateBitlockerPlugin.csproj b/AutomateBitlockerPlugin/AutomateBitlockerPlugin.csproj index 4075b81..b8108bc 100644 --- a/AutomateBitlockerPlugin/AutomateBitlockerPlugin.csproj +++ b/AutomateBitlockerPlugin/AutomateBitlockerPlugin.csproj @@ -49,13 +49,11 @@ False - False ..\build-deps\Microsoft.GroupPolicy.Management.dll True False - - False + False ..\References\Microsoft.GroupPolicy.ServerAdminTools.GpmgmtLib.dll