1
0
mirror of https://github.com/QRouland/UTPass.git synced 2026-01-10 03:26:57 +00:00

Add initial ssh support in git cpp plugin

This commit is contained in:
2025-02-18 14:18:34 +01:00
parent ec4ebca950
commit 6306af6dde
4 changed files with 50 additions and 24 deletions

View File

@@ -8,12 +8,17 @@ extern "C" {
#include <variant>
// Forward declarations for the different credential types.
struct HTTP { };
struct HTTP {};
struct HTTPUserPass {
QString pass; ///< Password for HTTP user authentication.
};
struct SSHPass { };
struct SSHKey { };
struct SSHKey {
QString pub_key; ///< public key path.
QString priv_key; ///< private key path.
QString passphrase; ///< key passphrase.
};
/**
* @brief Variant type to represent various types of credentials.
@@ -21,10 +26,9 @@ struct SSHKey { };
* This type is used to store one of the following credential types:
* - HTTP
* - HTTPUserPass
* - SSHPass
* - SSHKey
*/
typedef std::variant<HTTP, HTTPUserPass, SSHPass, SSHKey> cred_type;
typedef std::variant<HTTP, HTTPUserPass, SSHKey> cred_type;
/**
* @class GitJob