An example of how localStorage can be encrypted with 256 SHA using a one-way hashed password as a session-based key. The one-way hash used as the key for decryption of localStorage can be created when the user is authenticated by a server.
View the live code: http://codepolymath.github.io/localStorage-Encryption/