New answers tagged algorithm-design
2
Points 3 and 4 are a secure way of storing the input to bcrypt (with appropriate choice of parameters for bcrypt).
Points 1 and 2 aren't necessary but don't harm:
they would add a small amount of extra computation for an attacker is possession of the password database that wants to do a dictionary attack;
the attacker wouldn't be able to straight-out use ...
3
I think what you want to look at is "fair exchange". There's a giant catalog of protocols for fair exchange. They've been designed for doing exactly what (I think) you want.
See, e.g.,
https://en.wikipedia.org/wiki/Multi_party_fair_exchange_protocol
Alice trusts Bob only when Bob trusts Alice
Some fair exchange protocols require a third party who ...
0
I'd like to expand on some claims in previous answers. @AlbertVeli writes "encrypting a block twice with the same algorithm and key ... does not increase security". Rule of thumb is that it's true, however, you can imagine a crypto algorithm with not good enough properties, like bit diffusion. With such algo, applying encryption twice even with the same key ...
2
Note that it is probably technically impossible to meet your requirement that both secrets have to be revealed at exactly the same time, if interpreted literally. However, if we interpret this requirement as meaning that each party needs guarantees that the other party selected its own message, before decrypting the message of the other party, then this ...
Top 50 recent answers are included