Skip to content

Cmdlet Module for encryption of data where language has been constrained so you can't use .Net methods directly

Notifications You must be signed in to change notification settings

stephenconnolly1/PSFileEncryption

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

14 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

PowerShell fileEncryption module

A PowerShell module to perform symmetric AES based file encryption and decryption using a key derived from a user-provided password

The module is designed to work in Constrained PowerShell Language environments where native methods of .NET objects is forbidden. The module is therefore written in C# code and compiled

Build instructions

It is possible to build the module locally using the provided build.ps1 file. The script will compile the single code file into DLL and will attempt to place that in the user's PowerShell module folder within their profile, so no system-level access is required to install the module.

To build the module

  • From GitHub, download the source code as a .zip file.

  • Right Click the downloaded zip file and select Properties.

  • On the General tab check Unblock and click OK.

  • Right Click the .zip file and select Extract All....

  • Open a Windows DOS command prompt and change directory to the directory containing the downloaded code

  • Run the following command

    powershell -nologo -noprofile -executionPolicy bypass -file build.ps1

  • The module will be built and copied into a folder within the user's $PSModulePath

  • Open a PowerShell window and type Get-Module -ListAvailable. The FileEncryption module should be listed.

Usage

    Import-Module FileEncryption
    $Password = Read-Host -AsSecureString
    Encrypt-File -InputFile infile -OutputFile outfile -Password $Password
    Decrypt-File -InputFile infile -OutputFile outfile -Password $Password

About

Cmdlet Module for encryption of data where language has been constrained so you can't use .Net methods directly

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published