Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
M
MariaDB
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
nexedi
MariaDB
Commits
e7620ce4
Commit
e7620ce4
authored
Jun 19, 2015
by
Sergei Golubchik
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
MDEV-8281 aes_decrypt crashes in block_crypt()
fix aes_decrypt of yassl to support zero-length input
parent
e20be69e
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
5 additions
and
1 deletion
+5
-1
mysql-test/r/func_str.result
mysql-test/r/func_str.result
+3
-0
mysql-test/t/func_str.test
mysql-test/t/func_str.test
+1
-0
mysys_ssl/my_crypt.cc
mysys_ssl/my_crypt.cc
+1
-1
No files found.
mysql-test/r/func_str.result
View file @
e7620ce4
...
...
@@ -264,6 +264,9 @@ NULL
select aes_decrypt(aes_encrypt("","a"),"a");
aes_decrypt(aes_encrypt("","a"),"a")
select aes_decrypt("", "a");
aes_decrypt("", "a")
NULL
select repeat('monty',5),concat('*',space(5),'*');
repeat('monty',5) concat('*',space(5),'*')
montymontymontymontymonty * *
...
...
mysql-test/t/func_str.test
View file @
e7620ce4
...
...
@@ -105,6 +105,7 @@ select aes_decrypt(NULL,"a");
select
aes_decrypt
(
"a"
,
NULL
);
select
aes_decrypt
(
"a"
,
"a"
);
select
aes_decrypt
(
aes_encrypt
(
""
,
"a"
),
"a"
);
select
aes_decrypt
(
""
,
"a"
);
select
repeat
(
'monty'
,
5
),
concat
(
'*'
,
space
(
5
),
'*'
);
select
reverse
(
'abc'
),
reverse
(
'abcd'
);
select
rpad
(
'a'
,
4
,
'1'
),
rpad
(
'a'
,
4
,
'12'
),
rpad
(
'abcd'
,
3
,
'12'
),
rpad
(
11
,
10
,
22
),
rpad
(
"ab"
,
10
,
22
);
...
...
mysys_ssl/my_crypt.cc
View file @
e7620ce4
...
...
@@ -104,7 +104,7 @@ static int block_crypt(CipherMode cipher, Dir dir,
}
else
{
int
n
=
dest
[
source_length
-
1
]
;
int
n
=
source_length
?
dest
[
source_length
-
1
]
:
0
;
if
(
tail
||
n
==
0
||
n
>
MY_AES_BLOCK_SIZE
)
return
MY_AES_BAD_DATA
;
*
dest_length
-=
n
;
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment