pspete / psPAS

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

Code Runs but does not reach out to PVWA server and does nothing #399

Closed koushik2296 closed 2 years ago

koushik2296 commented 2 years ago

Describe the issue A concise summary of the issue Code runs without error . Trying to remove account if its not on domain. NO error in Code but any psPas function doesnt work. What could be the issue ? The psPAS is run from powershell CPM machine and not able to reach out to PVWA server . To Reproduce Steps to reproduce the behavior: 1. 2. 3.

Expected behavior A clear and concise description of what you expected to happen.

Screenshots & Console Output If applicable, add screenshots and/or console output to help explain your problem.


<--Console Output Goes Here-->

Your Environment Include relevant details about your environment

Additional context Add any other context about the problem here.

pspete commented 2 years ago

A quick look at the code provided shows it is using incompatible syntax for current module versions.

Do you see success with the following simplified version of your script:

$PVWAURL = 'https://Your.pvwa.server'
$VaultCredentials = Get-Credential
New-PASSession -Credential $VaultCredentials -BaseURI $PVWAURL -type LDAP
Get-PASAccount
koushik2296 commented 2 years ago

Yes that works

koushik2296 commented 2 years ago

I am able to reconcile an account as well, but the original code doesnt work

koushik2296 commented 2 years ago

If the account is disabled by CPM , does the -reconciletask work ?

pspete commented 2 years ago

Believe this provides a route to progressing from your reported issue and confirms the module works as expected. No updates or fixes are required to be applied to the module code, but your original script does need some attention.

koushik2296 commented 2 years ago

Got the Code working , Thank you ... The new module for the code needed modifications..