Pages:
Author

Topic: Difference between SegWit addresses - page 3. (Read 9500 times)

newbie
Activity: 4
Merit: 0
November 16, 2017, 04:25:25 AM
#24
No. Old addresses can exist alongside Segwit addresses in the same wallet.
dard way of doing it, it has alot of fail safety built into the design. It should be fine (Disclaimer: I don't use Electrum wallet)

Thanks for all the info. Very informative.
I installed electrum 3, and have now moved some to a new Bech32 (bc1?) address, how can I generate new address in the same electrum 3 wallet but w/ the old standard format? I want to send some over to the same wallet but can't because unsupported by it.
I've sort of looked around and dont see it.

Edit---
Just thought of it, would this be just sweeping private keys from wallet?
legendary
Activity: 966
Merit: 1042
November 04, 2017, 10:53:34 PM
#23
The public key hash for a bech32 address can also be a 256 bit value, but only for P2WSH addresses. These will have a larger number of possible addresses.

Correct.  bech32 P2WSH addresses are about 20 characters longer than bech32 P2WPKH addresses.

That's actually pretty great! I have been trying to read up on this but it's pretty confusing for us non technical folks. I'll wrap my head around it one of these days. Once I do I'll start to try and use the bech32 addresses just to get used to them and go from there.
member
Activity: 301
Merit: 74
November 04, 2017, 10:49:25 PM
#22
Upcoming 0.15.1 (which may or may not include waiting for 0.15.0.2 first, achow101 might tell us more)

Edit: Segwit GUI in Bitcoin Core will now be in 0.15.2, 0.15.1 will be bugfixes and backports
Thanks. How do you find this sort of info?


legendary
Activity: 1512
Merit: 1218
Change is in your hands
November 03, 2017, 12:28:57 PM
#21
Thank you Carlton for the detailed answer, i will look into it further. Smiley
legendary
Activity: 3416
Merit: 4658
November 03, 2017, 12:27:27 PM
#20
So there is no error correction whatsoever in Satoshi-era types like P2PKH and P2SH? (or even the original type P2PK?)

It was possible to detect with reasonable reliability if the address was invalid (one or more errors).

However, it was not possible to easily identify the specific character or characters that were erroneous, nor was it possible to correct those errors for the user.
legendary
Activity: 3430
Merit: 3071
November 03, 2017, 12:14:03 PM
#19
Is the sensitivity of case really important? I'm sure most people use their mouse to copy and paste the address.

In situations where people don't copy and paste, it helps to reduce the chance of errors.
Not only that, but the bech32 addresses use BCH codes (well BCH-like codes) which are an error correcting code. Bech32 addresses can detect up to 4 errors when entering the address and tell you where those errors are. They can also correct up to 2 errors (IIRC) but no wallet will actually do error correction for you because that is a good way to accidentally send money elsewhere.

Ah, interesting. Sounds familiar, I read the BIP173 text pretty quickly Grin

So there is no error correction whatsoever in Satoshi-era types like P2PKH and P2SH? (or even the original type P2PK?)


When is Core expected to add GUI support for these?


Upcoming 0.15.1 (which may or may not include waiting for 0.15.0.2 first, achow101 might tell us more)

Edit: Segwit GUI in Bitcoin Core will now be in 0.15.2, 0.15.1 will be bugfixes and backports

02/12/2018 Edit: Segwit wallets will be in the Bitcoin Core 0.16.0 release, very soon
legendary
Activity: 2898
Merit: 1386
November 03, 2017, 11:52:40 AM
#18
Electrum 3.0 is out and the addresses are starting with bc1 apparently. I have a hardware wallet in the other hand where SegWit is supported too but the addresses are starting with 3 instead. What are the differences and are they compatible between each other (including the old addresses). Could I receive/send without having to worry?

Didn't try but I could say that there are many persons in my contact who are using the same type of addresses that start with 3.
Initially, I thought that they are multisig addresses and I asked them whether it is or not, but they didn't tell me anything except that they are using the same address for every transaction and not facing any problems using the same and it's not including mixed transactions just like we see in exchange addresses. Even I would like to know if such addresses are multisig or not?

https://en.bitcoin.it/wiki/List_of_address_prefixes

"3" is a script hash prefix. If I recall correctly encrypted paper wallets address must start with a "3" in addition to the multisig starting with a "3".
member
Activity: 301
Merit: 74
November 03, 2017, 11:19:50 AM
#17
When is Core expected to add GUI support for these?
legendary
Activity: 3052
Merit: 1273
November 03, 2017, 11:10:28 AM
#16
Electrum 3.0 is out and the addresses are starting with bc1 apparently. I have a hardware wallet in the other hand where SegWit is supported too but the addresses are starting with 3 instead. What are the differences and are they compatible between each other (including the old addresses). Could I receive/send without having to worry?

Didn't try but I could say that there are many persons in my contact who are using the same type of addresses that start with 3.
Initially, I thought that they are multisig addresses and I asked them whether it is or not, but they didn't tell me anything except that they are using the same address for every transaction and not facing any problems using the same and it's not including mixed transactions just like we see in exchange addresses. Even I would like to know if such addresses are multisig or not?
staff
Activity: 3374
Merit: 6530
Just writing some code
November 03, 2017, 10:36:46 AM
#15
Is the sensitivity of case really important? I'm sure most people use their mouse to copy and paste the address.

In situations where people don't copy and paste, it helps to reduce the chance of errors.
Not only that, but the bech32 addresses use BCH codes (well BCH-like codes) which are an error correcting code. Bech32 addresses can detect up to 4 errors when entering the address and tell you where those errors are. They can also correct up to 2 errors (IIRC) but no wallet will actually do error correction for you because that is a good way to accidentally send money elsewhere.
legendary
Activity: 3416
Merit: 4658
November 03, 2017, 10:34:28 AM
#14
Is the sensitivity of case really important? I'm sure most people use their mouse to copy and paste the address.
In situations where people don't copy and paste, it helps to reduce the chance of errors.

base32 was chosen for improved error checking possibilities.  The fact that base32 can be represented with single case characters is just an added benefit for those situations where the user might need to write it down or tell it to someone else.  Another added benefit is that it also makes it possible to use smaller QR Codes (or the same size QR Code with increased redundancy).
legendary
Activity: 3430
Merit: 3071
November 03, 2017, 10:08:45 AM
#13
Is the sensitivity of case really important? I'm sure most people use their mouse to copy and paste the address.

In situations where people don't copy and paste, it helps to reduce the chance of errors.
legendary
Activity: 924
Merit: 1000
November 03, 2017, 09:48:41 AM
#12
So the number of possible addresses is reduced using bech32?

No.

The old P2PKH addresses that started with a 1 were typically 34 characters long.

The new bech32 addresses are typically 42 characters long.

Also...

The first character of the old addresses indicated the address type, and the last 6 characters were part of the checksum, leaving approximately 27 characters of base58 key hash data. This leaves enough room for more than:
1.46 × 1048 possible addresses


With a bech32 P2WPKH address, the first 3 characters indicate the address type, and the last 6 characters are the checksum, leaving 33 characters of base32 key hash data.  This leaves enough room for more than:
1.46 × 1048 possible addresses

Since the public key hash is only a 160 bit value, there are only 1.46 × 1048 possible addresses.  Therefore, BOTH address formats have enough room for ALL possible currently valid addresses.

Cheers.

Is the sensitivity of case really important? I'm sure most people use their mouse to copy and paste the address.
legendary
Activity: 3416
Merit: 4658
November 03, 2017, 09:42:34 AM
#11
The public key hash for a bech32 address can also be a 256 bit value, but only for P2WSH addresses. These will have a larger number of possible addresses.

Correct.  bech32 P2WSH addresses are about 20 characters longer than bech32 P2WPKH addresses.
legendary
Activity: 3430
Merit: 3071
November 03, 2017, 09:37:45 AM
#10
The public key hash for a bech32 address can also be a 256 bit value, but only for P2WSH addresses. These will have a larger number of possible addresses.
legendary
Activity: 3416
Merit: 4658
November 03, 2017, 09:19:20 AM
#9
So the number of possible addresses is reduced using bech32?

No.

The old P2PKH addresses that started with a 1 were typically 34 characters long.

The new bech32 addresses are typically 42 characters long.

Also...

The first character of the old addresses indicated the address type, and the last 6 characters were part of the checksum, leaving approximately 27 characters of base58 key hash data. This leaves enough room for more than:
1.46 × 1048 possible addresses


With a bech32 P2WPKH address, the first 3 characters indicate the address type, and the last 6 characters are the checksum, leaving 33 characters of base32 key hash data.  This leaves enough room for more than:
1.46 × 1048 possible addresses

Since the public key hash is only a 160 bit value, there are only 1.46 × 1048 possible addresses.  Therefore, BOTH address formats have enough room for ALL possible currently valid addresses.
legendary
Activity: 3430
Merit: 3071
November 03, 2017, 07:44:16 AM
#8
1) What are these Segwit Addresses?
  • There are 2 different Segwit address formats. They are P2SH (starting with a "3") and bech32 (starting "bc1")
  • P2SH can be sent to by people using older Bitcoin software with no Segwit support. This supports backwards compatibility
  • People sending from newer Bitcoin software that has Segwit and bech32 can send to the new address type that starts "bc1"
  • People sending from older Bitcoin software that has no Segwit probably cannot send to the new address type that starts "bc1"

So, if people send you BTC from old software, give them the Segwit addresses that start with "3". If people send you BTC using new Segwit Bitcoin software, give them the Segwit addresses that start with "bc1".

If you don't know if someone has the newer bech32 software or not, there's no need to worry, their software will simply refuse to send the transaction, so no harm can be done.


2) How are these different from normal Addresses?

  • You won't get the Segwit fee reduction unless you spend from one of these addresses
  • The addresses starting "3" are normal addresses. They already exist in the Bitcoin blockchain now. The difference is that the Bitcoin script permits a wide variety of options, in this case, using Segwit in a way that old Bitcoin software can handle (obviously old software has no clue what Segwit is, it didn't exist back then, this method works around that)
  • The addresses starting "bc1" are not normal addresses. They are brand new, and only work with Segwit
  • With addresses starting "bc1", it doesn't matter if you USE UPPER CASE. or if you use lower case. bc1bech32segwitaddressescanbeupperorlowercase is the same address as BC1BECH32SEGWITADDRESSESCANBEUPPERORLOWERCASE, neither your wallet software or the blockchain will care


3) How are the fees low compared to other addresses?

There are no guarantees. Bitcoin isn't like going to Walmart (where a price is the only price you can get), it's like going to an auction house. The miners control whose transactions they include in blocks, and they can do it any way they like, even totally crazy ways that lose them money.

But, you could expect to pay fees of ~50% less than non-Segwit transactions, for a regular transaction where you pay from just one address to one address (with one change address). Why? Sort of complicated, but I can explain if you like.


4) If i upgrade from 2.9.3 to 3.0 will i have old addresses or it will swipe them?

No. Old addresses can exist alongside Segwit addresses in the same wallet.

If you're nervous about this, just use a new wallet for all Segwit transactions. But Electrum's approach to wallet specs is flexible enough to allow it, and also the standard way of doing it, it has alot of fail safety built into the design. It should be fine (Disclaimer: I don't use Electrum wallet)
legendary
Activity: 924
Merit: 1000
November 03, 2017, 07:17:56 AM
#7
The addresses starting bc1 (bech32 P2WPKH type) are a new Segwit only type to make addresses easier to use. They essentially make addresess case-insensitive, e.g. BC1MYNEWBITCOINADDRESSISBECH32 is the exact same address as bc1mynewbitcoinaddressisbech32


So the number of possible addresses is reduced using bech32? Isn't that a disadvantage.
legendary
Activity: 1512
Merit: 1218
Change is in your hands
November 03, 2017, 06:11:36 AM
#6
Electrum 3.0 is out and the addresses are starting with bc1 apparently. I have a hardware wallet in the other hand where SegWit is supported too but the addresses are starting with 3 instead. What are the differences and are they compatible between each other (including the old addresses). Could I receive/send without having to worry?


The addresses starting with 3 (nested Segwit in a P2SH type) are definitely backwards compatible: older (non-Segwit) wallet software can receive BTC from your P2SH addresses, and they can send to them too.

The addresses starting bc1 (bech32 P2WPKH type) are a new Segwit only type to make addresses easier to use. They essentially make addresess case-insensitive, e.g. BC1MYNEWBITCOINADDRESSISBECH32 is the exact same address as bc1mynewbitcoinaddressisbech32

I'm sure bc1 (bech32 P2WPKH) are backwards compatible at the blockchain level, because they'd need a hard fork to implement them if not, but that doesn't mean that old wallet software will allow you to send BTC to them. Receiving from them using old wallet software may also be a problem, depending on how that specific wallet software is written. But old wallet software may be able to send or receive, to reiterate, it entirely depends on how the software was written.


It's maybe best to think of the 3 (P2SH) addresses as transitional, and the bc1 (bech32 P2WPKH) addresses as better for a post-Segwit situation (i.e. once non-Segwit addresses become atypical for users and businesses)

Hey Carlton Banks, can you explain this in simple english kindly? I am not a technical guy, don't understand the terms like P2SH etc. I have few questions, that i would like to ask.

1) What are these Segwit Addresses?
2) How are these different from normal Addresses?
3) How are the fees low compared to other addresses?
4) If i upgrade from 2.9.3 to 3.0 will i have old addresses or it will swipe them?

full member
Activity: 294
Merit: 104
✪ NEXCHANGE | BTC, LTC, ETH & DOGE ✪
November 03, 2017, 04:10:03 AM
#5
Electrum 3.0 is out and the addresses are starting with bc1 apparently. I have a hardware wallet in the other hand where SegWit is supported too but the addresses are starting with 3 instead. What are the differences and are they compatible between each other (including the old addresses). Could I receive/send without having to worry?

Of course they are compatible. The original developers of Bitcoin created segwit. But you should not confuse it with segwit2x which is a disgrace.
Pages:
Jump to: