From: Tobias Brunner Date: Fri, 12 Apr 2013 10:10:22 +0000 (+0200) Subject: Also support 128-bit RC2 X-Git-Tag: 5.1.0dr1~149^2~16 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=d8be7d38bf9a0b4cf62e7713aa5b354144938620;p=thirdparty%2Fstrongswan.git Also support 128-bit RC2 --- diff --git a/src/libstrongswan/crypto/pkcs5.c b/src/libstrongswan/crypto/pkcs5.c index ed2c41a0de..679d270d2a 100644 --- a/src/libstrongswan/crypto/pkcs5.c +++ b/src/libstrongswan/crypto/pkcs5.c @@ -613,8 +613,9 @@ pkcs5_t *pkcs5_from_algorithmIdentifier(chunk_t blob, int level0) this->data.pbes1.hash = HASH_SHA1; break; case OID_PBE_SHA1_RC2_CBC_40: + case OID_PBE_SHA1_RC2_CBC_128: this->scheme = PKCS5_SCHEME_PKCS12; - this->keylen = 5; + this->keylen = (oid == OID_PBE_SHA1_RC2_CBC_40) ? 5 : 16; this->encr = ENCR_RC2_CBC; this->data.pbes1.hash = HASH_SHA1; break;