From: Junio C Hamano <gitster@pobox.com>
To: "M Hickford via GitGitGadget" <gitgitgadget@gmail.com>
Cc: git@vger.kernel.org, Jeff King <peff@peff.net>,
Matthew John Cheetham <mjcheetham@outlook.com>,
M Hickford <mirth.hickford@gmail.com>
Subject: Re: [PATCH v2 0/2] credential: improvements to erase in helpers
Date: Wed, 14 Jun 2023 14:56:11 -0700 [thread overview]
Message-ID: <xmqqjzw5wvwk.fsf@gitster.g> (raw)
In-Reply-To: <pull.1525.v2.git.git.1686778838.gitgitgadget@gmail.com> (M. Hickford via GitGitGadget's message of "Wed, 14 Jun 2023 21:40:36 +0000")
"M Hickford via GitGitGadget" <gitgitgadget@gmail.com> writes:
> M Hickford (2):
> credential: avoid erasing distinct password
> credential: erase all matching credentials
Will queue. Comments by folks with more experience (than me) who
have worked on the credential subsystem are very much welcomed.
Thanks.
>
> Documentation/git-credential.txt | 4 +-
> Documentation/gitcredentials.txt | 2 +-
> builtin/credential-cache--daemon.c | 11 ++++--
> builtin/credential-store.c | 21 ++++++-----
> credential.c | 11 +++---
> credential.h | 2 +-
> t/lib-credential.sh | 59 ++++++++++++++++++++++++++++++
> 7 files changed, 88 insertions(+), 22 deletions(-)
>
>
> base-commit: fe86abd7511a9a6862d5706c6fa1d9b57a63ba09
> Published-As: https://github.com/gitgitgadget/git/releases/tag/pr-git-1525%2Fhickford%2Ferase-test-v2
> Fetch-It-Via: git fetch https://github.com/gitgitgadget/git pr-git-1525/hickford/erase-test-v2
> Pull-Request: https://github.com/git/git/pull/1525
>
> Range-diff vs v1:
>
> 1: 35ee1795bcd = 1: 35ee1795bcd credential: avoid erasing distinct password
> 2: fcdb579263f ! 2: 9b12f17dc7e credential: erase all matching credentials
> @@ Metadata
> ## Commit message ##
> credential: erase all matching credentials
>
> - Users expect that
> - `echo "url=https://example.com" | git credential reject` or
> - `echo "url=https://example.com\nusername=tim" | git credential reject`
> - erase all matching credentials.
> + `credential reject` sends the erase action to each helper, but the
> + exact behaviour of erase isn't specified in documentation or tests.
> + Some helpers (such as credential-libsecret) delete all matching
> + credentials, others (such as credential-cache and credential-store)
> + delete at most one matching credential.
>
> - Fixes for credential-cache and credential-store.
> + Test that helpers erase all matching credentials. This behaviour is
> + easiest to reason about. Users expect that `echo
> + "url=https://example.com" | git credential reject` or `echo
> + "url=https://example.com\nusername=tim" | git credential reject` erase
> + all matching credentials.
> +
> + Fix credential-cache and credential-store.
>
> Signed-off-by: M Hickford <mirth.hickford@gmail.com>
next prev parent reply other threads:[~2023-06-14 21:56 UTC|newest]
Thread overview: 26+ messages / expand[flat|nested] mbox.gz Atom feed top
2023-06-14 11:23 [PATCH 0/2] credential: improvements to erase in helpers M Hickford via GitGitGadget
2023-06-14 11:23 ` [PATCH 1/2] credential: avoid erasing distinct password M Hickford via GitGitGadget
2023-06-14 11:23 ` [PATCH 2/2] credential: erase all matching credentials M Hickford via GitGitGadget
2023-06-14 16:00 ` Junio C Hamano
2023-06-14 21:35 ` M Hickford
2023-06-14 21:40 ` [PATCH v2 0/2] credential: improvements to erase in helpers M Hickford via GitGitGadget
2023-06-14 21:40 ` [PATCH v2 1/2] credential: avoid erasing distinct password M Hickford via GitGitGadget
2023-06-14 22:43 ` Jeff King
2023-06-15 4:51 ` M Hickford
2023-06-14 21:40 ` [PATCH v2 2/2] credential: erase all matching credentials M Hickford via GitGitGadget
2023-06-14 22:51 ` Jeff King
2023-06-15 4:57 ` M Hickford
2023-06-14 21:56 ` Junio C Hamano [this message]
2023-06-14 22:51 ` [PATCH v2 0/2] credential: improvements to erase in helpers Jeff King
2023-06-15 6:03 ` [PATCH v3 " M Hickford via GitGitGadget
2023-06-15 6:03 ` [PATCH v3 1/2] credential: avoid erasing distinct password M Hickford via GitGitGadget
2023-06-15 7:08 ` Jeff King
2023-06-15 6:03 ` [PATCH v3 2/2] credential: erase all matching credentials M Hickford via GitGitGadget
2023-06-15 7:09 ` Jeff King
2023-06-15 19:19 ` [PATCH v4 0/2] credential: improvements to erase in helpers M Hickford via GitGitGadget
2023-06-15 19:19 ` [PATCH v4 1/2] credential: avoid erasing distinct password M Hickford via GitGitGadget
2023-06-15 19:19 ` [PATCH v4 2/2] credential: erase all matching credentials M Hickford via GitGitGadget
2023-06-15 21:09 ` [PATCH v4 0/2] credential: improvements to erase in helpers Junio C Hamano
2023-06-15 21:21 ` Jeff King
2023-06-15 21:52 ` Junio C Hamano
2023-06-16 16:54 ` Junio C Hamano
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=xmqqjzw5wvwk.fsf@gitster.g \
--to=gitster@pobox.com \
--cc=git@vger.kernel.org \
--cc=gitgitgadget@gmail.com \
--cc=mirth.hickford@gmail.com \
--cc=mjcheetham@outlook.com \
--cc=peff@peff.net \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.