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

Extend sandbox for configuration with db, domain and maybe bus namespaces and limit process API access #1773

Open
georgolden opened this issue Aug 11, 2022 · 0 comments

Comments

@georgolden
Copy link
Member

Describe the problem

impress/lib/worker.js

Lines 31 to 32 in d31792c

const context = metavm.createContext({ process });
const config = await new Config(cfgPath, { mode: process.env.MODE, context });

We have only process injected into config sandbox

  • we need to limit process API access only to process.env, because we don't really need other process API for config
  • we may need other namespaces to be available for Logger configuration to inject writable destinations from application

Describe the solution

  1. Limit process API access to just env
  2. Extend context within the application sandbox or some particular namespaces

@tshemsedinov please edit

Alternatives

No response

Additional context

No response

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

No branches or pull requests

1 participant