Field guide
Choose the format your destination actually accepts
An RSA key is a set of large numbers; OpenSSH and PKCS#1 are different containers for those same numbers. Converting the container does not rotate the key or change the matching public key. This MVP helps with the common case where a modern workstation created an OpenSSH private key but an older system expects traditional RSA PEM—or the reverse.
What happens in this browser
Generate asks the browser’s native WebCrypto implementation for an extractable RSA signing key with public exponent 65537 and SHA-256 parameters. The private components are exported temporarily into runtime memory and serialized into the chosen SSH or PEM container. Convert performs the inverse container operation, validates that private RSA components are present, and derives the public line again. The conversion library is loaded only after an action needs it.
There is no application server, upload endpoint, account, telemetry pipeline, or database. The static HTML, CSS, and JavaScript must first be downloaded like any website, but the cryptographic actions themselves make no application-initiated network requests. Key strings are not placed in cookies, localStorage, sessionStorage, IndexedDB, URLs, logs, analytics, or Astro build code. Clear removes UI references and asks the crypto layer to wipe tracked byte arrays. JavaScript strings are garbage-collected, so no browser tool can promise perfect deterministic memory zeroization.
Compatibility checklist before conversion
- Read the target product’s exact header or format requirement instead of relying only on a generic error.
- Confirm it accepts RSA and the selected key size; some modern services restrict or discourage
ssh-rsa signatures. - Work on a copy before running any command that rewrites a private-key file.
- Keep the original protected until the converted file has been tested and its public fingerprint compared.
- Apply restrictive file permissions after downloading; on Unix-like systems,
chmod 600 ./id_rsa is a common baseline.
Format conversion does not make an incompatible algorithm compatible. A system that requires Ed25519, ECDSA, PKCS#8, PuTTY PPK, a hardware-backed identity, or a certificate needs a different workflow. Those formats are deliberately outside this narrow MVP rather than being guessed from ambiguous input.
FAQ
Practical questions
Does the key leave my browser?
No application code uploads your key. Generate, Convert, Copy, Download, and Clear operate locally after the static app assets load. Browser extensions, managed-device software, clipboard tools, and the operating system remain outside the application security boundary.
Which key formats are supported?
Phase 1 supports unencrypted RSA private keys in the modern OpenSSH private-key container and legacy PKCS#1 PEM. It generates RSA 2048 or 4096 keys and produces an OpenSSH ssh-rsa public-key line for either private format.
Why are encrypted private keys rejected?
Correct passphrase support requires dedicated key-derivation, cipher, interoperability, and threat-model work. It is deferred rather than implemented partially. For now, use trusted local OpenSSH tooling on a copy and follow the command guidance shown by the tool.
Should I choose 2048 or 4096 bits?
Choose the policy required by the destination. RSA 2048 is faster and broadly compatible. RSA 4096 creates larger keys and slower operations but may satisfy stricter organizational policy. A larger key does not solve a format mismatch.
Why does the public key stay the same after conversion?
Conversion re-encodes the same RSA modulus, exponent, and private components in a different container. It does not generate a new identity. Compare the SHA-256 fingerprint before and after conversion to verify that the public identity did not change.
Why might a destination still reject the converted key?
The destination may require a different algorithm, key size, encryption state, public-key format, PKCS#8, PuTTY PPK, a certificate, or a product-specific import workflow. Format conversion cannot make an unsupported algorithm or policy compatible.
How should I protect a downloaded private key?
Save it only to a trusted device, restrict file access, and keep the original until the converted key is verified. On Unix-like systems, chmod 600 is a common baseline. Follow your organization policy for storage, backup, rotation, and incident response.
What exactly does Clear remove?
Clear removes key values and derived details from the interface, resets filenames, and asks the crypto layer to wipe tracked byte arrays. JavaScript strings are garbage-collected, so a browser application cannot promise deterministic physical memory zeroization.
Does the tool work offline?
The cryptographic workflow has no server dependency after the static assets load, but Phase 1 does not yet install a service worker. A fully installable and reliably precached offline PWA remains planned for the later PWA phase.