Password authentication is required to log in to a Windows ECS. Therefore, you must use the key file used when you created the ECS to obtain the administrator password generated during ECS creation. The administrator user is Administrator or the user configured using Cloudbase-Init. This password is randomly generated, offering high security.
You can obtain the initial password for logging in to a Windows ECS through the management console or APIs. For details, see this section.
Call the password obtaining APIs to obtain the ciphertext password of the public key encrypted using RSA. The API URI is in the format "GET /v2/{tenant_id}/servers/{server_id}/os-server-password".
For instructions about how to call the APIs, see Retrieving the Password for Logging In to a Windows ECS (Native OpenStack API) in Elastic Cloud Server API Reference.
Use the private key file used when you created the ECS to decrypt the ciphertext password obtained in step 4.
openssl pkcs8 -topk8 -inform PEM -outform DER -in rsa_pem.key -out pkcs8_der.key -nocrypt