- result = cleankeys(&keys, config.clean_policies);
+ dbctx = config.dbinit(config.backend, false);
+ result = cleankeys(dbctx, &keys,
+ config.clean_policies);
logthing(LOGTHING_NOTICE, "Got %d new keys.",
dbctx->update_keys(dbctx, &keys,
&config.blacklist,
logthing(LOGTHING_NOTICE, "Got %d new keys.",
dbctx->update_keys(dbctx, &keys,
&config.blacklist,
logthing(LOGTHING_NOTICE, "No changes.");
}
} else if (!strcmp("clean", argv[optind])) {
logthing(LOGTHING_NOTICE, "No changes.");
}
} else if (!strcmp("clean", argv[optind])) {
} else if (!strcmp("dumpconfig", argv[optind])) {
if ((argc - optind) == 2) {
writeconfig(argv[optind + 1]);
} else if (!strcmp("dumpconfig", argv[optind])) {
if ((argc - optind) == 2) {
writeconfig(argv[optind + 1]);
if (dbctx->fetch_key_id(dbctx, keyid, &keys, true)) {
get_fingerprint(keys->publickey, &fingerprint);
dbctx->delete_key(dbctx, &fingerprint, true);
if (dbctx->fetch_key_id(dbctx, keyid, &keys, true)) {
get_fingerprint(keys->publickey, &fingerprint);
dbctx->delete_key(dbctx, &fingerprint, true);
dbctx->store_key(dbctx, keys, true, false);
} else {
puts("Key not found");
dbctx->store_key(dbctx, keys, true, false);
} else {
puts("Key not found");