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

Add AppArmor profile for Debian and Ubuntu installations #1183

Merged
merged 2 commits into from
Nov 30, 2022

Conversation

kernelmethod
Copy link
Contributor

This PR adds an AppArmor profile for GoToSocial to examples/apparmor/gotosocial. The security guarantees provided by the profile should be roughly comparable to those provided by SELinux, but will work on Debian-family Linux distros (as well as some others, like OpenSUSE). The profile I've provided has been primarily tested and verified to work with the Docker-based deployment for GTS, but should also work for people who use the binary installation method.

I've also updated the security documentation (Federation > Security) to include an "application sandboxing" section, which currently has some AppArmor setup instructions that I've included as well as instructions for SELinux (which were previously provided in Installation Guide > Binary Installation From Release.

@kernelmethod
Copy link
Contributor Author

Let me know if there's a better place to put the new documentation. My understanding is that the SELinux documentation was put in the Binary Installation From Release instructions since it wasn't intended to be compatible with Docker installations (whereas the AppArmor profile should be compatible with both methods that are currently specified).

@tsmethurst
Copy link
Contributor

Thanks for the PR :)

I think instead of putting it in federation/security, it should go in the Advanced section of the install instructions. What do you think?

The admonitions extension to Python-Markdown allows you to include
rST-style "admonitions" to Markdown documents, for instance,

    !!! note
        Here's an important note to keep in mind!

In general, the current documentation uses bold text to try to achieve
the same effect, which is a bit harder to notice and makes it difficult
to differentiate between "here's something useful to know" versus "here
there be dragons".
This commit adds an AppArmor profile for gotosocial in
examples/apparmor/gotosocial. This will (hopefully) serve as a helpful
security mitigation for people are planning on deploying GTS on a
Debian-family Linux distribution.

I've also updates the documentation to include some information about
deploying GTS with either AppArmor or SELinux (moving the documentation
for the former out of the "binary installation guide" docs).
@kernelmethod
Copy link
Contributor Author

kernelmethod commented Nov 30, 2022

Sure! That sounds reasonable to me. I've just updated my branch so that the new documentation is now in Installation Guide > Advanced.

@tsmethurst
Copy link
Contributor

Great, thank you! This is very well written and clear, i look forward to trying it myself :D

@tsmethurst tsmethurst merged commit 1652633 into superseriousbusiness:main Nov 30, 2022
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.

None yet

2 participants