Compare commits
No commits in common. "1b5d16864723dda22ce12fc31a253c03b6698499" and "adf1e680064d5db773a2d792835b09614bb3c265" have entirely different histories.
1b5d168647
...
adf1e68006
|
@ -168,7 +168,7 @@ fn seda_chains() -> Vec<Blockchain> {
|
|||
let mut chains = vec![];
|
||||
|
||||
let aseda = Currency::builder()
|
||||
.coin_denom("SEDA")
|
||||
.coin_denom("seda")
|
||||
.coin_minimal_denom("aseda")
|
||||
.coin_decimals(18)
|
||||
.coin_gecko_id("ID")
|
||||
|
|
|
@ -439,6 +439,14 @@ impl Payload {
|
|||
for issuer in signature.issuer_fingerprints() {
|
||||
let mut currently_seen = std::collections::HashMap::new();
|
||||
for cert in &certs {
|
||||
if let Some(seen_index) = seen.get(&cert.fingerprint()) {
|
||||
return Err(BaseError::DuplicateSignature(
|
||||
cert.fingerprint(),
|
||||
index,
|
||||
*seen_index,
|
||||
)
|
||||
.into());
|
||||
}
|
||||
match cert
|
||||
.with_policy(&policy, None)?
|
||||
.keys()
|
||||
|
@ -448,29 +456,16 @@ impl Payload {
|
|||
.next()
|
||||
.map(|signing_key| signature.verify_hash(&signing_key, hashed.clone()))
|
||||
{
|
||||
Some(result) => {
|
||||
// matching key found, check for duplicates
|
||||
if let Some(seen_index) = seen.get(&cert.fingerprint()) {
|
||||
return Err(BaseError::DuplicateSignature(
|
||||
cert.fingerprint(),
|
||||
index,
|
||||
*seen_index,
|
||||
)
|
||||
.into());
|
||||
}
|
||||
Some(Ok(())) => {
|
||||
// key found, signature matched
|
||||
signature_matched = true;
|
||||
|
||||
match result {
|
||||
Ok(()) => {
|
||||
signature_matched = true;
|
||||
|
||||
// mark the cert as seen, so it isn't reusable
|
||||
currently_seen.insert(cert.fingerprint(), index);
|
||||
}
|
||||
Err(e) => {
|
||||
if error_on_invalid {
|
||||
return Err(e)?;
|
||||
}
|
||||
}
|
||||
// mark the cert as seen, so it isn't reusable
|
||||
currently_seen.insert(cert.fingerprint(), index);
|
||||
}
|
||||
Some(Err(e)) => {
|
||||
if error_on_invalid {
|
||||
return Err(e)?;
|
||||
}
|
||||
}
|
||||
None => {
|
||||
|
|
Loading…
Reference in New Issue