You are an expert in writing code in many different languages. Your goal is to perform code completion for the following code, keeping in mind the rest of the code and the file meta data.
    Metadata details:
    filename: duo.rs
    path of file: ./repos/matano/lib/rust/log_puller/src/pullers
    
    the code of the file until where you have to start completion: use std::{pin::Pin, sync::Arc};
use tokio::sync::Mutex;

use anyhow::{anyhow, Context as AnyhowContext, Error, Result};
use async_stream::{stream, try_stream};
use async_trait::async_trait;
use chrono::{DateTime, FixedOffset, Local, NaiveDateTime, Utc};
use futures::{futur
    
fn basic_auth_for_canon(integration_key: &str, secret_key: &str, canon: &[&str]) -> String {
    let canon = canon.join("\n");

    let s_key = hmac::Key::new(hmac::HMAC_SHA1_FOR_LEGACY_USE_ONLY, secret_key.as_bytes());
    let mut s_ctx = hmac::Context::with_key(&s_key);
    s_ctx.update(canon.as_bytes());
    let sig = s_ctx.sign();
    let auth = format!("{}:{}", integration_key, hex::encode(sig.as_ref()));

    let basic_auth = format!("Basic {}", base64::encode(&auth));

    basic_auth
}