BHA-160: Constructional Design of Hash Function Based On NP-hard Problem
BHA-160: Constructional Design of Hash Function Based On NP-hard Problem
BHA-160: Constructional Design of Hash Function Based On NP-hard Problem
Problem
Ali AlShahrani
Faculty of Computing Studies, Arab Open University
Riyadh, Saudi Arabia
a.shahrani@arabou.edu.sa
Any braid can be decomposed as a product of The proposed structure consists of an initial vector
simple braids. One type of simple braid is the Artin called initial braid and blocks of text (represented as
generators σi, these have a single crossing between i-th braid) to be the inputted into the hash function. We
and (i+1)-st strand as in Figure 1. Besides, the n-braid apply a braid operation (multiplication) on the braid
group Bn can be presented by the Artin generators groups to concentrate two different braids that then
produce a completely new unique braid. By repeating
σ1,…, σn -1 and relations σi σj = σj σi for |i - j| > 1 and
this process, we will get a random braid that cannot be
σi σj σi = σj σi σj for |i - j| = 1. traced back to get the initial value of the hash function.
n This condition is able to fulfill the important properties
of a secured hash function.
i+1
i The architecture of the proposed hash function will
follow the steps as follows as in Figure 2:
1
Generate a random braid BIV, to be as an initial
vector of the hash function.
Figure 1: Artin generator σi Generate another braid by manipulating the bits
from the text blocks.
Many operations can be applied on two braids. For Do a multiplication operation on the initial braid
example, braid multiplication is the most used and the braid generated beforehand.
operation over braid. The multiplication of braids a by Repeat the iteration until the last text blocks.
b where (a,b) є Bn results in a new braid which is
unique. The process of ascertaining the original two
braids (braid a and b), given the resulted braid after the Plain Text Blocks p0 P1 P2 .... pn
multiplication, is known to be a hard-problem. The
multiplication of two braids is carried out by placing F(x)
the braid a under the braid b. Di Bi
Braid Braid
As we previously mentioned, many cryptosystem's B
IV Groups Groups
primitives have been built on braid group theory, but
no hash function based on braid has been implemented
yet. However, many researches are done in the braid
group, and most of these researches showed the Braid Multiplication
strength of this theory against attacks.
Di+1
3. The Proposed BHA-160 Hash Function
Reduce Braid to 160-bit
Architecture
Currently, most of the existing hash functions are
focusing on scrambling and shifting of the bits in the Message
input blocks. With the intention of randomizing the bits Digest Di+1
of the input blocks, usually they are using the exclusive
OR (XOR) operation, and some additions in their
implementation. For our work, we proposed a new
approach of hash function architecture. In our opinion, Figure 2: Architecture of the proposed hash
hash function is not just scrambling or shifting the bits, function (BHA-160)
3.1 BHA-160 Processing Stages Stage 2: Convert to Artin Generators, σ
This process is the beginning of mapping the input into
The algorithm of BHA-160, takes as input a a braid representation. As we can see in Figure 5, B[i]
message of arbitrary length thereby producing as represents the braid index or, in other words, the
output, a 160-bit message digest. The input is location where crossing occurs in braid groups.
processed in 192 bit blocks. The combined braid, as
illustrated in the architecture, is achieved from the By mapping the input into a braid representation, we
braid multiplication and will be processed in order to need to calculate the value of the crossing. With the
reduce the size of the digest to 160-bit. The overall number of strands n = 128, we convert the first 7 bits
processing of a message to produce a digest consists of from binary to positive decimal. The 8th bit indicates
four stages. The stages are: the sign of the number that can be negative or positive.
The positive sign indicates a positive crossing and the
Stage 1: Append Padding Bits negative sign indicates a negative crossing.
The 192 bit block is padded to make sure the length is
always in the desired length. The padding process is 8 bit
done by taking the first 8-bit block from the input ....
message (which is less from the desired length) and
then cyclic left shift the bits of the block by 2 bits as B=1 B=2 B=3 B=12
shown in Figure 3.
192-bit
Stage 3: Braids Multiplication
Figure 3: Padding process for BHA-160 The inputs of this stage are two braids with 12-byte
size (12 crossing). The first braid represents the plain
After appending the padding bits, we will XOR every text block after the transformation (transforming the
8-bit in 192-bit block. The result of this stage is 12 8- plain text block to Artin representation Bi. The second
bit blocks. Figure 4 presents the input setup of BHA- braid will be the initial value of BIV that is represented
160 in the first stage. as braids Di with 24-byte (BIV that will be used for one
time only, in the beginning of this stage). However, the
192 BIT initial value of Di will be reduced to 12-byte size to be
8 bit
multiplied by Bi. The braid reduction occurs by
.... XORing D2i-1 and D2i for all values of 1≤ i ≤12.
Therefore, the resulted braid, after reduction, is a 12-
byte braid size which is represented as D'i.
Xor Xor
Di
σD1 σD2 .... σD24
12 - Crossing 12 - Crossing
Di+1
Figure 8: Performance of standard hash functions
σD1 σD2 σD3 .............. σD24 against BHA-160
.
0 – 24 Crossing
The performance results shows that our BHA-160 is in
the middle class, where it could outperform MD2 and it
X: Braid Multiplication is almost close to the performance of other functions.
However, we realised that a tradeoff between security
Figure 6: Braid Multiplication and performance exists. Manipulating braids includes
performing complex mathematical operations. In
addition, the key size of BHA-160 is relatively larger
than the key size used by most of the hash functions
192 - BIT
included in this study.
σD1 σD2 σD3 .............. σD20 .... σD24
. ..
5. Discussion
160 - BIT Two important parameters should be discussed, they
σD1 σD2 σD3 .............. σD20 are: the security and the performance of the proposed
. architecture. In terms of security, the 8-bit block of
plain text will produce an Artin representation of a
Figure 7: Message Digest Reduction string in a 128 braid (27=128), which is big enough for
security purposes, since the advice size for braid to be
used for cryptography purposes is an 80 strings braid.
Mathematically, the braid theory proved to be secure
since it is virtually impossible to retrieve one of the [6] Y. Cui, J. Jiang, Z. Lai, Z. Hu, W. Wong, Supervised
multiplied braids after a braid multiplication operation. discrete discriminant hashing for image retrieval,
Pattern Recognition, Volume 78, June 2018, Pages 79-
90.
In terms of performance, a block of 192-bit will require
one braid multiplication of two 128-strings braids, and [7] W. Stalling, Cryptography and network security:
24 XOR operations. This can be considered a minimal
operation that needs to be applied on every 192-bit principles and practices, Prentice Hall 2nd ED. 1999.
plain text block.
[8] N. Rogier and Chauvaud, The Compression Function of
MD2 is not Collision Free, Selected Areas in
Cryptography '95, 1995.
5. Conclusions
In conclusion, there is a presentation of less security [9] F. Muller, The MD2 Hash Function is not One-Way,
level by bit-operations harsh functions that have a Advanced in Cryptology-Asia Crypt '2004, 2004.
dependence on bits of XORing message as compared to
[10] V. Klima, Finding MD5 Collision-a toy for a Notebook,
the hash functions that are based on problems that are Cryptology ePrint Archive, Report 2005/075.
NP-hard. However, the proposed hash function is
proved that it is secure due to the fact that it is based on [11] X. Wang, D. Feng, X. Lai, H. Yu, Collision for Hash
mathematical problems that are hard to solve hence it is Functions MD4, MD5, HAVAL-128 and RIPEMD,
worth to be evaluated. The proposed hash function’s Cryptology ePrint Archive, Report 2004/199.
internal stages tend to depend on the mapping of bits
into braid representation as well as multiplying the [12] X. Wang, Y. Yin, H. Yu, Finding Collisions in the Full
resulted braids to each other. These stages form the SHA-1, Crypto 2005.
core of the entire architecture of the hash function that
is proposed and they could be able to fulfill the
significant features of a hash function that is secured.
References
[1] P. Hofmann and B. Schneier, Attacks on
Cryptographic Hashes in Internet Protocols,
facs.org. November 2005. [Online]. Available:
http://www.faqs.org/rfcs/rfc4270.html [Accessed
March 20, 2018]