Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

CopyKeys - Does not detect VM with encryption because VM extension name is hardcoded #33

Open
o-l-a-v opened this issue Nov 20, 2024 · 0 comments · May be fixed by #34
Open

CopyKeys - Does not detect VM with encryption because VM extension name is hardcoded #33

o-l-a-v opened this issue Nov 20, 2024 · 0 comments · May be fixed by #34

Comments

@o-l-a-v
Copy link

o-l-a-v commented Nov 20, 2024

The CopyKeys script does not detect a VM with encryption because it checks for the VM encryption extension with a hardcoded name.

Hardcoded extension name:

Check for eligible VM:

  • foreach ($Item in $VmList)
    {
    if (($null -ne $Item.Extensions -and $Item.Extensions.Count -gt 0) -and
    ($Item.Extensions.Id | ForEach-Object { `
    $_.split('/')[-1].tolower().contains( `
    [ConstantStrings]::adeExtensionPrefix)}) -contains $true)
    {
    $SuppressOutput = $VmListBox.Items.Add($Item.Name)
    }
    }
@o-l-a-v o-l-a-v linked a pull request Nov 20, 2024 that will close this issue
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant