---
title: burusftp keygen
linkTitle: keygen
---

## NAME
`burusftp keygen` - Generates SSH private key(s)

## SYNOPSIS
```synopsis
burusftp keygen --all [<path>]
burusftp keygen [(-b | --bits) <bits>] [(-t | --type) <type>] 
                [(-c | --curve) <curve>] <keyfile>
```

## OPTIONS
* `--all [<path>]`
  * Generates default set of keys to path provided. If path is not provided keys will be exported to `keys` directory inside [configuration directory]({{< ref "../../Configuration" >}}).
  * Default set consists of these keys: ECDSA with NIST P-256 curve, ED25519 and RSA with 2048 bit length
* `-b, --bits <bits>`
  * Number of bits in the key to create. Default value depends on host key algorithm (`--type`).
* `-c, --curve (nistp256|nistp384|nistp521)`
  * Curve used for ECDSA key. Default: `nistp521`.
* `-t, --type (rsa|dsa|ed25519|ecdsa)`
  * Host key algorithm. Default: `rsa`.

## EXAMPLES

```fish
# Generate set of keys to /config/keys
burusftp keygen --all

# Generate set of keys to D:\keys
burusftp keygen --all "D:\keys"
  
# Generate 4096-bit RSA key and save it to key.ppk file
burusftp keygen key.ppk

# Generate 512-bit DSA key and save it to key.ppk file.
burusftp keygen -t dsa -b 512 key.ppk

# Generate ECDSA key with NIST P-521 curve and save it to key.ppk file.
burusftp keygen -t ecdsa -c nistp521 key.ppk
```