A thought occurred to me after seeing this question: Storing data - think character data for an online game - on the user`s computer is definitely less safe (maybe an understatement) than on a server under your control, but...
- Is such a mechanism feasible? (while preventing cheating and such, of course...) If yes - why is it not used? Is it just me who hadn't seen it?
Some elaboration and ramblings:
A hypothetical advantage to this would be a need to store VERY little data on the server itself while still being able to handle a HUGE bookkeeping for the character, recording amounts of data you wouldn't dream of while storing the data on your server (think looking back on the exact date of your first attack in a game... sweet, useless, nostalgia :) ).
(Of course, there's a limit to how much you would do this way as well - your user isn't likely to condone a 1GB game save file... or they would... who knows. Maybe an option for what data to keep could give users the choice between conservative and extensive logging of their adventures?)
Take the following example: I think that an attempt to:
- Store a hash of the user's data on the server.
- On the next run, request the data from the user`s end.
- Hash it.
- Compare the hashes.
is bound to fail.
The user could change the data on his end after the verification. I'm assuming there will always be a 'hole' somewhere even if the programmer utilizes tons of checks throughout the game, verifying every action.
This could very well be a reason for not doing this... just remember I'm asking about feasibility, not practicality.
There are some more considerations, of course:
The user's data being at their hands can be less safe and less available. They could lose it, have it stolen, forget their flash drive containing the file at home etc etc.
But it could also mean that the server has very little data on it to be compromised - say, if all of the user's data will be in their file, and the server will only be able to verify its authenticity via hashing mechanism and whatnot.
It will also be very easy to back up a server containing so little data.
The mechanism for the user should be a simple encryption/signature of the data file... or is that bound to fail as well?