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

lnd: add litecoin support for Neutrino #3062

Closed
wants to merge 2 commits into from
Closed

lnd: add litecoin support for Neutrino #3062

wants to merge 2 commits into from

Conversation

ghost
Copy link

@ghost ghost commented May 9, 2019

Please could you review the following proposal for enabling litecoin support in LND/Neutrino :

LND/config.go :
allow the configuration of litecoin.node=neutrino

LND/chainparams.go/applyLitecoinParams :
apply some litecoin chainparams settings that were missed in the original implementation, namely:
GenesisBlock information
PowLimitBits and PowLimit

Ref: lightninglabs/neutrino#142

@wakiyamap
Copy link

Isn't it better to copy DNSseed too?

	dnsSeeds := make([]chaincfg.DNSSeed, len(litecoinParams.DNSSeeds))
	for i := 0; i < len(litecoinParams.DNSSeeds); i++ {
		dnsSeeds[i] = chaincfg.DNSSeed{
			Host:         litecoinParams.DNSSeeds[i].Host,
			HasFiltering: litecoinParams.DNSSeeds[i].HasFiltering,
		}
	}
	params.DNSSeeds = dnsSeeds

@ghost
Copy link
Author

ghost commented Jun 14, 2019

@wakiyamap yes, in general it would be best if the entire litecoinParams is copied over, but I don't know a way to do that without copying each data element explicitly. By the way, LND uses its own seeding as defined in lnd/chainregistry.go (line 561 - 595)

@wakiyamap
Copy link

@Wowee0 thanks reply!
lnd/chainregistry.go (line 561 - 595) is dnsseed of layer2(lnd).
Dnsseed of layer1 is different.

So I think this would load the default BTCtestnet dnsseed.

@ghost
Copy link
Author

ghost commented Jun 15, 2019

@wakiyamap ok, yes your code above should indeed be included - done. Good find!

@Roasbeef
Copy link
Member

Closing due to inactivity.

@Roasbeef Roasbeef closed this Jan 21, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants