Commit Graph
1375 Commits
Author SHA1 Message Date
schurzi b3d7acee44 Merge pull request #48 from dev-sec/kitchen_travis
update testing
2020-08-07 20:04:50 +02:00
Sebastian Gumprich 6b42f12434 update testing
Signed-off-by: Sebastian Gumprich <[email protected]>
2020-08-07 19:30:58 +02:00
dev-sec CI eb777fbe2f update changelog 2020-08-07 07:02:27 +00:00
schurzi eaeca04d96 do not blacklist used filesystems (#289)
* add additional check for efi

some systems seem to require vfat because of efi, despite not exposing a
/sys/firmware/efi directory.

Signed-off-by: Martin Schurz <[email protected]>

* make linter happy

Signed-off-by: Martin Schurz <[email protected]>

* rework check to check for all used filesystems

so we don't break existing mounts with our configuration

Signed-off-by: Martin Schurz <[email protected]>

* do not check this on el6

Signed-off-by: Martin Schurz <[email protected]>

* add comment to clarify

Signed-off-by: Martin Schurz <[email protected]>
2020-08-07 08:59:46 +02:00
dev-sec CI 83a6d88c46 update changelog 2020-08-03 19:31:28 +00:00
Sebastian Gumprich 04d19fd195 fix typo 2020-08-03 21:28:23 +02:00
dev-sec CI fe7e37e6e9 update changelog 2020-08-03 13:58:20 +00:00
schurzi 387fc472bd improve testing (#287)
* fix problem with package_facts on SuSE

SuSE Linux does not work with ansibel module packet_facts, so we need to
exclude this task there.

Signed-off-by: Martin Schurz <[email protected]>

* fix local docker tests for all distributions

Signed-off-by: Martin Schurz <[email protected]>

* fix local vagrant tests for all distributions

Signed-off-by: Martin Schurz <[email protected]>

* simplify travis tests

Signed-off-by: Martin Schurz <[email protected]>

* fix opensuse in travis

Signed-off-by: Martin Schurz <[email protected]>

* add fixes for suse

Signed-off-by: Martin Schurz <[email protected]>

* add special case for suse docker

Signed-off-by: Martin Schurz <[email protected]>
2020-08-03 15:55:27 +02:00
dev-sec CI 20bf4eaa99 update changelog 2020-07-28 08:29:59 +00:00
Sebastian Gumprich f1a65f5f44 Merge pull request #318 from dev-sec/fix_kitchen
fix local kitchen tests
2020-07-28 09:24:22 +02:00
Martin Schurz 04f731a08c fix local kitchen tests
somehow a "real" linux needs different options than WSL. This is now
also working on debian 10

Signed-off-by: Martin Schurz <[email protected]>
2020-07-28 09:12:43 +02:00
schurzi 9b14f64f67 Merge pull request #317 from aqw/umask
fix sftp_umask; store as literal not octal
2020-07-28 08:59:12 +02:00
dev-sec CI b7791833a7 update changelog 2020-07-28 06:33:18 +00:00
Sebastian Gumprich f50f22ca66 Merge pull request #294 from aqw/master
add SmartOS support
2020-07-28 08:30:17 +02:00
Alex Waite e59dd46c23 fix sftp_umask; store as literal not octal
Numbers with leading zeros need to be quoted in Ansible, otherwise they
are interpreted as octal. Which the templating happily writes out in...
decimal.

In this case, sftp_umask 0027 was ending up as 23 in sshd.conf.

Signed-off-by: Alex Waite <[email protected]>
2020-07-28 07:44:54 +02:00
Alex Waite 670be01d69 add var ssh_host_keys_dir, for OSes with alternate host key locations
Signed-off-by: Alex Waite <[email protected]>
2020-07-28 07:33:52 +02:00
Alex Waite 1a28c7bdef add SmartOS support
Signed-off-by: Alex Waite <[email protected]>
2020-07-28 07:29:39 +02:00
Alex Waite 1f1c715ec7 add var sshd_path, for OSs with alternate sshd locations
Signed-off-by: Alex Waite <[email protected]>
2020-07-28 07:29:27 +02:00
dev-sec CI 6fddedccb6 update changelog 2020-07-27 14:53:41 +00:00
liteua bf7c4dd46d add ssh_banner_path variable (#316)
Signed-off-by: Volodymyr Litvak <[email protected]>
2020-07-27 16:46:04 +02:00
dev-sec CI 75880c8f48 update changelog 2020-07-22 20:45:26 +00:00
schurzi 760f1206d6 rework CRYPTO_POLICY handling for fedora (#314)
* rework CRYPTO_POLICY handling for fedora

the previous implementation did not handle fedora right. Now we check if
a CRYPTO_POLICY is present regardless of the OS version.

Signed-off-by: Martin Schurz <[email protected]>

* improve tasks for CRYPTO_POLICY

Signed-off-by: Martin Schurz <[email protected]>

* add exception for Archlinux

Signed-off-by: Martin Schurz <[email protected]>

* swap conditions

Signed-off-by: Martin Schurz <[email protected]>
2020-07-22 22:42:28 +02:00
dev-sec CI 740feae180 update changelog 2020-07-22 19:29:59 +00:00
Sebastian Gumprich 65a8fa0c6c move hidepid vars into defaults so theyre overwritable (#285)
fixes #284

Signed-off-by: Sebastian Gumprich <[email protected]>
2020-07-22 21:27:25 +02:00
dev-sec CI e69f5891d9 update changelog 2020-07-22 12:45:52 +00:00
schurzi 395fd030ce improve testing in kitchen and travis (#313)
* improve local testing

don't use privileged mode, since this grants too much permissions.
Fixes several problems with PAM in test images.
REorder options in kitchen configuration to simplify it.

Signed-off-by: Martin Schurz <[email protected]>

* check all controls in travis

Signed-off-by: Martin Schurz <[email protected]>

* set env vars in travis correctly

according to documentation: https://docs.travis-ci.com/user/environment-variables/

Signed-off-by: Martin Schurz <[email protected]>

* add arch linux to local tests

Signed-off-by: Martin Schurz <[email protected]>

* shorten travis config

Signed-off-by: Martin Schurz <[email protected]>

* use correct init command for containers

Signed-off-by: Martin Schurz <[email protected]>

* try privileged again

Signed-off-by: Martin Schurz <[email protected]>

* arch seems to like privilege

Signed-off-by: Martin Schurz <[email protected]>
2020-07-22 14:42:45 +02:00
dev-sec CI 994ea81e64 update changelog 2020-07-21 20:38:28 +00:00
alegrey91andSebastian Gumprich a8e349913d Mount proc filesystem using hidepid option (#283)
* Added task to mount proc fs using hidepid option

Signed-off-by: alessio <[email protected]>
Signed-off-by: alegrey91 <[email protected]>
Signed-off-by: alessio <[email protected]>

* Removed mount shell command due to ci problem

Signed-off-by: alegrey91 <[email protected]>
Signed-off-by: alessio <[email protected]>

* Added task to create mount point before to add fstab entry

Signed-off-by: alegrey91 <[email protected]>
Signed-off-by: alessio <[email protected]>

* Added check to ensure fstab exist

Signed-off-by: alegrey91 <[email protected]>
Signed-off-by: alessio <[email protected]>

* Modified task title

Signed-off-by: alegrey91 <[email protected]>
Signed-off-by: alessio <[email protected]>

* Fixed typo

Signed-off-by: alegrey91 <[email protected]>
Signed-off-by: alessio <[email protected]>

* Fixed typo

Signed-off-by: alegrey91 <[email protected]>
Signed-off-by: alessio <[email protected]>

* Fixed wrong indented lines

Signed-off-by: alegrey91 <[email protected]>
Signed-off-by: alessio <[email protected]>

* Removed useless tasks and improved variables use

Signed-off-by: alessio <[email protected]>

* removed ansible test tag

Signed-off-by: alessio <[email protected]>

* removed trailing whitespace

Signed-off-by: alessio <[email protected]>

* updated documentation

Signed-off-by: alessio <[email protected]>

* fixed typo

Signed-off-by: alessio <[email protected]>

* Update README.md

* Update vars/main.yml

Co-authored-by: Sebastian Gumprich <[email protected]>
6.1.0
2020-07-21 22:35:50 +02:00
dev-sec CI 0016239486 update changelog 2020-07-21 20:18:43 +00:00
Arnold 0cbfc29f23 adding specific documentation for IPv6 support (#312)
* adding specific things for IPv6 support

Signed-off-by: Arnold <[email protected]>
2020-07-21 22:15:42 +02:00
dev-sec CI 7ea747af03 update changelog 2020-07-20 09:55:20 +00:00
Sebastian Gumprich 3b75e49c0e fix typo 2020-07-20 11:52:22 +02:00
Sebastian Gumprich 8806f9f06a fix typo 2020-07-18 10:27:21 +02:00
be0e7f7809 add support for CentOS8 (#309)
* add testing for CentOS8

Adds testing environments for CentOS8 to local Kitchen and remote Travis
tests. Currently only local Kitchen Docker tests are verified.

Signed-off-by: Martin Schurz <[email protected]>

* disable system wide CRYPTO_POLICY on RHEL8+

by default sshd will not use the crypto settings from sshd_config. To
make the settings effective we need to disable the system wide
CRYPTO_POLICY.

see: https://access.redhat.com/solutions/4410591

Signed-off-by: Martin Schurz <[email protected]>

* Set volume variable for travis tests to use cgroups mount where needed

Signed-off-by: Sebastian Gumprich <[email protected]>

Co-authored-by: Sebastian Gumprich <[email protected]>
Co-authored-by: Sebastian Gumprich <[email protected]>
2020-07-18 10:20:09 +02:00
dev-sec CI 6626617a4a update changelog 2020-07-13 16:55:06 +00:00
Sebastian Gumprich b4b306484b Merge pull request #307 from nununo/master
README: New section on server port and idempotency
2020-07-13 18:52:38 +02:00
Nuno Godinho 4a11070e2c README: New section on server port and idempotency
Add section called "Changing the default port and idempotency" and reference to role ssh-hardening-fallback, a wrapper around this role which implements a fallback to port 22 when the configured port is unreachable.

Signed-off-by: Nuno Godinho <[email protected]>
2020-07-13 16:26:01 +01:00
dev-sec CI 1b6623b899 update changelog 2020-07-12 07:18:59 +00:00
dev-sec CI 476f2ec8e2 update changelog 2020-07-12 07:18:50 +00:00
Sebastian Gumprich cb407267c0 remove mention of gitter 2020-07-12 09:16:53 +02:00
Sebastian Gumprich 4494ddd132 remove mention of gitter 2020-07-12 09:16:33 +02:00
Sebastian Gumprich 990f95807f remove mention of gitter 2020-07-12 09:16:22 +02:00
Sebastian Gumprich 8e7ce74953 remove mention of gitter 2020-07-12 09:16:04 +02:00
dev-sec CI 10888d72ab update changelog 2020-07-09 11:55:15 +00:00
Sebastian Gumprich 147a26c27a Merge pull request #305 from dev-sec/order_crypto
add blocks to crypto.yml checks
2020-07-09 13:52:21 +02:00
Sebastian Gumprich fda42b7022 Merge branch 'master' into order_crypto 2020-07-09 13:40:39 +02:00
Sebastian Gumprich 4c248a4901 remove obsolete include_task 2020-07-09 13:33:19 +02:00
Martin Schurz 18be974509 remove crypto.yml
move include tasks to hardening.yml and remove intermediate crypto.yml

Signed-off-by: Martin Schurz <[email protected]>
2020-07-09 12:56:39 +02:00
Martin Schurz 5e47ffae35 split crypto.yml in several playbooks
preserve the version ordering of defaults and group all tasks according
to base configuration variable (cipthers, hostkeys, kex and macs)

Signed-off-by: Martin Schurz <[email protected]>
2020-07-09 11:46:23 +02:00
dev-sec CI d87f6c6212 update changelog 2020-07-09 06:22:57 +00:00