This repository was archived by the owner on Jun 6, 2025. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 17
🐛 Fix two Mondoo Linux SSH checks #466
Closed
Closed
Changes from 3 commits
Commits
Show all changes
5 commits
Select commit
Hold shift + click to select a range
38400cc
fixed: mondooLinuxSecurityKexAlgos
mm-weber feedf5a
fixed: mondooLinuxSecuritySshdCiphers
mm-weber b00a5a9
made it more robust
mm-weber 207e41f
Update core/mondoo-linux-security.mql.yaml
mm-weber 6eed4a2
Update core/mondoo-linux-security.mql.yaml
mm-weber File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or 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 |
---|---|---|
|
@@ -2588,11 +2588,14 @@ queries: | |
- uid: mondoo-linux-security-only-strong-ciphers-are-used | ||
title: Ensure only strong ciphers are used | ||
impact: 100 | ||
filters: package('openssh-server').installed == true | ||
props: | ||
- uid: mondooLinuxSecuritySshdCiphers | ||
title: Define the hardened ciphers for all SSH configurations | ||
mql: | | ||
if( package('openssh-server').version == /6./ ) { | ||
sshVersionExtracted = package('openssh-server').version.split("1:").where(_ != empty).first.split("~").where(_ != empty).first | ||
|
||
if( semver(sshVersionExtracted) >= semver("6") && semver(sshVersionExtracted) < semver("7") ) { | ||
return ["aes256-ctr", "aes192-ctr", "aes128-ctr"] | ||
} | ||
return ["[email protected]","[email protected]","[email protected]","aes256-ctr","aes192-ctr","aes128-ctr"] | ||
|
@@ -2634,17 +2637,20 @@ queries: | |
- uid: mondoo-linux-security-only-strong-kex-algorithms-are-used | ||
title: Ensure that strong Key Exchange algorithms are used | ||
impact: 100 | ||
filters: package('openssh-server').installed == true | ||
mm-weber marked this conversation as resolved.
Show resolved
Hide resolved
|
||
props: | ||
- uid: mondooLinuxSecurityKexAlgos | ||
title: Define the hardened key exchange algorithms for all SSH configurations | ||
mql: | | ||
if( package('openssh-server').version == /6./) { | ||
sshVersionExtracted = package('openssh-server').version.split("1:").where(_ != empty).first.split("~").where(_ != empty).first | ||
|
||
if( semver(sshVersionExtracted) >= semver("6") && semver(sshVersionExtracted) < semver("7") ) { | ||
return ["[email protected]"] | ||
} | ||
if( package('openssh-server').version == /7./) { | ||
if( semver(sshVersionExtracted) >= semver("7") && semver(sshVersionExtracted) < semver("8") ) { | ||
mm-weber marked this conversation as resolved.
Show resolved
Hide resolved
|
||
return ["[email protected]","diffie-hellman-group18-sha512"] | ||
} | ||
if( package('openssh-server').version == /8\.[0|1|2|3|4|5]/ ) { | ||
if( semver(sshVersionExtracted) >= semver("8") && semver(sshVersionExtracted) < semver("9") ) { | ||
return ["[email protected]","[email protected]","diffie-hellman-group18-sha512"] | ||
} | ||
return ["[email protected]","[email protected]","diffie-hellman-group18-sha512"] | ||
|
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Uh oh!
There was an error while loading. Please reload this page.