Skip to content

Instantly share code, notes, and snippets.

@thefloweringash
Created August 25, 2020 07:11
Show Gist options
  • Save thefloweringash/9a4702575d28453d09b11850e37b29f5 to your computer and use it in GitHub Desktop.
Save thefloweringash/9a4702575d28453d09b11850e37b29f5 to your computer and use it in GitHub Desktop.
Big Sur signing tests
#include <stdio.h>
int main() {
printf("Hello, world\n");
return 0;
}
#!/usr/bin/env bash
set -x
rm -fv test
clang -o test test.c
codesign --display --verbose=4 test
openssl sha256 test
./test
@thefloweringash
Copy link
Author

Output

$ ./test.sh
+ rm -fv test
test
+ clang -o test test.c
+ codesign --display --verbose=4 test
Executable=/Users/lorne/signing-test/test
Identifier=test
Format=Mach-O thin (arm64)
CodeDirectory v=20400 size=509 flags=0x20002(adhoc,linker-signed) hashes=13+0 location=embedded
VersionPlatform=1
VersionMin=720896
VersionSDK=720896
Hash type=sha256 size=32
CandidateCDHash sha256=fefbbd38ff3448ac0eff8ba57c7e6ce329adc5a8
CandidateCDHashFull sha256=fefbbd38ff3448ac0eff8ba57c7e6ce329adc5a866fffa2301666716c6218b42
Hash choices=sha256
CMSDigest=fefbbd38ff3448ac0eff8ba57c7e6ce329adc5a866fffa2301666716c6218b42
CMSDigestType=2
Page size=4096
CDHash=fefbbd38ff3448ac0eff8ba57c7e6ce329adc5a8
Signature=adhoc
Info.plist=not bound
TeamIdentifier=not set
Sealed Resources=none
Internal requirements=none
+ openssl sha256 test
SHA256(test)= 144fc0e8ecf6df95f122b3f49e011146361e3a86933f69ba16340571afa6eba4
+ ./test
Hello, world

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment