Skip to content

Comments

Copy-DbaDbMail: Enhance handling of dedicated admin connections#10155

Merged
potatoqualitee merged 1 commit intodevelopmentfrom
dac_Copy-DbaDbMail
Feb 13, 2026
Merged

Copy-DbaDbMail: Enhance handling of dedicated admin connections#10155
potatoqualitee merged 1 commit intodevelopmentfrom
dac_Copy-DbaDbMail

Conversation

@andreasjordan
Copy link
Collaborator

Type of Change

  • Bug fix (non-breaking change, fixes # )
  • New feature (non-breaking change, adds functionality, fixes # )
  • Breaking change (affects multiple commands or functionality, fixes # )
  • Ran manual Pester test and has passed (Invoke-ManualPester)
  • Adding code coverage to existing functionality
  • Pester test is included
  • If new file reference added for test, has is been added to github.com/dataplat/appveyor-lab ?
  • Unit test is included
  • Documentation
  • Build system

When opening a connection we test if we need a DAC and we test if we already have a DAC. We reuse a DAC when possible. We remember if we opened a DAC to later be able to close it.

Get-DecryptedObject needs two things:

  • A Dedicated Admin Connection (DAC) to select master.sys.syslnklgns
  • A WinRM connection to read "HKLM:\SOFTWARE\Microsoft\Microsoft SQL Server$serviceInstanceId\Security"

That's why Get-DecryptedObject needs $Credential which it used all the time, but the parameter was missing. So every command that calls Get-DecryptedObject needs $Credential as well.

@potatoqualitee potatoqualitee merged commit 899ea75 into development Feb 13, 2026
15 checks passed
@potatoqualitee potatoqualitee deleted the dac_Copy-DbaDbMail branch February 13, 2026 23:28
@potatoqualitee
Copy link
Member

nice! tks

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 this pull request may close these issues.

2 participants