FazBrowse GitHub Viewer
|
Trending
|
URL:
|
Home
Tools:
[Download Repo ZIP]
[View Raw Code]
[Original HTTPS Page]
jeb-samplecode/scripts/AdbDemo.py at master · pnfsoftware/jeb-samplecode · GitHub
pnfsoftware
jeb-samplecode
Repository navigation
Code
Pull requests
3
(3)
Actions
Security and quality
Insights
Expand file tree
Breadcrumbs
jeb-samplecode
/
scripts
/
AdbDemo.py
Copy path
More file actions
More file actions
Latest commit
History
History
History
28 lines (26 loc) · 992 Bytes
Breadcrumbs
jeb-samplecode
/
scripts
/
AdbDemo.py
Copy path
File metadata and controls
28 lines (26 loc) · 992 Bytes
Raw
Copy raw file
Download raw file
Open symbols panel
Edit and raw actions
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
#?description=Create and use adb (Android Debug Bridge) wrappers and adb utility objects
#?shortcut=
from
com
.
pnfsoftware
.
jeb
.
client
.
api
import
IScript
from
com
.
pnfsoftware
.
jeb
.
core
.
units
.
code
.
android
.
adb
import
AdbWrapperFactory
,
AdbWrapperFactory
,
AndroidDeviceUtil
"""
Sample script for JEB Decompiler.
"""
class
AdbDemo
(
IScript
):
def
run
(
self
,
ctx
):
# factory object wraps adb, not tied to a specific device
adbf
=
AdbWrapperFactory
()
# see javadoc for a list of methods
adbf
.
initialize
()
print
(
'adb version: %s'
%
adbf
.
getVersion
())
for
dev
in
adbf
.
listDevices
():
# an AdbWrapper object is tied to a debuggable device
adb
=
adbf
.
createWrapper
(
dev
.
getSerial
())
break
else
:
print
'no android device found'
return
print
(
adb
)
# see javadoc for a list of methods
#adb.listPackages()
#adb.listProcesses()
#adb.readProperty("ro.build.version.release")
#adb....
# higher-level wrappers: see AndroidDeviceUtil
Back
|
FazBrowse Home
|
New Git URL