Skip to content

Comments

Allow the extension to be active in untrusted workspaces#364

Merged
SunsetTechuila merged 2 commits intoeditorconfig:mainfrom
jashug:main
Feb 8, 2025
Merged

Allow the extension to be active in untrusted workspaces#364
SunsetTechuila merged 2 commits intoeditorconfig:mainfrom
jashug:main

Conversation

@jashug
Copy link

@jashug jashug commented Feb 22, 2024

Closes #305

Just ran into this today. At an absolute minimum, the language definition and grammar should be available even in untrusted workspaces, but a quick look suggests that the generate command is also safe. There is no substitution in the template, plus the user would have to run the command manually. At worst, untrusted files could set their own .editorconfig, which only applies to files below in the directory hierarchy: This is probably wanted behavior even in an untrusted workspace.

If maintainers do decide some parts of the extension are too dangerous for untrusted workspaces, it is still possible to provide the language and grammar definitions.

Please fill in this template.

  • Use a meaningful title for the pull request.
  • Use meaningful commit messages.
  • Run tsc w/o errors (same as npm run compile).
  • Run npm run lint w/o errors.

Closes editorconfig#305

Just ran into this today. At an absolute minimum, the language definition and grammar should be available even in untrusted workspaces, but a quick look suggests that the generate command is also safe. There is no substitution in the template, plus the user would have to run the command manually. At worst, untrusted files could set their own `.editorconfig`, which only applies to files below in the directory hierarchy: This is probably wanted behavior even in an untrusted workspace.
Copy link
Member

@SunsetTechuila SunsetTechuila left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

don't see how this can compromise security in any meaningful way

@SunsetTechuila SunsetTechuila merged commit 17f1170 into editorconfig:main Feb 8, 2025
3 checks passed
@SunsetTechuila
Copy link
Member

thanks for the contribution

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.

Support Workspace Trust

3 participants