@@ -138,11 +138,11 @@ export abstract class Transaction {
138
138
TransactionType . AGGREGATE_COMPLETE ,
139
139
] . find ( ( type : TransactionType ) => entityType === type ) !== undefined ;
140
140
141
- // 1) take "R" part of a signature (first 32 bytes)
142
- const signatureR : Uint8Array = transactionBytes . slice ( 8 , 8 + 32 ) ;
141
+ // 1) add full signature
142
+ const signature : Uint8Array = transactionBytes . slice ( 8 , 8 + 64 ) ;
143
143
144
144
// 2) add public key to match sign/verify behavior (32 bytes)
145
- const pubKeyIdx : number = signatureR . length ;
145
+ const pubKeyIdx : number = signature . length ;
146
146
const publicKey : Uint8Array = transactionBytes . slice ( 8 + 64 , 8 + 64 + 32 ) ;
147
147
148
148
// 3) add generationHash (32 bytes)
@@ -162,12 +162,12 @@ export abstract class Transaction {
162
162
// 5) concatenate binary hash parts
163
163
// layout: `signature_R || signerPublicKey || generationHash || EntityDataBuffer`
164
164
const entityHashBytes : Uint8Array = new Uint8Array (
165
- signatureR . length
165
+ signature . length
166
166
+ publicKey . length
167
167
+ generationHash . length
168
168
+ transactionBody . length ,
169
169
) ;
170
- entityHashBytes . set ( signatureR , 0 ) ;
170
+ entityHashBytes . set ( signature , 0 ) ;
171
171
entityHashBytes . set ( publicKey , pubKeyIdx ) ;
172
172
entityHashBytes . set ( generationHash , generationHashIdx ) ;
173
173
entityHashBytes . set ( transactionBody , transactionBodyIdx ) ;
0 commit comments