for (i = 0; i < SHA_DIGEST_LENGTH; i++) seed[i] ^= from[i];
for (i = lzero; i < SHA_DIGEST_LENGTH; i++) seed[i] ^= from[i - lzero];
int RSA_padding_check_PKCS1_OAEP(unsigned char *to, int tlen,	     unsigned char *from, int flen, int num, unsigned char *param,	     int plen)    {    int i, dblen, mlen = -1;    unsigned char *maskeddb;    unsigned char *db, seed[SHA_DIGEST_LENGTH], phash[SHA_DIGEST_LENGTH];    if (flen < 2 * SHA_DIGEST_LENGTH + 1)	{	RSAerr(RSA_F_RSA_PADDING_CHECK_PKCS1_OAEP, RSA_R_OAEP_DECODING_ERROR);	return (-1);	}    dblen = flen - SHA_DIGEST_LENGTH;    db = Malloc(dblen);    if (db == NULL)	{	RSAerr(RSA_F_RSA_PADDING_ADD_PKCS1_OAEP, ERR_R_MALLOC_FAILURE);	return (-1);	}    maskeddb = from + SHA_DIGEST_LENGTH;        MGF1(seed, SHA_DIGEST_LENGTH, maskeddb, dblen);    for (i = 0; i < SHA_DIGEST_LENGTH; i++)	seed[i] ^= from[i];      MGF1(db, dblen, seed, SHA_DIGEST_LENGTH);    for (i = 0; i < dblen; i++)	db[i] ^= maskeddb[i];    SHA1(param, plen, phash);    if (memcmp(db, phash, SHA_DIGEST_LENGTH) != 0)	RSAerr(RSA_F_RSA_PADDING_CHECK_PKCS1_OAEP, RSA_R_OAEP_DECODING_ERROR);    else	{	for (i = SHA_DIGEST_LENGTH; i < dblen; i++)	    if (db[i] != 0x00)		break;	if (db[i] != 0x01 || i++ >= dblen)	    RSAerr(RSA_F_RSA_PADDING_CHECK_PKCS1_OAEP,		   RSA_R_OAEP_DECODING_ERROR);	else	    {	    mlen = dblen - i;	    if (tlen < mlen)		{		RSAerr(RSA_F_RSA_PADDING_ADD_PKCS1_OAEP, RSA_R_DATA_TOO_LARGE);		mlen = -1;		}	    else		memcpy(to, db + i, mlen);	    }	}    Free(db);    return (mlen);    }