Skip to content

Commit aa87b60

Browse files
authored
crypto: allow data to be passed that is larger than msg block (#184)
the sha_executeCommand will break it up in chunks for processing anyway
1 parent 385bb95 commit aa87b60

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

libogc/sha.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -151,7 +151,7 @@ s32 SHA_Input(sha_context* context, const void* data, const u32 data_size)
151151
if(context == NULL || data == NULL || data_size == 0)
152152
return -1;
153153

154-
if((((u32)context) & 0x1F) || (((u32)data) & 0x3F) || (data_size & ~(SHA_MSGBLOCK_SIZE-1)) != 0)
154+
if((((u32)context) & 0x1F) || (((u32)data) & 0x3F))
155155
return -4;
156156

157157
return SHA_ExecuteCommand(AddData, context, data, data_size, NULL);

0 commit comments

Comments
 (0)