I am setting up JEA for the first time and I am running into trouble with running custom .ps1 files. To test if it was .ps1 file I made another simple one that is just a write-host "hello" called hello.ps1. When I connect to the session and type
Hello.ps1 I receive the following error:
The term 'Hello.ps1' is not recognized as the name of a cmdlet, function, script file, or operable program. Check the spelling of the name, or if a path was included, verify that the path
is correct and try again.
+ CategoryInfo : ObjectNotFound: (Hello.ps1:String) [], CommandNotFoundException
+ FullyQualifiedErrorId : CommandNotFoundException
In the .psrc file I have:
VisibleExternalCommands = 'C:\Windows\System32\whoami.exe','C:\Program Files\WindowsPowerShell\Modules\JEA\Hello.ps1'
I have verified that whoami does work, so it looks like I have the .psrc file correctly configured. Since I only have permission to run the whoami I am also assuming I have the .pssc configured correctly.