xref: /curl/docs/cmdline-opts/pubkey.md (revision 62bfcb0c)
1---
2c: Copyright (C) Daniel Stenberg, <daniel@haxx.se>, et al.
3SPDX-License-Identifier: curl
4Long: pubkey
5Arg: <key>
6Protocols: SFTP SCP
7Help: SSH Public key filename
8Category: sftp scp ssh auth
9Added: 7.16.2
10Multi: single
11See-also:
12  - pass
13Example:
14  - --pubkey file.pub sftp://example.com/
15---
16
17# `--pubkey`
18
19Public key filename. Allows you to provide your public key in this separate
20file.
21
22curl attempts to automatically extract the public key from the private key
23file, so passing this option is generally not required. Note that this public
24key extraction requires libcurl to be linked against a copy of libssh2 1.2.8
25or higher that is itself linked against OpenSSL. (Added in 7.39.0.)
26