-/* $OpenBSD: cert.c,v 1.86 2022/09/03 13:01:43 tb Exp $ */
+/* $OpenBSD: cert.c,v 1.87 2022/09/03 13:30:27 claudio Exp $ */
/*
* Copyright (c) 2022 Theo Buehler <tb@openbsd.org>
* Copyright (c) 2021 Job Snijders <job@openbsd.org>
io_simple_buffer(b, &p->expires, sizeof(p->expires));
io_simple_buffer(b, &p->purpose, sizeof(p->purpose));
io_simple_buffer(b, &p->talid, sizeof(p->talid));
+ io_simple_buffer(b, &p->repoid, sizeof(p->repoid));
io_simple_buffer(b, &p->ipsz, sizeof(p->ipsz));
io_simple_buffer(b, &p->asz, sizeof(p->asz));
io_read_buf(b, &p->expires, sizeof(p->expires));
io_read_buf(b, &p->purpose, sizeof(p->purpose));
io_read_buf(b, &p->talid, sizeof(p->talid));
+ io_read_buf(b, &p->repoid, sizeof(p->repoid));
io_read_buf(b, &p->ipsz, sizeof(p->ipsz));
io_read_buf(b, &p->asz, sizeof(p->asz));
-/* $OpenBSD: extern.h,v 1.153 2022/09/02 19:10:36 claudio Exp $ */
+/* $OpenBSD: extern.h,v 1.154 2022/09/03 13:30:27 claudio Exp $ */
/*
* Copyright (c) 2019 Kristaps Dzonsons <kristaps@bsd.lv>
*
struct cert_as *as; /* list of AS numbers and ranges */
size_t asz; /* length of "asz" */
int talid; /* cert is covered by which TAL */
+ unsigned int repoid; /* repository of this cert file */
char *repo; /* CA repository (rsync:// uri) */
char *mft; /* manifest (rsync:// uri) */
char *notify; /* RRDP notify (https:// uri) */
-/* $OpenBSD: parser.c,v 1.75 2022/08/30 18:56:49 job Exp $ */
+/* $OpenBSD: parser.c,v 1.76 2022/09/03 13:30:27 claudio Exp $ */
/*
* Copyright (c) 2019 Claudio Jeker <claudio@openbsd.org>
* Copyright (c) 2019 Kristaps Dzonsons <kristaps@bsd.lv>
cert = proc_parser_cert(file, f, flen);
c = (cert != NULL);
io_simple_buffer(b, &c, sizeof(int));
- if (cert != NULL)
+ if (cert != NULL) {
+ cert->repoid = entp->repoid;
cert_buffer(b, cert);
+ }
/*
* The parsed certificate data "cert" is now
* managed in the "auths" table, so don't free