2

Let's take an egregious example of this:

Alice and Bob want to clone a Pokemon.

They set up a trade between their console devices. Alice's device sends a copy of the data to Bob's device, then Bob's device sends a copy of theirs to Alice. As each device begins to save the results, Alice shuts off her device preventing the save. Bob does not. Bob now has Alice's Pokemon and Alice still has a copy of it on her device.

Suppose we try to set up a dirty bit before beginning the transfer and revert changes on next power on if the transfer has not completed. That doesn't seem to work either. After both parties complete they send completion acknowledgements to one another, Alice simply has to shut her device off while Bob receives and processes the acknowledgement. Bob gets the clone, Alice's database state reverts to previous.

It just seems to me like it is incredibly difficult to ensure that two equal peers with no mediator can sync up on a single piece of data if both are at risk of communication cutoff strategically employed at the right moment. But is it impossible?

3
  • 1
    Huh. This is one of the moments that I actually refer someone to The Blockchain. – Marcus Müller Dec 17 '16 at 19:42
  • @Marcus Müller the problem with that is this is a local exchange between devices without a central authority or a party that can be trusted not to interrupt – Searinox Dec 18 '16 at 14:12
  • Switch around the steps so that if the transfer is interrupted the Pokemon gets lost? – user253751 Feb 16 '17 at 2:43
1

The situation you describe assumes that both Alice and Bob are not in full control of the device and software because otherwise Alice could use a modified software which prevents the deletion of the local Pokemon.
If this assumption is true, i.e. Alice cannot tamper with the device and software, one could do the transfer in multiple steps:

  1. Alice creates a random key and encrypts the Pokemon
  2. Alice sends the encrypted Pokemon to Bob but not yet the key. Alice waits for confirmation that Bob received the encrypted Pokemon.
  3. Alice deletes the local Pokemon.
  4. Alice sends the encryption key to Bob until it gets a confirmation. Bob confirms after successful decryption. Only after the confirmation both destroy the no longer needed key.

If the initial assumption is not correct, i.e. if Alice can actually modify the software which is in control of the exchange, then you need some external service where all parties can verify who owns a specific Pokemon now. While this will not make cheating impossible it can be used to detect if a Pokemon is used by somebody who does not own it. As indicated in a comment, Bitcoin is one way to run such a service.

5
  • This works for exchanging Pokemons if they each not send the key before they have received the encrypted Pokemon from the other party. – DepressedDaniel Dec 18 '16 at 4:49
  • @DepressedDaniel: unfortunately I'm unable to find out what you are trying to say with your comment. Could you explain it in more depth? – Steffen Ullrich Dec 18 '16 at 5:15
  • @Steffen-Ullrich Yes the assumption is that they do not have control of the software, because once they can edit the software itself it's basically game-over since they can do anything and it is outside the system's competence to prevent. That creation of a penalty in case of interruption via key is useful only if we care about a single party receiving the info however. In this case we care about both parties either successfully completing, or not completing the transaction - an exchange whose result will save the same outcome on both sides, surviving interruption exploits at any stage. – Searinox Dec 18 '16 at 14:11
  • @Steffen-Ullrich Another thing I'd add to your example, if the user interrupts AND never ever completes the key receipt then there is a data loss. The idea is for both parties to be consistent on the final outcome, to be in sync or for the lack of sync to be fixed after the next power-on, even if the other party is no longer around. If Alice doesn't continue the key send or powers off her own device after, then the data is effectively lost. – Searinox Dec 18 '16 at 14:16
  • @Searinox: If Alice switches off the device after she deleted the original Pokemon (step 3) the procedure will still continue in step 4 after she switched the device on again because Alice still has the encryption key. Thus there is only a loss if Alice can never connect to Bob again. There might by some cryptographic tricks which offer more protection but these should be better asked at crypto.stackexchange.com. – Steffen Ullrich Dec 18 '16 at 15:44

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.