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

Include encryption deps #8

Closed
alexpattyn opened this issue Apr 29, 2021 · 13 comments · Fixed by #97
Closed

Include encryption deps #8

alexpattyn opened this issue Apr 29, 2021 · 13 comments · Fixed by #97
Labels
enhancement New feature or request help wanted Extra attention is needed

Comments

@alexpattyn
Copy link

Is your feature request related to a problem? Please describe.
On distros like fedora silverblue you generally are discouraged from layering packages.

Describe the solution you'd like
Include gocryptfs, CryFS, libfuse in the flatpak.

Additional context
Considering these are sensitive deps I wouldn't want them included in the flatpak unless there was a way to have a flathub bot watch upstream for updates and make automatic PRs.

@mpobaschnig
Copy link
Owner

I tried this at the beginning, but was unsuccessful in doing so. According to this, this and this it is currently not possible to use fuse in a Flatpak. Maybe it is possible, but I'm not sure how.

@alexpattyn
Copy link
Author

Gotcha! I figured there was some reason. However borg does mount its archives as FUSE mounts and other flatpak apps like pika and vorta don't require borg on the host. So those apps may offer a clue. I know pika has a matrix room if you wanted to talk to the dev.

@mpobaschnig
Copy link
Owner

Thanks, I'll look into it again.

@mpobaschnig mpobaschnig mentioned this issue Dec 25, 2021
8 tasks
@mpobaschnig
Copy link
Owner

This is now being implemented at #22 but might take a while.

Help and contributions very much appreciated.

@mpobaschnig mpobaschnig added help wanted Extra attention is needed enhancement New feature or request labels Dec 25, 2021
@mhogomchungu
Copy link

mhogomchungu commented Oct 8, 2024

Greetings,

I have a project named SiriKali and it does what you are doing and i though i should assist in making vaults bundle its dependencies.

My project's manifest file is here and how to biuld and bundle Gocryptfs and Cryfs starts at line 218.

From within your flatpak application, you can get the "out of flatpak" path to where these binaries are installed by parsing the contents of "/.flatpak-info" and then get "Instance/app-path" option.

@mpobaschnig
Copy link
Owner

Thank you very much for your hints and help! I'll take a look at the weekend when I got some more time :)

@mpobaschnig
Copy link
Owner

Hey, I tried your approach and it worked, thanks a lot! I had hoped mounting gocryptfs directories without flatpak-spawn --host would work too but I guess this is probably too much to dive into. Maybe we'll switch over if someone finds out the exact problem.

@mhogomchungu
Copy link

FUSE is not permitted inside Flatpak by design so using "flatpak-spawn --host" is the only available option.

@mpobaschnig
Copy link
Owner

Alright, then there's not much we can do here. Thanks!

@mhogomchungu
Copy link

The problem here was to bundle CryFs and Gocryptfs.

You can bundle them and then use flatpak-spawn --host to run them outside of flatpak. The outside path to these bundled binaries can be obtained using "flatpak-info" file i explained in my first post.

@mpobaschnig
Copy link
Owner

Yes, I tried all of it and it works great! However, I'm still wondering why cryfs works within flatpak while gocryptfs does not when they are both based on fuse.

@mhogomchungu
Copy link

Are you sure CryFs works within flatpak?

It does not work here and i am getting "fuse: device not found, try 'modprobe fuse' first" error.

@mpobaschnig
Copy link
Owner

Unless there's some magic happening, yes. I pushed some work to https://github.com/mpobaschnig/vaults/tree/update-dependencies if you want to look at it or try out (e.g. using GNOME Builder).

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

Successfully merging a pull request may close this issue.

3 participants