adobe / adobe/aio-cli-plugin-app-dev

isolate action code

オープン
#32 コメント 3 件 リアクション 0 件 担当者 0 名 GitHub で見る
enhancement
主要言語
JavaScript
スター
2
フォーク
5
PR マージ指標
30日以内にマージされた PR はありません

説明

Right now all action code that is run, has access to the host's node environment -- which is the developer's machine.
This includes the filesystem, running processes, etc. This will not be representative of a true serverless system which we are simulating.

Explore code isolation via the node `vm` module: https://nodejs.org/docs/latest-v18.x/api/vm.html
Take note that if the code to run uses `require` we will need to pass in the `require` loader, which may or may not be secure. In general this should not be a problem since we webpack the code.

Related:
1. https://github.com/node-inspector/node-inspector/issues/284
2. https://www.rocket.chat/blog/node-js-vm
3. https://github.com/laverdet/isolated-vm
4. https://github.com/Richienb/node-polyfill-webpack-plugin (note fs is not in there, since browsers do have this now, but we can easily add the fs fallback in)
5. https://blog.logrocket.com/how-to-protect-your-node-js-applications-from-malicious-dependencies-5f2e60ea08f9/
6. https://github.com/tschaub/mock-fs

コントリビューションガイド

コントリビューションガイドを開く

調査の方向性

まず、このリポジトリでアクション実行のエントリポイントを見つけます。この issue ではファイルもテストも指定されていません。Node の vm のドキュメントとリンク先の隔離に関するリファレンスを読み、require とファイルシステムへのアクセスを考慮した隔離アプローチを定義します。この issue では具体的な完了基準が指定されていません。

索引モデルが issue の本文から書いたものです。

評価

技術スタック
javascript, node.js, webpack
領域
cli, security
issue の種類
機能追加
難易度
5/5
見積もり時間
1週間以上
活発さ
停滞
明瞭さ
説明が足りない
初心者へのやさしさ
25/100

新しい issue をメールで受け取る

初心者向けの GitHub issue を短くまとめたダイジェスト。