Loading src/cli/netop.rs +5 −12 Original line number Diff line number Diff line Loading @@ -2,9 +2,8 @@ use anyhow::Result; use async_trait::async_trait; use clap::{Parser, Subcommand}; use std::fmt; use std::ops::Deref; use tor_chanmgr::ChannelUsage; use tor_proto::circuit::CircParameters; use tor_rtcompat::Runtime; use crate::cli::queries; Loading Loading @@ -35,16 +34,10 @@ impl ExtendCmd { let fp = relay.rsa_id().to_string().replace('$', "").to_uppercase(); let nickname = relay.rs().nickname().to_string(); let path = tor_circmgr::path::TorPath::new_one_hop(relay); let params = CircParameters::default(); let usage = ChannelUsage::UselessCircuit; let circ = arti_client .circmgr() .builder() .build(&path, ¶ms, usage) .await; match circ { let circuit = arti_client.circmgr().deref(); let one_hop_circ = circuit.get_or_launch_dir_specific(&relay).await; match one_hop_circ { Err(e) => println!("[-] Unable to extend: {}", e), Ok(_) => println!( "[+] Successful one hop to: {} - {}", Loading Loading
src/cli/netop.rs +5 −12 Original line number Diff line number Diff line Loading @@ -2,9 +2,8 @@ use anyhow::Result; use async_trait::async_trait; use clap::{Parser, Subcommand}; use std::fmt; use std::ops::Deref; use tor_chanmgr::ChannelUsage; use tor_proto::circuit::CircParameters; use tor_rtcompat::Runtime; use crate::cli::queries; Loading Loading @@ -35,16 +34,10 @@ impl ExtendCmd { let fp = relay.rsa_id().to_string().replace('$', "").to_uppercase(); let nickname = relay.rs().nickname().to_string(); let path = tor_circmgr::path::TorPath::new_one_hop(relay); let params = CircParameters::default(); let usage = ChannelUsage::UselessCircuit; let circ = arti_client .circmgr() .builder() .build(&path, ¶ms, usage) .await; match circ { let circuit = arti_client.circmgr().deref(); let one_hop_circ = circuit.get_or_launch_dir_specific(&relay).await; match one_hop_circ { Err(e) => println!("[-] Unable to extend: {}", e), Ok(_) => println!( "[+] Successful one hop to: {} - {}", Loading