Re: [Lightning-dev] How to use LN

2018-01-25 Thread Benjamin Mord
Related, I am also interested in the differences between the three major
lightning implementations: lnd, eclair, and c-lightning. I understand they
are implemented in Go, Scala, and C, respectively. Are there other
important differences for early adopters to consider, when selecting an
implementation?

(Christian, I believe of these three implementations, you happen to work on
c-lightning. Correct? Are there contributors from lnd and eclair on this
list as well?)

On Jan 25, 2018 3:48 PM, "v e"  wrote:

Thanks Christian,

I do know that i should not expose lighteningd to multiple tenants however,
I am still trying to understand:

1) How merchant wallet is tied up to an invoice?

2) How consumer wallet can send satoshi to that invoice id?

If you have any code examples that would be great.



On Sat, Jan 20, 2018 at 5:41 AM, Christian Decker <
decker.christ...@gmail.com> wrote:

> v e  writes:
> > Will do as you suggested. one another question, when you say customers do
> > you mean end clients who are buying goods and services?
>
> Yes, they'll need to have clients that understand the Lightning protocol
> just like anyone else in the network.
>
> > Also i am building an server-client model where i am trying to host
> > multiple merchants who can accepts payments from end customers.
> > Does that mean i need to have (bitcoins node, c-lightning + charge) node
> > per merchant?
>
> Neither c-lightning nor Lightning Charge (or any other implementation
> for that matter) is multi-tenant, which is what you're
> describing. Someone with access to the RPC has full control over all
> channels and all funds in the daemon. Just like you wouldn't expose a
> raw bitcoind RPC interface to multiple users, you shouldn't directly
> expose lightningd to multiple tenants. You can build a layer inbetween
> that differentiates the tenants and controls access to individual
> resources though, but we don't currently support it directly.
>
> Notive also that we'd like to encourage every users, be it customer or
> shop, to run their own nodes, not rely on large managed infrastructure.
>
> Cheers,
> Christian
>


___
Lightning-dev mailing list
Lightning-dev@lists.linuxfoundation.org
https://lists.linuxfoundation.org/mailman/listinfo/lightning-dev
___
Lightning-dev mailing list
Lightning-dev@lists.linuxfoundation.org
https://lists.linuxfoundation.org/mailman/listinfo/lightning-dev


Re: [Lightning-dev] How to use LN

2018-01-25 Thread v e
Thanks Christian,

I do know that i should not expose lighteningd to multiple tenants however,
I am still trying to understand:

1) How merchant wallet is tied up to an invoice?

2) How consumer wallet can send satoshi to that invoice id?

If you have any code examples that would be great.



On Sat, Jan 20, 2018 at 5:41 AM, Christian Decker <
decker.christ...@gmail.com> wrote:

> v e  writes:
> > Will do as you suggested. one another question, when you say customers do
> > you mean end clients who are buying goods and services?
>
> Yes, they'll need to have clients that understand the Lightning protocol
> just like anyone else in the network.
>
> > Also i am building an server-client model where i am trying to host
> > multiple merchants who can accepts payments from end customers.
> > Does that mean i need to have (bitcoins node, c-lightning + charge) node
> > per merchant?
>
> Neither c-lightning nor Lightning Charge (or any other implementation
> for that matter) is multi-tenant, which is what you're
> describing. Someone with access to the RPC has full control over all
> channels and all funds in the daemon. Just like you wouldn't expose a
> raw bitcoind RPC interface to multiple users, you shouldn't directly
> expose lightningd to multiple tenants. You can build a layer inbetween
> that differentiates the tenants and controls access to individual
> resources though, but we don't currently support it directly.
>
> Notive also that we'd like to encourage every users, be it customer or
> shop, to run their own nodes, not rely on large managed infrastructure.
>
> Cheers,
> Christian
>
___
Lightning-dev mailing list
Lightning-dev@lists.linuxfoundation.org
https://lists.linuxfoundation.org/mailman/listinfo/lightning-dev


Re: [Lightning-dev] How to use LN

2018-01-20 Thread Christian Decker
v e  writes:
> Will do as you suggested. one another question, when you say customers do
> you mean end clients who are buying goods and services?

Yes, they'll need to have clients that understand the Lightning protocol
just like anyone else in the network.

> Also i am building an server-client model where i am trying to host
> multiple merchants who can accepts payments from end customers.
> Does that mean i need to have (bitcoins node, c-lightning + charge) node
> per merchant?

Neither c-lightning nor Lightning Charge (or any other implementation
for that matter) is multi-tenant, which is what you're
describing. Someone with access to the RPC has full control over all
channels and all funds in the daemon. Just like you wouldn't expose a
raw bitcoind RPC interface to multiple users, you shouldn't directly
expose lightningd to multiple tenants. You can build a layer inbetween
that differentiates the tenants and controls access to individual
resources though, but we don't currently support it directly.

Notive also that we'd like to encourage every users, be it customer or
shop, to run their own nodes, not rely on large managed infrastructure.

Cheers,
Christian
___
Lightning-dev mailing list
Lightning-dev@lists.linuxfoundation.org
https://lists.linuxfoundation.org/mailman/listinfo/lightning-dev


Re: [Lightning-dev] How to use LN

2018-01-19 Thread v e
Thanks christian,

Will do as you suggested. one another question, when you say customers do
you mean end clients who are buying goods and services?

Also i am building an server-client model where i am trying to host
multiple merchants who can accepts payments from end customers.
Does that mean i need to have (bitcoins node, c-lightning + charge) node
per merchant?


On Fri, Jan 19, 2018 at 3:31 AM, Christian Decker <
decker.christ...@gmail.com> wrote:

> Hi v e,
>
> in order to use Lightning Charge you will need the following:
>
>  - A full bitcoind node sync'd with the network
>  - A c-lightning node
>  - npm + lightgning-charge running to give you access to the REST API
>
> We currently do not have (and may never have) bindings for bitcoinj.
>
> Re invoices: the invoices are tracked by c-lightning and you can store a
> reference to them in your store using the `payment_hash`. Customers will
> need to have their own Lightning client and some channels open to the
> network in order to send payments.
>
> Cheers,
> Christian
>
> v e  writes:
> > Hi,
> >
> > I am building merchant app and consumer wallet app using
> > https://bitcoinj.github.io APIs for wallet creation. Now I want to use
> LN
> > built by your team. I am looking at this API
> > https://github.com/ElementsProject/lightning-charge
> >
> > and have few questions:
> >
> > * Do i need to run bitcoin core node?
> > * I see invoice apis, I assume that the invoice is generated at the
> > merchant wallet app. How do i tie the merchant wallet to the invoice?
> >
> > * similarly how do i send coins from consumer wallet to the created
> invoice?
> >
> > Sorry I am very new to this and apologize my assumptions.
> >
> > Any help is highly appreciated.
> > ___
> > Lightning-dev mailing list
> > Lightning-dev@lists.linuxfoundation.org
> > https://lists.linuxfoundation.org/mailman/listinfo/lightning-dev
>
___
Lightning-dev mailing list
Lightning-dev@lists.linuxfoundation.org
https://lists.linuxfoundation.org/mailman/listinfo/lightning-dev


Re: [Lightning-dev] How to use LN

2018-01-19 Thread Christian Decker
Hi v e,

in order to use Lightning Charge you will need the following:

 - A full bitcoind node sync'd with the network
 - A c-lightning node
 - npm + lightgning-charge running to give you access to the REST API

We currently do not have (and may never have) bindings for bitcoinj.

Re invoices: the invoices are tracked by c-lightning and you can store a
reference to them in your store using the `payment_hash`. Customers will
need to have their own Lightning client and some channels open to the
network in order to send payments.

Cheers,
Christian

v e  writes:
> Hi,
>
> I am building merchant app and consumer wallet app using
> https://bitcoinj.github.io APIs for wallet creation. Now I want to use LN
> built by your team. I am looking at this API
> https://github.com/ElementsProject/lightning-charge
>
> and have few questions:
>
> * Do i need to run bitcoin core node?
> * I see invoice apis, I assume that the invoice is generated at the
> merchant wallet app. How do i tie the merchant wallet to the invoice?
>
> * similarly how do i send coins from consumer wallet to the created invoice?
>
> Sorry I am very new to this and apologize my assumptions.
>
> Any help is highly appreciated.
> ___
> Lightning-dev mailing list
> Lightning-dev@lists.linuxfoundation.org
> https://lists.linuxfoundation.org/mailman/listinfo/lightning-dev
___
Lightning-dev mailing list
Lightning-dev@lists.linuxfoundation.org
https://lists.linuxfoundation.org/mailman/listinfo/lightning-dev