You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardexpand all lines: tutorials/sftp_publickeyauth_bitwarden.md
+60-10
Original file line number
Diff line number
Diff line change
@@ -5,17 +5,67 @@ Public-key authentication using Bitwarden SSH Agent allows you to connect to a r
5
5
- Private key managed by Bitwarden
6
6
- Public key placed on the server usually by the system administrator
7
7
8
-
1. Ensure you have configured Bitwarden to manage your SSH keys. For more information, refer to [Bitwarden SSH Agent](https://bitwarden.com/help/ssh-agent/#configure-bitwarden-ssh-agent).
9
-
2. Open the OpenSSH configuration file `~/.ssh/config` and add the following configuration specifying to use 1Password as the SSH agent:
10
-
```
11
-
Host *
12
-
IdentitiesOnly yes
13
-
# Bitwarden SSH agent
14
-
IdentityAgent ~/.bitwarden-ssh-agent.sock
8
+
1. Ensure you have configured Bitwarden to manage your SSH keys. For more information, refer to [Bitwarden SSH Agent](https://bitwarden.com/help/ssh-agent/#configure-bitwarden-ssh-agent). Open _Bitwarden → Settings…_ and select the checkbox _Enable SSH Agent_.
5. Open the OpenSSH configuration file `~/.ssh/config` and add the following configuration specifying to use Bitwarden as the SSH agent:
15
34
```
16
-
This [configuration](https://docs.cyberduck.io/protocols/sftp/#openssh-configuration-interoperability) directive is supported by Cyberduck and Mountain Duck.
17
-
5. In the [Bookmark](../cyberduck/bookmarks.md) or [Connection](../cyberduck/connection.md) panel, select *Use Public Key Authentication*
18
-
6. Select the public key corresponding to your SSH private key saved in Bitwarden. Typically, it is located in the `~/.ssh` directory.
35
+
Host *
36
+
IdentitiesOnly yes
37
+
# Bitwarden SSH agent
38
+
IdentityAgent ~/.bitwarden-ssh-agent.sock
39
+
```
40
+
This [configuration](https://docs.cyberduck.io/protocols/sftp/#openssh-configuration-interoperability) directive is supported by Cyberduck and Mountain Duck. If you are running Bitwarden installed from the Mac App Store the socket is located in `~/Library/Containers/com.bitwarden.desktop/Data/.bitwarden-ssh-agent.sock` instead.
41
+
42
+
6. Add a new [Bookmark](../cyberduck/bookmarks.md) in Cyberduck or Mountain Duck. Enter the alias from your OpenSSH configuration or the hostname in _Server_. You do **not** need to set a value for _Password_.
43
+
44
+
:::{image} _images/Bookmark_Panel.png
45
+
:alt: Bookmark Panel
46
+
:width: 600px
47
+
:::
48
+
49
+
:::{tip}
50
+
The server may respond with _[Too many authentication failures](../protocols/sftp/index.md#too-many-authentication-failures)_ when trying to authenticate with all keys stored in 1Password. In the [Bookmark](../cyberduck/bookmarks.md) panel, select the public key corresponding to your SSH private key saved in 1Password for *SSH Private Key*. The public key must be available as a file you can write from the clipboard to a file using:
51
+
52
+
```
53
+
pbpaste > ~/.ssh/test.pub
54
+
```
55
+
56
+
Alternatively, add the public key to the OpenSSH configuration file `~/.ssh/config` with the `IdentityFile` directive
57
+
58
+
```
59
+
# Public Key File used to filter identities from SSH agent
60
+
IdentityFile ~/.ssh/test.pub
61
+
```
62
+
63
+
7. Connect to the server and acknowledge the prompt to use the private key stored in Bitwarden.
0 commit comments