Revert "libxbps: verify repodata signatures even if rootdir is unset."

This reverts commit be05118aa8.
This commit is contained in:
Piotr Wójcik 2020-01-06 15:22:36 +01:00 committed by Juan RP
parent 615b6ce7e9
commit 6cf1555398

View File

@ -97,12 +97,7 @@ xbps_verify_signature(struct xbps_repo *repo, const char *sigfile,
/*
* Prepare repository RSA public key to verify fname signature.
*/
/* XXX: xbps-rindex does not set rootdir, use cwd and fallback to defaults otherwise */
rkeyfile = xbps_xasprintf("keys/%s.plist", hexfp);
if (access(rkeyfile, R_OK) == -1) {
free(rkeyfile);
rkeyfile = xbps_xasprintf("%s/keys/%s.plist", repo->xhp->metadir, hexfp);
}
repokeyd = xbps_plist_dictionary_from_file(repo->xhp, rkeyfile);
if (xbps_object_type(repokeyd) != XBPS_TYPE_DICTIONARY) {
xbps_dbg_printf(repo->xhp, "cannot read rkey data at %s: %s\n",