git/list[1] front-page[2] threads[3] people[4] search[5] about
 

Re: [RFC] Add posibility to preload stat information.

From
Fredrik Gustafsson <iveqy@iveqy.com>
Date
Mar 20, 2013, 18:40 UTC
Message-ID
<20130320184032.GC32426@paksenarrion.iveqy.com>
In-Reply-To
<20130320164806.GA10752@sigill.intra.peff.net>
On Wed, Mar 20, 2013 at 12:48:06PM -0400, Jeff King wrote:
> Kind of gross, but I guess it is useful to some people.

Yes it is. The questions is if it's gross enough to never leave my computer, or if someone else can find this useful.

Show 17 quoted lines
> 
> > +__git_recursive_stat ()
> > +{
> > +	if test ! -e /tmp/gitbash.lock
> > +	then
> > +		touch /tmp/gitbash.lock
> 
> This is a tmp-race security hole. E.g., do:
> 
>   ln -s /etc/nologin /tmp/gitbash.lock
> 
> as a user; when root runs __git_recursive_stat, it will create
> /etc/nologin. It's not quite as bad as some other holes, because we only
> "touch" the file, not overwrite its contents, but you can see that it's
> possible to do some mischief.
> 
> Should this maybe just be ~/.gitbash.lock or something?
Thank you! I totally missed that.

I guess a new solution would be to keep an access time-stamp in each repository and with certain intervall run git status on that repository.

-- 
Med vänliga hälsningar
Fredrik Gustafsson

tel: 0733-608274
e-post: iveqy@iveqy.com
Previous: Phil HordNext: Ramkumar Ramachandra
Message 8 of 13 in “[RFC] Add posibility to preload stat information.”
  1. Fredrik GustafssonMar 20, 2013
  2. Jeff KingMar 20, 2013
  3. Junio C HamanoMar 20, 2013
  4. Jeff KingMar 20, 2013
  5. Thomas RastMar 21, 2013
  6. Junio C HamanoMar 21, 2013
  7. Phil HordMar 30, 2013
  8. Fredrik GustafssonMar 20, 2013
  9. Ramkumar RamachandraMar 20, 2013
  10. Fredrik GustafssonMar 20, 2013
  11. Ramkumar RamachandraMar 20, 2013
  12. Fredrik GustafssonMar 20, 2013
  13. Jeff KingMar 20, 2013

Read the whole thread, see it on lore, or plain text.

$ cat FOOTERMessages come from the public archive at lore.kernel.org/git, fetched every hour. The front page is chosen and written each morning by an AI editor and can be wrong; the threads themselves are the record. About and API. For agents: an MCP server at https://gitlist.dev/mcp, and any thread, story or person page as Markdown by adding .md to its URL (or sending Accept: text/markdown). Details in /llms.txt.