Is it possible to "get into" the stage of PHP code execution between reading a high-level script and compiling it into a direct assembler and see which op codes are generated?

  • what is the real task? - etki 2:42 pm
  • @Etki, bcompile bypass - AseN 2:44 pm
  • aha, and what task? What do you need to do? - etki

1 answer 1

since you need op-codes, look here: https://stackoverflow.com/questions/1795425/how-to-get-opcodes-of-php

and here's a good link: https://ctors.net/2015/09/11/php_opcodes , they say it works with php7 too

in short, you need a Vulcan Logic Disassembler

if bytecodes were needed - run bcompiler_write_file on the desired file

  • The direction of thought is correct, only the task is diametrically opposite - php.net/manual/ru/function.bcompiler-write-file.php - AseN
  • Perfectly - (byte code from bcompile -> php code), but it will do (byte code from bcompile -> assembler) - AseN
  • to get into the execution stage - only with the help of a debugger or to compile php by putting the hooks in the right places - strangeqargo
  • there was also such an idea (just to get into the process), but maybe there are other ways? PS Yes, op-codes, of course - AseN
  • one
    In general, if it is interesting, the situation is as follows (I hope I will say something new): bcompiler generates zend овские опкоды из php-кода, то же самое производит и vld. Следовательно, подавать на вход vld результат работы bcompiler овские опкоды из php-кода, то же самое производит и vld. Следовательно, подавать на вход vld результат работы bcompiler which is equivalent to овские опкоды из php-кода, то же самое производит и vld. Следовательно, подавать на вход vld результат работы bcompiler ить A дважды на B. Отсюда возникла более лояльная потребность: как бы можно было распарсить результат bcompiler and brought to vld? - AseN 4:52 pm