Keyfilegenerator.cmd -
:: Delete temp files del temp.random encoded.hex 2>nul
@echo off setlocal enabledelayedexpansion title Key File Generator :: User settings set OUTPUT_FILE=generated_key.key set KEY_SIZE=4096 keyfilegenerator.cmd
:: Use certutil to generate random bytes and encode to base64 certutil -rand %KEY_SIZE% > temp.random 2>nul certutil -encodehex temp.random encoded.hex 0x40000001 >nul :: Delete temp files del temp