When investigating bug 6074, several issues with the session store was found. While it's not explicitly documented for each function, one function has a comment that says that all public API functions should return copies of sessionstore data, rather than references. This is not how the sessionstore behaves in all sitautions though - dictionaries in dictionaries are still returned as references to the data in the sessionstore. We should take another look at fixing and documenting the indented behavior of the sessionstore so it won't bite us again. We also need to investigate all calling code to see if we can safely move to a deep-copy approach, or if there's more code to be updated to match.