-
Notifications
You must be signed in to change notification settings - Fork 155
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Get ELF dynamic symbol version information #572
Comments
Currently the only way is via |
Thanks that could work for me, but I don't know how to obtain a object::read::elf::SectionTable from read::ElfFile, there doesn't seem to be an API doing that. |
Since what you are doing is simple and specific to ELF, I suggest using the low level API instead of let elf = object::elf::FileHeader64::<Endianness>::parse(data)?;
let endian = elf.endian()?;
if let Some(sections) = elf.sections(endian, data)? {
if let Some((mut verneed, _)) = sections.gnu_verneed(endian, data)? {
...
}
} |
Thank you! Or simply fallback on error is enough? |
Use |
I want to get the dynamic symbol version information using
object
programmatically.I can currently obtain it via
object -T
:however
object
isn't always available and I want to do it in Rust.I can't find a function/trait doing this and printing
symbol_name
alone doesn't provide me with the information required.My goal is to find which glibc version is required for the binary.
The text was updated successfully, but these errors were encountered: