Skip to content

Fixed taint propagation for String conversion fast path and utf8 strings#11

Open
alexbara2000 wants to merge 2 commits into
tmbrbr:primitaint-mergefrom
alexbara2000:StringConversionBug
Open

Fixed taint propagation for String conversion fast path and utf8 strings#11
alexbara2000 wants to merge 2 commits into
tmbrbr:primitaint-mergefrom
alexbara2000:StringConversionBug

Conversation

@alexbara2000

Copy link
Copy Markdown

The taint was being lost for string conversion due to fast path being taken when classes were being used. The taint was also being lost for utf8 conversion (special case). Both issues have been fixed and tested.

@alexbara2000

Copy link
Copy Markdown
Author

This fix is for issue 240 and issue 238

@tmbrbr

tmbrbr commented Dec 12, 2024

Copy link
Copy Markdown
Owner

Hi @alexbara2000, thanks for the PR!

I have a couple of comments - I think this would make sense to merge directly to https://github.com/SAP/project-foxhound, rather than the primitaint branch. We can then pull stuff to primitaint to ensure the fix is there too.

Can you also add a regression test for the issue as well? You had a nice code snippet in the issues. Let me know if you need support on where to do this.

@alexbara2000

Copy link
Copy Markdown
Author

Hey,

For sure I can add a couple tests for this PR. Just to make sure, are regression tests the ones in js/src/tests/non262/taint?

@tmbrbr

tmbrbr commented Dec 12, 2024

Copy link
Copy Markdown
Owner

That's where the tests live that can be tested in a pure JavaScript environment.

I think in this case you need access to DOM objects as well though right?

If so we have some tests here: https://github.com/SAP/project-foxhound/tree/main/taint/test/mochitest which you can add to.

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

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants