fix(sagent): secure file location

This commit is contained in:
xiongdian.me 2024-08-28 09:59:07 +08:00
parent a45828ea43
commit 2beb9ebbf9
2 changed files with 3 additions and 2 deletions

View File

@ -61,7 +61,8 @@ reset()
all()
{
local agent_file="/tmp/piv-agent-$(whoami)"
test -d ~/.ssh || mkdir ~/.ssh
local agent_file=~/.ssh/agent-$(whoami)
if [[ -f $agent_file ]]; then
source $agent_file > /dev/null
else

View File

@ -49,7 +49,7 @@ alias p114
alias cbds
which riot
sagt
test -f "/tmp/piv-agent-$(whoami)"
test -f ~/.ssh/agent-$(whoami)
gbes || which gbes
# check update