projects
/
platform
/
core
/
security
/
yaca.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
32797cd
)
Fix: RC4 doesn't support block cipher modes
author
Dariusz Michaluk
<d.michaluk@samsung.com>
Thu, 14 Jul 2016 08:48:11 +0000
(10:48 +0200)
committer
Krzysztof Jackiewicz
<k.jackiewicz@samsung.com>
Thu, 14 Jul 2016 11:29:26 +0000
(13:29 +0200)
Change-Id: Iab022f1791712e0670a02ab2262e03fc0b79c365
src/encrypt.c
patch
|
blob
|
history
diff --git
a/src/encrypt.c
b/src/encrypt.c
index
a9f097a
..
1c00abf
100644
(file)
--- a/
src/encrypt.c
+++ b/
src/encrypt.c
@@
-289,7
+289,10
@@
int encrypt_get_algorithm(yaca_encrypt_algorithm_e algo,
algo_name, bcm_name);
break;
case YACA_ENCRYPT_UNSAFE_RC4:
- ret = snprintf(cipher_name, sizeof(cipher_name), "%s", algo_name);
+ if (bcm != YACA_BCM_NONE)
+ ret = YACA_ERROR_INVALID_PARAMETER;
+ else
+ ret = snprintf(cipher_name, sizeof(cipher_name), "%s", algo_name);
break;
default:
return YACA_ERROR_INVALID_PARAMETER;