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ACFY4S3XEWZQC
#[error("Unable to connect to ssh-agent. The environment variable `SSH_AUTH_SOCK` \
was set, but it points to a nonexistent file or directory.")]
#[error(
"Unable to connect to ssh-agent. The environment variable `SSH_AUTH_SOCK` \
was set, but it points to a nonexistent file or directory."
)]
/// thrussh_keys::load_public_key("/home/pe/.ssh/id_ed25519.pub").unwrap();
/// use std::env;
/// let home_dir = env::var("HOME").unwrap_or_else(|_| "/home/pe".to_string());
/// let key_file = format!("{}/.ssh/id_ed25519.pub", home_dir);
/// thrussh_keys::load_public_key(key_file).unwrap();
f.write(b"[localhost]:13265 ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIJdD7y3aLq454yWBdwLWbieU1ebz9/cu7/QEXn9OIeZJ\n#pijul.org,37.120.161.53 ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIA6rWI3G2sz07DnfFlrouTcysQlj2P+jpNSOEWD9OJ3X\npijul.org,37.120.161.53 ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIA6rWI3G1sz07DnfFlrouTcysQlj2P+jpNSOEWD9OJ3X\n").unwrap();
f.write_all(b"[localhost]:13265 ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIJdD7y3aLq454yWBdwLWbieU1ebz9/cu7/QEXn9OIeZJ\n#pijul.org,37.120.161.53 ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIA6rWI3G2sz07DnfFlrouTcysQlj2P+jpNSOEWD9OJ3X\npijul.org,37.120.161.53 ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIA6rWI3G1sz07DnfFlrouTcysQlj2P+jpNSOEWD9OJ3X\n").unwrap();
use aes::*;
use block_modes::block_padding::NoPadding;
type Aes128Cbc = block_modes::Cbc<Aes128, NoPadding>;
type Aes256Cbc = block_modes::Cbc<Aes256, NoPadding>;
use aes::{
cipher::{KeyIvInit, StreamCipher},
Aes128, Aes256,
};
use ctr::Ctr128BE;
type Aes128Ctr = Ctr128BE<Aes128>;
type Aes256Ctr = Ctr128BE<Aes256>;
fn cbc_encrypt<C>(dest: &mut [u8], len: usize, key: &[u8], iv: &[u8]) -> Result<usize, Error>
where
C: BlockCipher + BlockEncryptMut + KeyInit,
{
Ok(CbcEncryptor::<C>::new_from_slices(key, iv)?
.encrypt_padded_mut::<NoPadding>(dest, len)?
.len())
}
fn cbc_decrypt<C>(dest: &mut [u8], key: &[u8], iv: &[u8]) -> Result<usize, Error>
where
C: BlockCipher + BlockDecryptMut + KeyInit,
{
Ok(CbcDecryptor::<C>::new_from_slices(key, iv)?
.decrypt_padded_mut::<NoPadding>(dest)?
.len())
}
edition = "2018"
edition = "2021"