PDFSM4EncryptedLength
密码学
描述
计算给定明文大小下 PDFSM4EncryptString 的精确输出长度
语法
Delphi
Function PDFSM4EncryptedLength(PlaintextLength: Int64): Int64;参数
| PlaintextLength | 明文大小(字节) |
|---|
返回值
| length | 16 字节 IV 加 PKCS#7 填充后的主体:16 + ((Length div 16) + 1) * 16 |
|---|---|
| -1 | PlaintextLength 为负 |
备注
调用 PDFSM4EncryptString 或 PDFSM4EncryptToStream 前用它确定缓冲区大小