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: docs/linux/set-up-fips-compliant-secure-remote-linux-development.md
+21-21Lines changed: 21 additions & 21 deletions
Original file line number
Diff line number
Diff line change
@@ -1,7 +1,7 @@
1
1
---
2
2
title: "Set up FIPS-compliant secure remote Linux development"
3
3
description: "How to set up a FIPS-compliant cryptographic connection between Visual Studio and a Linux machine for remote development."
4
-
ms.date: "01/17/2020"
4
+
ms.date: 07/06/2022
5
5
---
6
6
# Set up FIPS-compliant secure remote Linux development
7
7
@@ -32,13 +32,13 @@ The examples in this article use Ubuntu 18.04 LTS with OpenSSH server version 7.
32
32
sudo service ssh start
33
33
```
34
34
35
-
1. If you’d like the ssh server to start automatically when the system boots, enable it using systemctl:
35
+
1. If you'd like the `ssh` server to start automatically when the system boots, enable it using `systemctl`:
36
36
37
37
```bash
38
38
sudo systemctl enable ssh
39
39
```
40
40
41
-
1. Open */etc/ssh/sshd_config* as root. Edit (or add, if they don’t exist) the following lines:
41
+
1. Open *`/etc/ssh/sshd_config`* as root. Edit (or add, if they don't exist) the following lines:
42
42
43
43
```config
44
44
Ciphers aes256-cbc,aes192-cbc,aes128-cbc,3des-cbc
@@ -48,27 +48,27 @@ The examples in this article use Ubuntu 18.04 LTS with OpenSSH server version 7.
48
48
```
49
49
50
50
> [!NOTE]
51
-
> ssh-rsa is the only FIPS compliant host key algorithm VS supports. The aes\*-ctr algorithms are also FIPS compliant, but the implementation in Visual Studio isn't approved. The ecdh-\* key exchange algorithms are FIPS compliant, but Visual Studio doesn't support them.
51
+
> `ssh-rsa` is the only FIPS compliant host key algorithm VS supports. The `aes*-ctr` algorithms are also FIPS compliant, but the implementation in Visual Studio isn't approved. The `ecdh-*` key exchange algorithms are FIPS compliant, but Visual Studio doesn't support them.
52
52
53
-
You're not limited to these options. You can configure ssh to use additional ciphers, host key algorithms, and so on. Some other relevant security options you may want to consider are `PermitRootLogin`, `PasswordAuthentication`, and `PermitEmptyPasswords`. For more information, see the man page for sshd_config or the article [SSH Server Configuration](https://www.ssh.com/ssh/sshd_config).
53
+
You're not limited to these options. You can configure `ssh` to use other ciphers, host key algorithms, and so on. Some other relevant security options you may want to consider are `PermitRootLogin`, `PasswordAuthentication`, and `PermitEmptyPasswords`. For more information, see the `man` page for `sshd_config` or the article [SSH Server Configuration](https://www.ssh.com/ssh/sshd_config).
54
54
55
-
1. After saving and closing sshd_config, restart the ssh server to apply the new configuration:
55
+
1. After saving and closing `sshd_config`, restart the ssh server to apply the new configuration:
56
56
57
57
```bash
58
58
sudo service ssh restart
59
59
```
60
60
61
-
Next, you'll create an RSA key pair on your Windows computer. Then you'll copy the public key to the remote Linux system for use by ssh.
61
+
Next, you'll create an RSA key pair on your Windows computer. Then you'll copy the public key to the remote Linux system for use by `ssh`.
62
62
63
63
### To create and use an RSA key file
64
64
65
65
1. On the Windows machine, generate a public/private RSA key pair by using this command:
66
66
67
67
```cmd
68
-
ssh-keygen -t rsa -b 4096
68
+
ssh-keygen -t rsa -b 4096 -m PEM
69
69
```
70
70
71
-
The command creates a public key and a private key. By default, the keys are saved to *%USERPROFILE%\\.ssh\\id_rsa* and *%USERPROFILE%\\.ssh\\id_rsa.pub*. (In Powershell, use `$env:USERPROFILE` instead of the cmd macro `%USERPROFILE%`) If you change the key name, use the changed name in the steps that follow. We recommend you use a passphrase for increased security.
71
+
The command creates a public key and a private key. By default, the keys are saved to *`%USERPROFILE%\.ssh\id_rsa`* and *`%USERPROFILE%\\.ssh\\id_rsa.pub`*. (In PowerShell, use `$env:USERPROFILE` instead of the cmd macro `%USERPROFILE%`) If you change the key name, use the changed name in the steps that follow. We recommend you use a passphrase for increased security.
72
72
73
73
1. From Windows, copy the public key to the Linux machine:
74
74
@@ -83,13 +83,13 @@ Next, you'll create an RSA key pair on your Windows computer. Then you'll copy t
83
83
chmod 600 ~/.ssh/authorized_keys
84
84
```
85
85
86
-
1. Now, you can test to see if the new key works in ssh. Use it to sign in from Windows:
86
+
1. Now, you can test to see if the new key works in `ssh`. Use it to sign in from Windows:
87
87
88
88
```cmd
89
89
ssh -i %USERPROFILE%\.ssh\id_rsa user@hostname
90
90
```
91
91
92
-
You've successfully set up ssh, created and deployed encryption keys, and tested your connection. Now you're ready to set up the Visual Studio connection.
92
+
You've successfully set up `ssh`, created and deployed encryption keys, and tested your connection. Now you're ready to set up the Visual Studio connection.
93
93
94
94
## Connect to the remote system in Visual Studio
95
95
@@ -107,14 +107,14 @@ You've successfully set up ssh, created and deployed encryption keys, and tested
107
107
108
108
1. In the **Connect to Remote System** dialog, enter the connection details of your remote machine.
109
109
110
-
| Entry | Description
111
-
| ----- | ---
112
-
| **Host Name** | Name or IP address of your target device
113
-
| **Port** | Port that the SSH service is running on, typically 22
114
-
| **User name** | User to authenticate as
115
-
| **Authentication type** | Choose Private Key for a FIPS-compliant connection
116
-
| **Private key file** | Private key file created for ssh connection
117
-
| **Passphrase** | Passphrase used with private key selected above
110
+
| Entry | Description |
111
+
|--|--|
112
+
| **Host Name** | Name or IP address of your target device |
113
+
| **Port** | Port that the SSH service is running on, typically 22 |
114
+
| **User name** | User to authenticate as |
115
+
| **Authentication type** | Choose **Private Key** for a FIPS-compliant connection |
116
+
| **Private key file** | Private key file created for ssh connection |
117
+
| **Passphrase** | Passphrase used with private key selected above |
118
118
119
119
Change the authentication type to **Private Key**. Enter the path to your private key in the **Private key file** field. You can use the **Browse** button to navigate to your private key file instead. Then, enter the passphrase used to encrypt your private key file in the **Passphrase** field.
120
120
@@ -130,13 +130,13 @@ You've successfully set up ssh, created and deployed encryption keys, and tested
130
130
131
131
## Command-line utility for the Connection Manager
132
132
133
-
**Visual Studio 2019 version 16.5 or later**: ConnectionManager.exe is a command-line utility to manage remote development connections outside of Visual Studio. It's useful for tasks such as provisioning a new development machine. Or, you can use it to set up Visual Studio for continuous integration. For examples and a complete reference to the ConnectionManager command, see [ConnectionManager reference](connectionmanager-reference.md).
133
+
**Visual Studio 2019 version 16.5 or later**: `ConnectionManager.exe` is a command-line utility to manage remote development connections outside of Visual Studio. It's useful for tasks such as provisioning a new development machine. Or, you can use it to set up Visual Studio for continuous integration. For examples and a complete reference to the ConnectionManager command, see [ConnectionManager reference](connectionmanager-reference.md).
134
134
135
135
## Optional: Enable or disable FIPS mode
136
136
137
137
It's possible to enable FIPS mode globally in Windows.
138
138
139
-
1. To enable FIPS mode, press **Windows+R** to open the Run dialog, and then run gpedit.msc.
139
+
1. To enable FIPS mode, press **Windows+R** to open the **Run** dialog, and then run `gpedit.msc`.
140
140
141
141
1. Expand **Local Computer Policy > Computer Configuration > Windows Settings > Security Settings > Local Policies** and select **Security Options**.
0 commit comments