ocm_types/share/protocols/ssh.rs
1// SPDX-FileCopyrightText: 2026 Matthias Kraus <info@opengeomesh.org>
2//
3// SPDX-License-Identifier: LGPL-3.0-or-later
4
5use serde::{Deserialize, Serialize};
6
7use super::AccessType;
8use super::default_access_types;
9
10#[derive(Debug, Clone, PartialEq, Eq, Serialize, Deserialize)]
11#[serde(rename_all = "camelCase")]
12pub struct SshProperties {
13 /// The type of access being granted to the remote resource.
14 /// If omitted, it defaults to `['remote']`.
15 #[serde(
16 skip_serializing_if = "Vec::is_empty",
17 default = "default_access_types"
18 )]
19 pub access_types: Vec<AccessType>,
20 /// The full address to be used for ssh or scp access, in the
21 /// `username@host.fqdn:port/resource/path`, where authentication
22 /// expected to take place via public/private key.
23 pub uri: String,
24}