mirror of
https://github.com/denoland/deno.git
synced 2025-09-26 12:19:12 +00:00
feat: add --allow-sys permission flag (#16028)
This commit is contained in:
parent
b312279e58
commit
fa9e7aab6d
11 changed files with 527 additions and 51 deletions
24
cli/dts/lib.deno.ns.d.ts
vendored
24
cli/dts/lib.deno.ns.d.ts
vendored
|
@ -183,6 +183,15 @@ declare namespace Deno {
|
|||
*/
|
||||
env?: "inherit" | boolean | string[];
|
||||
|
||||
/** Specifies if the `sys` permission should be requested or revoked.
|
||||
* If set to `"inherit"`, the current `sys` permission will be inherited.
|
||||
* If set to `true`, the global `sys` permission will be requested.
|
||||
* If set to `false`, the global `sys` permission will be revoked.
|
||||
*
|
||||
* Defaults to `false`.
|
||||
*/
|
||||
sys?: "inherit" | boolean | string[];
|
||||
|
||||
/** Specifies if the `hrtime` permission should be requested or revoked.
|
||||
* If set to `"inherit"`, the current `hrtime` permission will be inherited.
|
||||
* If set to `true`, the global `hrtime` permission will be requested.
|
||||
|
@ -2913,6 +2922,7 @@ declare namespace Deno {
|
|||
| "write"
|
||||
| "net"
|
||||
| "env"
|
||||
| "sys"
|
||||
| "ffi"
|
||||
| "hrtime";
|
||||
|
||||
|
@ -2957,6 +2967,19 @@ declare namespace Deno {
|
|||
variable?: string;
|
||||
}
|
||||
|
||||
/** @category Permissions */
|
||||
export interface SysPermissionDescriptor {
|
||||
name: "sys";
|
||||
kind?:
|
||||
| "loadavg"
|
||||
| "hostname"
|
||||
| "systemMemoryInfo"
|
||||
| "networkInterfaces"
|
||||
| "osRelease"
|
||||
| "getUid"
|
||||
| "getGid";
|
||||
}
|
||||
|
||||
/** @category Permissions */
|
||||
export interface FfiPermissionDescriptor {
|
||||
name: "ffi";
|
||||
|
@ -2979,6 +3002,7 @@ declare namespace Deno {
|
|||
| WritePermissionDescriptor
|
||||
| NetPermissionDescriptor
|
||||
| EnvPermissionDescriptor
|
||||
| SysPermissionDescriptor
|
||||
| FfiPermissionDescriptor
|
||||
| HrtimePermissionDescriptor;
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue