Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

(feature) [COTEF1901-104] Improved test 1.6.4 (coredump.conf) #12

Merged
merged 2 commits into from
Jan 6, 2021

Conversation

jvleminc
Copy link
Collaborator

@jvleminc jvleminc commented Jan 5, 2021

A few recommended settings in /etc/coredump.conf were omitted. This PR adds them, as per the recommendations:

Solution: Add the following line to /etc/security/limits.conf or a /etc/security/limits.d/* file:

* hard core 0

Set the following parameter in /etc/sysctl.conf or a /etc/sysctl.d/* file:

fs.suid_dumpable = 0

Run the following command to set the active kernel parameter:

# sysctl -w fs.suid_dumpable=0

If systemd-coredump is installed:         
edit /etc/systemd/coredump.conf and add/modify the following lines:   <-----------

Storage=none
ProcessSizeMax=0

Run the command:

systemctl daemon-reload

Copy link
Owner

@alivx alivx left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

If systemd-coredump is installed, then you can add the new config.

Storage=none ProcessSizeMax=0 Run the command: systemctl daemon-reload
so, you must check if 'systemd-coredump' is installed first, then you can apply these changes.
or, you can put it in default/main.yaml as config.

Thank you for your effort mate :)

@jvleminc
Copy link
Collaborator Author

jvleminc commented Jan 6, 2021

Hmm, right before the lines I added, systemd-coredump is installed:

    - name: 1.6.4 Ensure core dumps are restricted
      apt:
        name: systemd-coredump
        state: present

So no need for a check. :-)

@alivx alivx merged commit e659401 into alivx:master Jan 6, 2021
@alivx
Copy link
Owner

alivx commented Jan 6, 2021

Merged.
Can you please check issue #1 (👍🏻 @jvleminc :) )

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants