Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Build CCJ Tumbler #53

Closed
8 tasks done
nopara73 opened this issue Oct 21, 2017 · 6 comments
Closed
8 tasks done

Build CCJ Tumbler #53

nopara73 opened this issue Oct 21, 2017 · 6 comments

Comments

@nopara73
Copy link
Contributor

nopara73 commented Oct 21, 2017

  • NOTIFICATION new-phase
  • GET /api/v1/tumbler/status
  • POST /api/v1/tumbler/inputs
  • GET /api/v1/tumbler/input-registration-status
  • POST /api/v1/tumbler/connection-confirmation
  • POST /api/v1/tumbler/output
  • GET /api/v1/tumbler/coinjoin
  • POST /api/v1/tumbler/signature
@nopara73 nopara73 added this to the CcjTestNet milestone Oct 21, 2017
@nopara73 nopara73 closed this as completed Nov 6, 2017
@wintercooled
Copy link
Contributor

Can you check the logic around this line in TumblerController.InputsAsync:

if (txOutResponse.Result.Value("confirmations") <= 0)
...etc

It looks like the exception is only thrown if both conditions are met whereas it seems that it should throw if either one or both are met.

@wintercooled
Copy link
Contributor

In TumberController.Status:

I think using:

Version = "1"

instead of

Version = "v1"

would be better as we can do > checks within the client easier.

@wintercooled
Copy link
Contributor

In TumblerController.CoinJoin we currently throw an exception if Alice has already asked for the CoinJoin transaction.

Would it not be ok to let an Alice request this > once?

What if their client quits during the process for some reason? We could make it possible to restart the client, reload the guid (assuming we have saved it locally) and rejoin the CoinJoin at the signing phase.

... just an idea.

@nopara73
Copy link
Contributor Author

nopara73 commented Nov 7, 2017

@wintercooled The logic is good, my comment was not clear. I modified the comment.
The point is, if the input registered is unconfirmed, then it's only acceptable if it's part of a previous successful CoinJoin.

// Check if inputs are unconfirmed, if so check if they are part of previous CoinJoin
if (txOutResponse.Result.Value<int>("confirmations") <= 0)
{
	if (!Global.CoinJoinStore.Transactions
		.Any(x => x.State == CoinJoinTransactionState.Succeeded && x.Transaction.GetHash() == op.Hash))
	{
		throw new ArgumentException("Provided input is not confirmed, nor spends a previous CJ transaction");
	}
}

@nopara73
Copy link
Contributor Author

nopara73 commented Nov 7, 2017

Version = "1"

Ok, I was thinking of this myself, too. Fixed.

@nopara73
Copy link
Contributor Author

nopara73 commented Nov 7, 2017

Would it not be ok to let an Alice request this > once?

The reason is, because I don't want to get DoSd. If it becomes a problem we can do that, I'd keep it this way for now.

We could make it possible to restart the client, reload the guid (assuming we have saved it locally) and rejoin the CoinJoin at the signing phase.

If it'd be needed that'd mean we failed. Signing phase should happen close to instantly.

soosr added a commit that referenced this issue Oct 30, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants