pub enum Signature {
V1(Vec<CertificateInfo>),
V2(Vec<CertificateInfo>),
V3(Vec<CertificateInfo>),
V31(Vec<CertificateInfo>),
V4,
ApkChannelBlock(String),
StampBlockV1(CertificateInfo),
StampBlockV2(CertificateInfo),
PackerNextGenV2(Vec<u8>),
GooglePlayFrosting,
VasDollyV2(String),
Unknown,
}Expand description
Describe used signature scheme in APK
Basic overview: https://source.android.com/docs/security/features/apksigning
Variants§
V1(Vec<CertificateInfo>)
Default signature scheme based on JAR signing
See: https://source.android.com/docs/security/features/apksigning/v2#v1-verification
V2(Vec<CertificateInfo>)
APK signature scheme v2
See: https://source.android.com/docs/security/features/apksigning/v2
V3(Vec<CertificateInfo>)
APK signature scheme v3
See: https://source.android.com/docs/security/features/apksigning/v3
V31(Vec<CertificateInfo>)
APK signature scheme v3.1
See: https://source.android.com/docs/security/features/apksigning/v3-1
V4
APK signature scheme v4
See: https://source.android.com/docs/security/features/apksigning/v4
Right now it’s just a stub. Need help/a hint on how to correctly implement the parsing of this signature.
ApkChannelBlock(String)
Some usefull information from apk channel block
StampBlockV1(CertificateInfo)
Stamp Signing Block v1
StampBlockV2(CertificateInfo)
Stamp Signing Block v2
PackerNextGenV2(Vec<u8>)
Some Chinese packer
Example: 75a606291d88a6c04ca9d4edfbc1b4352cf8a0aee31130f913ceee72f2dcbbbd
GooglePlayFrosting
Google Play Frosting Metadata
We just highlight the presence of the block, because the full structure is unknown to anyone in public space
For more details you can inspect: https://github.com/avast/apkverifier/blob/master/signingblock/frosting.go#L23
VasDollyV2(String)
Some apk protector/parser, idk, seen in the wild
The channel information in the ID-Value pair
Unknown
Got something that we don’t know yet