decipher.final([outputEncoding])


  • outputEncoding <string> 返回值的编码
  • 返回:<Buffer> | <string> 任何剩余的解码内容。如果指定了 outputEncoding,将返回一个字符串。如果未提供 outputEncoding,将返回一个 Buffer

如果在之前对 decipher.update() 的调用中指定了输出编码,outputEncoding 必须使用相同的编码。

🌐 If an output encoding was specified in a previous call to decipher.update(), outputEncoding must use the same encoding.

一旦调用了 decipher.final() 方法,Decipheriv 对象就不能再用于解密数据。尝试多次调用 decipher.final() 会导致抛出错误。

🌐 Once the decipher.final() method has been called, the Decipheriv object can no longer be used to decrypt data. Attempts to call decipher.final() more than once will result in an error being thrown.