Skip to content
This repository has been archived by the owner on Feb 12, 2023. It is now read-only.

Commit

Permalink
Adds support for Let's Encrypt x Certbot (#52)
Browse files Browse the repository at this point in the history
undefined
  • Loading branch information
AntociAlin committed Sep 26, 2022
1 parent c255c5c commit e67e27c
Show file tree
Hide file tree
Showing 10 changed files with 607 additions and 448 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/website_trigger.yaml
Expand Up @@ -20,4 +20,4 @@ jobs:
repo: "website",
workflow_id: "update_autodocs.yml",
ref: "main"
})
})
8 changes: 4 additions & 4 deletions README.md
Expand Up @@ -68,7 +68,7 @@ Come join the MutableSecurity journey!
</td>
<td>Clam AntiVirus (ClamAV) is a free software, cross-platfom antimalware toolkit able to detect many types of malware, including viruses. ClamAV includes a command-line scanner, automatic database updater, and a scalable multi-threaded daemon running on an anti-virus engine from a shared library. FreshClam is a virus database update tool for ClamAV. ClamAV Daemon checks periodically for virus database definition updates, downloads, installs them, and notifies clamd to refresh it's in-memory virus database cache.</td>
<td>
<img alt='Maturity: Production' src='https://img.shields.io/badge/Maturity-Production-blightgreen?style=flat-square'>
<img alt="Maturity: Production" src="https://img.shields.io/badge/Maturity-Production-blightgreen?style=flat-square">
</td>
</tr> <tr>
<td>
Expand All @@ -78,7 +78,7 @@ Come join the MutableSecurity journey!
</td>
<td>teler is a real-time intrusion detection and threat alert based on web log. Targets only nginx installed on Ubuntu.</td>
<td>
<img alt='Maturity: Production' src='https://img.shields.io/badge/Maturity-Production-blightgreen?style=flat-square'>
<img alt="Maturity: Production" src="https://img.shields.io/badge/Maturity-Production-blightgreen?style=flat-square">
</td>
</tr> <tr>
<td>
Expand All @@ -98,7 +98,7 @@ Come join the MutableSecurity journey!
</td>
<td>Let's Encrypt is a free, automated, and open certificate authority brought to you by the nonprofit Internet Security Research Group (ISRG). Certbot is a free, open source software tool for automatically using Let's Encrypt certificates on manually-administrated websites to enable HTTPS.</td>
<td>
<img alt='Maturity: Under refactoring' src='https://img.shields.io/badge/Maturity-Under%20refactoring-yellowgreen?style=flat-square'>
<img alt="Maturity: Under refactoring" src="https://img.shields.io/badge/Maturity-Under%20refactoring-yellowgreen?style=flat-square">
</td>
</tr> <tr>
<td>
Expand All @@ -108,7 +108,7 @@ Come join the MutableSecurity journey!
</td>
<td>Suricata is the leading independent open source threat detection engine. By combining intrusion detection (IDS), intrusion prevention (IPS), network security monitoring (NSM) and PCAP processing, Suricata can quickly identify, stop, and assess even the most sophisticated attacks.</td>
<td>
<img alt='Maturity: Under refactoring' src='https://img.shields.io/badge/Maturity-Under%20refactoring-yellowgreen?style=flat-square'>
<img alt="Maturity: Under refactoring" src="https://img.shields.io/badge/Maturity-Under%20refactoring-yellowgreen?style=flat-square">
</td>
</tr>
<tr>
Expand Down
15 changes: 5 additions & 10 deletions mutablesecurity/cli/cli.py
Expand Up @@ -14,17 +14,12 @@

from mutablesecurity.cli.feedback_form import FeedbackForm
from mutablesecurity.cli.printer import Printer
from mutablesecurity.cli.solutions_manager_adapter import (
SolutionsManagerAdapter,
)
from mutablesecurity.cli.solutions_manager_adapter import \
SolutionsManagerAdapter
from mutablesecurity.helpers.exceptions import (
BadArgumentException,
BadValueException,
MutableSecurityException,
StoppedMutableSecurityException,
UnexpectedBehaviorException,
UnsupportedPythonVersionException,
)
BadArgumentException, BadValueException, MutableSecurityException,
StoppedMutableSecurityException, UnexpectedBehaviorException,
UnsupportedPythonVersionException)
from mutablesecurity.leader import ConnectionFactory
from mutablesecurity.main import Main
from mutablesecurity.monitoring import Monitor
Expand Down
1 change: 1 addition & 0 deletions mutablesecurity/solutions/common/facts/files.py
Expand Up @@ -11,6 +11,7 @@ class FilePresenceTest(FactBase):
@staticmethod
def command(path: str, exists: bool) -> str:
prefix = "" if exists else "!"

return f"if [ {prefix} -e {path} ] ; then echo '1'; else echo '0' ; fi"

@staticmethod
Expand Down
17 changes: 17 additions & 0 deletions mutablesecurity/solutions/common/operations/apt.py
@@ -0,0 +1,17 @@
"""Module with apt operations."""
import typing

from pyinfra.api import operation


@operation
def autoremove() -> typing.Generator[str, None, None]:
"""Removes residual data automatically.
Args:
no args
Yields:
Iterator[typing.Generator[str, None, None]]: Command to execute
"""
yield "apt -y autoremove"

0 comments on commit e67e27c

Please sign in to comment.