Commit Graph

484 Commits

Author SHA1 Message Date
Dmitriy Rabotyagov 38909eae0e Switch sphinx language to en
With sphinx release of 5.0.0, they changed default for language variable
to 'en' from None. With that current None valuable is not valid and should
not be used.


Change-Id: I159a23ae2c147f75c0944a0a5e92f1a19ba20e2b
2022-05-30 16:01:18 +02:00
Dmitriy Rabotyagov 180fc448eb Make possible to avoid aide installation
This patch adds variable `security_rhel7_enable_aide`. When it's False,
all AIDE related tasks would be ommited.

Change-Id: I64af348d9f49922ab51d8cd348d987df4263faa1
2021-02-02 14:12:10 +00:00
Zuul 1890dc0520 Merge "Stop to use the __future__ module." 2020-07-27 12:04:52 +00:00
Andreas Jaeger 260b23b9b6 Use newer openstackdocstheme and reno versions
The sync from https://review.opendev.org/733244 updated to
openstackdocstheme 2.2.1 and reno 3.1.0 versions.

Set openstackdocs_pdf_link to link to PDF file. Note that
the link to the published document only works on docs.openstack.org
where the PDF file is placed in the top-level html directory. The
site-preview places the PDF in a pdf directory.

openstackdocstheme renames some variables, so follow the renames
before the next release removes them. A couple of variables are also
not needed anymore, remove them.

See also
http://lists.openstack.org/pipermail/openstack-discuss/2020-May/014971.html

Change-Id: Id2c810e9214981f381d5a9d4f1f2e40cb63a02af
2020-06-04 09:22:27 +02:00
OpenStack Proposal Bot 53bcfcf743 Updated from OpenStack Ansible Tests
Change-Id: Idf23e61424fc04fdd4f0804ced5742e25dc5f9b9
2020-06-04 09:21:15 +02:00
Andreas Jaeger 1fa67fd90d Enable syncing of docs
The docs job is failing in https://review.opendev.org/671840 and thus
nothing is synced in from openstack-ansible-tests. The failure is due to
the removal of entries from doc/requirements.txt. Add those
to test-requirements.txt instead.

Change-Id: I21bcbde8acc8d4fd83b28026bcec33f388e69912
2020-06-03 22:04:16 +02:00
Hervé Beraud b2b89afb08 Stop to use the __future__ module.
The __future__ module [1] was used in this context to ensure compatibility
between python 2 and python 3.

We previously dropped the support of python 2.7 [2] and now we only support
python 3 so we don't need to continue to use this module and the imports
listed below.

Imports commonly used and their related PEPs:
- `division` is related to PEP 238 [3]
- `print_function` is related to PEP 3105 [4]
- `unicode_literals` is related to PEP 3112 [5]
- `with_statement` is related to PEP 343 [6]
- `absolute_import` is related to PEP 328 [7]

[1] https://docs.python.org/3/library/__future__.html
[2] https://governance.openstack.org/tc/goals/selected/ussuri/drop-py27.html
[3] https://www.python.org/dev/peps/pep-0238
[4] https://www.python.org/dev/peps/pep-3105
[5] https://www.python.org/dev/peps/pep-3112
[6] https://www.python.org/dev/peps/pep-0343
[7] https://www.python.org/dev/peps/pep-0328

Change-Id: I1d485edac47a29c48e280f99bb2a3839739d7a7b
2020-06-02 19:32:55 +02:00
Andreas Jaeger 986b9058ee Update docstheme for style
New version of openstackdocstheme (Victoria+) respects pygments_style.
Since this repo is using now Victoria (master) requirements but has
not branched for Ussuri yet, it uses the new version.

Change pygments_style to 'native' since old theme version always used
'native' and the theme now respects the setting and using 'sphinx' can
lead to some strange rendering.

Change-Id: I3fe3956b80df054c8b56761e4c009457af5c98f0
2020-05-20 17:24:56 +00:00
Dmitriy Rabotyagov b7bd353139 Remove ⌘ symbol from docs
LaTex was failing because it isn't configured to render this symbol.

Change-Id: I77a5c7b9af578bcadc6b1027cf4d667e85f04e8b
2020-05-14 22:58:40 +03:00
Andreas Jaeger 6e23deb6af Cleanup py27 support
This repo is now testing only with Python 3, so let's make
a few cleanups:
- Remove python 2.7 stanza from setup.py
- Remove obsolete sections from setup.cfg
- Update requirements, no need for python_version anymore
- Use newer openstackdocstheme and Sphinx versions
- Cleanup */source/conf.py to remove now obsolete content.
- Remove install_command from tox.ini, the default is fine

Change-Id: Ic96b71596d4523e55fa4b451c99a8521dd581e4d
2020-04-25 15:07:26 +02:00
pengyuesheng be148a0bad Bump the openstackdocstheme extension to 1.20
Some options are now automatically configured by the version 1.20:
- project
- html_last_updated_fmt
- latex_engine
- latex_elements
- version
- release.

Change-Id: I14b62b4010950877d58a615de5f671ab6c866b48
2019-10-24 17:47:03 +08:00
Dmitriy Rabotyagov 9cfc60f307 PDF Documentation Build tox target
This patch adds a `pdf-docs` tox target that will build
PDF versions of our docs. As per the Train community goal:

  https://governance.openstack.org/tc/goals/selected/train/pdf-doc-generation.html

Add sphinxcontrib-svg2pdfconverter to doc/requirements.txt
to convert our SVGs.

Change-Id: I04319a1195873d63bfc45ffb0f5c7c89fb797652
Story: 2006105
2019-10-17 17:37:23 +00:00
Zuul 97ba470d24 Merge "Update the HTTP links to HTTPS in developer-guide.rst." 2019-04-24 20:21:43 +00:00
Zuul 88be53fb3e Merge "Optimizing the safety of the http link site in index.rst." 2019-04-24 20:21:42 +00:00
Zuul c5ef141730 Merge "Applying the HTTPS protocal in index.rst." 2019-04-24 20:21:41 +00:00
Zuul 381b1f9c86 Merge "Optimizing the safety of the http link site in index.rst." 2019-04-24 20:21:41 +00:00
zhouxinyong 66604c0a41 Advancing the protocal of the website to HTTPS in index.rst.
Change-Id: I30e489be1d60c44468416a02fc184d9e6cc6b31b
2018-11-13 19:19:56 +08:00
zhouxinyong 0df683afa8 Optimizing the safety of the http link site in index.rst.
Change-Id: Ie48d905525628c2f15f9cbb1be64a24e413cc1ce
2018-11-13 19:17:16 +08:00
zhouxinyong 7c9f084abe Applying the HTTPS protocal in index.rst.
Change-Id: Ie6cc3bfcb66b6955baa1e750c2cd99b5fdc5a108
2018-11-13 19:14:34 +08:00
zhouxinyong da0eea5104 Optimizing the safety of the http link site in index.rst.
Change-Id: Ib44fef76dd45599e4d02e0629998435528971cd2
2018-11-13 19:11:02 +08:00
zhouxinyong 08f408b303 Update the HTTP links to HTTPS in developer-guide.rst.
Change-Id: Icd647f106b69d7604dbccdec1504710b4445db78
2018-11-13 19:07:47 +08:00
Jesse Pretorius a91f762c33 docs: Write files in binary mode
For python3, the mode for writing the file is required.

Change-Id: Idc17e36bb88c786027c0d6476b54844ae5d7f81e
2018-10-04 00:55:07 +01:00
Kevin Carter 1cafaf8cce Add option to skip sudoers NOPASSWD check
This change adds the option `security_sudoers_nopasswd_check_enable`
when running check "V-71947". This change allows users to skip this
check via ansible extra variable instead of having to skip tags. While
this change has a functional benifit in some environments, it is being
done with the primary intention of providing a better experience to
deploying running clouds where services like cloud-init may be present.

Change-Id: I0d0c95534ace0b00fa64c2f243ad91ce5844d85a
Closes-Bug: #1741225
Signed-off-by: Kevin Carter <kevin.carter@rackspace.com>
2018-07-31 03:18:27 +00:00
Zuul 0dc69da871 Merge "Fix instructions for opting in to V-72115" 2018-07-19 07:40:44 +00:00
rtweed d19360e79a Fixes invalid URL in STIG Deviations summary page
Change-Id: I9d39c29de964ed5b5edfdf08771e36ab28172efc
Closes-Bug: 1768654
2018-06-13 18:25:14 +02:00
Eric Amador b038fd9374 Fix instructions for opting in to V-72115
The docs previously specified that the wrong boolean value should be set
in order to opt-in to control V-72115. The variable
security_rhel7_audit_lsetxattr has a value of no by default.

Change-Id: I2701ada847404a629de44a548ace2f5e9424638d
2018-06-12 14:08:04 -04:00
OpenStack Proposal Bot 5dda1f6592 Updated from global requirements
Change-Id: I566916c4705088c75c6ab5b1e1ebe5c4f8e9fbe2
2018-03-15 06:44:52 +00:00
melissaml 540408f597 Follow the new PTI for document build
For compliance with the Project Testing Interface as described in:
https://governance.openstack.org/tc/reference/project-testing-interface.html

For more detials information, please refer to:
http://lists.openstack.org/pipermail/openstack-dev/2017-December/125710.html

Change-Id: I56c7a5247235f550ee3ed4344f79c8fa9e86cc67
2018-03-12 12:48:34 +08:00
Major Hayden a10fae4fe1 Replace Fedora 26 with 27
Now that infra is moving from Fedora 26 to 27, we need to update
the role to reflect the changing support for Fedora releases.

Change-Id: Icce8fd7ee2f8c54e6eb33beec7af96c4d1d375d6
Signed-off-by: Major Hayden <major@mhtx.net>
2018-03-07 13:30:45 +00:00
Zuul c54fc86bfd Merge "Add scaffolding for contrib tasks" 2017-12-01 14:16:46 +00:00
Zuul 422b793b80 Merge "Change PermitRootLogin to allow alternate options" 2017-11-14 16:34:28 +00:00
Andy McCrae f32cb3c081 Change PermitRootLogin to allow alternate options
PermitRootLogin can be 'yes', 'no', 'without-password',
'prohibit-password' or 'forced-commands-only'.
This patch changes the functionality to ensure that
security_sshd_permit_root_login is one of the above settings - if so, it
will use that value.

Due to the way Ansible handles "no" and "yes", we have to check if the
value is "False" (string equivalent for boolean no), and if so output
"no", otherwise output the string (which would be one of the above
options).

Previously, we could only set this value to 'no'.

Change-Id: I5ee5ff6abc4578d17d4b23d8a2fa1648508ceeed
2017-11-09 15:18:28 +00:00
Major Hayden 2d407a5399
Add scaffolding for contrib tasks
This patch adds the basic scaffolding for developer-contributed
hardening standards that are outside the scope of the Security
Technical Implementation Guide (STIG). Deployers have the option
to deploy these hardening standards as well.

Change-Id: I33175ffd36a75d27e5ac6c13aaf1584e5fdf23dd
2017-11-08 07:28:47 -06:00
Zuul dc194a1ac4 Merge "Optionally search for world-writable files" 2017-11-06 16:44:10 +00:00
Zuul 6bd3cc9115 Merge "Docs/Reno fixes" 2017-11-06 16:21:02 +00:00
Zuul ff73470848 Merge "Make check of package checksums configurable" 2017-11-06 13:16:55 +00:00
Major Hayden 55afc0fce3
[Docs] Specify STIG version in branches
Change-Id: I82cdc0c8aa415beb39b2cf59013ef56454adfd3f
2017-11-02 08:41:07 -05:00
Christian Berendt baa5db7768 Make check of package checksums configurable
Change-Id: I9ac64d7995223a20b956d0a1b83bd1a60e556c03
2017-11-02 09:01:35 +01:00
Major Hayden 782bb48c14
Update to RHEL 7 STIG V1R3
This patch updates the tasks to match the changes in Version 1,
Release 3 of the RHEL 7 STIG. It adds four new configurations:

  - V-77819 (docs only, manual intervention req'd)
  - V-77821 (disabling DCCP, implemented)
  - V-77823 (docs only, manual intervention req'd)
  - V-77825 (enabling ASLR, implemented)

Closes-Bug: 1729344
Change-Id: I009fb31139e654f839d94781baf3d392c6613f46
2017-11-01 13:31:34 -05:00
Major Hayden a84b6847fc
Optionally search for world-writable files
The search for world-writable files is very intensive and causes
some long delays when running playbooks. This patch makes it
optional and updates the documentation to match.

Change-Id: I206f75597c48023a889bd7027daff2eff82b1a16
2017-10-30 13:56:13 -05:00
Major Hayden 6061695c85
Docs/Reno fixes
This patch fixes a ton of broken links, documentation, and reno errors.

Change-Id: If6f9a698a813db9aaf1eb4e10520a4c01cd00407
2017-10-25 12:00:18 -05:00
Major Hayden 231676a93e
Zuulv3 migration
Change-Id: Id9461969a3e365fb2dad0e52abaaedbcd7ebfdd7
2017-10-18 07:31:25 -05:00
Major Hayden ba98871f4b
Update to RHEL 7 V1R2 STIG
This patch updates the STIG XML to version 1 release 2.

The new release does not have V-72181 included, so the relevant
tasks and variables have been removed.

Closes-Bug: 1718772
Change-Id: I441dbacdfa82e49c0c24f86e303706ae79c7d4dd
2017-09-21 16:02:42 -05:00
Major Hayden 0c0767b3f1
Queens doc updates + removal of RHEL 6 STIG
This patch begins the teardown of the RHEL 6 STIG content from the
ansible-hardening repository. It will still be maintained in
Pike and earlier branches.

This patch also updates the ansible-hardening documentation for the
Queens release and notes that Pike is the latest stable version.

Closes-Bug: 1715745
Change-Id: Iaae52c97a35d82dd807ef78a1a6593ce3aa33540
2017-09-12 08:19:54 -06:00
Major Hayden b352760fd1
Fedora 26 support
This patch adds support for Fedora 26.

Depends-On: Ic4ea169908fec86623dbe91859ec524e48683ab7
Change-Id: I590bed829d9e3b7a6df477a00b65bfc10fc64dae
2017-08-28 07:33:16 -05:00
Marc Gariepy 3c632174e9 Change default prohibit root sshd password auth
Change-Id: Ib195041cd84bafa0cc7ca1d2ca42041618ce181d
2017-08-16 14:05:18 +00:00
Jenkins 4a2056e01f Merge "[Docs] Make install/usage docs more clear" 2017-07-21 14:15:38 +00:00
Jenkins 3fe83a0d24 Merge "Conditionally install EPEL if needed" 2017-07-12 18:41:48 +00:00
Jenkins eac2d7522a Merge "Correct the list of supported OS versions" 2017-07-12 16:11:46 +00:00
Major Hayden a64c833a71 Conditionally install EPEL if needed
The current behavior of the hardening role is to install the
epel-release package on all deployments. This patch changes
the logic to only install the EPEL repository if the deployer
has asked for ClamAV to be installed.

The patch also provides an option to disable the installation
of EPEL entirely using a variable.

Closes-Bug: 1702167
Change-Id: I9c5e6048f95636faf2a6d71ac9217ba69ca41296
2017-07-12 15:40:33 +00:00