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

Get-PASSafe -search xxx-sort asc fails #542

Open
begunrom opened this issue Jun 17, 2024 · 0 comments
Open

Get-PASSafe -search xxx-sort asc fails #542

begunrom opened this issue Jun 17, 2024 · 0 comments

Comments

@begunrom
Copy link

begunrom commented Jun 17, 2024

Get-PASSafe -search xxx-sort asc fails with

`Invoke-PASRestMethod : [400] Cannot sort by a property other than [safename, managingcpm].
At line:230 char:13

  • ... $result = Invoke-PASRestMethod -Uri $URI -Method GET -WebSession $S ...
    • CategoryInfo : NotSpecified: ({"ErrorCode":"P...managingcpm]."}:ErrorRecord) [Invoke-PASRestMethod], Exception
    • FullyQualifiedErrorId : PASWS014E,Invoke-PASRestMethod`

The parameters on the function force you to either select asc or desc, while the rest call expects safename or managingcpm

`PS C:\Users\adm-guro> Get-PASSafe -search XXX -sort managingcpm
Get-PASSafe : Cannot validate argument on parameter 'sort'. The argument "managingcpm" does not belong to the set "asc,desc" specified by the ValidateSet attribute. Supply an argument that is in the set and then try the command again.
At line:1 char:31

  • Get-PASSafe -search XXX -sort managingcpm
    • CategoryInfo : InvalidData: (:) [Get-PASSafe], ParameterBindingValidationException
    • FullyQualifiedErrorId : ParameterArgumentValidationError,Get-PASSafe`

Your Environment

  • psPAS Version: v6.4.85
  • CyberArk Version: 14.0
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

No branches or pull requests

1 participant