apk parser written in golang, aims to extract app information
apkparser 项目是一个安卓apk文件解析器, 从apk文件中,获取 AppInfo
type AppInfo struct {
Name string `json:"name,omitempty"` // 应用名称
BundleId string `json:"bundleId,omitempty"` // 包名
Version string `json:"version,omitempty"` // 版本名称
Build int64 `json:"build,omitempty"` // 版本号
Icon image.Image `json:"icon,omitempty"` // app icon
Size int64 `json:"size,omitempty"` // app size in bytes
CertInfo *CertInfo `json:"certInfo,omitempty"` // app 证书信息
Md5 string `json:"md5,omitempty"` // app md5
SupportOS64 bool `json:"supportOS64,omitempty"` // 是否支持64位
SupportOS32 bool `json:"supportOS32,omitempty"` // 是否支持32位
Permissions []string `json:"permissions,omitempty"` // 权限列表
MinSdkVersion int `json:"minSdkVersion"` // 最小兼容rom版本
MaxSdkVersion int `json:"maxSdkVersion"` // 最大兼容rom版本
TargetSdkVersion int `json:"targetSdkVersion"` // 推荐rom版本
}
type CertInfo struct {
Md5 string `json:"md5,omitempty"`
Sha1 string `json:"sha1,omitempty"`
Sha256 string `json:"sha256,omitempty"`
}
apk 证书相关信息的获取, 来自 avast/apkparser,本项目整合了 avast/apkparser的能力。
- 操作系统: 不限
- 编程语言: golang
- 库和框架: 不限
以下是安装该项目的步骤:
$ go get github.com/zclwy/apkparser
使用方式见 parser_test.go
apkparser 项目欢迎任何形式的贡献。如果您想要为该项目贡献代码或者报告某个问题,请提交一个 issue 或者一个 pull request。
© zclwy, 2023 ~ now license