From 5470ed134a7eb76eb47b8e21695ef2788a326337 Mon Sep 17 00:00:00 2001 From: Josh Siegel Date: Wed, 27 Jul 2022 12:27:11 +0000 Subject: [PATCH] algo/audit: address KS-RL-12 @ gusc1a-ossdev-jsl5 --- algorand/admin.py | 2 +- algorand/gentest.py | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/algorand/admin.py b/algorand/admin.py index 84b330040..e740dc11a 100644 --- a/algorand/admin.py +++ b/algorand/admin.py @@ -310,7 +310,7 @@ class PortalCore: return encode_single(type, val).hex()[64-(32):64] if type == 'uint256' or type == 'bytes32': return encode_single(type, val).hex()[64-(64):64] - raise Exception("you suck") + raise Exception("invalid type") def devnetUpgradeVAA(self): v = self.genUpgradePayload() diff --git a/algorand/gentest.py b/algorand/gentest.py index 8301d8926..4de2c84f9 100644 --- a/algorand/gentest.py +++ b/algorand/gentest.py @@ -79,7 +79,7 @@ class GenTest: return encode_single(type, val).hex()[64-(32):64] if type == 'uint256' or type == 'bytes32': return encode_single(type, val).hex()[64-(64):64] - raise Exception("you suck") + raise Exception("invalid type") def createSignedVAA(self, guardianSetIndex, signers, ts, nonce, emitterChainId, emitterAddress, sequence, consistencyLevel, target, payload): print("createSignedVAA: " + str(signers)) @@ -167,7 +167,7 @@ class GenTest: return "000000000000000000000000b6f6d86a8f9879a9c87f643768d9efc38c1da6e7" if chain == 5: return "0000000000000000000000005a58505a96d1dbf8df91cb21b54419fc36e93fde" - raise Exception("you suck") + raise Exception("invalid chain") def genRegisterChain(self, signers, guardianSet, nonce, seq, chain, addr = None): b = self.zeroPadBytes[0:((32 -11)*2)]