Skip to content
This repository has been archived by the owner on Feb 2, 2021. It is now read-only.

Thoughts on the Lighthouse protocol and proposed BIP70 alternative protocol #196

Closed
andychase opened this issue Aug 21, 2015 · 8 comments
Closed

Comments

@andychase
Copy link

Analysis of the Lighthouse model

In short, I don't see the point in trying to make crowdfunding "trustless" using smart contracts. Here's why:

  1. Pledgers can retract their pledges by spending their inputs before the pledges are claimed
  2. Project owners can claim partially-completed projects by filling the remainder with their own funds (or borrow some from a lending club if they need to)
  3. Even when completed normally, project owners can ultimately just do whatever they want with the outputs once the campaign is completed

It seems to me if you want to contribute money towards a project, you must completely trust the project owner straight away.

Suggested Alternative BIP-70 protocol

  1. Pledges are simply Bitcoin transactions. They can be sent off-chain and bundled or just published as normal. This prevents double spending either on accident or on purpose.
  2. Pledges include a change address refund_to

^ BIP 70 can handle the above two cases (especially: "If the sum of outputs.amount is zero, the customer will be asked how much to pay" -- BIP70)

Campaign successful

1.The funds were collected during campaigning, nothing needs to be published
2. Partial refunds are now possible (for my crowdfunding project this was important since I didn't know exactly how much I needed and wanted to be able to return extras)
3. The campaign can continue accepting contributions (Kickstarter allows this and it helps many projects) or reject BIP70 requests to prevent this if they want

Campaign failure

(either manually because of not enough interest or a deadline is reached):

  1. The owner can refund all contributions publicly with one or more transactions
Limiting trust / Centralized mode

If you want to limit trust, you can use a intermediary (Kickstarter, essentially), to dox project owners or take charge of pushing legal action against the rouge project owner.

Lighthouse model limitations:

  1. Can't "refund" with any sort of automated confirmation back to the pledgers
  2. Campaigns can't "expire" or be "cancelled" (in my model BIP70 could be set up to reject payments if the campaign was cancelled)
  3. Limits of amount and number of contributors

BIP-70 model advantages:

  1. Supports timeouts and canceling projects
  2. Prevents double spending
  3. Supports partial refunds
  4. Supports any number of contributors
  5. Has no minimum amount requirement
  6. Allows contributions past campaign goal
  7. Enables donations to be made from any BIP70 wallet

Should a static output be used?
  • Advantages
    • Total contributed so far is public
  • Disadvantages
    • Contributors addresses are public/revealed
      • I believe that if contributor wants to disguise their sending address, it should be up to them to tumble it beforehand
      • In many cases contributors address are not linked to their identity anyway (pseudo anonymous)

In my model using mixed addresses is possible through BIP-70, but the addresses would likely be revealed when the campaign owner starts using the outputs.

@andychase andychase changed the title Thoughts on the Lighthouse model and proposed alternative protocol Thoughts on the Lighthouse protocol and proposed BIP70 alternative protocol Aug 21, 2015
@mikehearn
Copy link
Contributor

Hey Andy,

I think there's some confusion here about the threat model Lighthouse has.

Trust isn't one dimensional. I may trust you to, for example, make a nice music album. But that doesn't mean I trust you to be a computer security expert who can handle digital cash. That's a different skillset and different set of possible mistakes. Lighthouse removes the need for the second kind of trust.

Note that if you don't trust the project creator to actually deliver what they are promising to make then that's a different problem. In that case, what you want is a Lighthouse project that pays to a multisig address where the signers are judges who decide if the project is completed successfully or not. The maker can then borrow against the pledged money. Note that once the crowdfund completes, and the money moves to the escrow holders, the pledges can't be revoked anymore so the funds can be used as collateral.

The "you can just get a loan and take the pledges" model assumes an untrustworthy project operator. Obviously, even if they complete a project themselves, they are still on the hook for delivering what they said they'd make. If you are concerned they might defraud you or prove terminally incompetent, then the solutions are multisig escrow, or ID verification+lawsuits, or just accepting the risk as Kickstarter backers do.

With respect to features like timeouts, overcollection etc - they can be added as features on top of the existing Lighthouse model too. The app doesn't have them because it's the work of one man (me) who has many other features to think about, not because they're impossible.

@andychase
Copy link
Author

(This conversation has been edited to remove my comments in which I learn more about the Lighthouse models pros/cons. Archive here: https://archive.is/0QMZL)

@mikehearn
Copy link
Contributor

I guess I just don't understand how my model makes it so you have to be a computer security expert, and your model doesn't.

In your model the money is under the control of the project owner, even when the project is not completed.

If you raise half the money and then get hacked and the funds are stolen, then what?

@mikehearn
Copy link
Contributor

No - all that would do is transfer the hackers money to the project owner. Think about it.

@mikehearn
Copy link
Contributor

Most pledge files are kept on Lighthouse servers, which are totally different computers to those running users wallets. But obviously if the hacker can get the private keys of the place you keep your crowdfunded money, it's game over with both your protocol and mine.

The difference is, the Lighthouse protocol lets you specify the address as being e.g. a cold wallet. And you don't have to touch that cold wallet during the crowdfund, even if people decide they want their pledged money back. And because there's no confusion over ownership, you avoid tricky legal issues .... if you take deposits and refund them then you can actually end up being regulated like a bank, which in practice makes it impossible to do. It's just safer and clearer all round if money only ever has one owner in the base case.

Anyway, all this stuff is already covered in the FAQ:

https://www.vinumeris.com/lighthouse/faq#why-is-it-useful

@andychase
Copy link
Author

First off I want to thank you for participating in this discussion. Truly my only intention here is to have a clear understanding of what Lighthouse is and what I can do to push Bitcoin crowdfunding along.

Okay I think I'm starting to make headway here in understanding! I get now that you are saying that Lighthouse has a decisive advantage in the case that you are using a third-party entity to handle donations, and that those donations alone can't be used as an attack vector. I get it!

Breakdown

That is a pretty cool advantage in my opinion.

But my focus has been all along: How much is actually gained vs how much is actually lost with this approach vs BIP70?

Okay to sum up this conversation I'd like to go through some of the features I'm talking about and lay down what would be needed to implement them in lighthouse.

Lighthouse Advantages:

  • Pledges can be repealed by owner (I saw this as a disadvantage, but I see now that's something you find desirable)
  • Intermediaries can handle collections without adding much additional risk (Though it's not a trustless system, they can still point people to making bad pledges- resistant to seizure not control)

Lighthouse Disadvantages/TODO:

  • Max number of donors
    • How to fix: raise max TX size
    • Difficulty: ??
  • Min pledge amount
    • How to fix raise max TX size
    • Difficulty: ??
  • Refunds/Expires aren't handled automatically
    • How to fix: A whole new network?
    • Difficulty: 1 man year
  • Pledges must be made from special software (currently, vs running BIP70 software)
    • How to fix: Add pledging to all Bitcoin software
    • Difficulty: 1 man year
  • UTXO feature required by full nodes or requires project owners to run full nodes
    • Shouldn't fix: Many believe it would be better to have this not in Bitcoin core
    • Difficulty: ??
  • Partial refunds not possible
    • How to fix: obtain refund_to addresses in lighthouse
    • Difficulty: 1 man hour
  • Can collect additional contributions
    • How to fix: Add server check and donate to static address instead
    • Difficulty: 1 man hour
  • Can reject contribution (in case of failure)
    • How to fix: If using third party, add a server check and add to ui
    • Difficulty: 1 man hour

@andychase
Copy link
Author

tldr;

  • Legality argument is hollow
  • Instant refunds are possible in my model
  • Integrated X.509 certificate authorization

Legality

You brought up the legal nature of my protocol. I defer to this post on the mailing list:

s7r writes --- Thu Aug 27 09:33:16 UTC 2015:

[Bitcoin] operates globally, so neither jurisdiction can apply to it
and have effects. It is the sole responsibility of all the
users/businesses involved in Bitcoin to comply with their local
regulations while using Bitcoin.

Instant Refunds

To replicate the functionality of a pledger being able to reverse their funds at any moment, I propose an implementation of a "pledge claim ticket" that is simply an off-chain transaction that is signed back to the pledgors return_to address. A pledger can broadcast this at any moment before the campaign is over to retrieve their funds.

Now: In practical terms, this could be a text file with the base64 encoding of the transaction that a pleger can download after they pledge. A website would be set up where this file could be drag-n-dropped in or copy/pasted to have it claimed/broadcasted.

Later: Maybe Bitcoin clients should have a way of standard way accepting and broadcasting off-chain transactions?

Security

This would require that the private key be available during the campaign for signing back each transaction, which, as you mentioned, isn't the most secure. I think there's ways to mitigate this like using a secure web wallet service for use in centralized mode (It's already centralized, so using a hardened service should be fine).

X.509 Certificates and Campaign Authorization

One part of the Lighthouse model that worried me was that there is no authorization. Anyone can produce a campaign in decentralized mode and start collecting funds under a false premise.

(This suggestion could be integrated in Lighthouse, the advantage here is that BIP-70 wallets support pledging with authorization and pledgers don't have to download Lighthouse. I'll spin the Lighthouse suggestion into a separate feature request.)

My method allows use of a X.509 certificate to sign and authorize the campaign outputs. The easiest method for getting a certificate I believe would be to use a X.509 email certificate such as from https://www.comodo.com/home/email-security/free-email-certificate.php

Pledgers would be able to see that email address when they initialize the pledge from their BIP-70 enabled wallet and know they are sending their money to someone authorized email.

This is not a perfect security scheme (attackers could just use an email address that looks close, hack the email, or intercept the email), but I would suggest is more integrated and trustworthy then a non-certificate approach.

Centralized mode benefits

In the centralized mode, the central campaign server operator is expected to verify each campaign separately, where in my model the verification could be just based on the certificate and done automatically (either for email or website ssl certificates).

Although server operators could set up their own email verification system, the advantage here is that you offload the trust to Comodo or some other and so you are trusting a verified third-party instead of the campaign server operator.

Disadvantage: The CA model has flaws and is not seen as perfect. Perhaps something like namecoin or keybase.io is the future (last one wouldn't work in my model as they use pgp keys not x.509 which is needed in BIP-70).

Trade-offs

There's a tradeoff here of simplicity and practically in my approach vs some minor security benefits in your approach, but believe we are on the same page there's no such thing as a "perfect solution":

An extreme level of black/white thinking, in which something is either mathematically perfect or hopelessly flawed to the extent it shouldn’t exist at all, with nothing in between.

I believe that my approach is simpler, easier to implement and maintain, and offers more immediate features for crowdfunding users and project owners.

I believe my make-or-break feature is being able to pledge with any BIP-70 enabled wallet.

Offer

If my implementation is a success and no major flaws are discovered, I'd love to work with you to implement this into the Lighthouse brand and push Bitcoin crowdfunding forward in a non-fragmented way.

@mikehearn
Copy link
Contributor

Re: using X.509 certs to digitally sign projects, good thinking. I fully agree, which is why I already thought of it and filed an item for doing so here in issue #54 last year. An implementation would be most welcome. Lighthouse projects are already (extended) BIP 70 protobufs so the same infrastructure can be reused.

Re: legality. The issue is not the legality of Bitcoin but of running a service where you are taking and managing deposits of money that isn't yours. If someone has given you money on the understanding they can withdraw it at any point, then that money isn't legally yours, it's theirs, even if they have agreed that it may become yours if a goal is reached in future. Taking deposits has a long history of going wrong, which is why it's regulated. If you can't control the money that's been given to you as a pledge until the exact moment the goal is reached, there are no such issues.

With respect to refunds:

To replicate the functionality of a pledger being able to reverse their funds at any moment, I propose an implementation of a "pledge claim ticket" that is simply an off-chain transaction that is signed back to the pledgors return_to address. A pledger can broadcast this at any moment before the campaign is over to retrieve their funds.

This doesn't work: the project owner can invalidate the 'claim ticket' at any point by just spending the money you gave them back to themselves, thus rendering it largely pointless. This is why Lighthouse works the way it does.

What's more, the moment you have such things, you're back to needing a specialised wallet to handle it all. Ordinary BIP70 supporting wallets won't know how to do any of this stuff. If they're going to be upgraded to support crowdfunding specifically, they can just as easily support the current Lighthouse protocol.

So I still don't see what your proposal does better.

Working through your list of disadvantages/todos:

Lighthouse Disadvantages/TODO:

Max number of donors
How to fix: raise max TX size
Difficulty: ??

It requires changes to the Bitcoin protocol. After the block size hard fork, we'd need another one that improves the signature hash protocol. So yes, this is being worked on, but is ultimately dependent on the Bitcoin community working through its social issues around upgrades to the block chain.

Refunds/Expires aren't handled automatically
How to fix: A whole new network?
Difficulty: 1 man year

A simple implementation is to upload your time locked refund transaction to a few different Lighthouse servers and have them broadcast when the time is right. This is much less than one year of work. Probably a few days of work at most, for someone familiar with the code. Perhaps a week or so otherwise.

But bear in mind that the deadline feature in sites like Kickstarter is probably more about keeping their site clean of failed projects than being a fundamental component to a crowdfund. Lighthouse doesn't have that issue as it doesn't have a single website for every project. So I'm not sure why a project really needs a deadline: most of the time if you think it's a good idea, you'd still think it's a good idea in six months.

Pledges must be made from special software (currently, vs running BIP70 software)
How to fix: Add pledging to all Bitcoin software
Difficulty: 1 man year

"All" software is overkill. Adding just a pledging client isn't that hard, especially for code based on bitcoinj, as the Lighthouse code can be reused.

With some refactoring I'm sure we could do a demo of how to integrate it into MultiBit or Bitcoin Wallet for Android in way less than a year.

UTXO feature required by full nodes or requires project owners to run full nodes
Shouldn't fix: Many believe it would be better to have this not in Bitcoin core
Difficulty: ??

If by "many" you mean a handful of Bitcoin Core developers who can be relied on to make almost any change controversial then yes, but I couldn't care less about that. This isn't a problem that needs fixing. There are plenty of XT nodes these days.

Partial refunds not possible
How to fix: obtain refund_to addresses in lighthouse
Difficulty: 1 man hour

A crowdfund with partial refunds is essentially a kind of loan, or a subset of a loan. You can talk to Mike from CoinShark about the work he's doing to add P2P lending support to Lighthouse.

Can collect additional contributions
How to fix: Add server check and donate to static address instead
Difficulty: 1 man hour

Indeed, this is not hard. It is issue #63

Can reject contribution (in case of failure)
How to fix: If using third party, add a server check and add to ui
Difficulty: 1 man hour

Please see issue #85

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants