Expand description
cryptocol crate provides libraries for cryptography.
This crate is optimized for Little-endian CPUs because Little-Endian CPUs are far more popular than Big-endian CPUs. For the information about Endianness (including Little-endian and Big-endian) Read more.
§Big-endian issue
This crate is just experimental for Big-endian CPUs. So, you are not encouraged to use this crate for Big-endian CPUs for serious purpose. Only use this crate for Big-endian CPUs with your own full responsibility.
§Road Map for Version 1.0
This crate Cryptocol is planned to provide the following functionalities. The checked items have already been implemented including documentation at least 95%. The unchecked items have been implemented including documentation less than 95% or have not yet even been started to implement.
§Small Numbers: meaningful as itself, and also foundations mainly for Big Numbers as well as for other modules
-
Unions for primitive data types and their implementation, and the
implementation of trait SmallUInt for the Unions —
ShortUnion
,IntUnion
,LongUnion
,LongerUnion
,SizeUnion
,SharedValues
, andSharedArrays
-
Trait SmallUInt, its implementation for primitive data types, and the
implementation of it for the Unions —
SmallUInt
§Big Numbers: meaningful as itself and also the foundation for Asymmetric-Key Algorithms
-
Fixed Sized Big Unsigned Integer Operation — You can find most of
the methods you need for big integer calculation at
BigUInt
. -
Auxiliary Fixed Sized Big Unsigned Integer Operations — If you don’t
find what you need at
BigUInt
, you may find it atBigUInt_More
. You can’t find modular-related methods atBigUInt
, but you may find them atBigUInt_Modular
. You can’t find panic-free-releated methods atBigUInt
, but you may find it atBigUInt_Panic_Free
. You can’t find prime number-related methods atBigUInt
, you may find it atBigUInt_Prime
.
§Hash Algorithms
-
MD4 hash algorithms based on 128 bits
— Includes MD4 and its expanded versions.
MD4_Generic
-
MD5 hash algorithms based on 128 bits
— Includes MD5 and its expanded versions.
MD5_Generic
-
SHA-1 hash algorithms based on 160 bits
— Includes SHA-1, SHA-0, and their expanded versions.
SHA1_Generic
-
SHA-2 hash algorithms based on 256 bits
— Includes SHA-256, SHA-224, and their expanded versions.
SHA2_256_Generic
-
SHA-2 hash algorithms based on 512 bits
— Includes SHA-512, SHA-384, SHA-512/256, and their expanded versions.
SHA2_512_Generic
-
SHA-2 hash algorithms based on 512/t bits
— Includes 512/256, SHA-512/224, and their expanded versions.
SHA2_512_t_Generic
-
SHA-3 and Keccak hash algorithms based on 8/16/32/64 bits
— Includes SHA3-224, SHA3-256, SHA3-384, SHA3-512, SHAKE 128, SHAKE 256, cSHAKE-128, cSHAKE-256, Keccak family and their expanded versions.
Keccak_Generic
§Symmetric-key Algorithms for the Encryption/Decryption of digital data
-
DES symmetric-key encryption/decryption algorithm and the traits and its implementations of Operation modes and padding bits for DES_Generic
— Includes DES and its expanded versions, and ECB, CBC, PCBC, CFB, OFB, and CTR modes, and padding bits
according to PKCS#7 and ISO 7816-4.
DES_Generic
ECB_PKCS7
,ECB_ISO
,CBC_PKCS7
,CBC_ISO
,PCBC_PKCS7
,PCBC_ISO
,CFB
,OFB
, andCTR
. -
AES symmetric-key encryption/decryption algorithm and the trait implementations of Operation modes and padding bits for AES_Generic
— Includes AES and its expanded versions, and ECB, CBC, PCBC, CFB, OFB, and CTR modes, and padding bits
according to PKCS#7 and ISO 7816-4.
AES_Generic
,ECB_PKCS7
,ECB_ISO
,CBC_PKCS7
,CBC_ISO
,PCBC_PKCS7
,PCBC_ISO
,CFB
,OFB
, andCTR
. - Bluefish symmetric-key encryption/decryption algorithm
-
BigCryptor64 and BigCryptor128 combinations of symmetric-key encryption/decryption algorithms and the trait implementations of Operation modes and padding bits for BigCryptor64 and BigCryptor128
— Includes 2DES, 3DES, 4DES, etc., 2AES, 3AES, 4AES, etc., and their expanded versions, and ECB, CBC, PCBC, CFB, OFB, and CTR modes, and padding bits according to PKCS#7 and ISO 7816-4.
NAES
,ECB_PKCS7
,ECB_ISO
,CBC_PKCS7
,CBC_ISO
,PCBC_PKCS7
,PCBC_ISO
,CFB
,OFB
, andCTR
.
§Pseudo-Random Number Generator Algorithms
-
Pseudo-random number generator — struct
Random_Generic
and trait Random_Engine -
Pseudo-random number generator engines using hash algorithms —
Any_MD4
,Any_MD5
,Any_SHA0
,Any_SHA1
,Any_SHA2_256
,Any_SHA2_512
,Any_SHA3_256
,Any_SHA3_512
,Any_SHAKE_128
,Random_SHA2_512
.Random_SHA3_512
, andRandom_BIG_KECCAK_1024
, -
Pseudo-random number generator engines using symmetric-key encryption algorithms —
Any_DES
,
Any_TDES
,Any_AES
,Any_TAES
,Random_AES
, andRandom_TAES
. -
Pseudo-random number generator engines using simple randomization algorithm
—
Any_Num_C
§Asymmetric-Key Algorithms for the Encryption/Decryption of digital data
- RSA (Ron Rivest, Adi Shamir, Leonard Adleman)
- ECC (Elliptic Curve Cryptosystem)
When the implementation of all the above functionalitis are completed, the version number 1.0.0.0 will be given. After that whenever another functionality is added to this crate, the version number will get higher beyond 1.0.0.0. Before the version number 1.0.0.0, the maximum version number will be 0.20.x.x since there are all twenty-five functionalities listed above. So, for example, even if the version number is 0.5.0.0, it does not mean that 50% of all functionalities are implemented.
Modules§
- hash
- various cryptographic hash functions
- number
- various numbers such as small fixed-sized unsigned integers, small fixed-sized signed integers, small fixed-sized integer unions, big fixed-sized unsigned integers, big fixed-sized signed integers, and large variable-sized signed integers
- random
- various pseudo-random number generators
- symmetric
- various symmetric-key algorithms for the encryption/decryption of digital data
Macros§
- define_
utypes_ with - The macro that defines the types
U256
,U512
,U1024
,U2048
,U3072
,U4096
,U5120
,U6144
,U7168
,U8192
, andU16384
. - define_
utypes_ with_ u8 - The macro that defines the types
U256
,U512
,U1024
,U2048
,U3072
,U4096
,U5120
,U6144
,U7168
,U8192
, andU16384
based onu8
. - define_
utypes_ with_ u16 - The macro that defines the types
U256
,U512
,U1024
,U2048
,U3072
,U4096
,U5120
,U6144
,U7168
,U8192
, andU16384
based onu16
. - define_
utypes_ with_ u32 - The macro that defines the types
U256
,U512
,U1024
,U2048
,U3072
,U4096
,U5120
,U6144
,U7168
,U8192
, andU16384
based onu32
. - define_
utypes_ with_ u64 - The macro that defines the types
U256
,U512
,U1024
,U2048
,U3072
,U4096
,U5120
,U6144
,U7168
,U8192
, andU16384
based onu64
. - define_
utypes_ with_ u128 - The macro that defines the types
U256
,U512
,U1024
,U2048
,U3072
,U4096
,U5120
,U6144
,U7168
,U8192
, andU16384
based onu128
.