0

I am doing something about getting execution logs form a java program. But I just achieve this when it's a jar file using command like java -javaagent:agent1.jar -jar MyProgram.jar . But if there is a software which don't need using java -jar to open , how can I use my agent1.jar to get its execution data ? For example, I made a game by java ,and I open it by opening the file MyGame.exe ,which mean that I can't use javaagent:agent.jar to instrument and get logs.

Are there any ways to solve this problem or any other tools can give me a reference?

Maon
  • 9
  • 1
  • 1
    do you have the possibility to modify the MyGame.exe file? If so you could instruct it to run your instrumented application. Also can you supply more information about the structure of your application? – benebo22 Jun 10 '21 at 08:57
  • Please specify "a software". Knowing the name of the tool to create the EXE container from the Java application, would be helpful. Did you use any of [those](https://www.javatips.net/blog/convert-java-jar-file-to-exe)? If so, which one? – kriegaex Jun 10 '21 at 16:06
  • Quite strange, that a very similar question has been asked so shortly after this one. Unfortunately you did not respond to the comments here, but just in case you use _install4j_, the answer would be [here](https://stackoverflow.com/a/68032738/1082681). – kriegaex Jun 19 '21 at 00:59

0 Answers0