I actually posted[1] about this a few days back I think.
So the format of P2PKH sigscript is the signature followed by the public key. So basically, extract the sigscript, identify the signature and there should be a OP_Pushbytes_65 which is 41 in hex. You should get the public key pertaining to that specific address.
[1]
https://bitcointalk.org/index.php?topic=5302887.msg55912788#msg55912788