Lines Matching refs:padLen
209 int i, numBlocks, padLen; in rijndael_padEncrypt() local
230 padLen = 16 - (inputOctets - 16*numBlocks); in rijndael_padEncrypt()
231 if (padLen <= 0 || padLen > 16) in rijndael_padEncrypt()
233 bcopy(input, block, 16 - padLen); in rijndael_padEncrypt()
234 for (cp = block + 16 - padLen; cp < block + 16; cp++) in rijndael_padEncrypt()
235 *cp = padLen; in rijndael_padEncrypt()
251 padLen = 16 - (inputOctets - 16*numBlocks); in rijndael_padEncrypt()
252 if (padLen <= 0 || padLen > 16) in rijndael_padEncrypt()
254 for (i = 0; i < 16 - padLen; i++) { in rijndael_padEncrypt()
257 for (i = 16 - padLen; i < 16; i++) { in rijndael_padEncrypt()
258 block[i] = (BYTE)padLen ^ iv[i]; in rijndael_padEncrypt()
370 int i, numBlocks, padLen; in rijndael_padDecrypt() local
398 padLen = block[15]; in rijndael_padDecrypt()
399 if (padLen >= 16) { in rijndael_padDecrypt()
402 for (i = 16 - padLen; i < 16; i++) { in rijndael_padDecrypt()
403 if (block[i] != padLen) { in rijndael_padDecrypt()
407 bcopy(block, outBuffer, 16 - padLen); in rijndael_padDecrypt()
430 padLen = block[15]; in rijndael_padDecrypt()
431 if (padLen <= 0 || padLen > 16) { in rijndael_padDecrypt()
434 for (i = 16 - padLen; i < 16; i++) { in rijndael_padDecrypt()
435 if (block[i] != padLen) { in rijndael_padDecrypt()
439 bcopy(block, outBuffer, 16 - padLen); in rijndael_padDecrypt()
446 return 16*numBlocks - padLen; in rijndael_padDecrypt()