Benign crates 2,956,103 installs Download

libp2p-uds 0.24.0

“Unix domain sockets transport for libp2p”

Large registry install base (10k+ downloads)Package is at least one year old
SHA-2565e0aba04370a00d8d0236e350bc862926c1b42542a169aa6a481e660e5b990fe

Evidence

Temp or Tmp path segment lib.rs · lines 29–32
29:10… UdsConfig` transport supports multiaddresses of the form `/unix//tmp/foo`.
30//!
31//! The `UdsConfig` structs implements the `Transport` trait of the `core` library. See the
32//! documentation of `core …
imports futures::future::BoxFuture lib.rs · lines 35–48
35:41… t(target_os = "emscripten")))))]
36
37use futures::{prelude::*, future::{BoxFuture, Ready}};
38use futures::stream::BoxStream;
39use libp2p_core::{
40 Transport,
41 multiaddr::{Protocol, Multiaddr},
42 transport::{ListenerEvent, TransportError}
43};
44use log::debug;
45use std::{io, path::PathBuf};
46
47macro_rules! codegen {
48 ($feature_name:expr, $uds_config:ident, $build_listener:expr, $unix_st …
References the Tokio async runtime namespace lib.rs · lines 120–133
120:2… UdsConfig,
121 |addr| async move { async_std::os::unix::net::UnixListener::bind(addr).await },
122 async_std::os::unix::net::UnixStream,
123);
124#[cfg(feature = "tokio")]
125codegen!(
126 "tokio",
127 TokioUdsConfig,
128 |addr| async move { tokio::net::UnixListener::bind(addr) },
129 tokio::net::UnixStream,
130 mut
131);
132
133/// Turns a `Multiaddr` containing a single `Unix` comp …
imports tempfile lib.rs · lines 158–178
158:22… re = "async-std"))]
159mod tests {
160 use super::{multiaddr_to_path, UdsConfig};
161 use futures::{channel::oneshot, prelude::*};
162 use std::{self, borrow::Cow, path::Path};
163 use libp2p_core::{Transport, multiaddr::{Protocol, Multiaddr}};
164 use tempfile;
165
166 #[test]
167 fn multiaddr_to_path_conversion() {
168 assert!(
⋯10 lines
References a public code-forge URL CHANGELOG.md · lines 1–25
⋯17 lines
18
19- Updated dependencies.
20- Conditional compilation fixes for the `wasm32-wasi` target
21 ([PR 1633](https://github.com/libp2p/rust-libp2p/pull/1633)).
22
23# 0.19.2 [2020-06-22]
24
25- Updated dependencies.

No evidence locations were recorded for this file. Raw result

Keyboard shortcuts on this page: j for the next sample, k for the previous one, x to go back to the feed, d to download the original bytes, r to re-queue the sample for analysis.