summaryrefslogtreecommitdiff
path: root/usr.sbin/rpki-client
diff options
context:
space:
mode:
authorClaudio Jeker <claudio@cvs.openbsd.org>2023-03-29 17:03:30 +0000
committerClaudio Jeker <claudio@cvs.openbsd.org>2023-03-29 17:03:30 +0000
commit35868ad5884d76dd6294e41b0f797c64f753232a (patch)
treed80d672023e10699ab5ad7353e934dfaf76d848e /usr.sbin/rpki-client
parentad4098651d30151d5be52feab8b0a066cfb45705 (diff)
Instead of storing the short TAL name as repouri use the first TAL URI
for that. This is more in line with the other uses of repouri. OK tb@
Diffstat (limited to 'usr.sbin/rpki-client')
-rw-r--r--usr.sbin/rpki-client/repo.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/usr.sbin/rpki-client/repo.c b/usr.sbin/rpki-client/repo.c
index 059fbfceff6..0a2513c202e 100644
--- a/usr.sbin/rpki-client/repo.c
+++ b/usr.sbin/rpki-client/repo.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: repo.c,v 1.41 2022/12/28 21:30:18 jmc Exp $ */
+/* $OpenBSD: repo.c,v 1.42 2023/03/29 17:03:29 claudio Exp $ */
/*
* Copyright (c) 2021 Claudio Jeker <claudio@openbsd.org>
* Copyright (c) 2019 Kristaps Dzonsons <kristaps@bsd.lv>
@@ -1012,18 +1012,18 @@ ta_lookup(int id, struct tal *tal)
/* Look up in repository table. (Lookup should actually fail here) */
SLIST_FOREACH(rp, &repos, entry) {
- if (strcmp(rp->repouri, tal->descr) == 0)
+ if (strcmp(rp->repouri, tal->uri[0]) == 0)
return rp;
}
rp = repo_alloc(id);
rp->basedir = repo_dir(tal->descr, "ta", 0);
- if ((rp->repouri = strdup(tal->descr)) == NULL)
+ if ((rp->repouri = strdup(tal->uri[0])) == NULL)
err(1, NULL);
/* check if sync disabled ... */
if (noop) {
- logx("ta/%s: using cache", rp->repouri);
+ logx("%s: using cache", rp->basedir);
entityq_flush(&rp->queue, rp);
return rp;
}