Subject: Re: bearer token authorization with HTTPS transport

From: Jeff King <[email-masked]>
Date: Tue, 30 Dec 2014 20:57:39 -0500

On Tue, Dec 30, 2014 at 08:42:09PM -0500, Jeff King wrote:

> Both should be pretty trivial. This approach seems conceptually cleaner
> to me, though it does mean you could not specify a bearer via the
> terminal prompt for a password (e.g., by cutting and pasting from
> elsewhere). I don't know if that is a problem or not. You could override
> it with:
> 
>   [credential]
>   helper = '!f() {
>     test "$1" = "get" || return
>     echo >/dev/tty "No, really, give me a bearer token: "
>     read token </dev/tty
>     echo "bearer=$token"
>   }; f'
> 
> or similar.

And by the way, I'm not advocating that as something people would do on
the fly. I mean only that it would be easy to write a drop-in helper to
prompt people for a bearer token _before_ git makes it to the
username/password prompt.

-Peff