Additional utility functions

This module provides some utility functions, but these shouldn’t normally be used by external applications.

secretstorage.util.format_secret(session, secret, content_type)[source]

Formats secret to make possible to pass it to the Secret Service API.

secretstorage.util.exec_prompt(bus, prompt, callback)[source]

Executes the given prompt, when complete calls callback function with two arguments: a boolean representing whether the operation was dismissed and a list of unlocked item paths. A main loop should be running and registered for this function to work.

secretstorage.util.exec_prompt_glib(bus, prompt)[source]

Like exec_prompt(), but synchronous (uses loop from GLib API). Returns (dismissed, unlocked) tuple.

secretstorage.util.exec_prompt_qt(bus, prompt)[source]

Like exec_prompt(), but synchronous (uses loop from PyQt4 API). Returns (dismissed, unlocked) tuple.

Previous topic

The secretstorage.item module

Next topic

Possible exceptions

This Page