mirror of
https://github.com/guanzhi/GmSSL.git
synced 2026-05-06 16:36:16 +08:00
Update sdf_lib.c
The `ECCCipher` in GmSSL has enough ciphertext buffer, so length checking is not required. And without setting ECCCipher.L makes the API easier to use.
This commit is contained in:
@@ -1048,11 +1048,6 @@ int SDF_InternalEncrypt_ECC(
|
||||
return SDR_NOTSUPPORT;
|
||||
}
|
||||
|
||||
if (pucEncData->L < uiDataLength) {
|
||||
SDFerr(SDF_R_BUFFER_TOO_SMALL);
|
||||
return SDR_NOBUFFER;
|
||||
}
|
||||
|
||||
if (sdf_vendor && sdf_vendor->decode_ecccipher) {
|
||||
if (SDF_NewECCCipher(&buf, uiDataLength) != SDR_OK) {
|
||||
SDFerr(ERR_R_SDF_LIB);
|
||||
|
||||
Reference in New Issue
Block a user