Use XPCOM nsICryptoHash to always compute the SHA256 content digest (much faster than the JavaScript implementation).