summaryrefslogtreecommitdiff
path: root/runtime/web_worker.rs
diff options
context:
space:
mode:
authorTheAifam5 <theaifam5@gmail.com>2021-08-09 16:53:21 +0200
committerGitHub <noreply@github.com>2021-08-09 16:53:21 +0200
commit353a4a1af3165b2c59319865350d70a99105269c (patch)
tree32eb71ccef95552bd4ec4af176b7ddcfe51d172c /runtime/web_worker.rs
parent3ab50b355141f744a0acec1a5cc3b3b95247d4b1 (diff)
feat: Add --unsafely-treat-insecure-origin-as-secure flag to disable SSL verification (#11324)
This commit adds "--unsafely-treat-insecure-origin-as-secure" flag that allows to disable SSL verification for all domains, or specific domains if they were passed as an argument to the flag. Co-authored-by: Bartek IwaƄczuk <biwanczuk@gmail.com>
Diffstat (limited to 'runtime/web_worker.rs')
-rw-r--r--runtime/web_worker.rs4
1 files changed, 4 insertions, 0 deletions
diff --git a/runtime/web_worker.rs b/runtime/web_worker.rs
index 3f68fc4e6..1349c510a 100644
--- a/runtime/web_worker.rs
+++ b/runtime/web_worker.rs
@@ -253,6 +253,7 @@ pub struct WebWorkerOptions {
pub args: Vec<String>,
pub debug_flag: bool,
pub unstable: bool,
+ pub unsafely_treat_insecure_origin_as_secure: Option<Vec<String>>,
pub root_cert_store: Option<RootCertStore>,
pub user_agent: String,
pub seed: Option<u64>,
@@ -304,10 +305,12 @@ impl WebWorker {
options.root_cert_store.clone(),
None,
None,
+ options.unsafely_treat_insecure_origin_as_secure.clone(),
),
deno_websocket::init::<Permissions>(
options.user_agent.clone(),
options.root_cert_store.clone(),
+ options.unsafely_treat_insecure_origin_as_secure.clone(),
),
deno_broadcast_channel::init(
options.broadcast_channel.clone(),
@@ -341,6 +344,7 @@ impl WebWorker {
deno_net::init::<Permissions>(
options.root_cert_store.clone(),
options.unstable,
+ options.unsafely_treat_insecure_origin_as_secure.clone(),
),
ops::os::init(),
ops::permissions::init(),