summaryrefslogtreecommitdiff
path: root/core
diff options
context:
space:
mode:
authorfoxit <jun_fang@foxitsoftware.com>2014-07-10 12:10:06 -0700
committerfoxit <jun_fang@foxitsoftware.com>2014-07-10 12:10:06 -0700
commitfab88961a74df2a15e163d3a3431004a0fa79293 (patch)
treec49c01c4ece8b6d86617ce68ea815b4bee6bb3b0 /core
parent41e06e74cf9f483c83a042cffcd90da1891e4cbe (diff)
downloadpdfium-fab88961a74df2a15e163d3a3431004a0fa79293.tar.xz
Fix uninitialized okeybuf
BUG=387011 R=palmer@chromium.org Review URL: https://codereview.chromium.org/382603003
Diffstat (limited to 'core')
-rw-r--r--core/src/fpdfapi/fpdf_parser/fpdf_parser_encrypt.cpp1
1 files changed, 1 insertions, 0 deletions
diff --git a/core/src/fpdfapi/fpdf_parser/fpdf_parser_encrypt.cpp b/core/src/fpdfapi/fpdf_parser/fpdf_parser_encrypt.cpp
index 417801b9c5..9dddd86c1a 100644
--- a/core/src/fpdfapi/fpdf_parser/fpdf_parser_encrypt.cpp
+++ b/core/src/fpdfapi/fpdf_parser/fpdf_parser_encrypt.cpp
@@ -461,6 +461,7 @@ CFX_ByteString CPDF_StandardSecurityHandler::GetUserPassword(FX_LPCBYTE owner_pa
okeylen = 32;
}
FX_BYTE okeybuf[64];
+ FXSYS_memset32(okeybuf, 0, sizeof(okeybuf));
FXSYS_memcpy32(okeybuf, (FX_LPCSTR)okey, okeylen);
if (m_Revision == 2) {
CRYPT_ArcFourCryptBlock(okeybuf, okeylen, enckey, key_len);