Skip to content

Commit

Permalink
cipher: fix documentation for decrypt traits
Browse files Browse the repository at this point in the history
  • Loading branch information
newpavlov authored Jun 5, 2024
1 parent d15d165 commit 46e9bb5
Showing 1 changed file with 8 additions and 8 deletions.
16 changes: 8 additions & 8 deletions cipher/src/block.rs
Original file line number Diff line number Diff line change
Expand Up @@ -240,7 +240,7 @@ pub trait BlockCipherDecrypt: BlockSizeUser {
.map(|blocks| self.decrypt_with_backend(BlocksCtx { blocks }))
}

/// Decrypt input and unpad it. Returns resulting ciphertext slice.
/// Decrypt input and unpad it. Returns resulting plaintext slice.
///
/// Returns [`UnpadError`] if padding is malformed or if input length is
/// not multiple of `Self::BlockSize`.
Expand All @@ -258,7 +258,7 @@ pub trait BlockCipherDecrypt: BlockSizeUser {
P::unpad_blocks(blocks.into_out())
}

/// Decrypt input and unpad it in-place. Returns resulting ciphertext slice.
/// Decrypt input and unpad it in-place. Returns resulting plaintext slice.
///
/// Returns [`UnpadError`] if padding is malformed or if input length is
/// not multiple of `Self::BlockSize`.
Expand All @@ -272,7 +272,7 @@ pub trait BlockCipherDecrypt: BlockSizeUser {
}

/// Decrypt input and unpad it buffer-to-buffer. Returns resulting
/// ciphertext slice.
/// plaintext slice.
///
/// Returns [`UnpadError`] if padding is malformed or if input length is
/// not multiple of `Self::BlockSize`.
Expand All @@ -293,7 +293,7 @@ pub trait BlockCipherDecrypt: BlockSizeUser {
}

/// Decrypt input and unpad it in a newly allocated Vec. Returns resulting
/// ciphertext Vec.
/// plaintext `Vec`.
///
/// Returns [`UnpadError`] if padding is malformed or if input length is
/// not multiple of `Self::BlockSize`.
Expand Down Expand Up @@ -481,7 +481,7 @@ pub trait BlockModeDecrypt: BlockSizeUser + Sized {
.map(|blocks| self.decrypt_with_backend(BlocksCtx { blocks }))
}

/// Decrypt input and unpad it. Returns resulting ciphertext slice.
/// Decrypt input and unpad it. Returns resulting plaintext slice.
///
/// Returns [`UnpadError`] if padding is malformed or if input length is
/// not multiple of `Self::BlockSize`.
Expand All @@ -499,7 +499,7 @@ pub trait BlockModeDecrypt: BlockSizeUser + Sized {
P::unpad_blocks(blocks.into_out())
}

/// Decrypt input and unpad it in-place. Returns resulting ciphertext slice.
/// Decrypt input and unpad it in-place. Returns resulting plaintext slice.
///
/// Returns [`UnpadError`] if padding is malformed or if input length is
/// not multiple of `Self::BlockSize`.
Expand All @@ -513,7 +513,7 @@ pub trait BlockModeDecrypt: BlockSizeUser + Sized {
}

/// Decrypt input and unpad it buffer-to-buffer. Returns resulting
/// ciphertext slice.
/// plaintext slice.
///
/// Returns [`UnpadError`] if padding is malformed or if input length is
/// not multiple of `Self::BlockSize`.
Expand All @@ -534,7 +534,7 @@ pub trait BlockModeDecrypt: BlockSizeUser + Sized {
}

/// Decrypt input and unpad it in a newly allocated Vec. Returns resulting
/// ciphertext Vec.
/// plaintext `Vec`.
///
/// Returns [`UnpadError`] if padding is malformed or if input length is
/// not multiple of `Self::BlockSize`.
Expand Down

0 comments on commit 46e9bb5

Please sign in to comment.