Photos
Blog
Projects
vanrenterghem.biz
projects
/
git.ikiwiki.info.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Tell `git revert` not to follow renames (CVE-2016-10026)
[git.ikiwiki.info.git]
/
IkiWiki
/
Receive.pm
diff --git
a/IkiWiki/Receive.pm
b/IkiWiki/Receive.pm
index c73adfbbb84b34462eaa474ca315570aba85cc44..5908e09f953ad09cb576cae6c956230be497d6df 100644
(file)
--- a/
IkiWiki/Receive.pm
+++ b/
IkiWiki/Receive.pm
@@
-35,10
+35,17
@@
EOF
}
"u != $uid";
} @{$config{untrusted_committers}}).
}
"u != $uid";
} @{$config{untrusted_committers}}).
- ")
exit(0);
\n";
+ ")
{
\n";
$ret.=<<"EOF";
$ret.=<<"EOF";
+ /* Trusted user.
+ * Consume all stdin before exiting, as git may
+ * otherwise be unhappy. */
+ char buf[256];
+ while (read(0, &buf, 256) != 0) {}
+ exit(0);
+ }
asprintf(&s, "CALLER_UID=%i", u);
newenviron[i++]=s;
}
asprintf(&s, "CALLER_UID=%i", u);
newenviron[i++]=s;
}