tessen

default description
git clone https://git.awy.one/tessen.git
Log | Files | Refs | README | LICENSE

commit 7e1fe8e7b5130e6b05b25d071ae4625752c7a2ce
parent 0b9f1ec9cbc513dd41a23998f96d10482ceb7444
Author: Ayush Agarwal <ayush@fastmail.in>
Date:   Wed,  8 Sep 2021 00:37:23 +0530

create `clean` and `die` function

The `clean` function will copy password store data for a specific amount
of time and then clear it. The `die` function is meant to clear the
clipboard and other sensitive data immediately.

Diffstat:
Mtessen | 16++++++++++------
1 file changed, 10 insertions(+), 6 deletions(-)

diff --git a/tessen b/tessen @@ -196,14 +196,18 @@ autotype_key_menu() { fi } -# cleanup jobs before the script exits clean() { + { + sleep "$CLIP_TIME" + wl-copy --clear + } > /dev/null 2>&1 & + disown + unset -v PASSFILE USERNAME PASSWORD PASSDATA_ARR CHOICE +} + +die() { wl-copy --clear - unset -v PASSFILE - unset -v USERNAME - unset -v PASSWORD - unset -v PASSDATA_ARR - unset -v CHOICE + unset -v PASSFILE USERNAME PASSWORD PASSDATA_ARR CHOICE } main() {