Skip to content

libsecret_error: Failed to unlock the keyring #6440

Closed as not planned
Closed as not planned

Description

@kcdev001

I developed my app using Flutter, and it runs fine when packaged as a deb or appimage.

However, it throws an error when built using flatpak. I don't know what the problem is, so I'd appreciate any help.

My configuration file is here: https://github.com/keychat-io/flathub/tree/new-pr
Build Command: flatpak-builder --repo=repo --force-clean --sandbox --install --install-deps-from=flathub build com.keychat.io.yml --verbose

Runing Error:

flatpak run com.keychat.io --verbose

Gtk-Message: 18:02:11.357: Failed to load module "canberra-gtk-module"
Gtk-Message: 18:02:11.358: Failed to load module "canberra-gtk-module"
libEGL warning: DRI3 error: Could not get DRI3 device
libEGL warning: Ensure your X server supports DRI3 to get accelerated rendering
IsarCore using libmdbx: v0.13.8-temp-upstream-fix

** (keychat:2): WARNING **: 18:02:11.740: libsecret_error: Failed to unlock the keyring
[ERROR:flutter/runtime/dart_vm_initializer.cc(40)] Unhandled Exception: PlatformException(Libsecret error, Failed to unlock the keyring, null, null)
#0      StandardMethodCodec.decodeEnvelope (package:flutter/src/services/message_codecs.dart:653)
#1      MethodChannel._invokeMethod (package:flutter/src/services/platform_channel.dart:367)
<asynchronous suspension>
#2      SecureStorage.isBiometricsEnable (package:keychat/service/secure_storage.dart:176)
<asynchronous suspension>
#3      SettingController.loadBiometricsStatus (package:keychat/controller/setting.controller.dart:65)
<asynchronous suspension>
#4      SettingController.onInit (package:keychat/controller/setting.controller.dart:30)
<asynchronous suspension>

Could it be a problem with this library?
juliansteenbakker/flutter_secure_storage#778

The key issue is that my program runs fine when I don't use flatpak. You can download the app here to test it:

https://github.com/keychat-io/keychat-app/releases

Activity

  1. bbhtt commented on Dec 16, 2025

    @bbhtt
    Collaborator

    It's a bug in that lib.

  2. kcdev001 commented on Dec 18, 2025

    @kcdev001
    Author

    How can you explain why this library runs normally in a non-flatpak environment?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions