ENTROPÍA

Does this descriptor have my private keys?

You pasted a descriptor somewhere and now you're sweating: does that string contain the keys that can move your bitcoin?

**getdescriptorinfo** tells you if a descriptor came with private material inside: the **hasprivatekeys** field marks it without using the descriptor.

What getdescriptorinfo does

getdescriptorinfo is a Bitcoin Core command that takes a descriptor and analyzes it without using it. It does not import it, does not derive addresses, does not spend anything: it just returns the checksum and the hasprivatekeys field.

That field tells you whether the descriptor came with private material inside. If it's true, the string you're looking at is enough to move the bitcoin it controls.

Source: Bitcoin Core · RPC getdescriptorinfo

How to read the result without panicking

Run Bitcoin Core, call getdescriptorinfo with your descriptor and look at hasprivatekeys. You don't need to import it into the wallet or touch the chain.

If it says true, that descriptor is not to be shared with anyone: whoever sees it can spend. If it says false, there are no private keys in that text, but there may still be an extended public key (xpub, ypub, or zpub) that reveals all your addresses.

What to do with that result

Before pasting a descriptor into a form, a chat, or a block explorer, run getdescriptorinfo. It's the way to look inside without using the descriptor or putting funds at risk.

If the field says true, don't publish it: treat that descriptor like the seed itself. If it says false, still check whether you're comfortable showing your transaction history.

A false from hasprivatekeys doesn't mean you can post the descriptor without consequences

The field only tells you if the descriptor string contains private material. A descriptor with an extended public key (xpub, ypub, or zpub) returns false, but it still exposes all the wallet's addresses and history. Sharing it won't let someone spend, but it kills privacy.

Source: Bitcoin Core · RPC getdescriptorinfo