# Differences between algorithms, ciphers, primitives and functionalities

Working in security, I often hear terms such as algorithms, ciphers, primitives and functionalities. but as cryptography is not my field, they seem to be used interchangeably.

What are the differences between all those terms, and what nuances do they bring?

• Jun 26, 2022 at 18:25

Those terms definitely have some differences!

Algorithm has the same meaning in cryptography as elsewhere in computer science: a process or set of rules to be followed in calculations or other problem-solving operations, especially by a computer. This is the most general term on your list.

A cipher is an algorithm you can use to encrypt or decrypt a message. For instance: RSA is a cipher. Not all the algorithms in cryptography are ciphers though.

A primitive is something low-level that will be used in cryptographic algorithms and ciphers, like Pseudo-Random Permutations or One-Way Hash Functions. They are tools to construct a crypto scheme.

Finally, I believe that functionalities are properties of your schemes, for instance perfect forward secrecy.

• Are you explaining that 'primitives' are categories? (in that case I would have tagged them 'high level', but I may be wrong, English is not my native language.) Jun 26, 2022 at 18:36
• RSA cannot encrypt. RSAES is a family of algorithms that use RSA as one step in encryption. RSASSA is a family of algorithms that use RSA for signatures. RSA is a primitive, it's used in larger algorithms to construct encryption/decryption, signature/verification and key encapsulation/decapsulation algorithms. Jun 26, 2022 at 18:52
• You can definitely see them as categories and I see why high level would make sense, but it is in comparison with "scheme" (which is higher) and "protocol", even higher. In "Guideline for Using Cryptographic Standards in the Federal Government: Cryptographic Mechanisms", you will see this definition for primitive: "A low-level cryptographic algorithm used as a basic building block for higher-level cryptographic algorithms." Jun 26, 2022 at 18:53
• Another way to describe functionalities is that it's a description of what a primitive/cipher/algorithm should do, without saying how it's done, a bit like a specification. Jun 28, 2022 at 21:37