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

[CLOYSTER-57] Implement fail2ban #63

Closed

Conversation

lbgracioso
Copy link
Collaborator

The name says everything.

Signed-off-by: Lucas Gracioso <[email protected]>
@lbgracioso lbgracioso added the enhancement New feature or request label Jul 3, 2024
@lbgracioso lbgracioso requested a review from viniciusferrao July 3, 2024 01:31
@lbgracioso lbgracioso marked this pull request as ready for review July 4, 2024 14:14
src/answerfile.cpp Show resolved Hide resolved
[[maybe_unused]] virtual void configure() = 0;

public:
[[maybe_unused]] virtual void install() = 0;
Copy link
Owner

Choose a reason for hiding this comment

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

If it's a virtual void function does it make sense to be [[maybe_unused]]? I don't get it.

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

As an example, the last PR approved that added ITool used install. This one doesn't..

@@ -23,7 +23,8 @@ class NFS : public IService {
const boost::asio::ip::address& address,
const std::string& permissions);

void configure();
void install() final {};
Copy link
Owner

Choose a reason for hiding this comment

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

It does nothing?

Copy link
Owner

Choose a reason for hiding this comment

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

But it should do.

@@ -123,6 +127,7 @@ class AnswerFile {

void loadFile(const std::filesystem::path& path);
std::vector<std::shared_ptr<ITool>> getTools();
std::vector<std::shared_ptr<IService>> getServices();
Copy link
Owner

Choose a reason for hiding this comment

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

Same question regarding the std::shared_ptr.

Copy link
Collaborator Author

@lbgracioso lbgracioso Jul 9, 2024

Choose a reason for hiding this comment

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

I had the feeling we would use it later in different ways, at least when I imagined it and created. That's why I put shared.

For now it's a very simple implementation only to install and configure the tools in a easier way.

@lbgracioso lbgracioso changed the title Implement fail2ban [CLOYSTER-57] Implement fail2ban Aug 26, 2024
@lbgracioso lbgracioso self-assigned this Aug 26, 2024
@viniciusferrao
Copy link
Owner

I think we can hold this PR a little bit, because to it work correctly we need to have a Firewall infrastructure on the code, and we don't have it.

The Firewall will be probably firewalld, however we don't have any control of it yet as we should have.

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

Successfully merging this pull request may close these issues.

2 participants