mirror of
https://github.com/pgpainless/pgpainless.git
synced 2025-09-10 18:59:39 +02:00
Kotlin conversion: UnprotectedKeysProtector
This commit is contained in:
parent
a8bc929f24
commit
b125333c89
2 changed files with 15 additions and 33 deletions
|
@ -0,0 +1,15 @@
|
|||
// SPDX-FileCopyrightText: 2023 Paul Schaub <vanitasvitae@fsfe.org>
|
||||
//
|
||||
// SPDX-License-Identifier: Apache-2.0
|
||||
package org.pgpainless.key.protection
|
||||
|
||||
/**
|
||||
* Implementation of the [SecretKeyRingProtector] which assumes that all handled keys are not password protected.
|
||||
*/
|
||||
class UnprotectedKeysProtector : SecretKeyRingProtector {
|
||||
override fun hasPassphraseFor(keyId: Long) = true
|
||||
|
||||
override fun getDecryptor(keyId: Long) = null
|
||||
|
||||
override fun getEncryptor(keyId: Long) = null
|
||||
}
|
Loading…
Add table
Add a link
Reference in a new issue