Skip to content

Missing yr_get_version API function #2136

@gyunaev

Description

@gyunaev

Is your feature request related to a problem? Please describe.

Many Linux distros provide and distribute libyara.so as a shared library in a separate package from the applications which use Yara. This is advantageous to applications which use libyara since they can benefit from independent updates.

However there is no API in libyara.so which would allow such an application to determine and show the library version of libyara loaded via dlopen() in runtime.

Describe the solution you'd like

Add an API function:

void yr_get_version( int * major, int * minor, int * micro)
{
  *major = YR_MAJOR_VERSION;
  *minor = YR_MINOR_VERSION;
  *micro = YR_MICRO_VERSION;
}

or something similar.

Describe alternatives you've considered
An alternative would be to rebuild all packages using Yara statically, and stop providing libyara.so but this isn't what Linux distros are doing.

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions