A method of encrypting a number of plaintext bits based on a bit-length parameter, comprising: obtaining a bit-length parameter indicating a number of plaintext bits to encrypt; obtaining a set of plaintext bits, wherein a length of the set of plaintext bits is equal to the bit-length parameter; obtaining a set of key bits, wherein a length of the set of key bits is equal to the bit-length parameter; and performing multiple arithmetic-reorder-substitution rounds using the set of plaintext bits and the set of key bits, wherein each arithmetic-reorder-substitution round comprises: performing an integer arithmetic operation on round key bits and round input bits, wherein: the set of plaintext bits are used as round input bits for a first arithmetic-reorder-substitution round and each subsequent arithmetic-reorder-substitution round uses the output of the previous arithmetic reorder-substitution round as its round input bits; and the set of key bits are used as round key bits for the first round and round key bits for each subsequent arithmetic-reorder-substitution are derived from the set of key bits; performing a bit-level reordering operation on an output of the integer arithmetic operation; and performing a substitution box operation on an output of the bit-level reordering operation; and performing an XOR operation on an output of the multiple arithmetic-reorder-substitution rounds and a set of round key bits based on the set of key bits to yield a ciphertext. obtaining a bit-length parameter indicating a number of plaintext bits to encrypt; obtaining a set of plaintext bits, wherein a length of the set of plaintext bits is equal to the bit-length parameter; obtaining a set of key bits, wherein a length of the set of key bits is equal to the bit-length parameter; and performing multiple arithmetic-reorder-substitution rounds using the set of plaintext bits and the set of key bits, wherein each arithmetic-reorder-substitution round comprises: performing an integer arithmetic operation on round key bits and round input bits, wherein: the set of plaintext bits are used as round input bits for a first arithmetic-reorder-substitution round and each subsequent arithmetic-reorder-substitution round uses the output of the previous arithmetic reorder-substitution round as its round input bits; and the set of key bits are used as round key bits for the first round and round key bits for each subsequent arithmetic-reorder-substitution are derived from the set of key bits; performing a bit-level reordering operation on an output of the integer arithmetic operation; and performing a substitution box operation on an output of the bit-level reordering operation; and performing an XOR operation on an output of the multiple arithmetic-reorder-substitution rounds and a set of round key bits based on the set of key bits to yield a ciphertext. the set of plaintext bits are used as round input bits for a first arithmetic-reorder-substitution round and each subsequent arithmetic-reorder-substitution round uses the output of the previous arithmetic reorder-substitution round as its round input bits; and the set of key bits are used as round key bits for the first round and round key bits for each subsequent arithmetic-reorder-substitution are derived from the set of key bits; performing a bit-level reordering operation on an output of the integer arithmetic operation; and performing a substitution box operation on an output of the bit-level reordering operation; and performing an XOR operation on an output of the multiple arithmetic-reorder-substitution rounds and a set of round key bits based on the set of key bits to yield a ciphertext. <EOS>