mirror of
https://github.com/warp-tech/warpgate.git
synced 2025-09-03 21:24:26 +08:00
fix: ssh server doesnt offer ed-25519 hostkey (#1473)
This commit is contained in:
parent
ff5e4bc691
commit
f1520c79b0
2 changed files with 4 additions and 3 deletions
|
@ -47,7 +47,7 @@ pub fn generate_host_keys(config: &WarpgateConfig) -> Result<()> {
|
|||
Ok(())
|
||||
}
|
||||
|
||||
pub fn load_host_keys(config: &WarpgateConfig) -> Result<PrivateKey, russh::keys::Error> {
|
||||
pub fn load_host_keys(config: &WarpgateConfig) -> Result<Vec<PrivateKey>, russh::keys::Error> {
|
||||
let path = get_keys_path(config);
|
||||
let mut keys = Vec::new();
|
||||
|
||||
|
@ -55,8 +55,9 @@ pub fn load_host_keys(config: &WarpgateConfig) -> Result<PrivateKey, russh::keys
|
|||
keys.push(load_secret_key(key_path, None)?);
|
||||
|
||||
let key_path = path.join("host-rsa");
|
||||
keys.push(load_secret_key(key_path, None)?);
|
||||
|
||||
load_secret_key(key_path, None)
|
||||
Ok(keys)
|
||||
}
|
||||
|
||||
pub fn generate_client_keys(config: &WarpgateConfig) -> Result<()> {
|
||||
|
|
|
@ -37,7 +37,7 @@ pub async fn run_server(services: Services, address: ListenEndpoint) -> Result<(
|
|||
MethodKind::KeyboardInteractive,
|
||||
][..],
|
||||
),
|
||||
keys: vec![load_host_keys(&config)?],
|
||||
keys: load_host_keys(&config)?,
|
||||
event_buffer_size: 100,
|
||||
nodelay: true,
|
||||
preferred: Preferred {
|
||||
|
|
Loading…
Add table
Reference in a new issue