From dc33d983ff64238904d0c52fbf2327cd2ae27ce1 Mon Sep 17 00:00:00 2001 From: Arjan H Date: Sun, 2 Feb 2025 19:56:37 +0100 Subject: [PATCH] Workaround for building standalone GUI for arm64 --- gui/hsm.go | 2 ++ gui/hsm_arm64.go | 34 ++++++++++++++++++++++++++++++++++ 2 files changed, 36 insertions(+) create mode 100644 gui/hsm_arm64.go diff --git a/gui/hsm.go b/gui/hsm.go index 4e3e799..acc1f3f 100644 --- a/gui/hsm.go +++ b/gui/hsm.go @@ -1,3 +1,5 @@ +//go:build amd64 + package main import ( diff --git a/gui/hsm_arm64.go b/gui/hsm_arm64.go new file mode 100644 index 0000000..5494159 --- /dev/null +++ b/gui/hsm_arm64.go @@ -0,0 +1,34 @@ +//go:build arm64 + +package main + +import "crypto" + +const CERT_FILES_PATH = "/opt/boulder/labca/certs/webpki/" + +type HSMConfig struct { + Module string + UserPIN string + SOPIN string + SlotID string + Label string +} + +func (cfg *HSMConfig) Initialize(ca_type string, seqnr string) { +} + +func (cfg *HSMConfig) CreateSlot() error { + return nil +} + +func (cfg *HSMConfig) GetPrivateKey() ([]byte, error) { + return nil, nil +} + +func (cfg *HSMConfig) ClearAll() error { + return nil +} + +func (cfg *HSMConfig) ImportKeyCert(keyFile, certFile string) (crypto.PublicKey, error) { + return nil, nil +}