mirror of
https://github.com/denoland/deno.git
synced 2025-09-28 05:04:48 +00:00
refactor: --unsafely-ignore-certificate-errors (#11629)
This commit is contained in:
parent
465cf9a6fe
commit
b9a8111a00
17 changed files with 78 additions and 79 deletions
|
@ -119,15 +119,15 @@ impl ProgramState {
|
|||
}
|
||||
|
||||
if let Some(insecure_allowlist) =
|
||||
flags.unsafely_treat_insecure_origin_as_secure.as_ref()
|
||||
flags.unsafely_ignore_certificate_errors.as_ref()
|
||||
{
|
||||
let domains = if insecure_allowlist.is_empty() {
|
||||
"for all domains".to_string()
|
||||
"for all hostnames".to_string()
|
||||
} else {
|
||||
format!("for: {}", insecure_allowlist.join(", "))
|
||||
};
|
||||
let msg = format!(
|
||||
"DANGER: SSL ceritificate validation is disabled {}",
|
||||
"DANGER: TLS ceritificate validation is disabled {}",
|
||||
domains
|
||||
);
|
||||
eprintln!("{}", colors::yellow(msg));
|
||||
|
@ -153,7 +153,7 @@ impl ProgramState {
|
|||
!flags.no_remote,
|
||||
Some(root_cert_store.clone()),
|
||||
blob_store.clone(),
|
||||
flags.unsafely_treat_insecure_origin_as_secure.clone(),
|
||||
flags.unsafely_ignore_certificate_errors.clone(),
|
||||
)?;
|
||||
|
||||
let lockfile = if let Some(filename) = &flags.lock {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue