file to hash fileHash = crypto.createHash('sha256').update(file.buffer).digest('hex')