summaryrefslogtreecommitdiff
path: root/plugins/ssh-agent
AgeCommit message (Collapse)Author
2022-10-03fix(ssh-agent): silence `ssh-add` if quiet mode is enabled (#11201)Marc Cornellà
Fixes #11201
2021-11-17feat(ssh-agent): add `quiet` option to silence plugin (#9659)Marc Cornellà
Closes #9659 Co-authored-by: Jeff Warner <jeff@develops.software>
2021-10-23fix(ssh-agent): fix check for running `ssh-agent` process with hidepid /proc ↵Marc Cornellà
(#8492) Fixes #8492
2021-10-11fix(ssh-agent): fix for bad `zstyle` command argumentMarc Cornellà
Fixes #10282
2021-10-11feat(ssh-agent): allow lazy-loading SSH identities (#6309)Marc Cornellà
Fixes #7477
2021-09-10Revert "feat(ssh-agent): only start ssh-agent once (#5359)"Marc Cornellà
This reverts commit 7692881d2a61a4ba47eeef5d7827c0d2cb896def.
2021-08-27feat(ssh-agent): allow specifying absolute path to `identities`Marc Cornellà
Fixes #9650
2021-08-26refactor(ssh-agent): clean up and reorganize codeMarc Cornellà
2021-08-26feat(ssh-agent): only start ssh-agent once (#5359)Marc Cornellà
Close #5359 Close #7379 Co-authored-by: Will Andrews <will@firepipe.net> Co-authored-by: zhangyc <zhangyc@fenbi.com>
2021-08-26feat(ssh-agent): allow using external helper to ask for passwords (#7631)Simone Gaiarin
2021-06-14Revert "ssh-agent: improvements (#6309)"Marc Cornellà
This reverts commit a206271460ce49e842b1b410c0424b8c9a0a3d14.
2021-06-11ssh-agent: improvements (#6309)Nuno Goncalves
* ssh-agent: lock this script with a mkdir style mutex This script is a kind of singleton pattern and is not reentrant. If several shells are oppened in a fast sequence, then several independent ssh-agents would be created, which is not acceptable. A mutex is required. Signed-off-by: Nuno Goncalves <nunojpg@gmail.com> * ssh-agent: only start agent if .ssh dir exists To use the same profile system-wide, it might happen that the .ssh directory does not exist (typically $HOME/.ssh/). This would trigger a error. Creating the directory would be a option, but it usually will not make sense to do so because it means the user doesn't have ssh keys or config. Signed-off-by: Nuno Goncalves <nunojpg@gmail.com> * ssh-agent: adds lazy option to disable key loading on start Option is documented on updated README.md Signed-off-by: Nuno Goncalves <nunojpg@gmail.com> * ssh-agent: simplify agent-forwarding checking Signed-off-by: Nuno Goncalves <nunojpg@gmail.com> Co-authored-by: Robby Russell <robby@planetargon.com>
2021-03-25fix: use `$USERNAME` guaranteed to always be defined in zshMarc Cornellà
Fixes #9701
2021-03-15feat(ssh-agent): add `ssh-add-args` setting (#7908)Will Boyce
* ssh-agent: add `:omz:plugins:ssh-agent ssh_add_args` option * Clean up and document extra setting * Document valid ssh-add arguments Co-authored-by: Marc Cornellà <hello@mcornella.com>
2019-09-08ssh-agent: check if `ssh-add -l` was successfulMarc Cornellà
2019-05-07ssh-agent: consolidate uppercase message (#7834)Jannik
2019-01-21ssh-agent: check for loaded id filenames first (#7521)Marc Cornellà
This change makes the plugin check if an identity is loaded by looking first at the key filename reported by `ssh-add -l`. This fixes the use case where ssh-keygen is not able to output the fingerprint of a key, such as the one reported on #7516. Now, for an identity to be passed onto ssh-add, it has to fail the match for a loaded identity, both filename and signature.
2019-01-19ssh-agent: add default keys if no zstyle identities were set (#7520)Marc Cornellà
2019-01-14ssh-agent: autoload identities in one go (#7507)Andreas
With this PR the ssh-agent plugin loads all identities which are not yet loaded in a single call to ssh-add. If a passphrase is shared between loaded identities it only needs to be entered once. Fixes #7506
2019-01-14ssh-agent: use key signatures to check loaded ids (#7504)François Scala
Use fingerprint of ssh key instead of file name to control if the key is already loaded. Also check for .ssh folder presence (#5128)
2019-01-09ssh-agent: autoload identities not already loaded (#7174)Marc Cornellà
With this PR the ssh-agent plugin checks the `ssh-add -l` output for the identities added, and adds all those specified by the user that haven't been added yet. We also decouple the logic of starting ssh-agent from the logic of adding identities, meaning that even if ssh-agent has been started by some other means (like launchd) we can still ssh-add the user's identities. Fixes #3019 Fixes #6979
2018-08-07use https everywhere (#6574)Janosch Schwalm
* use https everywhere * use https links on the files that are left Also, removed some broken links and updated redirections.
2018-07-01Use existing ssh-agent when invoking a sudo shell (#3891)Michael Stucki
When invoking a shell as root using ```sudo -s```, the ssh-agent plugin starts a new agent although it already exists. The problem boils down to a check if ssh-agent is running using ```ps x```. If that is extended to ```ps ax``` for root, then the existing ssh-agent will still work.
2018-05-28Clarify ssh-agent settings positionMarc Cornellà
2016-09-17ssh-agent: check ssh-agent process w/ ps againMarc Cornellà
The alternative is using tools that aren't available everywhere. The latest report is that cygwin/msys2 doesn't have pgrep. Fixes #5418.
2016-09-05ssh-agent: fix non-standard process check w/ pgrepMarc Cornellà
Confirmed to work on MacOS, OpenBSD, Solaris and busybox.
2016-09-03Force ssh-agent output to use bourne-style syntaxMarc Cornellà
On systems where the shell cannot be changed because of a strict security policy, ssh-agent will use the syntax of whatever the default $SHELL is. For instance, if the default shell is tcsh, ssh-agent will use the c-shell style (setenv). This change forces ssh-agent to use bourne-style syntax since that has to be later interpreted by zsh. Consequently, the environment file will contain `export' statements from now on (instead of `setenv').
2016-09-03Simplify PID check of current ssh-agentMarc Cornellà
2016-09-03Clean up formatting of ssh-agent pluginMarc Cornellà
2016-09-03Extract comments into README for ssh-agent pluginMarc Cornellà
2016-09-03Delete useless `/usr/bin/env` in ssh-agentMarc Cornellà
2016-09-03ssh-agent: Use /usr/bin/env to find ssh-addMaximilian Güntner
This change is important when ssh-add is not inside /usr/bin e.g. on NixOS. Signed-off-by: Maximilian Güntner <code@maschinenpsychologe.de>
2016-08-21Clobber ssh environment regardless of setopt (#5322)Piotr Gaczkowski
2014-05-24typo, fixes #1806ncanceill
2014-03-13ssh-agent: prevent environment file from flappingChristian Höltje
On an OS X laptop, the variable `$HOST` changes a lot depending on what wifi network you're connected to. This causes a lot of `~/.ssh/environment-$HOST` files to be created and causes multiple ssh-agents to created. Instead, use `scutil --get ComputerName` to get something more stable.
2013-11-05Fix bad ps syntax in ssh-agent pluginnishigori
2013-11-04Merge pull request #1529 from aquaplanet/fix-sshagent-openbsdRobby Russell
Fix ssh-agent plugin for OpenBSD, making it more portable
2013-07-16Fix ssh-agent plugin identities comment for using multiple identities.Armin Widegreen
2013-03-16add ssh-agent option to set default lifetime of identitiesMarcel Wolf
By default, ssh-agent stores identities forever. It has an option to set a maximum lifetime for identites (useful to expire passphrase protected keys). Allow this option to be set using: zstyle :omz:plugins:ssh-agent lifetime <time>
2012-12-30OpenBSD doesn't have -ef flags for ps. Both linux and OpenBSD have -x flags ↵Anders Andersson
which works just as greate here
2011-06-04Add support for loading mulitple identitiesgwjo
2011-06-04Add support for agent forwardinggwjo
2011-03-01ssh-agent plugin now ends in "-$HOST" so an agent is started properly with ↵Theodore Robert Campbell Jr
nfs shared homes.
2010-09-30Reorganizing plugins so that each plugin has it's own directory now so that ↵Robby Russell
any plugin-specific functions can be bundled within there.