rspec/rules/S5542/rationale.adoc

30 lines
1.3 KiB
Plaintext

Encryption algorithms are essential for protecting sensitive information and
ensuring secure communications in a variety of domains. They are used for
several important reasons:
* Confidentiality, privacy, and intellectual property protection
* Security during transmission or on storage devices
* Data integrity, general trust, and authentication
When selecting encryption algorithms, tools, or combinations, you should also
consider two things:
1. No encryption is unbreakable.
2. The strength of an encryption algorithm is usually measured by the effort
required to crack it within a reasonable time frame.
For these reasons, as soon as cryptography is included in a project, it is
important to choose encryption algorithms that are considered strong and secure
by the cryptography community.
For AES, the weakest mode is ECB (Electronic Codebook). Repeated blocks of data
are encrypted to the same value, making them easy to identify and reducing the
difficulty of recovering the original cleartext.
Unauthenticated modes such as CBC (Cipher Block Chaining) may be used but are
prone to attacks that manipulate the ciphertext. They must be used with caution.
For RSA, the weakest algorithms are either using it without padding or
using the PKCS1v1.5 padding scheme.