* computeStorePathForText: take the references into account when
computing the store path (NIX-77). This is an important security property in multi-user Nix stores. Note that this changes the store paths of derivations (since the derivation aterms are added using addTextToStore), but not most outputs (unless they use builtins.toFile).
This commit is contained in:
parent
c558b1583c
commit
b618fa6eb6
5 changed files with 18 additions and 6 deletions
|
|
@ -667,7 +667,7 @@ Path LocalStore::addToStore(const Path & _srcPath, bool fixed,
|
|||
Path LocalStore::addTextToStore(const string & suffix, const string & s,
|
||||
const PathSet & references)
|
||||
{
|
||||
Path dstPath = computeStorePathForText(suffix, s);
|
||||
Path dstPath = computeStorePathForText(suffix, s, references);
|
||||
|
||||
addTempRoot(dstPath);
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue