add rustls-native-certs

closes #1241
This commit is contained in:
Damien Elmes 2021-06-18 18:15:41 +10:00
parent e6a7b8fba1
commit a58826941f
7 changed files with 130 additions and 0 deletions

13
Cargo.lock generated
View file

@ -1900,6 +1900,7 @@ dependencies = [
"percent-encoding", "percent-encoding",
"pin-project-lite", "pin-project-lite",
"rustls", "rustls",
"rustls-native-certs",
"serde", "serde",
"serde_json", "serde_json",
"serde_urlencoded", "serde_urlencoded",
@ -1972,6 +1973,18 @@ dependencies = [
"webpki", "webpki",
] ]
[[package]]
name = "rustls-native-certs"
version = "0.5.0"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "5a07b7c1885bd8ed3831c289b7870b13ef46fe0e856d288c30d9cc17d75a2092"
dependencies = [
"openssl-probe",
"rustls",
"schannel",
"security-framework",
]
[[package]] [[package]]
name = "ryu" name = "ryu"
version = "1.0.5" version = "1.0.5"

View file

@ -55,7 +55,9 @@ rust_library(
"mime_guess", "mime_guess",
"multipart", "multipart",
"rustls", "rustls",
"rustls-native-certs",
"rustls-tls", "rustls-tls",
"rustls-tls-native-roots",
"rustls-tls-webpki-roots", "rustls-tls-webpki-roots",
"serde_json", "serde_json",
"socks", "socks",
@ -110,6 +112,7 @@ rust_library(
"@raze__percent_encoding__2_1_0//:percent_encoding", "@raze__percent_encoding__2_1_0//:percent_encoding",
"@raze__pin_project_lite__0_2_6//:pin_project_lite", "@raze__pin_project_lite__0_2_6//:pin_project_lite",
"@raze__rustls__0_19_1//:rustls", "@raze__rustls__0_19_1//:rustls",
"@raze__rustls_native_certs__0_5_0//:rustls_native_certs",
"@raze__tokio__1_7_0//:tokio", "@raze__tokio__1_7_0//:tokio",
"@raze__tokio_rustls__0_22_0//:tokio_rustls", "@raze__tokio_rustls__0_22_0//:tokio_rustls",
"@raze__tokio_socks__0_5_1//:tokio_socks", "@raze__tokio_socks__0_5_1//:tokio_socks",

View file

@ -1941,6 +1941,16 @@ def raze_fetch_remote_crates():
build_file = Label("//cargo/remote:BUILD.rustls-0.19.1.bazel"), build_file = Label("//cargo/remote:BUILD.rustls-0.19.1.bazel"),
) )
maybe(
http_archive,
name = "raze__rustls_native_certs__0_5_0",
url = "https://crates.io/api/v1/crates/rustls-native-certs/0.5.0/download",
type = "tar.gz",
sha256 = "5a07b7c1885bd8ed3831c289b7870b13ef46fe0e856d288c30d9cc17d75a2092",
strip_prefix = "rustls-native-certs-0.5.0",
build_file = Label("//cargo/remote:BUILD.rustls-native-certs-0.5.0.bazel"),
)
maybe( maybe(
http_archive, http_archive,
name = "raze__ryu__1_0_5", name = "raze__ryu__1_0_5",

View file

@ -1772,6 +1772,15 @@
"license_file": null, "license_file": null,
"description": "Rustls is a modern TLS library written in Rust." "description": "Rustls is a modern TLS library written in Rust."
}, },
{
"name": "rustls-native-certs",
"version": "0.5.0",
"authors": "Joseph Birr-Pixton <jpixton@gmail.com>",
"repository": "https://github.com/ctz/rustls-native-certs",
"license": "Apache-2.0 OR ISC OR MIT",
"license_file": null,
"description": "rustls-native-certs allows rustls to use the platform native certificate store"
},
{ {
"name": "ryu", "name": "ryu",
"version": "1.0.5", "version": "1.0.5",

View file

@ -60,7 +60,9 @@ rust_library(
"native-tls", "native-tls",
"native-tls-crate", "native-tls-crate",
"rustls", "rustls",
"rustls-native-certs",
"rustls-tls", "rustls-tls",
"rustls-tls-native-roots",
"rustls-tls-webpki-roots", "rustls-tls-webpki-roots",
"serde_json", "serde_json",
"socks", "socks",
@ -118,6 +120,7 @@ rust_library(
"@raze__percent_encoding__2_1_0//:percent_encoding", "@raze__percent_encoding__2_1_0//:percent_encoding",
"@raze__pin_project_lite__0_2_6//:pin_project_lite", "@raze__pin_project_lite__0_2_6//:pin_project_lite",
"@raze__rustls__0_19_1//:rustls", "@raze__rustls__0_19_1//:rustls",
"@raze__rustls_native_certs__0_5_0//:rustls_native_certs",
"@raze__tokio__1_7_0//:tokio", "@raze__tokio__1_7_0//:tokio",
"@raze__tokio_native_tls__0_3_0//:tokio_native_tls", "@raze__tokio_native_tls__0_3_0//:tokio_native_tls",
"@raze__tokio_rustls__0_22_0//:tokio_rustls", "@raze__tokio_rustls__0_22_0//:tokio_rustls",

View file

@ -0,0 +1,91 @@
"""
@generated
cargo-raze crate build file.
DO NOT EDIT! Replaced on runs of cargo-raze
"""
# buildifier: disable=load
load("@bazel_skylib//lib:selects.bzl", "selects")
# buildifier: disable=load
load(
"@rules_rust//rust:rust.bzl",
"rust_binary",
"rust_library",
"rust_test",
)
package(default_visibility = [
# Public for visibility by "@raze__crate__version//" targets.
#
# Prefer access through "//cargo", which limits external
# visibility to explicit Cargo.toml dependencies.
"//visibility:public",
])
licenses([
"notice", # Apache-2.0 from expression "Apache-2.0 OR (ISC OR MIT)"
])
# Generated Targets
# Unsupported target "google" with type "example" omitted
rust_library(
name = "rustls_native_certs",
srcs = glob(["**/*.rs"]),
aliases = {
},
crate_features = [
"default",
"rustls",
],
crate_root = "src/lib.rs",
crate_type = "lib",
data = [],
edition = "2018",
rustc_flags = [
"--cap-lints=allow",
],
tags = [
"cargo-raze",
"manual",
],
version = "0.5.0",
# buildifier: leave-alone
deps = [
"@raze__rustls__0_19_1//:rustls",
] + selects.with_or({
# cfg(all(unix, not(target_os = "macos")))
(
"@rules_rust//rust/platform:aarch64-apple-ios",
"@rules_rust//rust/platform:aarch64-unknown-linux-gnu",
"@rules_rust//rust/platform:x86_64-apple-ios",
"@rules_rust//rust/platform:x86_64-unknown-linux-gnu",
): [
"@raze__openssl_probe__0_1_4//:openssl_probe",
],
"//conditions:default": [],
}) + selects.with_or({
# cfg(target_os = "macos")
(
"@rules_rust//rust/platform:x86_64-apple-darwin",
): [
"@raze__security_framework__2_3_1//:security_framework",
],
"//conditions:default": [],
}) + selects.with_or({
# cfg(windows)
(
"@rules_rust//rust/platform:x86_64-pc-windows-msvc",
): [
"@raze__schannel__0_1_19//:schannel",
],
"//conditions:default": [],
}),
)
# Unsupported target "compare_mozilla" with type "test" omitted
# Unsupported target "smoketests" with type "test" omitted

View file

@ -64,6 +64,7 @@ reqwest = { git = "https://github.com/ankitects/reqwest.git", rev = "7591444614d
"native-tls", "native-tls",
"rustls-tls", "rustls-tls",
"rustls-tls-webpki-roots", "rustls-tls-webpki-roots",
"rustls-tls-native-roots",
] } ] }
rusqlite = { version = "0.24.1", features = ["trace", "functions", "collation", "bundled"] } rusqlite = { version = "0.24.1", features = ["trace", "functions", "collation", "bundled"] }
scopeguard = "1.1.0" scopeguard = "1.1.0"