MCPcopy Create free account
hub / github.com/Firebasky/Java / Main

Class Main

Spring/CVE-2017-8046-spring/complete/src/main/java/EZvulhub/Main.java:3–23  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

1package EZvulhub;
2
3public class Main {
4 public static void main(String[] args) {
5 String command = "calc";
6 generateCommond(command);
7 }
8
9 private static void generateCommond(String command) {
10 System.out.println("m命令: " + command);
11 byte[] result = command.getBytes();
12 System.out.print("命令转为字节数组表示: ");
13 System.out.print("new byte[]{");
14 for (int i = 0; i < result.length; i++) {
15 if (i != result.length - 1) {
16 System.out.print(result[i] + ",");
17 } else {
18 System.out.print(result[i]);
19 }
20 }
21 System.out.print("}\n");
22 }
23}

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected