-
Notifications
You must be signed in to change notification settings - Fork 651
Issue #110 - Fix afl-clang-fast -E and -shared regressions. #112
base: master
Are you sure you want to change the base?
Conversation
Thanks for your pull request. It looks like this may be your first contribution to a Google open source project (if not, look below for help). Before we can look at your pull request, you'll need to sign a Contributor License Agreement (CLA). 📝 Please visit https://cla.developers.google.com/ to sign. Once you've signed (or fixed any issues), please reply here with What to do if you already signed the CLAIndividual signers
Corporate signers
ℹ️ Googlers: Go here for more info. |
1 similar comment
Thanks for your pull request. It looks like this may be your first contribution to a Google open source project (if not, look below for help). Before we can look at your pull request, you'll need to sign a Contributor License Agreement (CLA). 📝 Please visit https://cla.developers.google.com/ to sign. Once you've signed (or fixed any issues), please reply here with What to do if you already signed the CLAIndividual signers
Corporate signers
ℹ️ Googlers: Go here for more info. |
CLA is signed by Mozilla. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thank you!
This looks good to me, but cc-ing @andreafioraldi to take a look who sent #80 before to make sure it doesn't break his use case.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Likely CLA doesn't get verified automatically because of:
Corporate signers
Your company has a Point of Contact who decides which employees are authorized to participate. Ask your POC to be added to the group of authorized contributors. If you don't know who your Point of Contact is, direct the Google project maintainer to go/cla#troubleshoot (Public version).
@choller do you know if you're added to that group?
@Dor1s Hello |
@sylvestre Hello! Yeah, I'm able to see Mozilla among the corporate signers, and in the worst case can just ignore the CLA check here. However, there is definitely a way to make the check pass. It might be nice to achieve that to avoid any confusion with future: https://cla.developers.google.com/about#add-contributors As I understand, there must be some Google Group that was submitted with the corporate CLA. |
Sure, I will see on our side what we can do to do the right thing :) |
thank you @sylvestre ! and in the meantime we're waiting for @@andreafioraldi to take a look |
LGTM, I will test it tomorrow morning (I'm in EU) but it should be ok, it doesn't revert my patch. Btw my use case is openssl on Fuzzbench, so if you want to test it now in order to merge ASAP just try to compile it using afl-clang-fast. |
-shared reintroduces the google/fuzzbench#110 bug. IMO -E is really needed, and fix the @choller compilation failures, -shared instead breaks the linking with errors about undefined references to afl-llvm-rt. It is true that if we compile afl-llvm-rt into all the shared objects they will have duplicated code, however that code will be not used. We should keep the -E case and drop -shared. |
This indicates that the project is linking an executable without attaching the runtime, and I would consider that a bug. It would mean that the runtime is only present because a shared object with the runtime is loaded into the executable and that needs fixing.
I'm not talking about multiple shared objects, but shared object vs. the binary loading it. If both have the runtime, then I think there is no way for the loader to resolve this properly. I also just looked up why this was added initially:
So this was causing real malfunctions with persistent mode. I also think it's not useful to argue that this breaks one project in fuzzbench, because the change you introduced broke another project even before. I think we should stick to the way sanitizers solve this, because they face similar problems with runtime duplication (attaching for example the ASan runtime to shared objects will crash your process). |
I think an intermediate solution would be to add an environment variable that allows overriding this behavior. Something like |
+1 for AFL_ATTACH_RT_SHARED |
Great, I'll change the PR accordingly. We should still investigate long-term why the OpenSSL build fails in this way, because that might be a bug. |
@andreafioraldi suggested to use |
I forgot to put sancov in the list when I wrote it on Discord,
|
Thanks @choller and @andreafioraldi for updating the PR! LGTM. @sylvestre, let us know if there's any update re the CLA, thanks! |
The CLA check here should be fixed. |
@googlebot ping |
No description provided.