You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@sling.apache.org by ol...@apache.org on 2019/12/12 16:51:08 UTC
[sling-org-apache-sling-commons-crypto] 01/03: SLING-8883 Provide a
simple crypto API
This is an automated email from the ASF dual-hosted git repository.
olli pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/sling-org-apache-sling-commons-crypto.git
commit 0d680ccfae43e24c5c9cb5bde108a10de4fab0b4
Author: Oliver Lietz <ol...@apache.org>
AuthorDate: Thu Dec 12 16:11:29 2019 +0100
SLING-8883 Provide a simple crypto API
* Rename parameter in method decrypt from message to ciphertext
* Add some javadoc
---
.../java/org/apache/sling/commons/crypto/CryptoService.java | 10 +++++++++-
1 file changed, 9 insertions(+), 1 deletion(-)
diff --git a/src/main/java/org/apache/sling/commons/crypto/CryptoService.java b/src/main/java/org/apache/sling/commons/crypto/CryptoService.java
index 017e2ef..aa4b424 100644
--- a/src/main/java/org/apache/sling/commons/crypto/CryptoService.java
+++ b/src/main/java/org/apache/sling/commons/crypto/CryptoService.java
@@ -24,8 +24,16 @@ import org.osgi.annotation.versioning.ProviderType;
@ProviderType
public interface CryptoService {
+ /**
+ * @param message The message to encrypt
+ * @return The encrypted message, the ciphertext
+ */
@NotNull String encrypt(@NotNull final String message);
- @NotNull String decrypt(@NotNull final String message);
+ /**
+ * @param ciphertext The encrypted message, the ciphertext to decrypt
+ * @return The decrypted message
+ */
+ @NotNull String decrypt(@NotNull final String ciphertext);
}