<feed xmlns='http://www.w3.org/2005/Atom'>
<title>guix/nix, branch crypto-team</title>
<subtitle>Transactional package manager, declarative GNU/Linux distribution, reproducible deployment tool, and more! https://guix.gnu.org</subtitle>
<link rel='alternate' type='text/html' href='https://git.vineetk.net/guix/'/>
<entry>
<title>nix-daemon: Allow any client to set build-max-log-size.</title>
<updated>2026-08-21T15:42:58+00:00</updated>
<author>
<name>Christopher Baines</name>
<email>mail@cbaines.net</email>
</author>
<published>2026-08-07T15:45:00+00:00</published>
<link rel='alternate' type='text/html' href='https://git.vineetk.net/guix/commit/?id=c3832cd497a8fcd87e84878c6ee3bbc10f42d0ca'/>
<id>c3832cd497a8fcd87e84878c6ee3bbc10f42d0ca</id>
<content type='text'>
I want to use the build-max-log-size feature since it's useful for the
bordeaux build farm to cap the log size. I can't see any reason to limit this
functionality as I think it has the same security implications as the
build-timeout and build-max-silent-time settings.

* nix/nix-daemon/nix-daemon.cc (performOp): Allow any client to set
build-max-log-size.

Change-Id: I87825c43ef914c85866e82fe1ed899f13a559b38
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
I want to use the build-max-log-size feature since it's useful for the
bordeaux build farm to cap the log size. I can't see any reason to limit this
functionality as I think it has the same security implications as the
build-timeout and build-max-silent-time settings.

* nix/nix-daemon/nix-daemon.cc (performOp): Allow any client to set
build-max-log-size.

Change-Id: I87825c43ef914c85866e82fe1ed899f13a559b38
</pre>
</div>
</content>
</entry>
<entry>
<title>daemon: Bypass authentication when importing content-addressed store items.</title>
<updated>2026-08-17T14:47:36+00:00</updated>
<author>
<name>Ludovic Courtès</name>
<email>ludo@gnu.org</email>
</author>
<published>2026-05-30T21:54:05+00:00</published>
<link rel='alternate' type='text/html' href='https://git.vineetk.net/guix/commit/?id=64d4de2a920445e5992f020e56490f5fcbdbba7c'/>
<id>64d4de2a920445e5992f020e56490f5fcbdbba7c</id>
<content type='text'>
This puts ‘importPaths’ on par with ‘addToStore’ and ‘addTextToStore’: since
the two latter RPCs let anyone add content-addressed items in the store,
there’s no reason for ‘importPaths’ to require signatures by authorized keys
on these content-addressed items.

This will allow for things like ‘guix copy’ of .drv items without
authorization, or ‘guix deploy’ with (build-locally? #f) without
authorization.

* nix/libstore/store-api.hh (isContentAddressedPath): New prototype.
* nix/libstore/store-api.cc (isContentAddressedPath): New function.
* nix/libutil/util.hh (isPlainFile): New prototype.
* nix/libutil/util.cc (isPlainFile): New function.
* nix/libstore/local-store.cc (LocalStore::importPath): Define ‘narHash’ and
‘contentAddressed’.  Allow unsigned imports when ‘contentAddressed’ is true;
bypass signature verification when ‘contentAddressed’ is true.
* tests/store.scm ("import not signed"): Rewrite to not use a
content-addressed store item.
("import signed by unauthorized key"): Likewise.
("import not signed but content-addressed tree"): New test.
("import not signed but content-addressed regular file"): New test.
("import signed by unauthorized key but content-addressed"): New test.
("import with corrupt signature"): New test.
("import signed by authorized key but hash doesn't match"): New test.
("import with corrupt signature but content-addressed"): New test.
("import signed by authorized key, hash doesn't match, but content-addressed"):
New test.
* doc/guix.texi (Invoking guix archive): Document the exception for
content-addressed store items.  Add anchor for ‘--authorize’.
(Invoking guix deploy): Document the benefit of (build-locally? #f).
Add cross-reference for ‘authorize?’.

Co-authored-by: Reepca Russelstein &lt;reepca@russelstein.xyz&gt;
Signed-off-by: Ludovic Courtès &lt;ludo@gnu.org&gt;
Merges: #8979
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
This puts ‘importPaths’ on par with ‘addToStore’ and ‘addTextToStore’: since
the two latter RPCs let anyone add content-addressed items in the store,
there’s no reason for ‘importPaths’ to require signatures by authorized keys
on these content-addressed items.

This will allow for things like ‘guix copy’ of .drv items without
authorization, or ‘guix deploy’ with (build-locally? #f) without
authorization.

* nix/libstore/store-api.hh (isContentAddressedPath): New prototype.
* nix/libstore/store-api.cc (isContentAddressedPath): New function.
* nix/libutil/util.hh (isPlainFile): New prototype.
* nix/libutil/util.cc (isPlainFile): New function.
* nix/libstore/local-store.cc (LocalStore::importPath): Define ‘narHash’ and
‘contentAddressed’.  Allow unsigned imports when ‘contentAddressed’ is true;
bypass signature verification when ‘contentAddressed’ is true.
* tests/store.scm ("import not signed"): Rewrite to not use a
content-addressed store item.
("import signed by unauthorized key"): Likewise.
("import not signed but content-addressed tree"): New test.
("import not signed but content-addressed regular file"): New test.
("import signed by unauthorized key but content-addressed"): New test.
("import with corrupt signature"): New test.
("import signed by authorized key but hash doesn't match"): New test.
("import with corrupt signature but content-addressed"): New test.
("import signed by authorized key, hash doesn't match, but content-addressed"):
New test.
* doc/guix.texi (Invoking guix archive): Document the exception for
content-addressed store items.  Add anchor for ‘--authorize’.
(Invoking guix deploy): Document the benefit of (build-locally? #f).
Add cross-reference for ‘authorize?’.

Co-authored-by: Reepca Russelstein &lt;reepca@russelstein.xyz&gt;
Signed-off-by: Ludovic Courtès &lt;ludo@gnu.org&gt;
Merges: #8979
</pre>
</div>
</content>
</entry>
<entry>
<title>daemon: Throw ‘AuthenticationError’ on archive authentication error.</title>
<updated>2026-08-17T14:47:36+00:00</updated>
<author>
<name>Ludovic Courtès</name>
<email>ludo@gnu.org</email>
</author>
<published>2026-07-02T12:51:19+00:00</published>
<link rel='alternate' type='text/html' href='https://git.vineetk.net/guix/commit/?id=8cb871e0c69030599fa8e8410f1ecaee21ddbbd0'/>
<id>8cb871e0c69030599fa8e8410f1ecaee21ddbbd0</id>
<content type='text'>
* nix/libstore/local-store.hh (AuthenticationError): New error type.
* nix/libstore/local-store.cc (readAuthenticateReply): Throw it.

Signed-off-by: Ludovic Courtès &lt;ludo@gnu.org&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
* nix/libstore/local-store.hh (AuthenticationError): New error type.
* nix/libstore/local-store.cc (readAuthenticateReply): Throw it.

Signed-off-by: Ludovic Courtès &lt;ludo@gnu.org&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>daemon: Separate out ‘textTypeWithReferences’.</title>
<updated>2026-08-17T14:47:36+00:00</updated>
<author>
<name>Ludovic Courtès</name>
<email>ludo@gnu.org</email>
</author>
<published>2026-05-30T13:16:57+00:00</published>
<link rel='alternate' type='text/html' href='https://git.vineetk.net/guix/commit/?id=27f40fad8064064d7c9d3ce5a126a331b62716e1'/>
<id>27f40fad8064064d7c9d3ce5a126a331b62716e1</id>
<content type='text'>
* nix/libstore/store-api.cc (textTypeWithReferences): New function.
(computeStorePathForText): Use it.

Change-Id: I9d82ac04619d736ce737dec745416396b7b18751
Signed-off-by: Ludovic Courtès &lt;ludo@gnu.org&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
* nix/libstore/store-api.cc (textTypeWithReferences): New function.
(computeStorePathForText): Use it.

Change-Id: I9d82ac04619d736ce737dec745416396b7b18751
Signed-off-by: Ludovic Courtès &lt;ludo@gnu.org&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>daemon: Remove ‘requireSignature’ argument to ‘importPath’.</title>
<updated>2026-08-17T14:47:36+00:00</updated>
<author>
<name>Ludovic Courtès</name>
<email>ludo@gnu.org</email>
</author>
<published>2026-05-30T13:07:15+00:00</published>
<link rel='alternate' type='text/html' href='https://git.vineetk.net/guix/commit/?id=d04d7d9be525aaf2d55792b172b051ec5a539eed'/>
<id>d04d7d9be525aaf2d55792b172b051ec5a539eed</id>
<content type='text'>
In ‘guix-daemon’ the value of ‘requireSignature’ has always been true.

* nix/libstore/local-store.hh (LocalStore)[importPath]: Remove
‘requireSignature’ argument.
* nix/libstore/local-store.cc (LocalStore::importPath): Adjust accordingly.

Change-Id: I4e2d781c85107770cb64ab71d2e7fb711859e0c7
Signed-off-by: Ludovic Courtès &lt;ludo@gnu.org&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
In ‘guix-daemon’ the value of ‘requireSignature’ has always been true.

* nix/libstore/local-store.hh (LocalStore)[importPath]: Remove
‘requireSignature’ argument.
* nix/libstore/local-store.cc (LocalStore::importPath): Adjust accordingly.

Change-Id: I4e2d781c85107770cb64ab71d2e7fb711859e0c7
Signed-off-by: Ludovic Courtès &lt;ludo@gnu.org&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>daemon: Remove ‘requireSignature’ argument to ‘importPaths’.</title>
<updated>2026-08-17T14:47:35+00:00</updated>
<author>
<name>Ludovic Courtès</name>
<email>ludo@gnu.org</email>
</author>
<published>2026-05-30T13:01:59+00:00</published>
<link rel='alternate' type='text/html' href='https://git.vineetk.net/guix/commit/?id=6fbe87f2c890e10c6b24f838b73ad3683b5c97b0'/>
<id>6fbe87f2c890e10c6b24f838b73ad3683b5c97b0</id>
<content type='text'>
For ‘guix-daemon’ the value of ‘requireSignature’ has always been true.

* nix/libstore/store-api.hh (StoreAPI)[importPaths]: Remove ‘requireSignature’
argument.
* nix/libstore/local-store.hh (LocalStore)[importPaths]: Likewise.
* nix/libstore/local-store.cc (LocalStore::importPaths): Adjust accordingly.
* nix/nix-daemon/nix-daemon.cc (performOp): Remove first argument to
‘importPaths’.

Change-Id: I7ed87f3af03cca7078e224788114c499773f01c2
Signed-off-by: Ludovic Courtès &lt;ludo@gnu.org&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
For ‘guix-daemon’ the value of ‘requireSignature’ has always been true.

* nix/libstore/store-api.hh (StoreAPI)[importPaths]: Remove ‘requireSignature’
argument.
* nix/libstore/local-store.hh (LocalStore)[importPaths]: Likewise.
* nix/libstore/local-store.cc (LocalStore::importPaths): Adjust accordingly.
* nix/nix-daemon/nix-daemon.cc (performOp): Remove first argument to
‘importPaths’.

Change-Id: I7ed87f3af03cca7078e224788114c499773f01c2
Signed-off-by: Ludovic Courtès &lt;ludo@gnu.org&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>nix: build: Fix error message.</title>
<updated>2026-07-23T04:09:47+00:00</updated>
<author>
<name>Nicolas Graves</name>
<email>ngraves@ngraves.fr</email>
</author>
<published>2026-07-21T10:27:43+00:00</published>
<link rel='alternate' type='text/html' href='https://git.vineetk.net/guix/commit/?id=c4145027d328b3238d713407899b5afff57de057'/>
<id>c4145027d328b3238d713407899b5afff57de057</id>
<content type='text'>
This fixes surprising error message like as follows,
which looks like an overlook:

@ unsupported-platform /gnu/store/4xb677bysagk7pl4xba9xz4gzwvsh0zn-guile-bootstrap-2.0.drv x86_64-gnu
while setting up the child process: in phase exec: a `x86_64-gnu' is required to build `x86_64-linux',
 but I am a `/gnu/store/4xb677bysagk7pl4xba9xz4gzwvsh0zn-guile-bootstrap-2.0.drv'

* nix/libstore/build.cc (execBuilderOrBuiltin):
  Fix the error message when canBuildLocally fails.

Fixes: 3af52f845fe2 ("[...] use std::format instead of boost::format.")
Merges: https://codeberg.org/guix/guix/pulls/10080
Signed-off-by: Nguyễn Gia Phong &lt;cnx@loang.net&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
This fixes surprising error message like as follows,
which looks like an overlook:

@ unsupported-platform /gnu/store/4xb677bysagk7pl4xba9xz4gzwvsh0zn-guile-bootstrap-2.0.drv x86_64-gnu
while setting up the child process: in phase exec: a `x86_64-gnu' is required to build `x86_64-linux',
 but I am a `/gnu/store/4xb677bysagk7pl4xba9xz4gzwvsh0zn-guile-bootstrap-2.0.drv'

* nix/libstore/build.cc (execBuilderOrBuiltin):
  Fix the error message when canBuildLocally fails.

Fixes: 3af52f845fe2 ("[...] use std::format instead of boost::format.")
Merges: https://codeberg.org/guix/guix/pulls/10080
Signed-off-by: Nguyễn Gia Phong &lt;cnx@loang.net&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>daemon: libutil: make nar parser much stricter.</title>
<updated>2026-07-02T17:42:47+00:00</updated>
<author>
<name>Reepca Russelstein</name>
<email>reepca@russelstein.xyz</email>
</author>
<published>2026-06-16T00:22:37+00:00</published>
<link rel='alternate' type='text/html' href='https://git.vineetk.net/guix/commit/?id=3e5c3217f334805531e5db1680d97490999253f7'/>
<id>3e5c3217f334805531e5db1680d97490999253f7</id>
<content type='text'>
The prior implementation of 'parse' was, to put it mildly, very accepting of
invalid input.  This made it very difficult to review its security properties,
which ended up relying entirely on the fact that it still didn't allow "/" in
directory entry names and that O_CREAT|O_EXCL implicitly causes symlinks to
not be followed in the final component, and mkdir and symlink never follow
symlinks in the final component, and all of the above throw exceptions when
they fail.

Some examples of what was allowed prior:

1. Empty archives:
   "nix-archive-1" "(" ")"
2. Archives with only a type:
   "nix-archive-1" "(" "type" "regular" ")"
3. Archives of regular files with multiple contents, which would be
   concatenated (e.g. this has contents "foobar"):
   "nix-archive-1" "(" "type" "regular" "contents" "foo" "contents" "bar" ")"
4. Archives of directories with multiple entries with the same name, and that
   aren't sorted:
   "nix-archive-1" "(" "type" "directory"
                       "entry" "(" "name" "c" "node" "(" ")" ")"
                       "entry" "(" "name" "b" "node" "(" ")" ")"
                       "entry" "(" "name" "b" "node" "(" ")" ")"
                       "entry" "(" "name" "a" "node" "(" ")" ")" ")"
5. Archives of directories with empty entries:
   "nix-archive-1" "(" "type" "directory" "entry" "(" ")" ")"
6. Archives of directories with entries with no name:
   "nix-archive-1" "(" "type" "directory" "entry" "(" "node" "(" ")" ")" ")"
7. Archives of directories with entries with no node:
   "nix-archive-1" "(" "type" "directory" "entry" "(" "name" "a" ")" ")"
7. Archives of directories with entries with multiple names:
   "nix-archive-1" "(" "type" "directory" "entry" "(" "name" "a"
                                                      "node" "(" ")"
                                                      "name" "b" ")" ")"
8. Archives of directories with entries with multiple nodes:
   "nix-archive-1" "(" "type" "directory" "entry" "(" "node" "(" ")"
                                                      "node" "(" ")" ")" ")"
9. Archives of directories with entries with multiple names and multiple
   nodes:
   "nix-archive-1" "(" "type" "directory"
                       "entry" "(" "name" "a" "node" "(" ")"
                                   "name" "b" "node" "(" ")" ")" ")"

Such permissiveness rather defeats the "normalized" part of "Normalized
ARchive".

Additionally, 'parse' previously used recursion with no explicit depth limit.
In practice Linux would still limit the depth to around 2048, since filenames
longer than 4096 bytes yield ENAMETOOLONG, but no such restriction exists on
Hurd.

The permissiveness issue is resolved by rewriting 'parse', and the unbounded
recursion issue is resolved by adding a nestLimit parameter so that no more
than DIRECTORY_NESTING_LIMIT (currently 256) levels of recursion are used.  An
alternate implementation that doesn't use recursion, 'parse_unbounded', is
included in case it is determined that the nesting limit should be removed,
but currently only 'parse' is used.

* nix/libutil/archive.cc (parse): rewrite to add nestLimit parameter.
  (parseDump): pass DIRECTORY_NESTING_LIMIT as nestLimit argument to 'parse'.
  (parse_unbounded): new function.

Change-Id: Ia3c32cc645b609f6ae7f3bcafc491ec0073cbb51
Signed-off-by: Ludovic Courtès &lt;ludo@gnu.org&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
The prior implementation of 'parse' was, to put it mildly, very accepting of
invalid input.  This made it very difficult to review its security properties,
which ended up relying entirely on the fact that it still didn't allow "/" in
directory entry names and that O_CREAT|O_EXCL implicitly causes symlinks to
not be followed in the final component, and mkdir and symlink never follow
symlinks in the final component, and all of the above throw exceptions when
they fail.

Some examples of what was allowed prior:

1. Empty archives:
   "nix-archive-1" "(" ")"
2. Archives with only a type:
   "nix-archive-1" "(" "type" "regular" ")"
3. Archives of regular files with multiple contents, which would be
   concatenated (e.g. this has contents "foobar"):
   "nix-archive-1" "(" "type" "regular" "contents" "foo" "contents" "bar" ")"
4. Archives of directories with multiple entries with the same name, and that
   aren't sorted:
   "nix-archive-1" "(" "type" "directory"
                       "entry" "(" "name" "c" "node" "(" ")" ")"
                       "entry" "(" "name" "b" "node" "(" ")" ")"
                       "entry" "(" "name" "b" "node" "(" ")" ")"
                       "entry" "(" "name" "a" "node" "(" ")" ")" ")"
5. Archives of directories with empty entries:
   "nix-archive-1" "(" "type" "directory" "entry" "(" ")" ")"
6. Archives of directories with entries with no name:
   "nix-archive-1" "(" "type" "directory" "entry" "(" "node" "(" ")" ")" ")"
7. Archives of directories with entries with no node:
   "nix-archive-1" "(" "type" "directory" "entry" "(" "name" "a" ")" ")"
7. Archives of directories with entries with multiple names:
   "nix-archive-1" "(" "type" "directory" "entry" "(" "name" "a"
                                                      "node" "(" ")"
                                                      "name" "b" ")" ")"
8. Archives of directories with entries with multiple nodes:
   "nix-archive-1" "(" "type" "directory" "entry" "(" "node" "(" ")"
                                                      "node" "(" ")" ")" ")"
9. Archives of directories with entries with multiple names and multiple
   nodes:
   "nix-archive-1" "(" "type" "directory"
                       "entry" "(" "name" "a" "node" "(" ")"
                                   "name" "b" "node" "(" ")" ")" ")"

Such permissiveness rather defeats the "normalized" part of "Normalized
ARchive".

Additionally, 'parse' previously used recursion with no explicit depth limit.
In practice Linux would still limit the depth to around 2048, since filenames
longer than 4096 bytes yield ENAMETOOLONG, but no such restriction exists on
Hurd.

The permissiveness issue is resolved by rewriting 'parse', and the unbounded
recursion issue is resolved by adding a nestLimit parameter so that no more
than DIRECTORY_NESTING_LIMIT (currently 256) levels of recursion are used.  An
alternate implementation that doesn't use recursion, 'parse_unbounded', is
included in case it is determined that the nesting limit should be removed,
but currently only 'parse' is used.

* nix/libutil/archive.cc (parse): rewrite to add nestLimit parameter.
  (parseDump): pass DIRECTORY_NESTING_LIMIT as nestLimit argument to 'parse'.
  (parse_unbounded): new function.

Change-Id: Ia3c32cc645b609f6ae7f3bcafc491ec0073cbb51
Signed-off-by: Ludovic Courtès &lt;ludo@gnu.org&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>daemon: Don't delete files from the store with guix build -K --rounds=3 --check.</title>
<updated>2026-07-01T07:08:53+00:00</updated>
<author>
<name>Hugo Buddelmeijer</name>
<email>hugo@buddelmeijer.nl</email>
</author>
<published>2026-06-30T15:42:10+00:00</published>
<link rel='alternate' type='text/html' href='https://git.vineetk.net/guix/commit/?id=85571d27d2e830fd7f6e96dc4df7f92a30ff3c2e'/>
<id>85571d27d2e830fd7f6e96dc4df7f92a30ff3c2e</id>
<content type='text'>
Specifying all three of -K, --check, --rounds=3 caused valid packages to be
deleted from the store.

When `buildMode == bmCheck`, the built package is not renamed from
`actualPath` to `i.second.path.  Then later, when `settings.keepFailed` and
`curRound &lt; nrRounds`, `i.second.path` was renamed to `i.second.path + "-check"`
anyway.

* nix/libstore/build.cc (DerivationGoal::registerOutputs): Add check for bmCheck
before renaming store path.
* tests/store.scm ("build-things, check mode"): Ensure file is a valid path.
("build-things, check mode + keep-failed"): New test.

Fixes: #9631.
Change-Id: I31d24b2349f563867b8101a1b5ce3c10896ce165
Co-authored-by: Ludovic Courtès &lt;ludo@gnu.org&gt;
Signed-off-by: Ludovic Courtès &lt;ludo@gnu.org&gt;
Merges: #9632
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Specifying all three of -K, --check, --rounds=3 caused valid packages to be
deleted from the store.

When `buildMode == bmCheck`, the built package is not renamed from
`actualPath` to `i.second.path.  Then later, when `settings.keepFailed` and
`curRound &lt; nrRounds`, `i.second.path` was renamed to `i.second.path + "-check"`
anyway.

* nix/libstore/build.cc (DerivationGoal::registerOutputs): Add check for bmCheck
before renaming store path.
* tests/store.scm ("build-things, check mode"): Ensure file is a valid path.
("build-things, check mode + keep-failed"): New test.

Fixes: #9631.
Change-Id: I31d24b2349f563867b8101a1b5ce3c10896ce165
Co-authored-by: Ludovic Courtès &lt;ludo@gnu.org&gt;
Signed-off-by: Ludovic Courtès &lt;ludo@gnu.org&gt;
Merges: #9632
</pre>
</div>
</content>
</entry>
<entry>
<title>daemon: libstore: reject invalid store paths in importPath.</title>
<updated>2026-06-24T13:20:16+00:00</updated>
<author>
<name>Reepca Russelstein</name>
<email>reepca@russelstein.xyz</email>
</author>
<published>2026-06-21T12:28:58+00:00</published>
<link rel='alternate' type='text/html' href='https://git.vineetk.net/guix/commit/?id=247245fbef1923a3bc17a23627e9c016900b4edc'/>
<id>247245fbef1923a3bc17a23627e9c016900b4edc</id>
<content type='text'>
Previously an authorized substitute server could produce invalid store paths -
that is, paths that do denote a top-level file in the store, but that do not
obey the syntax restrictions beyond what that implies.  Given that an
authorized substitute server can already potentially do a lot of damage if it
really wanted to, this isn't a major issue, but closing off this opportunity
does simplify the analysis somewhat.

* nix/libstore/local-store.cc (LocalStore::importPath): use
  strict readStorePath(s) variants.
* tests/store.scm ("import path not in store, unsigned", "import path not in
  store, signed", "import invalid path, unsigned", "import invalid path,
  signed" test cases): new test cases.  The "not in store" cases succeeded
  previously, while the "invalid path" cases did not succeed prior to this
  commit.

Fixes: guix/guix#9078
Change-Id: Ib81c19ec1ae0fff5b7c7268f4f7429b16a870996
Signed-off-by: Ludovic Courtès &lt;ludo@gnu.org&gt;
Merges: #9434
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Previously an authorized substitute server could produce invalid store paths -
that is, paths that do denote a top-level file in the store, but that do not
obey the syntax restrictions beyond what that implies.  Given that an
authorized substitute server can already potentially do a lot of damage if it
really wanted to, this isn't a major issue, but closing off this opportunity
does simplify the analysis somewhat.

* nix/libstore/local-store.cc (LocalStore::importPath): use
  strict readStorePath(s) variants.
* tests/store.scm ("import path not in store, unsigned", "import path not in
  store, signed", "import invalid path, unsigned", "import invalid path,
  signed" test cases): new test cases.  The "not in store" cases succeeded
  previously, while the "invalid path" cases did not succeed prior to this
  commit.

Fixes: guix/guix#9078
Change-Id: Ib81c19ec1ae0fff5b7c7268f4f7429b16a870996
Signed-off-by: Ludovic Courtès &lt;ludo@gnu.org&gt;
Merges: #9434
</pre>
</div>
</content>
</entry>
</feed>
