main.c
/*
 * Add a manifest (MFT) or CRL found in an X509 certificate, RFC 6487.
 */
Add a manifest (MFT) or CRL found in an X509 certificate, RFC 6487.
Add a manifest ( MFT ) or CRL found in an X509 certificate RFC 6487 .
static void
queue_add_from_cert(int proc, int rsync, struct entityq *q,
    const char *uri, struct repotab *rt, size_t *eid)
{
	char			*nfile;
	enum rtype		 type;
	const struct repo	*repo;
	if ((type = rtype_resolve(uri)) == RTYPE_EOF)
		errx(1, "%s: unknown file type", uri);
	if (type != RTYPE_MFT && type != RTYPE_CRL)
		errx(1, "%s: invalid file type", uri);
	if (type == RTYPE_CRL)
		return;
	repo = repo_lookup(rsync, rt, uri);
	uri += 8 + strlen(repo->host) + 1 + strlen(repo->module) + 1;
	if (asprintf(&nfile, "%s/%s/%s", repo->host, repo->module, uri) == -1)
		err(1, "asprintf");
	entityq_add(proc, q, nfile, type, repo, NULL, NULL, 0, NULL, eid);
}
static void queue_add_from_cert ( int proc , int rsync , struct entityq * q , const char * uri , struct repotab * rt , size_t * eid ) { char * nfile ; enum rtype type ; const struct repo * repo ; if ( ( type = rtype_resolve ( uri ) ) == RTYPE_EOF ) errx ( 1 , " " , uri ) ; if ( type != RTYPE_MFT && type != RTYPE_CRL ) errx ( 1 , " " , uri ) ; if ( type == RTYPE_CRL ) return ; repo = repo_lookup ( rsync , rt , uri ) ; uri += 8 + strlen ( repo -> host ) + 1 + strlen ( repo -> module ) + 1 ; if ( asprintf ( & nfile , " " , repo -> host , repo -> module , uri ) == -1 ) err ( 1 , " " ) ; entityq_add ( proc , q , nfile , type , repo , NULL , NULL , 0 , NULL , eid ) ; }
Add a manifest (MFT) or CRL found in an X509 certificate, RFC 6487.
Add a manifest ( MFT ) or CRL found in an X509 certificate RFC 6487 .
/* ignore the CRL since it is already loaded via the MFT */ /* Look up the repository. */