📌 Use Case
When working with Oracle Integration Cloud (OIC), secure authentication often requires RSA private keys in PEM format. These keys are commonly used for:
- Uploading secrets into OCI Vault.
- Configuring OIC Functions with key-based authentication.
- Creating SFTP, REST, or API Connections in OIC that use private keys instead of passwords.
If you are on Windows, you can use the built-in OpenSSH ssh-keygen tool (available in Windows 10/11 CMD or PowerShell) to generate or reformat RSA private keys.
⚙️ Solution Steps (Windows CMD)
Step 1: Ensure OpenSSH is Installed
- Open Command Prompt.
- Run:
If you see a version (e.g.,ssh -VOpenSSH_for_Windows_8.x), you’re good to go.
If not, install OpenSSH from Windows Optional Features.
Step 2: Run the ssh-keygen Command in CMD
Use the following command to create or reformat a private key in PEM format:
ssh-keygen -p -f my_oic_key.pem -N "" -t rsa -m pem
🔎 Example:
ssh-keygen -p -f svc_oic_ccsvault_tst@clp.com.hk-2025-09-16T13_18_48.364Z.pem -N "" -t rsa -m pem
Parameters explained:
-p→ Update or re-save the key file.-f my_oic_key.pem→ Path and name of your private key file.-N ""→ Empty passphrase (no password required).-t rsa→ Generate RSA type key.-m pem→ Export the key in PEM format (needed for OIC Vault, Functions, Connections).
Step 3: Verify the Key File
- Only one private key file (
.pem) will be created/updated. - It will be saved in PEM format.
- No public key file (
.pub) is generated in this mode.
Step 4: Use in OIC
- Upload the
.pemfile into OCI Vault as a secret. - Configure OIC Functions to read this private key.
- Use it in SFTP / REST / API Connections in OIC for key-based authentication.
✅ Final Result: You now have an RSA private key in PEM format, created directly from Windows CMD, ready for use in Oracle Integration Cloud Vault, Functions, and Connections.

No comments:
Post a Comment