-
Notifications
You must be signed in to change notification settings - Fork 106
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #515 from NuSkooler/bugfix/ssh_doc_updates
Updated the SSH version, config, and documentation
- Loading branch information
Showing
9 changed files
with
280 additions
and
293 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -10,4 +10,6 @@ logs/ | |
mail/ | ||
node_modules/ | ||
docs/_site/ | ||
docs/.sass-cache/ | ||
docs/.sass-cache/ | ||
|
||
docs/.jekyll-cache/ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -35,6 +35,10 @@ npm install # or simply 'yarn' | |
## 0.0.13-beta to 0.0.14-beta | ||
|
||
* Due to changes to supported algorithms in newer versions of openssl, the default list of supported algorithms for the ssh login server has changed. There are both removed ciphers as well as optional new kex algorithms available now. ***NOTE:*** Changes to supported algorithms are only needed to support keys generated with new versions of openssl, if you already have a ssl key in use you should not have to make any changes to your config. | ||
* Removed ciphers: 'blowfish-cbc', 'arcfour256', 'arcfour128', and 'cast128-cbc' | ||
* Added kex: 'curve25519-sha256', '[email protected]', 'curve25519-sha256', '[email protected]', 'ecdh-sha2-nistp256', 'ecdh-sha2-nistp384', 'ecdh-sha2-nistp521' | ||
|
||
## 0.0.12-beta to 0.0.13-beta | ||
* To enable the new Waiting for Caller (WFC) support, please see [WFC](docs/modding/wfc.md). | ||
* :exclamation: The SSH server's `ssh2` module has gone through a major upgrade. Existing users will need to comment out two SSH KEX algorithms from their `config.hjson` if present else clients such as NetRunner will not be able to connect over SSH. Comment out `diffie-hellman-group-exchange-sha256` and `diffie-hellman-group-exchange-sha1` | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -188,22 +188,15 @@ module.exports = () => { | |
// | ||
// 1 - Generate a Private Key (PK): | ||
// Currently ENiGMA 1/2 requires a PKCS#1 PEM formatted PK. | ||
// To generate a secure PK, issue the following command: | ||
// | ||
// > openssl genpkey -algorithm RSA -pkeyopt rsa_keygen_bits:2048 \ | ||
// -pkeyopt rsa_keygen_pubexp:65537 | openssl rsa \ | ||
// -out ./config/security/ssh_private_key.pem -aes128 | ||
// | ||
// (The above is a more modern equivalent of the following): | ||
// > openssl genrsa -aes128 -out ./config/security/ssh_private_key.pem 2048 | ||
// For information on generating a key, see: | ||
// https://nuskooler.github.io/enigma-bbs/servers/loginservers/ssh.html#generate-a-ssh-private-key | ||
// | ||
// 2 - Set 'privateKeyPass' to the password you used in step #1 | ||
// | ||
// 3 - Finally, set 'enabled' to 'true' | ||
// | ||
// Additional reading: | ||
// - https://blog.sleeplessbeastie.eu/2017/12/28/how-to-generate-private-key/ | ||
// - https://gist.github.com/briansmith/2ee42439923d8e65a266994d0f70180b | ||
// - https://nuskooler.github.io/enigma-bbs/servers/loginservers/ssh.html | ||
// | ||
privateKeyPem: paths.join( | ||
__dirname, | ||
|
@@ -222,14 +215,18 @@ module.exports = () => { | |
// | ||
algorithms: { | ||
kex: [ | ||
'curve25519-sha256', | ||
'[email protected]', | ||
'ecdh-sha2-nistp256', | ||
'ecdh-sha2-nistp384', | ||
'ecdh-sha2-nistp521', | ||
'diffie-hellman-group14-sha1', | ||
'diffie-hellman-group1-sha1', | ||
// Group exchange not currnetly supported | ||
// 'diffie-hellman-group-exchange-sha256', | ||
// 'diffie-hellman-group-exchange-sha1', | ||
'curve25519-sha256', | ||
'[email protected]', | ||
'ecdh-sha2-nistp256', | ||
'ecdh-sha2-nistp384', | ||
'ecdh-sha2-nistp521', | ||
], | ||
cipher: [ | ||
'aes128-ctr', | ||
|
@@ -242,12 +239,7 @@ module.exports = () => { | |
'aes256-cbc', | ||
'aes192-cbc', | ||
'aes128-cbc', | ||
'blowfish-cbc', | ||
'3des-cbc', | ||
'arcfour256', | ||
'arcfour128', | ||
'cast128-cbc', | ||
'arcfour', | ||
], | ||
hmac: [ | ||
'hmac-sha2-256', | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,45 @@ | ||
--- | ||
layout: page | ||
title: Troubleshooting SSH | ||
--- | ||
|
||
Stuck with errors trying to get your SSH setup configured? See below for some common problems. Or as always, reach out to us by creating an [Issue](https://github.com/NuSkooler/enigma-bbs/issues) or start a [Discussion](https://github.com/NuSkooler/enigma-bbs/discussions) | ||
|
||
## No Such File or Directory | ||
|
||
***Symptom:*** | ||
BBS not starting with an error similar to the following: | ||
|
||
```shell | ||
Error initializing: Error: ENOENT: no such file or directory, open '<path>/config/security/ssh_private_key.pem' | ||
``` | ||
|
||
***Solution:*** | ||
Several things can cause this: | ||
|
||
1. `ssh_private_key.pem` was installed to the wrong location. Make sure that it is in the `config/security` directory and has the name matching the error message. You can also change your `config.hjson` if you prefer to point to the location of the key file. | ||
2. `ssh_private_key.pem` has the wrong file permissions. Verify that the file will be readable by the user that the BBS is running as. Because it is a cryptographic key however, we do recommend that access is restricted only to that user. | ||
|
||
## Error With Netrunner | ||
|
||
***Symptom:*** | ||
Some ssh clients connect, but Netrunner (and other older clients) get a connection failed message and the following is in the log: | ||
|
||
```shell | ||
"level":40,"error":"Handshake failed","code":2,"msg":"SSH connection error" | ||
``` | ||
|
||
***Solution:*** | ||
|
||
The key was most likely not generated with the `-t rsa` option, and is using a newer algorithm that is not supported by Netrunner and similar clients. Regenerate the certificate with the `-t rsa` option. | ||
|
||
***Symptom:*** | ||
Some ssh clients connect, but Netrunner (and other older clients) get a connection failed message and the following is in the log: | ||
|
||
```shell | ||
"level":40,"error":"Group exchange not implemented for server","msg":"SSH connection error" | ||
``` | ||
|
||
***Solution:*** | ||
|
||
Remove the following encryption protocols from your `config.hjson`: `diffie-hellman-group-exchange-sha256` and `diffie-hellman-group-exchange-sha1` |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.