Interestingly, I just hit this issue after moving to core-updates-frozen. Not sure what caused it now, p11-kit nor flatpak has changed, but must be something between them.
Unfortunately, this would cause a huge rebuild from what I can tell, so I tried --with-graft and it didn't seem to make a difference. Also, p11-kit is now out of date, with the latest version being 0.24.0.
So, perhaps this could make its way into core-updates-frozen with the upcoming world rebuild coming? https://bugs.gnu.org/50860Also wanted to note that this change would match what nix does with p11-kit for the same reason.
Open to other suggestions, hoping to not break flatpak in core-updates-frozen.
For the record, I'm using the beta of Flatpak (installs fine with --with-source transformation), version 1.11.3.
Also, I found a workaround by manually killing the p11-kit server and running a new one that I built with this patch and updated to the latest version. In case this helps anyone, I ran with the parameters Flatpak tries to launch:
p11-kit server --sh -n /run/user/1000/.flatpak-helper/pkcs11-flatpak-#### --provider p11-kit-trust.so "pkcs11:model=p11-kit-trust?write-protected=yes"
where the -n argument #### came from trying to run a Flatpak app and seeing it fail not finding the p11-kit server at that socket. Probably you can do this more easily by forcing Flatpak when it first runs to use the fixed p11-kit version (through a patch in Flatpak or some environment setting? or what the system starts?). But with p11-kit server already running for me, this did the trick for testing.
On Monday, October 25th, 2021 at 3:13 PM, Ludovic Courtès <email@example.com> wrote:
Toggle quote (18 lines)
> Andrew Whatson firstname.lastname@example.org skribis:
> > Flatpak has a soft dependency on p11-kit, which was configured without
> > knowledge of the system-wide CA certificate store. This caused some
> > flatpak apps to fail with ERR_CERT_AUTHORITY_INVALID errors.
> > - gnu/packages/tls.scm (p11-kit): Configure with
> > /etc/ssl/certs/ca-certificates.crt as a trusted path.
> I pushed a similar fix on ‘master’ based on John’s patch as
> We might as well update the default p11-kit though? (Somehow I was
> assuming it had many dependents, but it only has 80+.)
Flatpak's dependency doesn't show up on a guix refresh --list-dependents p11-kit, as it comes through some other package somehow (I never looked how exactly). But I guess that is more "using" than needing to build against? Wondering if there are some hidden runtime cases to look out for. (Probably more relevant when thinking of changing that configure flag?)
For this bug, the fixes that I wrote did need a cleaning out of previous Flatpaks (checking how you launch Flatpak apps as our previous version put the full store path in .desktop files) as p11-kit gets started in some indirect way. I think via D-Bus and its portal, but the system p11-kit could be used instead of the fixed version. I made sure to remove previous Flatpak installs from my profile and did a restart to be sure. Noting here for completeness.