pspete / psPAS

PowerShell module for CyberArk Privileged Access Security REST API
https://pspas.pspete.dev
MIT License
287 stars 90 forks source link

Add-PASSafeMember - unable to add : Level 1 - Authorize Account Request #417

Closed arkayali closed 1 year ago

arkayali commented 1 year ago

Describe the issue Add-PASSafeMember - doesn't add : Level 1 - Authorize Account Request (or Level 2), however, it works fine with "Access Safe without confirmation"

To Reproduce

$SafeOwner2 = [PSCustomObject]@{ UseAccounts = $true RetrieveAccounts = $true ListAccounts = $true AddAccounts = $true UpdateAccountContent = $true UpdateAccountProperties = $true InitiateCPMAccountManagementOperations = $true SpecifyNextAccountContent = $true RenameAccounts = $true DeleteAccounts = $true UnlockAccounts = $true ManageSafe = $true ManageSafeMembers = $true BackupSafe = $true ViewAuditLog = $true ViewSafeMembers = $true requestsAuthorizationLevel1 = $true AccessWithoutConfirmation = $true CreateFolders = $true DeleteFolders = $true MoveAccountsAndFolders = $true }

$SafeOwner2 |L -SafeName $safe.name -MemberName $safe.SafeOwner2 -UseGen1API

Expected behavior in Work Flow authorization, I need Level 1 to be added as a permission

Screenshots & Console Output image

Your Environment Include relevant details about your environment

PowerShell Version: 5 psPAS Version: 5.3.69 CyberArk Version: 11.5

pspete commented 1 year ago

requestsAuthorizationLevel1 & requestsAuthorizationLevel2 belong to the gen2 parameterset: https://pspas.pspete.dev/commands/Add-PASSafeMember#gen2-default

For gen1 use the RequestsAuthorizationLevel parameter per the documentation: https://pspas.pspete.dev/commands/Add-PASSafeMember#-requestsauthorizationlevel

arkayali commented 1 year ago

Hi @pspete Thank you so much .. seems I missed that