forked from wolfSSL/wolfssl
Fixed CID 576799.
This commit is contained in:
@@ -751,7 +751,14 @@ int wc_i2d_PKCS12(WC_PKCS12* pkcs12, byte** der, int* derSz)
|
|||||||
outerSz += mac->saltSz;
|
outerSz += mac->saltSz;
|
||||||
|
|
||||||
/* MAC iterations */
|
/* MAC iterations */
|
||||||
outerSz += SetShortInt(ASNSHORT, &tmpIdx, mac->itt, MAX_SHORT_SZ);
|
ret = SetShortInt(ASNSHORT, &tmpIdx, mac->itt, MAX_SHORT_SZ);
|
||||||
|
if (ret >= 0) {
|
||||||
|
outerSz += ret;
|
||||||
|
ret = 0;
|
||||||
|
}
|
||||||
|
else {
|
||||||
|
return ret;
|
||||||
|
}
|
||||||
|
|
||||||
/* sequence of inner data */
|
/* sequence of inner data */
|
||||||
outerSz += SetSequence(innerSz, seq);
|
outerSz += SetSequence(innerSz, seq);
|
||||||
|
Reference in New Issue
Block a user