Find-VPASTargetValue


Supported Environments:
SelfHosted
SharedServices
PCloudStandard


Synopsis:

COMPLETE CYBERARK QUERY


Description:

USE THIS FUNCTION TO SEARCH FOR A TARGET VALUE IN ALL ASSETS LIKE SAFES, ACCOUNTS, PLATFORMS, MEMBERS, ETC.


Syntax:

Find-VPASTargetValue -searchQuery <String> [-SkipSafes] [-SkipAccounts] [-SkipPlatforms] [-SkipEPVUsers] [-SkipEPVGroups] [-SkipApplications] [-SkipRoles] [-SkipIdentities] [-ExportToCSV] [-CSVDirectory <String>] [-token <Hashtable>] [<CommonParameters>]

Find-VPASTargetValue -InputParameters <Hashtable> [-token <Hashtable>] [<CommonParameters>]


Parameters:

-searchQuery <String>
Search string to find target resource via username, address, safe, platform, etc.

Required: true
Position: named
Default value:
Accept pipeline input: true (ByPropertyName)
Accept wildcard characters: false

-SkipSafes [<SwitchParameter>]
Flag to ignore safes, getting safe data will be skipped

Required: false
Position: named
Default value: False
Accept pipeline input: true (ByPropertyName)
Accept wildcard characters: false

-SkipAccounts [<SwitchParameter>]
Flag to ignore accounts, getting account data will be skipped

Required: false
Position: named
Default value: False
Accept pipeline input: true (ByPropertyName)
Accept wildcard characters: false

-SkipPlatforms [<SwitchParameter>]
Flag to ignore platforms, getting platform data will be skipped

Required: false
Position: named
Default value: False
Accept pipeline input: true (ByPropertyName)
Accept wildcard characters: false

-SkipEPVUsers [<SwitchParameter>]
Flag to ignore EPVUsers, getting EPVUser data will be skipped

Required: false
Position: named
Default value: False
Accept pipeline input: true (ByPropertyName)
Accept wildcard characters: false

-SkipEPVGroups [<SwitchParameter>]
Flag to ignore EPVGroups, getting EPVGroup data will be skipped

Required: false
Position: named
Default value: False
Accept pipeline input: true (ByPropertyName)
Accept wildcard characters: false

-SkipApplications [<SwitchParameter>]
Flag to ignore applications, getting applicationID data will be skipped

Required: false
Position: named
Default value: False
Accept pipeline input: true (ByPropertyName)
Accept wildcard characters: false

-SkipRoles [<SwitchParameter>]
Flag to ignore roles, getting role data will be skipped

Required: false
Position: named
Default value: False
Accept pipeline input: true (ByPropertyName)
Accept wildcard characters: false

-SkipIdentities [<SwitchParameter>]
Flag to ignore identities, getting identity data will be skipped

Required: false
Position: named
Default value: False
Accept pipeline input: true (ByPropertyName)
Accept wildcard characters: false

-ExportToCSV [<SwitchParameter>]
Output results to a CSV file found in AppData\Local\VPASModuleOutputs directory

Required: false
Position: named
Default value: False
Accept pipeline input: true (ByPropertyName)
Accept wildcard characters: false

-CSVDirectory <String>
Output directory where the exported CSV file will be saved to
Default value: C:\Users\{CurrentUser}\AppData\Local\VPASModuleOutputs\ExportedCSVs

Required: false
Position: named
Default value:
Accept pipeline input: true (ByPropertyName)
Accept wildcard characters: false

-InputParameters <Hashtable>
HashTable of values containing the parameters required to make the API call

Required: true
Position: named
Default value:
Accept pipeline input: true (ByPropertyName)
Accept wildcard characters: false

-token <Hashtable>
HashTable of data containing various pieces of login information (PVWA, LoginToken, HeaderType, etc).
If -token is not passed, function will use last known hashtable generated by New-VPASToken

Required: false
Position: named
Default value:
Accept pipeline input: true (ByPropertyName)
Accept wildcard characters: false

<CommonParameters>
This cmdlet supports the common parameters: Verbose, Debug
ErrorAction, ErrorVariable, WarningAction, WarningVariable
OutBuffer, PipelineVariable, and OutVariable. For more information, see
about_CommonParameters (https:/go.microsoft.com/fwlink/?LinkID=113216)


Examples:

$Output = Find-VPASTargetValue -searchQuery {SEARCHQUERY VALUE}

$InputParameters = @{
        searchQuery = $true|$false
         SkipSafes = $true|$false
         SkipAccounts = $true|$false
         SkipPlatforms = $true|$false
         SkipEPVUsers = $true|$false
         SkipEPVGroups = $true|$false
         SkipApplications = $true|$false
         SkipRoles = $true|$false
         SkipIdentities = $true|$false
         ExportToCSV = $true|$false
         CSVDirectory = "C:\Temp"
}
$Output = Find-VPASTargetValue -InputParameters $InputParameters


Outputs:

If successful:
{
         ...
         (
         ExtraInfo @{safeNumber=124; location=\; creator=; olacEnabled=False; numberOfVersionsRetention=; numberOfDaysRetention=7;...
                 Condition vadim matched on safe creator: vadim@vman.com
                 Asset Safe
                 Value testsafe001
                 ),
                 ...
        }
        

$false if failed