public inbox for pve-devel@lists.proxmox.com
 help / color / mirror / Atom feed
From: Christoph Heiss <c.heiss@proxmox.com>
To: pve-devel@lists.proxmox.com
Subject: [pve-devel] [PATCH installer 7/7] auto-installer: add test for hashed root password option
Date: Thu, 23 May 2024 14:19:35 +0200	[thread overview]
Message-ID: <20240523121938.1058898-8-c.heiss@proxmox.com> (raw)
In-Reply-To: <20240523121938.1058898-1-c.heiss@proxmox.com>

Signed-off-by: Christoph Heiss <c.heiss@proxmox.com>
---
 .../parse_answer/hashed_root_password.json    | 20 +++++++++++++++++++
 .../parse_answer/hashed_root_password.toml    | 14 +++++++++++++
 2 files changed, 34 insertions(+)
 create mode 100644 proxmox-auto-installer/tests/resources/parse_answer/hashed_root_password.json
 create mode 100644 proxmox-auto-installer/tests/resources/parse_answer/hashed_root_password.toml

diff --git a/proxmox-auto-installer/tests/resources/parse_answer/hashed_root_password.json b/proxmox-auto-installer/tests/resources/parse_answer/hashed_root_password.json
new file mode 100644
index 0000000..19c51ba
--- /dev/null
+++ b/proxmox-auto-installer/tests/resources/parse_answer/hashed_root_password.json
@@ -0,0 +1,20 @@
+{
+  "autoreboot": 1,
+  "cidr": "192.168.1.114/24",
+  "country": "at",
+  "dns": "192.168.1.254",
+  "domain": "testinstall",
+  "filesys": "ext4",
+  "gateway": "192.168.1.1",
+  "hdsize": 223.57088470458984,
+  "lvm_auto_rename": 1,
+  "hostname": "pveauto",
+  "keymap": "de",
+  "mailto": "mail@no.invalid",
+  "mngmt_nic": "eno1",
+  "root_password": {
+    "hashed": "$y$j9T$VgMv8lsz/TEvzesCZU3xD.$SK.h4QW51Jr/EmjuaTz5Bt4kYiX2Iezz6omzoqVEwj9"
+  },
+  "target_hd": "/dev/sda",
+  "timezone": "Europe/Vienna"
+}
diff --git a/proxmox-auto-installer/tests/resources/parse_answer/hashed_root_password.toml b/proxmox-auto-installer/tests/resources/parse_answer/hashed_root_password.toml
new file mode 100644
index 0000000..ed4d2e5
--- /dev/null
+++ b/proxmox-auto-installer/tests/resources/parse_answer/hashed_root_password.toml
@@ -0,0 +1,14 @@
+[global]
+keyboard = "de"
+country = "at"
+fqdn = "pveauto.testinstall"
+mailto = "mail@no.invalid"
+timezone = "Europe/Vienna"
+root_password_hashed = "$y$j9T$VgMv8lsz/TEvzesCZU3xD.$SK.h4QW51Jr/EmjuaTz5Bt4kYiX2Iezz6omzoqVEwj9"
+
+[network]
+source = "from-dhcp"
+
+[disk-setup]
+filesystem = "ext4"
+disk_list = ["sda"]
-- 
2.44.0



_______________________________________________
pve-devel mailing list
pve-devel@lists.proxmox.com
https://lists.proxmox.com/cgi-bin/mailman/listinfo/pve-devel


      parent reply	other threads:[~2024-05-23 12:20 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-05-23 12:19 [pve-devel] [PATCH installer 0/7] auto-installer: add option for providing hashed root password Christoph Heiss
2024-05-23 12:19 ` [pve-devel] [PATCH installer 1/7] common: move `PasswordOptions` type to tui crate Christoph Heiss
2024-05-23 12:19 ` [pve-devel] [PATCH installer 2/7] tui-installer: remove `Debug` implementation for password options Christoph Heiss
2024-05-23 12:19 ` [pve-devel] [PATCH installer 3/7] low-level: change root password option to contain either plaintext or hash Christoph Heiss
2024-05-23 12:19 ` [pve-devel] [PATCH installer 4/7] tui-installer: adapt to new `root_password` plain/hashed setup option Christoph Heiss
2024-05-23 12:19 ` [pve-devel] [PATCH installer 5/7] auto-installer: " Christoph Heiss
2024-05-23 12:19 ` [pve-devel] [PATCH installer 6/7] auto-installer: add new `global.root_password_hashed` answer option Christoph Heiss
2024-05-24  9:08   ` Christoph Heiss
2024-05-23 12:19 ` Christoph Heiss [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20240523121938.1058898-8-c.heiss@proxmox.com \
    --to=c.heiss@proxmox.com \
    --cc=pve-devel@lists.proxmox.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
Service provided by Proxmox Server Solutions GmbH | Privacy | Legal