Bitcoin Forum
September 26, 2024, 01:56:43 AM *
News: Latest Bitcoin Core release: 27.1 [Torrent]
 
  Home Help Search Login Register More  
  Show Posts
Pages: [1] 2 »
1  Bitcoin / Development & Technical Discussion / About exchange address on: June 08, 2021, 02:16:23 AM
I have seen many monitoring websites that can collect the address of the coinbase exchange. How do they do it?
2  Bitcoin / Development & Technical Discussion / P2PKH hex to address on: May 20, 2021, 04:00:17 AM
I encountered an address that could not be converted during the process of transcoding the p2pkh address,Below is the transaction tx hash

Quote
4f1433d6433d3ce8a877519ba9ddc310dbee96dba939aca0dbef0176a3563436

I get the content of scriptpubkey hex
Quote
b'0804678afd04678afd75a820894eeb82f9a851f5d1cb1be3249f58bc8d259963832c5e7474a76f7 a859ee95c87'

Get the byte array of this hex

Quote
b'\x08\x04g\x8a\xfd\x04g\x8a\xfdu\xa8 \x89N\xeb\x82\xf9\xa8Q\xf5\xd1\xcb\x1b\xe3$\x9fX\xbc\x8d%\x99c\x83,^tt\xa7oz\x85\x9e\xe9\\\x87'

Which part of this hex is the public key? Isn't the address flag of p2pkh 0x00?
3  Bitcoin / Development & Technical Discussion / Re: p2pk scriptpubkey conversion address on: May 18, 2021, 11:46:16 PM
no you can't because there is no address defined for P2PK scriptpubkeys.
addresses are only defined for the following scripts: P2PKH, P2SH, P2WPKH and P2WSH
everything else is going to have to be represented as hex or asm.

when you are converting the P2PK to address you are defining your own standard that is not going to be compatible with anything else.
you are also hashing the entire script containing 0x41 at the start and the 0xac at the end which are not part of the public key.

thank you
4  Bitcoin / Development & Technical Discussion / Re: python scriptpubkey OP_CHECKMULTISIG to address on: May 18, 2021, 03:23:46 PM
I analyzed your first example and found that you're trying to compare the hash of a multisig scriptPubKey asm with P2SH asm bytes. "a9" stands for OP_HASH160 which is not used in direct multisig. In other words your code will work with multisig wrapped in P2SH but not "raw" multisig where you insert the script by itself without P2SH opcodes.

There is technically no address format for raw multisig (see https://learnmeabitcoin.com/technical/p2ms) which is why they're wrapped around P2SH in the first place. If there were such an address format, you'd simply be able to feed the asm in bytes into the cover_address function.

Thanks again for your help
5  Bitcoin / Development & Technical Discussion / p2pk scriptpubkey conversion address on: May 18, 2021, 03:21:41 PM
Why can’t this txid get the correct address? Is there any way I can get the address

Quote
{'txid': '4775e10df3521f1b9320b3ae9a7305b016078767000d9a7fff0c42f8dc0bdd9b', 'hash': '4775e10df3521f1b9320b3ae9a7305b016078767000d9a7fff0c42f8dc0bdd9b', 'version': 1, 'size': 234, 'vsize': 234, 'weight': 936, 'locktime': 0, 'vin': [{'txid': '130d9f30ec833b4f1917339c58a857063c8f9380599e453d9a29eabc5323f57a', 'vout': 0, 'scriptSig': {'asm': '30450220448f442347d3b47b6f72659c94407c01e2ce8c11db51a3c7095651ec202f2aeb022100b 65196d9a8f2923c5905f903e02643c25b14d983b0c0c88392d8e2b2d6011af1[ALL]', 'hex': '4830450220448f442347d3b47b6f72659c94407c01e2ce8c11db51a3c7095651ec202f2aeb02210 0b65196d9a8f2923c5905f903e02643c25b14d983b0c0c88392d8e2b2d6011af101'}, 'sequence': 4294967295}], 'vout': [{'value': 20.74189877, 'n': 0, 'scriptPubKey': {'asm': '04a39b9e4fbd213ef24bb9be69de4a118dd0644082e47c01fd9159d38637b83fbcdc115a5d6e970 586a012d1cfe3e3a8b1a3d04e763bdc5a071c0e827c0bd834a5 OP_CHECKSIG', 'hex': '4104a39b9e4fbd213ef24bb9be69de4a118dd0644082e47c01fd9159d38637b83fbcdc115a5d6e9 70586a012d1cfe3e3a8b1a3d04e763bdc5a071c0e827c0bd834a5ac', 'type': 'pubkey'}}, {'value': 0.05, 'n': 1, 'scriptPubKey': {'asm': 'OP_DUP OP_HASH160 06a83fbdd5df3ecd783f9506807511af3d866863 OP_EQUALVERIFY OP_CHECKSIG', 'hex': '76a91406a83fbdd5df3ecd783f9506807511af3d86686388ac', 'reqSigs': 1, 'type': 'pubkeyhash', 'addresses': ['1cCcJ9zs4aCysVH6hmDuSasazXnmmKYtM']}}], 'hex': '01000000017af52353bcea299a3d459e5980938f3c0657a8589c3317194f3b83ec309f0d1300000 000494830450220448f442347d3b47b6f72659c94407c01e2ce8c11db51a3c7095651ec202f2aeb 022100b65196d9a8f2923c5905f903e02643c25b14d983b0c0c88392d8e2b2d6011af101fffffff f0235a0a17b00000000434104a39b9e4fbd213ef24bb9be69de4a118dd0644082e47c01fd9159d3 8637b83fbcdc115a5d6e970586a012d1cfe3e3a8b1a3d04e763bdc5a071c0e827c0bd834a5ac404 b4c00000000001976a91406a83fbdd5df3ecd783f9506807511af3d86686388ac00000000', 'blockhash': '000000000000008c8471e40400e6ed162cf2efeb132735e043316f29c3e72f39', 'confirmations': 439642, 'time': 1372800859, 'blocktime': 1372800859}


I tried to write a lot of code, but still can’t get the correct address. I want to know if there is any way to get the correct address,I spent a lot of time on this issue, hoping to get a little hint, thank you very much.
Code:
# coding:utf-8
from bip32utils import Base58
import bech32
from hashlib import *
from base58 import *
import base58
import binascii


def hashStr(buffer):
    return binascii.hexlify(buffer)

def SHA256D(bstr):
    return sha256(sha256(bstr).digest()).digest()

def ConvertPKHToAddress(prefix, addr):
    data = prefix + addr
    return b58encode(data + SHA256D(data)[:4])

def PubkeyToAddress(pubkey_hex):
    pubkey = bytearray.fromhex(pubkey_hex)
    round1 = sha256(pubkey).digest()
    h = new('ripemd160')
    h.update(round1)
    pubkey_hash = h.digest()
    return ConvertPKHToAddress(b'\x00', pubkey_hash)


print(PubkeyToAddress('4104a39b9e4fbd213ef24bb9be69de4a118dd0644082e47c01fd9159d38637b83fbcdc115a5d6e970586a012d1cfe3e3a8b1a3d04e763bdc5a071c0e827c0bd834a5ac'))
b'16SvHaiZXXgoBxAvZPo36zsyuAxLK1qECy'


6  Bitcoin / Development & Technical Discussion / Re: python scriptpubkey OP_CHECKMULTISIG to address on: May 18, 2021, 08:53:43 AM
I try to parse the Hex in the following code, the actual address is 1VayNert3x1KzbpzMGt2qdqrAThiRovi8, but after I parse it, it is 16SvHaiZXXgoBxAvZPo36zsyuAxLK1qECy, I don’t know what I’m doing wrong

Code:
# coding:utf-8
from bip32utils import Base58
import bech32
from hashlib import *
from base58 import *
import base58
import binascii


def hashStr(buffer):
    return binascii.hexlify(buffer)

def SHA256D(bstr):
    return sha256(sha256(bstr).digest()).digest()

def ConvertPKHToAddress(prefix, addr):
    data = prefix + addr
    return b58encode(data + SHA256D(data)[:4])

def PubkeyToAddress(pubkey_hex):
    pubkey = bytearray.fromhex(pubkey_hex)
    round1 = sha256(pubkey).digest()
    h = new('ripemd160')
    h.update(round1)
    pubkey_hash = h.digest()
    return ConvertPKHToAddress(b'\x00', pubkey_hash)


print(PubkeyToAddress('4104a39b9e4fbd213ef24bb9be69de4a118dd0644082e47c01fd9159d38637b83fbcdc115a5d6e970586a012d1cfe3e3a8b1a3d04e763bdc5a071c0e827c0bd834a5ac'))

b'2hoLE1uiNFYJTgjGf58K3Vy8RBz7AeqZyD'
7  Bitcoin / Development & Technical Discussion / Re: python scriptpubkey OP_CHECKMULTISIG to address on: May 18, 2021, 12:32:13 AM
Thank you for your help. I published the code of hashStr. I am a beginner. I tried to convert hex to address, but I found that the address starting with 3 cannot be converted. I don’t know what is missing in my code,Thank you very much Reply.
8  Bitcoin / Development & Technical Discussion / python scriptpubkey OP_CHECKMULTISIG to address on: May 17, 2021, 03:09:21 PM
Please forgive me, I posted a request for help in another section, maybe I posted it in the wrong place, no one responded, so I posted it here, I hope I can get some help,   Hello everyone, I am new to Bitcoin, I have a problem and need help, first of all, thank you, the following is my question:
I tried to use the following code to convert the scriptPubKey in the Bitcoin transaction to an address, but why p2sh cannot be converted?

Code:
def hashStr(buffer):
    return binascii.hexlify(buffer)


def SHA256D(bstr):
    return sha256(sha256(bstr).digest()).digest()

def ConvertPKHToAddress(prefix, addr):
    data = prefix + addr
    return b58encode(data + SHA256D(data)[:4])

def PubkeyToAddress(pubkey_hex):
    pubkey = pubkey_hex
    round1 = sha256(pubkey.encode("utf8")).digest()
    h = new('ripemd160')
    h.update(round1)
    pubkey_hash = h.digest()
    return ConvertPKHToAddress(b'\x00', pubkey_hash)


def cover_address(script_pub_key):
    script_pub_key_str=hashStr(script_pub_key)
    if script_pub_key_str[0:4]==b'76a9':
        #This is a pubkeyhash
        bytes=script_pub_key[2]  #number of bytes in the pub_key
        try:
            assert bytes==20
        except:
            return None
        public_key = script_pub_key[3:3+bytes] #20 bytes
        z=b'\00'+public_key
        #checksum=sha256(sha256(z))[:4]
        #address1=base58.b58encode(z + checksum)
        address2=base58.b58encode_check(z)   # adds checksum for you
        return format(address2.decode())
    elif script_pub_key_str[0:2]==b'a9':
        #this is a scripthash (pay-to-script address)
        bytes=script_pub_key[1]  #number of bytes in the pub_key
        try:
            assert bytes==20
        except:
            return None
        public_key = script_pub_key[2:2+bytes] #20 bytes
        z=b'\05'+public_key  #used for mainnet
        address2=base58.b58encode_check(z)
        return address2.decode()
    elif script_pub_key_str[0:2]==b'00':
        spk = binascii.unhexlify(script_pub_key_str.decode())
        version = spk[0] - 0x50 if spk[0] else 0
        program = spk[2:]
        return bech32.encode('bc', version, program)
    else:
        #print(script_pub_key_str)
        return None

I want to convert the following p2sh scriptpubkey to an address, but I don’t know how to do it, the following is the transaction I want to  convert
Quote
{'txid': 'ca0cae6cd13e9150757612b1a3ea2e0e2d990d31098252892d032ffa73fc4f83', 'hash': 'ca0cae6cd13e9150757612b1a3ea2e0e2d990d31098252892d032ffa73fc4f83', 'version': 1, 'size': 205, 'vsize': 205, 'weight': 820, 'locktime': 0, 'vin': [{'txid': '05a9f3f1ed8099af7f37f818ce92442a1dccf9b471375bcb7dd4771db8080361', 'vout': 0, 'scriptSig': {'asm': '0 3045022041a325a85809d9b0c14b7858d8a7169f6dd847d41dbf342bfb745d76d15699c1022100c d6e77a8c3ffb95372d5ea716e0522efe121f253cf2381fd1d004204a8feeee7[ALL]', 'hex': '00483045022041a325a85809d9b0c14b7858d8a7169f6dd847d41dbf342bfb745d76d15699c1022 100cd6e77a8c3ffb95372d5ea716e0522efe121f253cf2381fd1d004204a8feeee701'}, 'sequence': 4294967295}], 'vout': [{'value': 1.999, 'n': 0, 'scriptPubKey': {'asm': '1 037953dbf08030f67352134992643d033417eaa6fcfb770c038f364ff40d761588 0002d4a196263b56e24c40a87f4f5adc89b74a17712cc540c20135fc50a2403937 2 OP_CHECKMULTISIG', 'hex': '5121037953dbf08030f67352134992643d033417eaa6fcfb770c038f364ff40d761588210002d4a 196263b56e24c40a87f4f5adc89b74a17712cc540c20135fc50a240393752ae', 'type': 'nonstandard'}}], 'hex': '0100000001610308b81d77d47dcb5b3771b4f9cc1d2a4492ce18f8377faf9980edf1f3a90500000 0004a00483045022041a325a85809d9b0c14b7858d8a7169f6dd847d41dbf342bfb745d76d15699 c1022100cd6e77a8c3ffb95372d5ea716e0522efe121f253cf2381fd1d004204a8feeee701fffff fff01603bea0b00000000475121037953dbf08030f67352134992643d033417eaa6fcfb770c038f 364ff40d761588210002d4a196263b56e24c40a87f4f5adc89b74a17712cc540c20135fc50a2403 93752ae00000000', 'blockhash': '00000000000002b211876fa753c8bf5c3b4f43198c6a20d91b26cd1ed5b71918', 'confirmations': 471187, 'time': 1355895514, 'blocktime': 1355895514}



Thank you so much for taking the time to read.
9  Bitcoin / Bitcoin Technical Support / python scriptpubkey OP_CHECKMULTISIG to address on: May 17, 2021, 06:28:24 AM
Hello everyone, I am new to Bitcoin, I have a problem and need help, first of all, thank you, the following is my question:
I tried to use the following code to convert the scriptPubKey in the Bitcoin transaction to an address, but why p2sh cannot be converted? Is there a similar python package that can be converted to an address by drinking it directly

Code:
def cover_address(script_pub_key):
    script_pub_key_str=hashStr(script_pub_key)
    if script_pub_key_str[0:4]==b'76a9':
        #This is a pubkeyhash
        bytes=script_pub_key[2]  #number of bytes in the pub_key
        try:
            assert bytes==20
        except:
            return None
        public_key = script_pub_key[3:3+bytes] #20 bytes
        z=b'\00'+public_key
        #checksum=sha256(sha256(z))[:4]
        #address1=base58.b58encode(z + checksum)
        address2=base58.b58encode_check(z)   # adds checksum for you
        return format(address2.decode())
    elif script_pub_key_str[0:2]==b'a9':
        #this is a scripthash (pay-to-script address)
        bytes=script_pub_key[1]  #number of bytes in the pub_key
        try:
            assert bytes==20
        except:
            return None
        public_key = script_pub_key[2:2+bytes] #20 bytes
        z=b'\05'+public_key  #used for mainnet
        address2=base58.b58encode_check(z)
        return address2.decode()
    elif script_pub_key_str[0:2]==b'00':
        spk = binascii.unhexlify(script_pub_key_str.decode())
        version = spk[0] - 0x50 if spk[0] else 0
        program = spk[2:]
        return bech32.encode('bc', version, program)
    else:
        #print(script_pub_key_str)
        return None
I want to convert the following into an address, but the address cannot be resolved using the above method. What is wrong?

Code:
{'txid': 'ca0cae6cd13e9150757612b1a3ea2e0e2d990d31098252892d032ffa73fc4f83', 'hash': 'ca0cae6cd13e9150757612b1a3ea2e0e2d990d31098252892d032ffa73fc4f83', 'version': 1, 'size': 205, 'vsize': 205, 'weight': 820, 'locktime': 0, 'vin': [{'txid': '05a9f3f1ed8099af7f37f818ce92442a1dccf9b471375bcb7dd4771db8080361', 'vout': 0, 'scriptSig': {'asm': '0 3045022041a325a85809d9b0c14b7858d8a7169f6dd847d41dbf342bfb745d76d15699c1022100cd6e77a8c3ffb95372d5ea716e0522efe121f253cf2381fd1d004204a8feeee7[ALL]', 'hex': '00483045022041a325a85809d9b0c14b7858d8a7169f6dd847d41dbf342bfb745d76d15699c1022100cd6e77a8c3ffb95372d5ea716e0522efe121f253cf2381fd1d004204a8feeee701'}, 'sequence': 4294967295}], 'vout': [{'value': 1.999, 'n': 0, 'scriptPubKey': {'asm': '1 037953dbf08030f67352134992643d033417eaa6fcfb770c038f364ff40d761588 0002d4a196263b56e24c40a87f4f5adc89b74a17712cc540c20135fc50a2403937 2 OP_CHECKMULTISIG', 'hex': '5121037953dbf08030f67352134992643d033417eaa6fcfb770c038f364ff40d761588210002d4a196263b56e24c40a87f4f5adc89b74a17712cc540c20135fc50a240393752ae', 'type': 'nonstandard'}}], 'hex': '0100000001610308b81d77d47dcb5b3771b4f9cc1d2a4492ce18f8377faf9980edf1f3a905000000004a00483045022041a325a85809d9b0c14b7858d8a7169f6dd847d41dbf342bfb745d76d15699c1022100cd6e77a8c3ffb95372d5ea716e0522efe121f253cf2381fd1d004204a8feeee701ffffffff01603bea0b00000000475121037953dbf08030f67352134992643d033417eaa6fcfb770c038f364ff40d761588210002d4a196263b56e24c40a87f4f5adc89b74a17712cc540c20135fc50a240393752ae00000000', 'blockhash': '00000000000002b211876fa753c8bf5c3b4f43198c6a20d91b26cd1ed5b71918', 'confirmations': 471187, 'time': 1355895514, 'blocktime': 1355895514}
10  Bitcoin / Development & Technical Discussion / Re: Bitcoin rpc gradually slows down on: April 17, 2021, 08:41:23 AM
Code:
    
           for vin in raw_tx[u'vin']:  
                if "coinbase" in vin:
                    continue
                if ("txid" not in vin):
                    continue
                voutid = vin["vout"]
                while True:
                    try:
                        tx_out = self.ConnRpc.getrawtransaction(vin["txid"], True)
                        vout = tx_out[u'vout'][voutid]
                        break
                    except:
                        self.connect()
                        sleep(0.1)
                if "scriptPubKey" not in vout:
                    pass

                if vout["scriptPubKey"]["type"] == "nulldata":
                    pass
                elif "addresses" in vout['scriptPubKey']:
                    outaddr = vout['scriptPubKey']['addresses'][0]
                    if outaddr not in address:
                        address[outaddr] = -1 * float(vout["value"])
                    else:
                        address[outaddr] += -1 * float(vout["value"])
                else:
                    pass


I try to keep querying the transactions of some blocks, but the time return time will gradually return from 6 seconds to 30 seconds, getting slower and slower
11  Bitcoin / Development & Technical Discussion / Bitcoin rpc gradually slows down on: April 17, 2021, 08:18:59 AM
I use python3 to call the getrawtransaction interface of bitcoin rpc. Why does the query return time take longer and longer? The system load and disk IO are not too high load。
12  Bitcoin / Development & Technical Discussion / How to get multiple addresses belonging to the same person on: December 24, 2020, 07:36:31 AM
Regarding the seed wallet, I would like to know how to obtain these addresses are related and belong to one person? I have seen many blockchain browsers automatically recognize that the wallet address belongs to the same person. How is this done?
13  Bitcoin / Development & Technical Discussion / Re: How to delete unconfirmed transactions in Bitcoin mempool on: December 22, 2020, 08:39:10 AM
It's the mempool so it gathering all the transactions that are out there. There is no real way to remove specific ones.
Why would you want to delete them?

Or are you trying to remove a transaction that you sent and want to have dropped?

-Dave


Can I get all the transactions in the memory pool first, and then clear the transactions in the memory pool? I hope not to restart the bitcoin node
14  Bitcoin / Development & Technical Discussion / Re: How to delete unconfirmed transactions in Bitcoin mempool on: December 22, 2020, 08:36:50 AM
In your bitcoin.config file, you can adjust some settings. You can set the minrelaytxfee to a higher fee rate.

Also, if you are not performing analysis frequently, you can set persistmempool=0, and restart your node immediately after completing your analysis. This will result in your mempool being wiped each time you stop your bitcoin node. If you stop and quickly restart your node with this setting, you will miss some number of transactions that would have been relayed during the brief period your node was not running.
I don’t want to analyze transactions below 0.9. There is currently no way to restart the bitcoind node because I want to analyze every transaction with a transaction greater than 0.9
15  Bitcoin / Development & Technical Discussion / Re: How to delete unconfirmed transactions in Bitcoin mempool on: December 22, 2020, 06:15:46 AM
If the transaction is associated with your wallet, you can do one of two things:
*restart bitcoin with the -zapwallettxes option. This will cause bitcoin core to 'forget' all transactions associated with your wallet, and rescan the blockchain for transactions associated with addresses in your wallet.
*use the RPC command removeprunedfunds, which will remove the transaction from your wallet.

Please note that removing a transaction from your mempool will not affect any other node's mempool, and your transaction can still confirm in the future as long as it is valid.
I want to analyze unconfirmed transactions, but there are more and more transactions in the memory pool, which leads to longer and longer analysis time of my program, so I hope to delete after the analysis, any good suggestions

You could run the getrawmempool RPC command, add those txids to a list of txids you have analyzed that remain on the list for x days. When you run your analysis, you can compare the txids to what is in the mempool to the txids on your list. You can also review each confirmed block, and any transaction that has been confirmed can also be removed from your list.


Thank you very much for your answer, I use this method to run, export the data in the memory pool to the list, and compare the list with the memory pool, but the analysis time of the program will also change as the bitcoind runs longer. Long, I haven't found a quick way. Can I exclude some transactions with relatively low fees? If I only analyze transactions with higher fees, this can speed up the speed, but how to block some transactions with lower fees?
16  Bitcoin / Development & Technical Discussion / Re: How to delete unconfirmed transactions in Bitcoin mempool on: December 22, 2020, 03:48:27 AM
If the transaction is associated with your wallet, you can do one of two things:
*restart bitcoin with the -zapwallettxes option. This will cause bitcoin core to 'forget' all transactions associated with your wallet, and rescan the blockchain for transactions associated with addresses in your wallet.
*use the RPC command removeprunedfunds, which will remove the transaction from your wallet.

Please note that removing a transaction from your mempool will not affect any other node's mempool, and your transaction can still confirm in the future as long as it is valid.
I want to analyze unconfirmed transactions, but there are more and more transactions in the memory pool, which leads to longer and longer analysis time of my program, so I hope to delete after the analysis, any good suggestions
17  Bitcoin / Development & Technical Discussion / How to delete unconfirmed transactions in Bitcoin mempool on: December 22, 2020, 01:29:47 AM
I executed bitcoin-cli getrawmempool and listed many records. I want to delete one of them. Is there a way to do this?
18  Bitcoin / Development & Technical Discussion / Re: How to get unconfirmed transactions? on: December 14, 2020, 09:45:32 AM
You mentioned connecting dozens of nodes here. Do I need to fill in these node addresses in the Bitcoind.conf configuration file? Or fill in many node addresses in my code? Thank you very much, I am a enthusiast who just participated in learning blockchain
In Bitcoin.conf file, you should be able to add as many nodes as you want but there will be a restriction on the number of nodes your client will connect to. You can try opening port 8333 to allow other nodes to connect to you, the node count should increase gradually as your IP address gets relayed and propagated through addr messages within nodes.

Generally, the transactions that are non-standard, ie. valid transactions but are do not pass the standardness check[1] enforced by the nodes, will not be accepted by your node. They could still be accepted into a block however. Those are the kinds of transactions that you'll probably never see in the mempool, but only in blocks mined by miners.

By attempting to connect to as many node as possible, you could allow your bitcoind to potentially have more sources for the transactions to be relayed to you, deceasing the chances of certain transactions having low propagation (Txes with low relay fee, etc) but are otherwise standard and valid.

[1] https://github.com/bitcoin/bitcoin/blob/master/src/consensus/validation.h#L21

Thank you very much
19  Bitcoin / Development & Technical Discussion / Re: How to get unconfirmed transactions? on: December 14, 2020, 08:55:41 AM
Thank you, are all unconfirmed transactions in the memory pool? Will there be confirmed transactions in the memory pool?

As ranochigo wrote, it'll only give you the mempool of the node you're querying, which is not complete and only has transactions it knows. But you can connect to several dozen different nodes, checking that the ones you're connecting to aren't peers of any others you're sampling, run getrawmempool on all of them and intersect all the transactions in a set to get the majority of the unconfirmed transactions.

You mentioned connecting dozens of nodes here. Do I need to fill in these node addresses in the Bitcoind.conf configuration file? Or fill in many node addresses in my code? Thank you very much, I am a enthusiast who just participated in learning blockchain
20  Bitcoin / Development & Technical Discussion / Re: How to get unconfirmed transactions? on: December 14, 2020, 08:38:23 AM
Thank you, are all unconfirmed transactions in the memory pool?
Not all. See my response.
Will there be confirmed transactions in the memory pool?
No. Transactions are removed from mempool when they're in the block.

thank you very much
Pages: [1] 2 »
Powered by MySQL Powered by PHP Powered by SMF 1.1.19 | SMF © 2006-2009, Simple Machines Valid XHTML 1.0! Valid CSS!