Safety check - also to be removed shortly.

This commit is contained in:
CalDescent 2022-06-13 22:41:10 +01:00
parent 0eebfe4a8c
commit 8b3f9db497

View File

@ -393,6 +393,10 @@ public class Block {
byte[] encodedOnlineAccounts = BlockTransformer.encodeOnlineAccounts(onlineAccountsSet);
int onlineAccountsCount = onlineAccountsSet.size();
if (encodedOnlineAccounts.length > 1024)
// Safety check - to be removed along with above temporary limitation
return null;
// Concatenate online account timestamp signatures (in correct order)
byte[] onlineAccountsSignatures = new byte[onlineAccountsCount * Transformer.SIGNATURE_LENGTH];
for (int i = 0; i < onlineAccountsCount; ++i) {