I am afraid that you will have to fall back towards the perl script to resolve this issue.
Curious: when we are passing the guest OS credentials (like root in the examples above) - is this communication over 443 (encrypted)?
If you connect with your vcenter with the HTTPS protocol this will be via port 443.
Connect-VIServer -Protocol HTTPS -server vcenter
For more information check out the Connect-VIServer cmdlet.
Retrieving data ...