---
name: "py3rsa-keygen"
section: "1"
platform: "linux"
package: "python3-rsa"
version: "4.9-2"
release: "Debian 13 (Trixie)"
platforms: ["linux"]
url: "https://new.carta.tech/py3rsa-keygen"
---

# py3rsa-keygen(1)

generate a new RSA keypair

## NAME

**py3rsa-keygen** - generate a new RSA keypair

## SYNOPSIS

**py3rsa-keygen** \[*OPTION*\]... *KEYSIZE*

## DESCRIPTION

Generate a new RSA keypair of *KEYSIZE* bits.

## OPTIONS

- **-h**, **--help**

  show help message and exit

- **--pubout=***PUBOUT*

  output filename for the public key. the public key is not saved if this option is not present. you can use **py3rsa-priv2pub** to create the public key file later.

- **-o** *OUT*, **--out=***OUT*

  output filename for the private key. the key is written to stdout if this option is not present.

- **--form=***FORM*

  key format of the private and public keys - default PEM

## AUTHOR

**py3rsa-keygen** was written by Sybren A. Stuvel \<sybren AT stuvel.eu\>.
