Yes, github is the perfect place. Let me take a look, I'll reply there. On Fri, Mar 16, 2018 at 12:39 PM, Fernando Campos <[email protected]> wrote:
> Hello! > > I posted in github this comment: https://github.com/google/ > sanitizers/issues/611#issuecomment-368566634 > > Don't know if github was not the right place for this kind of questions. > Let me try in this list... > > Hi! > I have an environment in which I am using an external SDK. This SDK > consist of a shared library I link with, and which makes use of dlopen to > open other libX.so with RTLD_DEEPBIND flag. I'm not interested at all on > sanitize the SDK, I only want to sanitize my own code. > > How should I proceed? I'm confused about the different > -shared-libasan/-static-libasan options. > As far as I understand, compiling with -static-libasan (GCC6) should > inject all the sanitizer code in my binary and should have no effects on > non-sanitized SDK, but I get an error on SDK trying to dlopen the .so: > Couldn't load libXXX.so: System error code(-2): libXXX.so: cannot open > shared object file: No such file or directory > > Using LD_LIBRARY_PATH to allow the SDK finding its libXXX.so I get the > famous _int_free SEGV ASAN error. Seems like the SDK is redefining any > alloc/free function, so there is a mismatch on symbol resolution (SDK vs > Asan). > > Looks like linking with -fsanitize=address changes the order of symbols > lookup/LD_PATH. I would need to isolate the SDK so it remains using libc or > its own implementation (I don't know how internally works and I don't have > access to source code neither). > > I want this behavior #871 (comment) > <https://github.com/google/sanitizers/issues/871#issuecomment-337896857>, > but I'm not able to make the SDK run when my binary is using asan. > > I am open to use blacklist, suppression list, > *attribute*((no_sanitize("address"))) > or any other option, but I would like to understand the problem. > > Any hints? > Thanks > > -- > You received this message because you are subscribed to the Google Groups > "address-sanitizer" group. > To unsubscribe from this group and stop receiving emails from it, send an > email to [email protected]. > For more options, visit https://groups.google.com/d/optout. > -- You received this message because you are subscribed to the Google Groups "address-sanitizer" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. For more options, visit https://groups.google.com/d/optout.
