feat(update): fix schema-3 verify-before-parse and add replay floor, TrustStore, pin pruning, and InstallCoordinator
This commit is contained in:
1 parent
00d7478335
commit
47736cb6ce
13 files changed
+2663
-23
No files matched your search
@@ -0,0 +1,22 @@
|
||||
#include <Void/Crypto/Crypto.hpp>
|
||||
#include <Void/Update/Update.hpp>
|
||||
|
||||
int main()
|
||||
{
|
||||
auto k = Void::Crypto::Ed25519PrivateKey::generate();
|
||||
if (!k.has_value()) {
|
||||
return 1;
|
||||
}
|
||||
auto pub = k->public_key();
|
||||
if (!pub.has_value()) {
|
||||
return 2;
|
||||
}
|
||||
Void::Update::TrustStore trust;
|
||||
if (!trust.bootstrap({{"k1", pub->bytes}}).has_value()) {
|
||||
return 3;
|
||||
}
|
||||
if (!trust.snapshot().contains("k1")) {
|
||||
return 4;
|
||||
}
|
||||
return 0;
|
||||
}
|
||||
Reference in new issue
Block a user