A fair peer-based coin-flipping protocol?
Yes, your basic idea is feasible.  What you are describing is a distributed coin flip protocol based on a commitment scheme.

However, you protocol as described is vulnerable to replay attacks: after one peer receives the other's hash, they can send back the same hash, wait for the other peer to reveal their random bit and salt, and send back those as well.  That way, they can force the outcome of the XOR operation to always be 0.

There are a number of ways to modify this protocol so that this attack won't work:


include a unique peer ID in the hash input,
abort (or restart) the protocol if two peers produce the same hash value, or
require the peer who revealed their hash last to be the first one to reveal their inputs.


Any one of these modifications would be enough to prevent this attack.

Edit: I thought this seemed familiar.  Here's my earlier answer to essentially the same question.