Service


Object Hierarchy:

Object hierarchy for Service

Description:

[ CCode ( type_id = "secret_service_get_type ()" ) ]
public class Service : DBusProxy, AsyncInitable, DBusInterface, Initable, Backend

A proxy object representing the Secret Service.

A Service object either represents an implementation of the `org.freedesktop.Secret` D-Bus service or a file that is encrypted using a master secret that was provided by the secret portal.

Normally a single Service object can be shared between multiple callers. The [func@Service.get] method is used to access this Service object. If a new independent Service object is required, use [func@Service.open].

In order to securely transfer secrets to the Sercret Service, a session is established. This session can be established while initializing a Service object by passing the secret_service_open_session flag to the [func@Service.get] or [func@Service.open] functions. In order to establish a session on an already existing Service, use the [method@Service.ensure_session] function.

To search for items, use the [method@Service.search] method.

Multiple collections can exist in the Secret Service, each of which contains secret items. In order to instantiate [class@Collection] objects which represent those collections while initializing a Service then pass the secret_service_load_collections flag to the [func@Service.get] or [func@Service.open] functions. In order to establish a session on an already existing Service, use the [method@Service.load_collections] function. To access the list of collections use [method@Service.get_collections].

Certain actions on the Secret Service require user prompting to complete, such as creating a collection, or unlocking a collection. When such a prompt is necessary, then a [class@Prompt] object is created by this library, and passed to the [method@Service.prompt] method. In this way it is handled automatically.

In order to customize prompt handling, override the [vfunc@Service.prompt_async] and [vfunc@Service.prompt_finish] virtual methods of the Service class.


Namespace: Secret
Package: libsecret-1

Content:

Static methods:

Creation methods:

Methods:

Inherited Members:

All known members inherited from interface GLib.AsyncInitable
All known members inherited from interface GLib.DBusInterface
All known members inherited from interface GLib.Initable
All known members inherited from interface Secret.Backend