sloonz’s blog

Wireguard: Beyond the most basic configuration

Last week I wanted to replace my OpenVPN setup with WireGuard. The basics were well-documented, going beyond the basics was a bit trickier. Let me teach you want I learned. The basics But first, let’s summarize the basics. I have a server with a hosting provider that I want to use as a VPN server. I won’t delve into details here, since there are so many great explanations on the web already (here, here, here or here), let’s just make a quick summary of a simple setup, as a base for discussing the (slightly) more advanced usages I had to configure myself:...

June 28, 2024 · sloonz

AI Usage in Practice : Discovering Cody Internals

Lately, I’ve been trying to integrate the huge advance of AI to help my day-to-day tasks. A big help would be a useful programming assistant. ChatGPT already is a big help ; integrating it more tightly into workflow would probably a bigger help. I don’t really care about things like Copilot, which are really “autocomplete on steroids” ; that’s just not how I use ChatGPT. I usually start by specifying what I want to do, ask ChatGPT to rephrase my specifications, clarify misunderstandings, ask ChatGPT to give me an implementation and then iterate on this implementation (for example, “Your implementation does not take into account requirement #2”)....

January 25, 2024 · sloonz

Sandboxing Applications with Bubblewrap: A Simple Script

Previously in this series, we discovered how to use bubblewrap to sandbox simple applications. Then, we moved on to more complex applications, and concluded that, while it works, the long command lines used were getting very unwieldy. I will now present you the script (unimaginatively called sandbox) I use to sandbox my applications. Its configuration file is located at ~/.config/sandbox.yml. It starts with resources : mostly path binds, but also environment variables and D-Bus services....

January 8, 2024 · sloonz

Sandboxing Applications with Bubblewrap: Desktop Applications

Last time, we discovered how to use bubblewrap to sandbox simple CLI applications. We will now try to sandbox desktop applications. Desktop applications want access to a lot of different resources: for example the Wayland (or X) server socket, sound server socket or D-Bus services. You could grant blanket access to all such resources for every application, but that increases the attack surface quite a lot. An alternative is to give access only to resources used by the application you’re trying to sandbox — though figuring this out isn’t always straightforward since nobody cares documenting the resources they are using....

January 1, 2024 · sloonz

Sandboxing Applications with Bubblewrap: Securing a Basic Shell

Everybody knows that allowing different applications unlimited access to each other’s data is not exactly optimal from a security point of view. While servers have enjoyed containers to isolate applications from each other, we lack a good solution for the desktop. Or do we? There is, obviously, flatpak. Unfortunately, flatpak present itself as a “Linux application sandboxing and distribution framework”. This will not do. I already have a distribution. I’m pretty happy with it....

December 24, 2023 · sloonz