sharlatan pushed a commit to branch go-team
in repository guix.
commit c13b1ec7aadad40ac2b5c8b4e650b55b969abff5
Author: Sharlatan Hellseher <[email protected]>
AuthorDate: Mon Feb 24 17:41:06 2025 +0000
gnu: Add go-github-com-miekg-pkcs11.
* gnu/packages/golang-crypto.scm: Add (gnu packages security-token).
(go-github-com-miekg-pkcs11): New variable.
Change-Id: I4319b03008e145f0a4a0a175df14d10f9cb56879
---
gnu/packages/golang-crypto.scm | 35 +++++++++++++++++++++++++++++++++++
1 file changed, 35 insertions(+)
diff --git a/gnu/packages/golang-crypto.scm b/gnu/packages/golang-crypto.scm
index a8f76aa04a..07b528e7a2 100644
--- a/gnu/packages/golang-crypto.scm
+++ b/gnu/packages/golang-crypto.scm
@@ -60,6 +60,7 @@
#:use-module (gnu packages golang-web)
#:use-module (gnu packages golang-xyz)
#:use-module (gnu packages password-utils)
+ #:use-module (gnu packages security-token)
#:use-module (gnu packages specifications))
;;; Commentary:
@@ -1576,6 +1577,40 @@ library's internal ChaCha20 package.")
the Go standard library's TLS 1.3 implementation.")
(license license:bsd-3)))
+(define-public go-github-com-miekg-pkcs11
+ (package
+ (name "go-github-com-miekg-pkcs11")
+ (version "1.1.1")
+ (source
+ (origin
+ (method git-fetch)
+ (uri (git-reference
+ (url "https://github.com/miekg/pkcs11")
+ (commit (string-append "v" version))))
+ (file-name (git-file-name name version))
+ (sha256
+ (base32 "1w403kmqxf8w25aap4901nrm7wj0wf95lrwwv1nvdjnwi8jjgapz"))))
+ (build-system go-build-system)
+ (arguments
+ (list
+ #:import-path "github.com/miekg/pkcs11"
+ #:phases
+ #~(modify-phases %standard-phases
+ (add-before 'check 'pre-check
+ (lambda _
+ (setenv "SOFTHSM_LIB" (format #f "~a/lib/softhsm/libsofthsm2.so"
+ #$(this-package-native-input
"softhsm"))))))))
+ (native-inputs
+ (list softhsm))
+ (home-page "https://github.com/miekg/pkcs11")
+ (synopsis "PKCS #11 wrapper for Golang")
+ (description
+ "This package provides an implementation of the
+@url{https://en.wikipedia.org/wiki/PKCS_11, PKCS#11} API. It wraps the
+library closely, but uses Go idiom where it makes sense. It has been tested
+with SoftHSM.")
+ (license license:bsd-3)))
+
(define-public go-github-com-minio-blake2b-simd
(let ((commit "3f5f724cb5b182a5c278d6d3d55b40e7f8c2efb4")
(revision "0"))