summary refs log tree commit diff
diff options
context:
space:
mode:
authorDavid Hook <dgh@cryptoworkshop.com>2019-01-15 09:18:28 +1100
committerDavid Hook <dgh@cryptoworkshop.com>2019-01-15 09:18:28 +1100
commita4dfc8f5b5db53ac21d7ad5f5c7851429e902b54 (patch)
tree1653986a8bb339fb1837b6ee6ce1ec612cf89723
parentrefactor of PKMacBuilder (diff)
downloadBouncyCastle.NET-ed25519-a4dfc8f5b5db53ac21d7ad5f5c7851429e902b54.tar.xz
added missing interface
-rw-r--r--crypto/src/crypto/IKeyUnwrapper.cs24
1 files changed, 24 insertions, 0 deletions
diff --git a/crypto/src/crypto/IKeyUnwrapper.cs b/crypto/src/crypto/IKeyUnwrapper.cs
new file mode 100644
index 000000000..764ead2ce
--- /dev/null
+++ b/crypto/src/crypto/IKeyUnwrapper.cs
@@ -0,0 +1,24 @@
+namespace Org.BouncyCastle.Crypto
+{
+    /// <summary>
+    /// Base interface for a key unwrapper.
+    /// </summary>
+    /// <typeparam name="A">The algorithm details/parameter type for the key unwrapper.</typeparam>
+    public interface IKeyUnwrapper<out A>
+	{
+        /// <summary>
+        /// The parameter set used to configure this key unwrapper.
+        /// </summary>
+        A AlgorithmDetails { get; }
+
+        /// <summary>
+        /// Unwrap the passed in data.
+        /// </summary>
+        /// <param name="cipherText">The array containing the data to be unwrapped.</param>
+        /// <param name="offset">The offset into cipherText at which the unwrapped data starts.</param>
+        /// <param name="length">The length of the data to be unwrapped.</param>
+        /// <returns>an IBlockResult containing the unwrapped key data.</returns>
+        IBlockResult Unwrap(byte[] cipherText, int offset, int length);
+	}
+}
+