mirror of
https://github.com/apache/nuttx-apps.git
synced 2026-08-02 12:49:03 +00:00
Normal Crypto API usage is to call ioctl(CGCGSESSION) to initialize the session, then one (or more) calls to ioctl(CIOCCRYPT) with flag bit COP_FLAG_UPDATE set to append to the hash/xform calculation, then a call to ioctl(CIOCCRYPT) with flag bit COP_FLAG_UPDATE cleared to extract the result, and finally ioctl(CIOCFSESSION) to finish the session. This follows the classic init / update* / finish data processing model. However crc32.c test case 8 precedes ioctl(CIOCCRYPT) with COP_FLAG_UPDATE set with ioctl(CIOCGSESSION) and follows it with ioctl(CIOCCRYPT) with COP_FLAG_UPDATE cleared to extract the CRC, and then ioctl(CIOCFSESSION) to finish the session, all _within_ the loop to CRC eight segments. This works with the software implementation since the intermediate CRC-32 is carried forward out of one session to seed the next session. Fix by moving the init and finish portions out of the loop in test case 8. Signed-off-by: Peter Barada <peter.barada@gmail.com> |
||
|---|---|---|
| .. | ||
| crypto | ||
| drivertest | ||
| fftest | ||
| nand_sim | ||
| pcitest | ||
| rng/nist-sts | ||
| rpmsgdev | ||
| sd_stress | ||
| ser | ||
| setest | ||
| .gitignore | ||
| CMakeLists.txt | ||
| Make.defs | ||
| Makefile | ||