Skip to content
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

false positive with dtls #547

Closed
ramosian-glider opened this issue Sep 1, 2015 · 6 comments
Closed

false positive with dtls #547

ramosian-glider opened this issue Sep 1, 2015 · 6 comments

Comments

@ramosian-glider
Copy link
Member

Originally reported on Google Code with ID 44

lib/msan/lit_tests/dtls_test.c currently produces a false report
because we don't know the dynamic tls and don't clean its shadow on thread exit.

The behavior is different with glibs < 2.19 and >= 2.19,
see https://groups.google.com/forum/#!topic/address-sanitizer/BfwYD8HMxTM
With < 2.19 dtls will be created by malloc and thus will be poisoned,
with >= 2.19 dtls will be created by mmap and this will not be poisoned,
but we still must unpoison it on thread exit.

We'l need to use the new __tls_get_addr interceptor machinery 
to clean shadow for dtls on its creation and on thread exit.

Most of the code is already there (lib/sanitizer_common/sanitizer_tls_get_addr.h)

Reported by konstantin.s.serebryany on 2014-01-29 09:42:03

@ramosian-glider
Copy link
Member Author

Reported by konstantin.s.serebryany on 2014-01-29 09:42:14

@ramosian-glider
Copy link
Member Author

Reported by konstantin.s.serebryany on 2014-01-29 10:33:56

@ramosian-glider
Copy link
Member Author

Btw, where does ASan clear shadow for DTLS?
I don't see anything like that.
And I think it does not need it either.

Reported by eugenis@google.com on 2014-06-25 11:02:35

@ramosian-glider
Copy link
Member Author

'cause thread-locals don't have redzones

Reported by eugenis@google.com on 2014-06-25 11:03:02

@ramosian-glider
Copy link
Member Author

Fixed:
http://llvm.org/viewvc/llvm-project?view=revision&revision=211683

Reported by eugenis@google.com on 2014-06-25 11:39:19

  • Status changed: Fixed

@ramosian-glider
Copy link
Member Author

Adding Project:MemorySanitizer as part of GitHub migration.

Reported by glider@google.com on 2015-07-30 09:22:26

  • Labels added: ProjectMemorySanitizer

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant