Disconnect-PAMSession
Ends the Harbor session, clearing the token and re-auth material from module memory. Safe to call when not connected.
Syntax
Section titled “Syntax”Disconnect-PAMSessionDescription
Section titled “Description”Drops this PowerShell session’s CyberArk connection (the one Connect-PAMSession opened) and the cached CPM list, and logs it. Nothing is sent to the vault and nothing on disk changes: a stored service-account secret stays where it is declared.
Examples
Section titled “Examples”Example 1
Section titled “Example 1”Disconnect-PAMSessionExample 2
Section titled “Example 2”Connect-PAMSession -ConfigProfile test; Get-PAMSafeRegister -Refresh; Disconnect-PAMSessionConnects, re-syncs the register from the vault, and disconnects again.
See also
Section titled “See also”- All Harbor Onboard cmdlets
- In PowerShell:
Get-Help Disconnect-PAMSession -Full
Covers Harbor Onboard 0.59.0 / Harbor Health 0.22.0. On an older release? Upgrading and the release notes list what changed.
