FazBrowse GitHub Viewer
|
Trending
|
URL:
|
Home
Tools:
[Download Repo ZIP]
[View Raw Code]
[Original HTTPS Page]
bytecode-viewer/plugins/example/ExampleStringDecrypter.java at master · pythonzz/bytecode-viewer · GitHub
pythonzz
bytecode-viewer
Repository navigation
Code
Pull requests
Actions
Projects
Security and quality
Insights
Expand file tree
Breadcrumbs
bytecode-viewer
/
plugins
/
example
/
ExampleStringDecrypter.java
Copy path
More file actions
More file actions
Latest commit
History
History
History
52 lines (43 loc) · 1.92 KB
Breadcrumbs
bytecode-viewer
/
plugins
/
example
/
ExampleStringDecrypter.java
Copy path
File metadata and controls
52 lines (43 loc) · 1.92 KB
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
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
import
the
.
bytecode
.
club
.
bytecodeviewer
.
api
.*
import
the
.
bytecode
.
club
.
bytecodeviewer
.
gui
.
components
.
MultipleChoiceDialog
;
import
java
.
util
.
ArrayList
;
import
java
.
lang
.
reflect
.
Field
;
import
org
.
objectweb
.
asm
.
tree
.
ClassNode
;
import
org
.
objectweb
.
asm
.
tree
.
FieldNode
import
static
the
.
bytecode
.
club
.
bytecodeviewer
.
Constants
.
nl
;
/**
* This is an example of a string decrypter plugin
*/
public
class
ExampleStringDecrypter
extends
Plugin
{
@
Override
public
void
execute
(
ArrayList
<
ClassNode
>
classNodesList
) {
PluginConsole
gui
=
new
PluginConsole
(
"Example String Decrypter"
);
MultipleChoiceDialog
dialog
=
new
MultipleChoiceDialog
(
"Bytecode Viewer - WARNING"
,
"WARNING: This will load the classes into the JVM and execute the initialize function"
+
nl
+
"for each class. IF THE FILE YOU'RE LOADING IS MALICIOUS, DO NOT CONTINUE."
,
new
String
[]{
"Continue"
,
"Cancel"
});
if
(
dialog
.
promptChoice
() ==
0
)
{
for
(
ClassNode
cn
:
classNodesList
)
{
the
.
bytecode
.
club
.
bytecodeviewer
.
api
.
BCV
.
getClassNodeLoader
().
addClass
(
cn
);
for
(
Object
o
:
cn
.
fields
.
toArray
())
{
FieldNode
f
= (
FieldNode
)
o
;
if
(
f
.
name
.
equals
(
"z"
)) {
// && f.desc.equals("([Ljava/lang/String;)V")) {
try
{
for
(
Field
f2
:
the
.
bytecode
.
club
.
bytecodeviewer
.
api
.
BCV
.
getClassNodeLoader
().
nodeToClass
(
cn
).
getFields
())
{
String
s
=
f2
.
get
(
null
);
if
(
s
!=
null
&& !
s
.
empty
())
gui
.
appendText
(
cn
+
":"
+
s
);
}
}
catch
(
Exception
|
StackOverflowError
e
) {}
}
}
}
gui
.
setVisible
(
true
);
}
}
}
Back
|
FazBrowse Home
|
New Git URL