awc-example: don't import signatures

This commit is contained in:
Aode (lion) 2021-11-18 16:09:06 -06:00
parent 03597d7080
commit 8c199123e2
2 changed files with 3 additions and 6 deletions

View file

@ -13,7 +13,5 @@ apub-core = { version = "0.1.0", path = "../../apub-core/" }
apub-rustcrypto = { version = "0.1.0", path = "../../apub-rustcrypto/" }
awc = { version = "3.0.0-beta.10", default-features = false, features = ["rustls"] }
example-types = { version = "0.1.0", path = "../example-types/" }
http-signature-normalization-actix = { version = "0.5.0-beta.12", default-features = false, features = ["client"] }
rand = "0.8.4"
rsa = "0.5.0"
serde = { version = "1", features = ["derive"] }

View file

@ -1,9 +1,8 @@
use apub_awc::AwcClient;
use apub_awc::{AwcClient, SignatureConfig};
use apub_breaker_session::BreakerSession;
use apub_rustcrypto::Rustcrypto;
use apub_core::session::RequestCountSession;
use apub_rustcrypto::Rustcrypto;
use example_types::{object_id, NoteType, ObjectId};
use http_signature_normalization_actix::Config;
use rsa::RsaPrivateKey;
use std::time::Duration;
@ -11,7 +10,7 @@ use std::time::Duration;
async fn main() -> Result<(), Box<dyn std::error::Error>> {
let private_key = RsaPrivateKey::new(&mut rand::thread_rng(), 1024)?;
let crypto = Rustcrypto::new("key-id".to_string(), private_key);
let config = Config::default();
let config = SignatureConfig::default();
let breakers = BreakerSession::limit(10, Duration::from_secs(60 * 60));