locked
Keep track of every command run in PowerShell and save them in a text file. RRS feed

  • Question

  • Hello team,

    I would like to find a way to log all commands that have been executed in a PowerShell session to a text file.

    For example, that the execution of dir or cd is recorded in a format that looks more or less like the following:

    Aug 8/7/2019 16:43 powershell[PID]: user <username> executed command dir.

    And so on with all commands.

    I'm trying to find a way to record those activities for purposes of integrating it into a cybersecurity tool.

    Greetings,

    Sergio.
    Wednesday, August 7, 2019 3:05 PM

All replies