Explorar el Código

* Make sure key is zero-padded if seed is smaller than key length (bug 20949, patch from Ilya Melnikov)

git-svn-id: trunk@19904 -
michael hace 13 años
padre
commit
109fa89bc8
Se han modificado 1 ficheros con 1 adiciones y 0 borrados
  1. 1 0
      packages/fcl-base/src/idea.pp

+ 1 - 0
packages/fcl-base/src/idea.pp

@@ -289,6 +289,7 @@ begin
     Raise EIDEAError.Create(SErrEmptyKey);
   If (Length(S)>SizeOf(Key)) then
     KLen:=SizeOf(Key);
+  FillChar(Key,SizeOf(Key),0);
   Move(S[1],Key,KLen);
 end;