I have two pages, both with iParts, which need to communicate with each other. Some of the details I want to communicate are a bit sensitive. It's not credit cards or other personal info, but it could potentially be used to manipulate the system to gain access to records that shouldn't be seen by the current user.
I know the first page can pass parameters to the second page using the URL, but the security is non-existent. Even my mother-in-law can manipulate URL params.
Cookies are invisible to the user and not very easy to manipulate, but have the problem of being global across all browser windows. A user could legitimately have two windows open, and each one should know which item it was asked to work on in a way that isn't affected by opening another window.
What other mechanisms are available in iMIS for saving some information on one page (e.g. the key of the item the user clicked on) so the destination page can make use of it?
I think you basically have 3
I think you basically have 3 options here: 1) QueryString variables 2) Session variables or 3) Server.Transfer (as well as a combination of techniques)
The QueryString option would work fine but you would want to encrypt the data before setting the querystring variable so that they couldn't manipulate the data or see the data that you are tracking.
Using Session variables is more secure because it only stores the data on the server and the end user isn't exposed to the data. The end user simply gets a cookie set on their computer to identify the session. However, you would still have the same issue whereby a second browser window in the same session might overwrite the data from another session.
So to get around the session issue, you could generate a GUID that you pass through the QueryString which maps to a session variable which would contain the actual data you are looking for. This would resolve the issue of having multiple windows open in the same session. The GUID would ensure that the data you are retrieving is specific to the current window, and passing the GUID through the querystring ensures this.
This is probably more complex than it needs to be. So the last option would be to do a Server.Transfer and set public properties on the source page that would be read on the target page. This ensure that the data is kept on the server (thus you don't need to encrypt it), and it also ensures that the data from page 1 is read on page 2 (so you could have multiple windows open and they wouldn't affect one another).
Here's a good MSDN article with more detail: http://msdn.microsoft.com/en-us/library/6c3yckfw(vs.80).aspx
I would go with the encrypted querystring or the Server.Transfer to keep it simple.
Cheers,
James / Bursting Silver