Questions tagged [bytecode-manipulation]

Low level Virtual Machine bytecode manipulations. Including creating/modifying/optimizing/etc bytecode for various VMs. For example JVM, Python VM, Lua VM, etc.

Why?

Using some VM based programming languages for period of time usually leads to realising that some parts of the code aren't translated into bytecode efficiently, might be optimized for the specific VM even more or we just need some functionality which isn't implemented into standard bytecode compiler/interpreter/etc, like:

  • bytecode encryption
  • bytecode linkage
  • etc.

Links:

More about bytecode:

383 questions
-1
votes
1 answer

where does exactly Hibernate uses HttpURLConnection

I have been searching everywhere, but could not find where exactly hibernate uses HttpURLConnection. Theoretically I think it uses for its back end connectivity. My issue is I have a java agent which instruments HttpURLConnection to set a header…
-1
votes
2 answers

How method-based JIT compiler handles class field members

The Just-In-Time (JIT) compiler references a compiler that translates a code into native code at program runtime. Normally, it translates the Bytecode to machine code for Java programming language. There are general two kinds of JIT compilers:…
-1
votes
3 answers

How do I change a double in a compiled jar?

I have a jar, which contains a line of code which compares two doubles, one having the value of 0.7, but I need to be able to change that to 0.0. I cannot use reflection or anything like that because of the fact that this is a compiled jar file (not…
user3830679
-1
votes
6 answers

How to replace a method return type?

This is just a learning experiment for fun. I'm toying with bytecode manipulation. I'm just messing around for learning with asm in java. I wonder if it is possible to replace the return type of a method from an interface. Let's say that I have an…
ssedano
  • 8,322
  • 9
  • 60
  • 98
-1
votes
1 answer

A java Agent to inspect all JVM running classes?

I am trying do an academic project on BCI and JavaAssist. I would be glad if anyone could help me with these: Is it possible to build a java agent which can inspect/control all classes running currently in the JVM? Is it possible to build a java…
-2
votes
1 answer

Encoding a .json file for a bytecode vm

I'm trying to make a Bytecode VM in python just for fun, as a hobby project, but i have a problem, how i can encode a json file like this: { "code": [["0xf2", "Hello"], ["0xf3", 1]], "constants": [] } into some file format, something like…
-2
votes
1 answer

ASM Byte Code override method scoped var near end of method

I can't just replace the entire method. I have to just inject a reassignment of a local var after the last time it normally gets set but before it gets used near the end of the method. Here's some pseudocode void test() { /* stuff */ String thing…
vaps
  • 57
  • 5
-2
votes
1 answer

Modifying Java Methods/Bytecode in Runtime with C++

me and a friend of mine are working on a coding project and we ran into a little issue. We are essentially trying to modify Java Methods/Bytecode during runtime using C++. I am just curious if this is possible or how it is possible. We have already…
BigLenny
  • 11
  • 2
1 2 3
25
26