lyft / lyft/python-blessclient
Unintentional Identity file signing
Personne n'a encore pris cette issue.
- Langage dominant
- Python
- Étoiles
- 117
- Forks
- 31
- Métriques de merge des PR
- Aucune PR mergée en 30 j
Description
Hi, while troubleshooting some unrelated problems I noticed this client is generated signed key certs for any identity that we use in the in the ssh command.
The culprit seems to be this:
https://github.com/lyft/python-blessclient/blob/master/blessclient/client.py#L171
called here:
https://github.com/lyft/python-blessclient/blob/master/blessclient/client.py#L448
Given an ssh config as recommended:
Match exec "env | grep -q BLESS_COMPLETE || /Users/stype/blessclient/blessclient.run --gui --host '%h'"
IdentityFile ~/.ssh/blessid
If we are to call any other ssh command as:
ssh -i ~/.ssh/mykey user@host
and we didn't have a filter on domain_regex: blessclient will still generate and sign the mykey key.
While I believe this could be in some case desired functionality(when doing ssh wrapping instead of ssh config), I think it might be better to just let it toggle via an env var or the existing BLESS_IDENTITYFILE as in most cases than not if you specify a particular identity on the command line, you want to use exactly that to auth and signing is unnecessary.
If this is accepted I can create a PR to cleanup/implement this.
Guide de contribution
Aucun guide de contribution indexé pour ce dépôt
Par où commencer
- Lisez l'issue en entier, puis le guide de contribution du projet.
- Signalez en commentaire que vous la prenez — cela évite que deux personnes fassent le même travail.
- Forkez le dépôt et travaillez sur une branche.
- Ouvrez une pull request qui référence le numéro de l'issue.
Piste de recherche
Commencez dans blessclient/client.py aux lignes 171 et 448, où l’identité est gérée et où le chemin de signature est appelé. Reproduisez le comportement avec la configuration SSH indiquée et une commande ssh utilisant -i ~/.ssh/mykey, puis suivez la manière dont BLESS_IDENTITYFILE et domain_regex influencent la sélection. Le travail est terminé lorsque le client ne signe plus une identité sélectionnée explicitement, sauf si la configuration choisie active ce comportement.
Rédigé par le modèle d'indexation à partir du texte de l'issue.
Évaluation
- Stack technique
- python
- Domaine
- authentication, security
- Type d'issue
- Bug
- Difficulté
- 3/5
- Temps estimé
- 1-2 jours
- Activité
- À l'abandon
- Clarté
- Plutôt claire
- Accessibilité débutants
- 35/100