Skip to content

Commit

Permalink
lib/elf: Panic if ELF file contains DT_NEEDED tags
Browse files Browse the repository at this point in the history
  • Loading branch information
mintsuki committed Jun 4, 2024
1 parent d694902 commit e6a742e
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions common/lib/elf.c
Original file line number Diff line number Diff line change
Expand Up @@ -313,6 +313,8 @@ static bool elf64_apply_relocations(uint8_t *elf, struct elf64_hdr *hdr, void *b
case DT_JMPREL:
dt_jmprel = dyn->d_un;
break;
case DT_NEEDED:
panic(true, "elf: ELF file attempts to load a dynamically linked library");
}
}

Expand Down

0 comments on commit e6a742e

Please sign in to comment.