Exporting specific session fields for a report
By default, the Centrify cmdlet for getting session information might return more information than you want for a simple report. If you want to narrow down the fields returned, you can use a native cmdlet, such as
Select-Object, to specify the fields of interest, then another native cmdlet, such as
Out-File, to export the results to a text file. For example, to limit the results to a few key fields, you might specify a command similar to this:
Get-CdaAuditSession -Installation "installation-name" | Select‑Object ‑Property User, Machine, StartTime, EndTime, State, | Out‑File c:\samplesession.txt
This example pipes the results from the Audit Module for PowerShell
Get‑CdaAuditSession cmdlet to the
Select-Object cmdlet, then uses another pipe to send the resulting output to a file.