Skip to content

Static code analysis for powershell code through PSScript Analyzer

Notifications You must be signed in to change notification settings

cridin1/pwsh-static-analysis

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

38 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

pwsh-static-analyzer

syntax-analysis

Static code analysis for PowerShell code. Make sure you have installed PSScript Analyzer.

$>python .\analyzer.py --help
                                                                                            

 █▀▄ █   █ ▄▀▀ █▄█    ▄▀▀ ▀█▀ ▄▀▄ ▀█▀ █ ▄▀▀    ▄▀▄ █▄ █ ▄▀▄ █   ▀▄▀ ▄▀▀ █ ▄▀▀
 █▀  ▀▄▀▄▀ ▄██ █ █ ▀▀ ▄██  █  █▀█  █  █ ▀▄▄ ▀▀ █▀█ █ ▀█ █▀█ █▄▄  █  ▄██ █ ▄██



usage: analyzer.py [-h] [--SCRIPT_MODE] [--FROM_ESCAPE] [-v [V]]
                   [OUT_FILE] PS_PATH [GROUND_TRUTH]

Python NLP wrapper for powershell syntax analysis through PSScript Analyzer

positional arguments:
  OUT_FILE       Output csv file
  PS_PATH        CODE file path from the model
  GROUND_TRUTH   Ground truth text file path

options:
  -h, --help     show this help message and exit
  --SCRIPT_MODE  Multiple Scripts mode
  --FROM_ESCAPE  Output files from ESCAPE
  -v [V]         Verbose

In utils\analysis_classes.py, the analysis is extended to different error types.

Releases

No releases published

Packages

No packages published