#!/bin/bash

# keyring_unlocker: Unlocks the GNOME keyring securely using user input.

# This script prompts for user input password without showing it on the screen,
# and passes it to gnome-keyring-daemon, which is a secure tool for storing and
# retrieving passwords. The keyring is unlocked after the correct password is
# entered.

# Reads user input password without showing it on screen.
read -rsp "Password: " pass

# Takes the entered password and passes it to gnome-keyring-daemon, a tool for securely storing and retrieving passwords.
# This should result in the keyring being unlocked, according to https://superuser.com/a/141232
echo -n "$pass" | gnome-keyring-daemon --login
