mirror of
https://github.com/maxgoedjen/secretive.git
synced 2026-09-09 18:09:04 +02:00
Fix keyType constants being Data instead of String, specify in update calls (#830)
This commit is contained in:
@@ -67,6 +67,7 @@ import SecretKit
|
||||
public func update(certificate: Certificate) throws {
|
||||
let updateQuery = KeychainDictionary([
|
||||
kSecClass: Constants.keyClass,
|
||||
kSecAttrService: Constants.keyTag,
|
||||
kSecAttrAccount: certificate.id,
|
||||
])
|
||||
|
||||
@@ -134,7 +135,7 @@ extension CertificateStore {
|
||||
|
||||
enum Constants {
|
||||
static let keyClass = kSecClassGenericPassword as String
|
||||
static let keyTag = Data("com.maxgoedjen.certificatestore.opensshcertificate".utf8)
|
||||
static let keyTag = "com.maxgoedjen.certificatestore.opensshcertificate"
|
||||
static let notificationToken = UUID().uuidString
|
||||
}
|
||||
|
||||
|
||||
@@ -183,6 +183,7 @@ extension SecureEnclave {
|
||||
let attributes = try JSONEncoder().encode(attributes)
|
||||
let updatedAttributes = KeychainDictionary([
|
||||
kSecAttrLabel: name,
|
||||
kSecAttrService: Constants.keyTag,
|
||||
kSecAttrGeneric: attributes,
|
||||
])
|
||||
|
||||
@@ -294,7 +295,7 @@ extension SecureEnclave.Store {
|
||||
|
||||
enum Constants {
|
||||
static let keyClass = kSecClassGenericPassword as String
|
||||
static let keyTag = Data("com.maxgoedjen.secretive.secureenclave.key".utf8)
|
||||
static let keyTag = "com.maxgoedjen.secretive.secureenclave.key"
|
||||
static let notificationToken = UUID().uuidString
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user