diff options
author | Tobias Stoeckmann <tobias@stoeckmann.org> | 2016-06-18 18:41:07 +0200 |
---|---|---|
committer | Andrew Gregory <andrew.gregory.8@gmail.com> | 2017-05-09 05:27:41 +0200 |
commit | 3218360114d0e3a3a965feb2f6fd3f4e2da8c8a0 (patch) | |
tree | 620ecf9a078da881f2e954c5f1566a87276fb5f0 /doc/PKGBUILD.5.txt | |
parent | 8abb0cbf0e76bc9e59aa58b368ca11a2f0c189f2 (diff) | |
download | pacman-3218360114d0e3a3a965feb2f6fd3f4e2da8c8a0.tar.gz pacman-3218360114d0e3a3a965feb2f6fd3f4e2da8c8a0.tar.xz |
Reject files larger than 16384 bytes in read_sigfile.
If signature files are larger than SIZE_MAX, not enough memory could
be allocated for this file. The script repo-add rejects files which
are larger than 16384 bytes, therefore handle these as errors here,
too.
While at it, I also rearranged the code to avoid a quite harmless
TOCTOU race condition between stat() and fopen().
Signed-off-by: Tobias Stoeckmann <tobias@stoeckmann.org>
Signed-off-by: Allan McRae <allan@archlinux.org>
(cherry picked from commit 5fcd60e2641c9293c2783aad509baf217e77aa6f)
Diffstat (limited to 'doc/PKGBUILD.5.txt')
0 files changed, 0 insertions, 0 deletions