Forum Discussion
Access to PS Remoting Client info in the constrained endpoint
Well, depends on what you have configured for the endpoint. You might want to add some specific cmdlets to the session config file, such as Get-ComputerInfo. Or expose the env: PsDrive, etc.
For scenarios like this, it's best to use something like certificate auth. IP, hostname, machine name - all can easily be changed/spoofed.
VasilMichev, thanks for the quick reply. If I expose Get-ComputerInfo cmdlet, it would give me the details of the endpoint host machine and not of the client, unless there's a way to have it executed on the client side, is there?
Being able to query client's IP and hostname, will allow me to perform additional checks from the endpoint host side to make sure that it was not spoofed.
I agree, that using something like a cert authentication would be much a better approach, but currently I can't figure out a way to securely inject a new cert into each new VM (I'm building them using MDT, btw).