Mirror: A maybe slightly safer-ish wrapper around eval Function constructors
0
fork

Configure Feed

Select the types of activity you want to include in your feed.

Expose SafeFunction as Function in safe global

+2
+2
src/index.ts
··· 160 160 for (const key in trueGlobal) safeGlobal[key] = undefined; 161 161 // We also reset all ignored keys explicitly 162 162 for (const key in ignore) safeGlobal[key] = undefined; 163 + // It _might_ be safe to expose the Function constructor like this... who knows 164 + safeGlobal!.Function = SafeFunction; 163 165 // Lastly, we also disallow certain property accesses on the safe global 164 166 return (safeGlobal = withProxy(safeGlobal!)); 165 167 }