|
| | Manifest (axml::XmlDocument doc, const ResourceTable *resources=nullptr) |
| | Read doc.
|
| |
| std::string_view | package () const |
| | package attribute of the <manifest> element.
|
| |
| std::optional< int64_t > | version_code () const |
| | android:versionCode, if present and known.
|
| |
| std::optional< std::string_view > | version_name () const |
| | android:versionName, if present as text.
|
| |
| std::optional< int64_t > | min_sdk () const |
| | uses-sdk android:minSdkVersion / targetSdkVersion, if present and known.
|
| |
| std::optional< int64_t > | target_sdk () const |
| |
| std::optional< uint32_t > | version_code_reference () const |
| | The resource id when android:versionCode, minSdkVersion, targetSdkVersion, debuggable or allowBackup is written as a reference (see the comment at the top of this file); nullopt for a plain value or no attribute.
|
| |
| std::optional< uint32_t > | min_sdk_reference () const |
| |
| std::optional< uint32_t > | target_sdk_reference () const |
| |
| std::optional< uint32_t > | debuggable_reference () const |
| |
| std::optional< uint32_t > | allow_backup_reference () const |
| |
| const std::vector< std::string > & | permissions () const |
| | android:name of every <uses-permission>.
|
| |
| const std::vector< std::string > & | declared_permissions () const |
| | android:name of every <permission> the app itself declares.
|
| |
| std::optional< int > | declared_permission_protection_level (std::string_view name) const |
| | android:protectionLevel of an app-declared <permission> (the raw Android value), or nullopt if the permission is not declared by this app, or its level is a resource reference that could not be resolved.
|
| |
| const std::vector< Component > & | components () const |
| | All components, or those of one kind.
|
| |
| std::vector< const Component * > | components_of (Component::Kind kind) const |
| |
| std::optional< std::string_view > | launcher_activity () const |
| | The launcher activity's name, if any (MAIN + LAUNCHER intent filter).
|
| |
| std::optional< bool > | debuggable () const |
| | application android:debuggable, if explicitly set and known.
|
| |
| std::optional< bool > | allow_backup () const |
| | application android:allowBackup, if explicitly set and known.
|
| |
| const axml::XmlDocument & | xml () const |
| | The underlying decoded XML, for attributes this view does not surface.
|
| |
Typed AndroidManifest.xml.
Built from an axml::XmlDocument.
| std::optional< uint32_t > dex::apk::Manifest::version_code_reference |
( |
| ) |
const |
|
inline |
The resource id when android:versionCode, minSdkVersion, targetSdkVersion, debuggable or allowBackup is written as a reference (see the comment at the top of this file); nullopt for a plain value or no attribute.
When the matching value accessor returns nullopt and this is set, the reference could not be resolved and the value is unknown.
| std::optional< int > dex::apk::Manifest::declared_permission_protection_level |
( |
std::string_view |
name | ) |
const |
android:protectionLevel of an app-declared <permission> (the raw Android value), or nullopt if the permission is not declared by this app, or its level is a resource reference that could not be resolved.
A declaration without the attribute is normal (0). The base level is the low nibble: 0 normal, 1 dangerous, 2 signature, 3 signatureOrSystem; higher bits are flags (e.g. 0x10 privileged). A permission whose level is unknown does not make a component guarded_by_signature_permission.