split cert and key location and allow key lookup on tpm

This commit is contained in:
pascal
2026-09-22 17:04:50 +02:00
parent d04aef6f14
commit 7fbde60b7c
17 changed files with 604 additions and 139 deletions
-8
View File
@@ -3,7 +3,6 @@
package pkcs11
import (
"encoding/binary"
"errors"
"fmt"
"runtime"
@@ -327,10 +326,3 @@ func first(attrs []attribute) *attribute {
}
return &attrs[0]
}
// ULong encodes an integer attribute value the way the module reads a CK_ULONG.
func ULong(v uint) []byte {
buf := make([]byte, unsafe.Sizeof(ulong(0)))
binary.NativeEndian.PutUint64(buf, uint64(v))
return buf
}