MichaelGrafnetter/DSInternals

PWDump custom view issue when run under SYSTEM account

DiPersiaTech opened this issue · 4 comments

When running

Get-ADDBAccount -All -DBPath "$Path\Active Directory\ntds.dit" -BootKey $key | Format-Custom -View PWDump

under the system account context (Which our automation system does), the output is broken into multiple lines. For example -

User:2677:NO
LM-HASH**********************:1111111111111111111111111:::

Where output should show as a single line -
User2677:NO LM-HASH**********************:1111111111111111111111111::::

Can replicate this by starting Powershell using PSEXEC as the system.

Hello @DiPersiaTech , line wrapping depends solely on the configuration of your terminal window, which is profile-specific. You should be able to bypass it by piping the output to the Out-File cmdlet.

@MichaelGrafnetter thanks for the response. Same behavior actually, regardless of screen or file. I assumed the custom view had something to do with it and running under system. This is with the out-file

Get-ADDBAccount -All -DBPath "$Path\Active Directory\ntds.dit" -BootKey $key | Format-Custom -View PWDump | Out-File $Path\dump.txt -Force -Encoding ascii

Interesting. Looking into the source file, there is only a space.

I concur. That is weird. If/when you get time, can you try to replicate with psexec just so I can see if it's me or. . .?