Keyring: Secure Password Storage

25.7.0 · active · verified Sat Mar 28

Keyring is a Python library that provides an easy way to access the system's keyring service, allowing applications to store and retrieve passwords securely. The current version is 25.7.0, released on September 20, 2023. Keyring follows a regular release cadence, with updates addressing compatibility, security, and functionality improvements.

Warnings

Install

Imports

Quickstart

A simple example demonstrating how to set and retrieve passwords using the Keyring library.

import keyring

# Set a password
keyring.set_password('system', 'username', 'password')

# Retrieve a password
retrieved_password = keyring.get_password('system', 'username')
print(retrieved_password)

view raw JSON →