public inbox for elfutils@sourceware.org
 help / color / mirror / Atom feed
From: Mark Wielaard <mark@klomp.org>
To: Daniel Thornburgh <dthorn@google.com>
Cc: elfutils-devel@sourceware.org
Subject: Re: debuginfod Credential Helper RFC
Date: Thu, 04 Aug 2022 19:02:07 +0200	[thread overview]
Message-ID: <025de8a2c25112e902cc330199b9d0ebb61fbaf6.camel@klomp.org> (raw)
In-Reply-To: <CAEdiOycpr3wEWArX7pNa1OmQJJzpghYtp4cKW7n05V5jRfVNxw@mail.gmail.com>

Hi Daniel,

On Tue, 2022-08-02 at 13:36 -0700, Daniel Thornburgh via Elfutils-devel 
wrote:
> So, I put together a design with this approach, and it passed a security
> review, so the approach broadly seems to work for us.
> 
> It came up in review that it'd be considerably more usable to have the
> environment variable point to a file: DEBUGINFOD_HEADERS_FILE=<file>. This
> would avoid storing credentials in environment variables, and it would
> allow you to set up the path to the header file in your shell config at the
> beginning of a session.
> 
> Would this work for libdebuginfod? We'd also want to standardize on the
> format of such a file; probably a newline-separated list of headers in the
> format accepted by debuginfod_add_http_header()?

I wonder if we should generalize that for other DEBUGINFOD_envs. But
instead of adding more environment variables have a debuginfod control
file like we already have for cache_clean_interval, max_unused_age and
cache_miss.

So as an alternative to setting any of the DEBUGINFOD_frob environment
variables you could put an urls, cache_path, progress, verbose
retry_limit, timeout, maxtime, maxsize or headers file under
XDG_CONFIG_HOME (~/.config) debuginfod_client that would be used if the
corresponding environment variable isn't set.

The downside of course is that it would cause more file stats when
creating a debuginfod_client handle, but the overhead is probably
minimal especially if programs just reuse the debuginfod_client
objects.

Or maybe it should just be one control file that can have entries for
all of the variables.

Cheers,

Mark

  reply	other threads:[~2022-08-04 17:02 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-07-26 22:50 Daniel Thornburgh
2022-07-28 16:23 ` Mark Wielaard
2022-07-28 17:47   ` Daniel Thornburgh
2022-07-29 18:58     ` Mark Wielaard
2022-07-29 21:08       ` Daniel Thornburgh
2022-08-02 20:36         ` Daniel Thornburgh
2022-08-04 17:02           ` Mark Wielaard [this message]
2022-08-04 18:04             ` Daniel Thornburgh
2022-08-08 20:41               ` Frank Ch. Eigler
2022-08-09 18:13                 ` Daniel Thornburgh

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=025de8a2c25112e902cc330199b9d0ebb61fbaf6.camel@klomp.org \
    --to=mark@klomp.org \
    --cc=dthorn@google.com \
    --cc=elfutils-devel@sourceware.org \
    /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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).