It may be broken or not work on some APKs, getting it running on Termux is kinda weird, but you could then use a better output of APKSigner to read signatures and verify APKs on first install.
Apksigner on its own was pretty useless for me, thats why it uses a workaround. Apks are zips, so it renames the file, decompresses and reads some file where the signer is actually mentioned with Name and all. Then it deletes it.
Iirc there was some bug with Termux and the unpack thing, because Android sucks I guess. On Linux it works fine.
Try to use my apkverify tool.
It may be broken or not work on some APKs, getting it running on Termux is kinda weird, but you could then use a better output of APKSigner to read signatures and verify APKs on first install.
Apksigner on its own was pretty useless for me, thats why it uses a workaround. Apks are zips, so it renames the file, decompresses and reads some file where the signer is actually mentioned with Name and all. Then it deletes it.
Iirc there was some bug with Termux and the unpack thing, because Android sucks I guess. On Linux it works fine.