Bitcoin Forum
May 05, 2026, 03:23:51 PM *
News: Latest Bitcoin Core release: 31.0 [Torrent]
 
   Home   Help Search Login Register More  
Pages: [1]
  Print  
Author Topic: How to generate a Litecoin Private key and correspondent Public Address in C#  (Read 1393 times)
Gustiras (OP)
Newbie
*
Offline

Activity: 1
Merit: 0


View Profile
February 19, 2015, 12:06:23 AM
Last edit: February 19, 2015, 12:49:27 AM by Gustiras
 #1

Hello,

I found this C# tool to generate addresses for Bitcoin (compressed and uncompressed):

https://en.bitcoin.it/wiki/Bitcoin_Address_Utility
https://github.com/casascius/Bitcoin-Address-Utility

It works perfectly for Bitcoin, but for Litecoin it seems not to work.

Any ideas how to use similar code to generate Litecoin Addresses?

Thanks
jasemoney
Legendary
*
Offline

Activity: 1610
Merit: 1008


Forget-about-it


View Profile
February 19, 2015, 03:33:01 AM
Last edit: February 19, 2015, 03:43:54 AM by jasemoney
 #2

https://bitcointalk.org/index.php?topic=25804.0

https://github.com/samr7/vanitygen

https://bitcointalk.org/index.php?topic=202146.0



https://github.com/litecoin-project/litecoin/blob/master-0.8/src/base58.h#L275
Quote
"        PUBKEY_ADDRESS = 48, // Litecoin addresses start with L"

you can write a quick file to start the vanitygen in windows..
create a notepad text file call it
Quote
runvanitygen.bat

put this in it
Quote
vanitygen -i -k -o complete.txt -X 48 Litecoin
will search for a pattern Litecoin
-i means case insensitive
-k means it will keep finding more after it finds one match
-X 48 is the pubkey address number found in the base58 file from litecoin code, since litecoin is widely spread you can use just -L instead
-o creates and outputs the result(s) to a txt file

this will get you a matched private key and an address. it will not show the other various key datas.
\you can change Litecoin to whatever it just needs to start with a capital L and cant contain uppercase i, lowercase L uppercase o, nor number zero.

*apologies im sure this isnt exactly what your looking for, but if you want to create addresses and hold the keys this is how. if you want to know the WIF compressed uncompressed etc from a private key then this isnt helpful

$MAID & $BTC other than that some short hodls and some long held garbage.
monsterer
Legendary
*
Offline

Activity: 1008
Merit: 1011


View Profile
February 19, 2015, 10:19:47 PM
 #3

Hello,

I found this C# tool to generate addresses for Bitcoin (compressed and uncompressed):

https://en.bitcoin.it/wiki/Bitcoin_Address_Utility
https://github.com/casascius/Bitcoin-Address-Utility

It works perfectly for Bitcoin, but for Litecoin it seems not to work.

Any ideas how to use similar code to generate Litecoin Addresses?

Thanks

Look for the address type byte - it needs changing Smiley
mcaizgk2
Member
**
Offline

Activity: 66
Merit: 50


View Profile
February 21, 2015, 02:03:25 AM
 #4

Hello,

I found this C# tool to generate addresses for Bitcoin (compressed and uncompressed):

https://en.bitcoin.it/wiki/Bitcoin_Address_Utility
https://github.com/casascius/Bitcoin-Address-Utility

It works perfectly for Bitcoin, but for Litecoin it seems not to work.

Any ideas how to use similar code to generate Litecoin Addresses?

Thanks

You can use BitcoinLib for this purpose which comes with an out of the box Litecoin integration:

ILitecoinService CoinService = new LitecoinService();
string newAddress = CoinService.GetNewAddress();
string privateKeyForNewAddress = CoinService.DumpPrivKey(newAddress);

bloodDiamond
Full Member
***
Offline

Activity: 168
Merit: 100


View Profile
February 21, 2015, 09:54:12 AM
 #5

Hello,

I found this C# tool to generate addresses for Bitcoin (compressed and uncompressed):

https://en.bitcoin.it/wiki/Bitcoin_Address_Utility
https://github.com/casascius/Bitcoin-Address-Utility

It works perfectly for Bitcoin, but for Litecoin it seems not to work.

Any ideas how to use similar code to generate Litecoin Addresses?

Thanks

You can use BitcoinLib for this purpose which comes with an out of the box Litecoin integration:

ILitecoinService CoinService = new LitecoinService();
string newAddress = CoinService.GetNewAddress();
string privateKeyForNewAddress = CoinService.DumpPrivKey(newAddress);



maybe do you know if there are some bitcoin libraries written in VB.NET???

thanks
nagatlakshmi
Hero Member
*****
Offline

Activity: 616
Merit: 500



View Profile WWW
February 21, 2015, 11:39:17 AM
 #6

Very interesting and informative thread.  I learn lot of things here.

Pages: [1]
  Print  
 
Jump to:  

Powered by MySQL Powered by PHP Powered by SMF 1.1.19 | SMF © 2006-2009, Simple Machines Valid XHTML 1.0! Valid CSS!