我想验证一个文件的代码签名,我可以使用codesign -dv从命令行获取信息。
Executable=/Users/user/XXXXXXXX.txt
Identifier=com.apple.xxxxxx
Format=bundle with Mach-O thin (x86_64)
CodeDirectory v=20200 size=281 flags=0x200(kill) hashes=4+5 location=embedded
Hash type=sha1 size=20
CDHash=ca2c3d47e597a19d7776e248832169488bc8c4a0
Signature size=4169
Authority=Apple Mac OS Application Signing
Authority=Apple Worldwide Developer Relations Certification Authority
Authority=Apple Root CA
Info.plist entries=31
TeamIdentifier=K36BKF7T3D
Sealed Resources version=2 rules=8 files=151
Internal requirements count=1 size=128
但有没有办法使用代码获取相同的信息。