0
I have a simple bitcoin packet which contains TX message.
in a TX message, one of it's Transaction input hex data was like this:
8b3e6cc50fd114f8f40f4223dcf3150448ffc1dc5587f1ca5de6d65f1972f46101000000232200203fff89bc822618068e248c92163cd1f3d0c4f1c7e71f0baf172f4b31438fb423ffffffff
when i open this pcap file with wireshark, it show's previous output equal to:
8b3e6cc50fd114f8f40f4223dcf3150448ffc1dc5587f1ca5de6d65f1972f46101000000
after that i see script length which is 0x23(35). so signature script of this packet is equal to:
2200203fff89bc822618068e248c92163cd1f3d0c4f1c7e71f0baf172f4b31438fb423
.
can anybody explain to me how to extract source address which is generated from signature script in the above?
2You also can't just blindly search pcaps for "addresses", I can construct data to send over the bitcoin network that looks like a valid transaction to you, but isn't to anybody else. You'd be colossally silly to rely on this having any meaning without the context of a validating node. – Anonymous – 2019-06-16T14:04:53.753
@Anonymous I know that my scriptsig is for a segwit address and I calculate it's output address correctly before. My main question is which is the relation between public key which inserted in scriptsig and source address? in other words how we can evaluate the validity of trasnaction and ensure that sender have enough credit to send a specific bitcoin to an output address? i want to find a relation beween output address and source address from this scriptsig. – Aristo – 2019-06-17T05:23:04.597
1You can’t. The idea is silly. Run a validating node, don’t try to parse the information from packet dumps. – Anonymous – 2019-06-17T05:31:34.043