Android Adb命令查看包名信息
Android O 8.1.0
data/system/packages.list
data/system/packages.xml
data/system/package-usage.list
data/system/overlays.xml
data/system/uiderrors.txt
you can use command "dumpsys package package-name | grep permission" to check whether the package really has this permission granted.
$ adb shell dumpsys activity -h
Activity manager dump options:
[-a] [-c] [-p PACKAGE] [-h] [WHAT] ...
WHAT may be one of:
a[ctivities]: activity stack state
r[recents]: recent activities state
b[roadcasts] [PACKAGE_NAME] [history [-s]]: broadcast state
broadcast-stats [PACKAGE_NAME]: aggregated broadcast statistics
i[ntents] [PACKAGE_NAME]: pending intent state
p[rocesses] [PACKAGE_NAME]: process state
o[om]: out of memory management
perm[issions]: URI permission grant state
prov[iders] [COMP_SPEC ...]: content provider state
provider [COMP_SPEC]: provider client-side state
s[ervices] [COMP_SPEC ...]: service state
as[sociations]: tracked app associations
settings: currently applied config settings
service [COMP_SPEC]: service client-side state
package [PACKAGE_NAME]: all state related to given package
all: dump all activities
top: dump the top activity
WHAT may also be a COMP_SPEC to dump activities.
COMP_SPEC may be a component name (com.foo/.myApp),
a partial substring in a component name, a
hex object identifier.
-a: include all available server state.
-c: include client state.
-p: limit output to given package.
--checkin: output checkin format, resetting data.
--C: output checkin format, not resetting data.
--proto: output dump in protocol buffer format.
--autofill: dump just the autofill-related state of an activity
Activity manager dump options:
[-a] [-c] [-p PACKAGE] [-h] [WHAT] ...
WHAT may be one of:
a[ctivities]: activity stack state
r[recents]: recent activities state
b[roadcasts] [PACKAGE_NAME] [history [-s]]: broadcast state
broadcast-stats [PACKAGE_NAME]: aggregated broadcast statistics
i[ntents] [PACKAGE_NAME]: pending intent state
p[rocesses] [PACKAGE_NAME]: process state
o[om]: out of memory management
perm[issions]: URI permission grant state
prov[iders] [COMP_SPEC ...]: content provider state
provider [COMP_SPEC]: provider client-side state
s[ervices] [COMP_SPEC ...]: service state
as[sociations]: tracked app associations
settings: currently applied config settings
service [COMP_SPEC]: service client-side state
package [PACKAGE_NAME]: all state related to given package
all: dump all activities
top: dump the top activity
WHAT may also be a COMP_SPEC to dump activities.
COMP_SPEC may be a component name (com.foo/.myApp),
a partial substring in a component name, a
hex object identifier.
-a: include all available server state.
-c: include client state.
-p: limit output to given package.
--checkin: output checkin format, resetting data.
--C: output checkin format, not resetting data.
--proto: output dump in protocol buffer format.
--autofill: dump just the autofill-related state of an activity
$ adb shell dumpsys package -h
Package manager dump options:
[-h] [-f] [--checkin] [cmd] ...
--checkin: dump for a checkin
-f: print details of intent filters
-h: print this help
cmd may be one of:
l[ibraries]: list known shared libraries
f[eatures]: list device features
k[eysets]: print known keysets
r[esolvers] [activity|service|receiver|content]: dump intent resolvers
perm[issions]: dump permissions
permission [name ...]: dump declaration and use of given permission
pref[erred]: print preferred package settings
preferred-xml [--full]: print preferred package settings as xml
prov[iders]: dump content providers
p[ackages]: dump installed packages
s[hared-users]: dump shared user IDs
m[essages]: print collected runtime messages
v[erifiers]: print package verifier info
d[omain-preferred-apps]: print domains preferred apps
i[ntent-filter-verifiers]|ifv: print intent filter verifier info
version: print database version info
write: write current settings now
installs: details about install sessions
check-permission <permission> <package> [<user>]: does pkg hold perm?
dexopt: dump dexopt state
compiler-stats: dump compiler statistics
service-permissions: dump permissions required by services
<package.name>: info about given package
Package manager dump options:
[-h] [-f] [--checkin] [cmd] ...
--checkin: dump for a checkin
-f: print details of intent filters
-h: print this help
cmd may be one of:
l[ibraries]: list known shared libraries
f[eatures]: list device features
k[eysets]: print known keysets
r[esolvers] [activity|service|receiver|content]: dump intent resolvers
perm[issions]: dump permissions
permission [name ...]: dump declaration and use of given permission
pref[erred]: print preferred package settings
preferred-xml [--full]: print preferred package settings as xml
prov[iders]: dump content providers
p[ackages]: dump installed packages
s[hared-users]: dump shared user IDs
m[essages]: print collected runtime messages
v[erifiers]: print package verifier info
d[omain-preferred-apps]: print domains preferred apps
i[ntent-filter-verifiers]|ifv: print intent filter verifier info
version: print database version info
write: write current settings now
installs: details about install sessions
check-permission <permission> <package> [<user>]: does pkg hold perm?
dexopt: dump dexopt state
compiler-stats: dump compiler statistics
service-permissions: dump permissions required by services
<package.name>: info about given package
$ adb shell dumpsys package p