When require.context === host and sets require.builtin to block fs module.
Everything works fine except for requiring an external module which require('fs') in its code.
In this case, VM should throw an Access denied to require 'fs' error but it doesn't.
Seems like require in host is not patched as expected
When
require.context=== host and setsrequire.builtinto blockfsmodule.Everything works fine except for requiring an external module which
require('fs')in its code.In this case,
VMshould throw anAccess denied to require 'fs'error but it doesn't.Seems like
requirein host is not patched as expected