<p>I'm running both a bitcoin and a litecoin node, both are generating invalid addresses.</p>

<p>My LTC generated address:
<strong>MV6eGvkbkgcDZLDpK1WQeZLMmx3PHZmXC7</strong></p>

<p>My BTC generated address:
<strong>2MvuZyhhGHCUcFPHCEUNeBbGEKYJ5wpytjk</strong></p>

<p>I'm generating them in the bitcoin-cli/litecoin-cli with getnewaddress </p>

<p>What am I doing wrong and how to fix it?</p>

CC BY-SA 4.0
2018-06-10T22:49:33.167Z
Those look like valid P2SH testnet addresses. Is that not what you expected?
Pieter Wuille
CC BY-SA 4.0
2018-06-10T23:17:47.347Z
not really, the node is pointing to the main net, what could I be doing wrong?
sigmaxf
CC BY-SA 4.0
2018-06-10T23:18:51.787Z
Do you have -testnet or -regtest on the command line? Or in bitcoin.conf?
Pieter Wuille
CC BY-SA 4.0
2018-06-10T23:44:41.450Z
What does `getbestblockhash` print out?
Nate Eldredge
CC BY-SA 4.0
2018-06-11T00:09:39.983Z
it gets the last block: 85c058d5541a7eafdb159ebb9f00be39dbfd17a41fed5d33104c075afeebef9f
sigmaxf
CC BY-SA 4.0
2018-06-11T00:11:27.493Z
no -testnet or -regtest on command line or bitcoin.conf
sigmaxf
CC BY-SA 4.0
2018-06-11T02:30:51.593Z
MV63... appears to be a valid P2SH Litecoin address and contains LTC 0.19 according to https://chainz.cryptoid.info/ltc/address.dws?MV6eGvkbkgcDZLDpK1WQeZLMmx3PHZmXC7.htm.  So everything may be correct on the Litecoin side.  The Bitcoin one really does look like testnet; what does `getbestblockhash` print out there?
Nate Eldredge
CC BY-SA 4.0
2018-06-11T02:33:30.660Z
2MVu... is a valid P2SH testnet address, anyway; I just sent some coins to it :-) https://www.blocktrail.com/tBTC/address/2MvuZyhhGHCUcFPHCEUNeBbGEKYJ5wpytjk
Nate Eldredge
<wallet><nodes>
Bitcoin node generating invalid addresses
sigmaxf
# Bitcoin node generating invalid addresses

(Asked by: username_0 on 2018-06-10)

I'm running both a bitcoin and a litecoin node, both are generating invalid addresses.

My LTC generated address:
**MV6eGvkbkgcDZLDpK1WQeZLMmx3PHZmXC7**

My BTC generated address:
**2MvuZyhhGHCUcFPHCEUNeBbGEKYJ5wpytjk**

I'm generating them in the bitcoin-cli/litecoin-cli with getnewaddress

What am I doing wrong and how to fix it?

**Tags:** wallet, nodes

> **Comments:**
> **username_1**: Those look like valid P2SH testnet addresses. Is that not what you expected?  
> **username_0**: not really, the node is pointing to the main net, what could I be doing wrong?  
> **username_1**: Do you have -testnet or -regtest on the command line? Or in bitcoin.conf?  
> **username_2**: What does `getbestblockhash` print out?  
> **username_0**: it gets the last block: 85c058d5541a7eafdb159ebb9f00be39dbfd17a41fed5d33104c075afeebef9f  
> **username_0**: no -testnet or -regtest on command line or bitcoin.conf  
> **username_2**: MV63... appears to be a valid P2SH Litecoin address and contains LTC 0.19 according to https://chainz.cryptoid.info/ltc/address.dws?MV6eGvkbkgcDZLDpK1WQeZLMmx3PHZmXC7.htm.  So everything may be correct on the Litecoin side.  The Bitcoin one really does look like testnet; what does `getbestblockhash` print out there?  
> **username_2**: 2MVu... is a valid P2SH testnet address, anyway; I just sent some coins to it :-) https://www.blocktrail.com/tBTC/address/2MvuZyhhGHCUcFPHCEUNeBbGEKYJ5wpytjk  

---

## 0 answers

