public inbox for pve-devel@lists.proxmox.com
 help / color / mirror / Atom feed
From: "Fabian Grünbichler" <f.gruenbichler@proxmox.com>
To: pve-devel@lists.proxmox.com
Subject: [PATCH pmg-api 7/8] utils: drop now unused get_hwaddress
Date: Thu,  7 May 2026 13:59:28 +0200	[thread overview]
Message-ID: <20260507115957.1497272-8-f.gruenbichler@proxmox.com> (raw)
In-Reply-To: <20260507115957.1497272-1-f.gruenbichler@proxmox.com>

server ID generation is now only implemented in the proxmox-subscription crate.

Signed-off-by: Fabian Grünbichler <f.gruenbichler@proxmox.com>
---
 src/PMG/Utils.pm | 23 -----------------------
 1 file changed, 23 deletions(-)

diff --git a/src/PMG/Utils.pm b/src/PMG/Utils.pm
index b9c645e..8fd97fc 100644
--- a/src/PMG/Utils.pm
+++ b/src/PMG/Utils.pm
@@ -1482,29 +1482,6 @@ sub scan_journal_for_rbl_rejects {
     return ($rbl_count, $pregreet_count);
 }
 
-my $hwaddress;
-my $hwaddress_st = {};
-
-sub get_hwaddress {
-    my $fn = '/etc/ssh/ssh_host_rsa_key.pub';
-    my $st = stat($fn);
-
-    if (
-        defined($hwaddress)
-        && $hwaddress_st->{mtime} == $st->mtime
-        && $hwaddress_st->{ino} == $st->ino
-        && $hwaddress_st->{dev} == $st->dev
-    ) {
-        return $hwaddress;
-    }
-
-    my $sshkey = PVE::Tools::file_get_contents($fn);
-    $hwaddress = uc(Digest::MD5::md5_hex($sshkey));
-    $hwaddress_st->@{ 'mtime', 'ino', 'dev' } = ($st->mtime, $st->ino, $st->dev);
-
-    return $hwaddress;
-}
-
 my $default_locale = "en_US.UTF-8 UTF-8";
 
 sub cond_add_default_locale {
-- 
2.47.3





  parent reply	other threads:[~2026-05-07 12:01 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-05-07 11:59 [PATCH manager/pmg-api/proxmox{,-backup,-perl-rs,-offline-mirror} 0/8] adapt subscription handling to alternative server IDs Fabian Grünbichler
2026-05-07 11:59 ` [PATCH proxmox 1/8] proxmox-subscription: add new machine-id based serverid Fabian Grünbichler
2026-05-07 11:59 ` [PATCH proxmox-backup 2/8] subscription: adapt to multiple server ID variants Fabian Grünbichler
2026-05-07 11:59 ` [PATCH proxmox-perl-rs 3/8] common: subscription: expose server ID candidates Fabian Grünbichler
2026-05-07 11:59 ` [PATCH manager 4/8] subscription: adapt to multiple server ID variants Fabian Grünbichler
2026-05-07 11:59 ` [PATCH manager 5/8] api2tools: remove unused get_hwaddress Fabian Grünbichler
2026-05-07 11:59 ` [PATCH pmg-api 6/8] subscription: adapt to multiple server ID variants Fabian Grünbichler
2026-05-07 11:59 ` Fabian Grünbichler [this message]
2026-05-07 11:59 ` [PATCH proxmox-offline-mirror 8/8] subscription handling: adapt to multiple server ID candidates Fabian Grünbichler

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=20260507115957.1497272-8-f.gruenbichler@proxmox.com \
    --to=f.gruenbichler@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