В ядре Linux была устранена следующая уязвимость: bpf: не переписывать шаблоны bpf_fastcall, введенные прыжком mark_fastcall_pattern_for_call() должны обеспечить соответствие серии команд «spill; call; fill» не прерывается прыжком. В противном случае перезапись, примененная bpf_remove_fastcall_spills_fills(), не является звуковой. Запишите инструкции, предназначенные для прыжков в insn_aux_data[*].jump_target, когда CFG построен, и используйте этот флаг, чтобы остановить рост шаблона в такой инструкции.
Прыжки к первому разливу хороши. Обратите внимание, что существующее поле insn_aux_data[*].jmp_point не может быть повторно использовано, так как оно помечает инструкции по возврату подпрограммы.
Показать оригинальное описание (EN)
In the Linux kernel, the following vulnerability has been resolved: bpf: don't rewrite bpf_fastcall patterns entered by a jump mark_fastcall_pattern_for_call() must ensure that matched "spill; call; fill" instruction series is not interrupted by a jump. Otherwise the rewrite applied by bpf_remove_fastcall_spills_fills() is not sound. Record the instructions targeted by jumps in insn_aux_data[*].jump_target when the CFG is built and use this flag to stop growing a pattern at such an instruction. Jumps to the first spill are fine. Note that existing insn_aux_data[*].jmp_point field can't be reused, as it marks subprogram return instructions.