From 1047b8c84df002b1dcad3f4ff642d466926ea071 Mon Sep 17 00:00:00 2001 From: "Dr. Stephen Henson" Date: Mon, 5 May 2014 23:56:43 +0100 Subject: [PATCH] Set Enveloped data version to 2 if ktri version not zero. (cherry picked from commit 546b1b438468e629eea4e836190b1bb056e39286) --- crypto/cms/cms_env.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/crypto/cms/cms_env.c b/crypto/cms/cms_env.c index 8c6d91f3c8..b6b6ca1696 100644 --- a/crypto/cms/cms_env.c +++ b/crypto/cms/cms_env.c @@ -973,7 +973,7 @@ static void cms_env_set_version(CMS_EnvelopedData *env) env->version = 3; return; } - else if (ri->type != CMS_RECIPINFO_TRANS) + else if (ri->type != CMS_RECIPINFO_TRANS || ri->d.ktri->version != 0) { env->version = 2; }