Revert "Merge pull request #4166 from Tyriar/event_with_emitter"#4177
Merged
Tyriar merged 1 commit intoxtermjs:masterfrom Oct 6, 2022
Merged
Revert "Merge pull request #4166 from Tyriar/event_with_emitter"#4177Tyriar merged 1 commit intoxtermjs:masterfrom
Tyriar merged 1 commit intoxtermjs:masterfrom
Conversation
Member
|
@Tyriar How is that more dangerous than the current approach? I mean a serious attacker can just follow the internal symbols to get down to the emitters anyway? (Btw thats basically what I did during the listener debugging to get a hold if their root...) |
Member
Author
|
It's not a security issue, but a separation of concerns issue. The risk is too great that some commit would be made that creates an instance of a class class but not assign it to a variable typed with the interface (not the class) which would expose fire. |
Member
|
Ah ok, yeah this newer approach mixed functionality into one thingy, that needs a certain usage pattern. I tend to treat those things as "if in doubt: explicit is better than implicit". |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
This reverts commit d22f7c9, reversing changes made to 1f8e6f0.
When discussed with the VS Code team they pointed out this is a bit dangerous exposing the emitters publicly everywhere. Reverting as I was convinced safety beats convenience.