Skip to content

Instantly share code, notes, and snippets.

@lap00zza
Created September 5, 2018 18:56
Show Gist options
  • Save lap00zza/8c9ee31431c464d46efc59047df4f13c to your computer and use it in GitHub Desktop.
Save lap00zza/8c9ee31431c464d46efc59047df4f13c to your computer and use it in GitHub Desktop.

Revisions

  1. lap00zza created this gist Sep 5, 2018.
    15 changes: 15 additions & 0 deletions defender_scan.sh
    Original file line number Diff line number Diff line change
    @@ -0,0 +1,15 @@
    #!/bin/sh
    # A simple shell wrapper for Windows Defender

    defender_path="/c/Program Files/Windows Defender/MpCmdRun.exe"

    if [ $1 == "--help" ]
    then
    echo "Usage:"
    echo " ./defender_scan /full/path/to/file_or_directory"
    echo "Note:"
    echo "- Don't end directory with /"
    echo "- Looks like symlinks cant be resolved"
    else
    "$defender_path" -Scan -ScanType 3 -File $1
    fi