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

[fail2ban] Add new plugin for fail2ban #3685

Merged
merged 1 commit into from
Jun 27, 2024
Merged

[fail2ban] Add new plugin for fail2ban #3685

merged 1 commit into from
Jun 27, 2024

Conversation

slapcat
Copy link
Contributor

@slapcat slapcat commented Jun 22, 2024

New plugin for fail2ban daemon.


Please place an 'X' inside each '[]' to confirm you adhere to our Contributor Guidelines

  • Is the commit message split over multiple lines and hard-wrapped at 72 characters?
  • Is the subject and message clear and concise?
  • Does the subject start with [plugin_name] if submitting a plugin patch or a [section_name] if part of the core sosreport code?
  • Does the commit contain a Signed-off-by: First Lastname email@example.com?
  • Are any related Issues or existing PRs properly referenced via a Closes (Issue) or Resolved (PR) line?
  • Are all passwords or private data gathered by this PR obfuscated?

Copy link

Congratulations! One of the builds has completed. 🍾

You can install the built RPMs by following these steps:

  • sudo yum install -y dnf-plugins-core on RHEL 8
  • sudo dnf install -y dnf-plugins-core on Fedora
  • dnf copr enable packit/sosreport-sos-3685
  • And now you can install the packages.

Please note that the RPMs should be used only in a testing environment.

Copy link
Member

@TurboTurtle TurboTurtle left a comment

Choose a reason for hiding this comment

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

Overall looks good, just a couple suggestions.

sos/report/plugins/fail2ban.py Outdated Show resolved Hide resolved
sos/report/plugins/fail2ban.py Outdated Show resolved Hide resolved
sos/report/plugins/fail2ban.py Outdated Show resolved Hide resolved
sos/report/plugins/fail2ban.py Outdated Show resolved Hide resolved
@arif-ali
Copy link
Member

Just doubling check, any config files we are collecting here, any passwords that needs obfuscating?

Also the trail line is still there, in the recent push

@slapcat
Copy link
Contributor Author

slapcat commented Jun 22, 2024

Just doubling check, any config files we are collecting here, any passwords that needs obfuscating?

There should not be any passwords, but the fail2ban-client banned output will contain IP addresses. I know in some circumstances these would be obfuscated, but I don't think it would make sense here since it would be valuable diagnostic data for troubleshooting fail2ban issues.

@arif-ali
Copy link
Member

overall, looks good to me, before we can merge this, we need the commits to be squashed, so that we have one commit for the PR. Once you do that we can move this one forward

@arif-ali
Copy link
Member

just coming back to this PR< is there any reason why we just don't do /etc/fail2ban and the reason for specifically pointing out those directories? As per @pmoravec issue raised in #3686 we have potential 2 identical items being collecting, and hence could have an issue here

New plugin for fail2ban daemon.

Signed-off-by: Jake Nabasny <jake.nabasny@canonical.com>
@slapcat
Copy link
Contributor Author

slapcat commented Jun 26, 2024

Nothing sensitive should be in /etc/fail2ban, so it is okay to grab the entire directory. I've updated the code to reflect that and address the issue raised in #3686.

Copy link
Member

@arif-ali arif-ali left a comment

Choose a reason for hiding this comment

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

thanks, lgtm

sos/report/plugins/fail2ban.py Outdated Show resolved Hide resolved
@arif-ali arif-ali merged commit ca7300e into sosreport:main Jun 27, 2024
32 checks passed
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.

4 participants