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

[deleted] #5537

Closed
Shruti-Ramenahalli opened this issue Mar 14, 2024 · 3 comments
Closed

[deleted] #5537

Shruti-Ramenahalli opened this issue Mar 14, 2024 · 3 comments
Labels

Comments

@Shruti-Ramenahalli
Copy link

Shruti-Ramenahalli commented Mar 14, 2024

[deleted]

@krzysdz
Copy link
Contributor

krzysdz commented Mar 14, 2024

This is not a problem with express or hbs. The problem is passing user-controlled input to res.render.
The express documentation says:

The locals object is used by view engines to render a response. The object keys may be particularly sensitive and should not contain user-controlled input, as it may affect the operation of the view engine or provide a path to cross-site scripting. Consult the documentation for the used view engine for additional considerations.

@joeyguerra
Copy link

For further reference, please review OWASP C5: Validate All Inputs.

I'm currently thinking that since hbs knows it's own schema, it could mitigate this issue by disallowing its core underlying design schema from the view model being passed in.

@Shruti-Ramenahalli have you considered submitting a pull request to the hbs repo with a suggested design fix?

@wesleytodd
Copy link
Member

If you believe there is a security issue please see our reporting guidelines.

@wesleytodd wesleytodd changed the title Security Issue: Express Package Vulnerability [deleted] Mar 14, 2024
@wesleytodd wesleytodd added invalid and removed bug labels Mar 14, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

4 participants