Next Article in Journal
A Survey on Characterizing Trees Using Domination Number
Previous Article in Journal
Lie Symmetry Group, Invariant Subspace, and Conservation Law for the Time-Fractional Derivative Nonlinear Schrödinger Equation
 
 
Font Type:
Arial Georgia Verdana
Font Size:
Aa Aa Aa
Line Spacing:
Column Width:
Background:
Article

Stochastic Fractal Search Algorithm Improved with Opposition-Based Learning for Solving the Substitution Box Design Problem

Escuela de Ingeniería Informática, Pontificia Universidad Católica de Valparaíso, Avenida Brasil 2241, Valparaíso 2362807, Chile
*
Author to whom correspondence should be addressed.
Mathematics 2022, 10(13), 2172; https://doi.org/10.3390/math10132172
Submission received: 21 April 2022 / Revised: 10 June 2022 / Accepted: 17 June 2022 / Published: 22 June 2022

Abstract

:
The main component of a cryptographic system that allows us to ensure its strength against attacks, is the substitution box. The strength of this component can be validated by various metrics, one of them being the nonlinearity. To this end, it is essential to develop a design for substitution boxes that allows us to guarantee compliance with this metric. In this work, we implemented a hybrid between the stochastic fractal search algorithm in conjunction with opposition-based learning. This design is supported by sequential model algorithm configuration for the proper parameters configuration. We obtained substitution boxes of high nonlinearity in comparison with other works based on metaheuristics and chaotic schemes. The proposed substitution box is evaluated using bijectivity, the strict avalanche criterion, nonlinearity, linear probability, differential probability and bit-independence criterion, which demonstrate the excellent performance of the proposed approach.

1. Introduction

The explosive increase in the use of communication channels through digital media, the use of automatic learning in the field of medicine, and the digitization of participatory democratic means in the exchange of goods and services are some areas in which it is strongly required that the concept of security is robustly associated. Cryptography allows us to guarantee this property. Taking into account the symmetric block cipher scheme, for example, advanced encryption standard, we observe that the main component of these ciphers is the substitution box, which allows us to incorporate the concept of confusion, obscuring the link between the secret key and cipher text [1] in our cipher system. The strength of the substitution box present in the encryption system allows us to ensure its quality. There are different metrics to analyze a substitution box: nonlinearity, strict avalanche criterion, balance, bit independent criterion, and transparency order [2], to name a few. These metrics are used to determine the weaknesses or strengths of the substitution box against cryptanalysis [3,4]. In this work, we maximize the property of nonlinearity of substitution boxes of 8 input bits and 8 output bits. Traditionally, substitution box design methods can be grouped into the following schemes: algebraic, random, chaotic and heuristic methods. Here, we use a population optimization algorithm based on fractal search, the stochastic fractal search algorithm, which is inspired by fractals to comply with the exploitation property and stochasticity to implement the exploration mechanism, allowing the algorithm to efficiently traverse the search space. This metaheuristic is integrated with opposition-based learning, whose main notion emerges from the concept of Yin-Yang, and allows us to increase the degree of exploration of the first algorithm, through the generation of opposite populations and subsequent analysis of the best solutions that are then operated by the optimization algorithm. We can increase the performance of the proposed scheme by addressing the problem of the adequate selection of parameters through the use of sequential model-based optimization for general algorithm configuration, which gives us an optimal set of parameters for the execution of stochastic fractal search. We have contrasted the execution of the hybrid algorithm with the classic version of the algorithm, showing the best performance of the hybrid proposal. Experiments show that the substitution boxes found have excellent cryptographic properties, which is compared with the results of other types of substitution box design. We evaluated the proposed substitution box based on bijectivity [5,6], nonlinearity, strict avalanche criteria, differential uniformity, linear approximation probability, justifying being a correct scheme for the generation of substitution boxes.
The organization of the work is defined as follows: the state of the art is introduced in the next section. The substitution box problem is described in Section 3. Section 4 provides an explanation of the optimization algorithm and opposition-based learning. Experimental findings are presented in Section 5. Finally, conclusions and future works can be found in Section 6.

2. State of the Art

During the last years, two research areas concerning the development of methods for the generation of substitution boxes have been strongly promoted: optimization algorithms and chaotic systems. In the set of works related to solving the substitution box design problem, we can mention the following works: [7] proposed a construction method based on a linear fractional transform, using the Box–Muller Transform, polarization decision, and central limit algorithm. The results reported good values for nonlinearity and other common metrics of security criteria. In [8], the authors reported a design combining the cuckoo search algorithm with chaotic maps. The latter was used to generate the initial population of the substitution box. Experiments showed that the substitution boxes were found to have good qualities to resist linear and differential attacks. A design that occupies the Mobius transformation was reported in [9]. The transformation was applied into random values that were generated by a nonlinear combination of chaotic tent map and sine map. The statistical analysis carried out showed good results, comparing the proposed substitution boxes with others of public knowledge, such as AES or Skipjack. In [10], the authors constructed a scheme utilizing the firefly algorithm. A discrete chaotic map fulfills the function of initializing the population. The use of the latter does not contain fixed points, which promotes the generation of chaotic sequences. The performance of this approach is checked against general criteria: bijectivity, bit-independence criteria, strict avalanche criteria, differential uniformity, linear approximation probability. The nonlinearity reaches the value of 107.5 on average. An algebraic technique for building a promising substitution box was proposed in [11]. The proposed substitution box is evaluated using standard metrics such as the bit-independent criterion, strict avalanche criterion, and nonlinearity, among others. Additionally, it was compared with another substitution box, including Skipjack, Xyi, AES, Gray, APA and Prime. The work in [12] implemented an improved one-dimensional chaotic logistic map that exhibits a strong chaotic behavior. The results were exposed through statistical and algebraic analysis. The proposed substitution box obtained an average nonlinearity of 108.13. Particle swarm optimization integrated with the chaotic Renyi map for the initial population was presented in [13]. In the experiments, various configurations for the parameters of the algorithm were considered, for example, setting the number of iterations equal to 1000. On the other hand, it was proposed an image encryption scheme that is based on the suggested substitution box. The analysis of results was carried out using the majority logic criterion and other metrics. In [14], the authors considered a design applying biometrics. In this case, characteristics of the fingerprints were used for the construction of substitution boxes. The results were compared against chaotic and biometric design schemes. The standard comparison metrics were used and, in addition, randomness, confidence interval and time consumption were also evaluated. A design that uses chaotic logistic map for the generation of dynamic key-based substitution boxes was explained in [15]. This work counteracted the repercussions of algebraic attacks. The results were analyzed based on the conventional strength metrics of a substitution box. A random-restart hill-climbing algorithm for the construction of substitution box was described in [16]. Their objective function was nonlinearity. The results showed a reduction in the construction time and also added an algorithm to optimize linear approximation probability without affecting negatively the nonlinearity and biyectivity. In [17], the authors combined sine map and logistic functions to form a new chaotic map that holds excellent dynamic and complex properties, and this design was hybridized with algebraic techniques for the construction of substitution boxes. Standard metrics, such as nonlinearity, strict avalanche criteria, and linear approximation probability, were compared to other designs. The proposed substitution box was applied to image encryption. The results were analyzed using majority logic criterion. The utilization of piecewise linear chaotic map and quantum chaos for a key-based approach was presented in [18]. The proposed substitution box was evaluated against bijectivity, nonlinearity, strict avalanche criteria, bit independence criterion, differential approximation probability, and key sensitivity. The Leaders and Followers combined with hill-climbing was presented in [19]. An objective function was implemented that considers the whole Walsh–Hadamard spectrum of substitution boxes. The experiments reported that the method is resistant to classical cryptanalysis and side-channel attacks. In [20], the authors proposed a modified firefly algorithm, that performs a random movement based on the best firefly utilizing discrete chaotic maps. The experimental results revealed that the proposed method complies with properties that guarantee the strength of a substitution box. The work described in [21] is a genetic algorithm whose operators aim to maintain bijectivity and improve the nonlinearity of the solutions. The initial population is generated through a chaotic logistic map. The results show that the solutions are balanced and comply with high nonlinearity. A composition between logistic, tent and sine map builds a new chaotic map as explained in [22]. The qualities of the system were determined using the Lyapunov exponents and entropy variation. They proposed an image encryption scheme that showed good performance in complexity and execution times and that is also resilient to types of attacks, which allows it to be used in private network security. In [23], the authors presented the use of the leaders and followers algorithm in conjunction with hill climbing. This hybrid is also improved by means of machine learning, whose purpose is to determine the optimal moment of transition between exploration and exploitation. The scheme used an objective function that incorporates nonlinearity and transparency order in a weighted way. The results of this scheme are competitive with the results presented in several publications and leave room for possible improvements, for example, the use of deep learning, the formation of more complex objective functions using more than two properties. An improved version of the work established in [24] was proposed in [25]. This work proposed the cryptanalysis of an image encryption scheme, in which the formation of the substitution boxes was performed using a combination of chaotic maps, involving Lorenz [26] and Rossler [27]. The proposal in [28] utilized a heuristic evolution strategy based on affine transformation and permutation process. The experiments were evaluated according to standard criteria, fixed point analysis, and computational time. The proposed substitution box was tested to encrypt images, and the suitability was assessed using a majority logic criterion. It was concluded that the proposal is a feasible candidate to be applied in the context of image security. The introduction of a Markov model was given in [29]. This approach consists in stacking bitwise operations and solving them with reinforcement learning. This approach generated results are comparable to the state of the art. On the other hand, it included improvements to the SKINNY S-box implementation. The training of the model took about a month of computation. Results are expressed in terms of differential uniformity, linearity and number of nonlinear operations. The method in [30] to build substitution boxes uses particle swarm optimization, with random population. The proposed substitution box in combination with the chaotic Rossler map is employed to establish security in the storage and communication of images. Standard metrics were used to demonstrate the quality of the proposed substitution boxes. The images resulting from the encryption process were analyzed based on the histogram, correlation coefficient, and entropy, among other metrics. In [31], the authors exposed a design, implementing the Tiki-Taka optimization algorithm in combination with a chaotic map selection method. Five chaotic maps are included for population generation. The selection of the map is based on a reward–penalty mechanism. Common metrics are used to evaluate the strength of the proposed substitution box, and the transparency order is also included. It was shown that, thanks to the properties of chaotic systems—ergodicity, pseudo randomness, and unpredictability—the performance of the original version of the optimization algorithm is improved. A modified Pascal’s triangle in combination with the equation of the elliptic curve was presented in [32]. The experiments demonstrate the characteristics (differential approximation probability and linear approximation probability, among others) of the proposed substitution box, which was also used to implement image encryption and noise removal. For the comparison, common substitution boxes in the literature were used, such as AES, Skipjack, Xyi, along with other works. The work in [33] implemented the cuckoo search algorithm, which was enhanced in its search capacity and convergence speed, using a discrete chaotic map for the initial population generation. The results include nonlinearity, bijectivity, the bit-independence criterion, strict avalanche criterion, differential uniformity, and linear probability. The proposed scheme generated strong substitution boxes that meet the majority of cryptographic requirements.
One of the optimization algorithms that has emerged in recent times, and that has been applied to solve various problems, is stochastic fractal search. In the original paper [34], the proposed algorithm was evaluated using classic benchmark functions. The results were compared with particle swarm optimization and artificial bee colony, among others. The set of experiments also addressed the resolution of three different engineering design problems: tension/compression of a spring, welded beam and pressure vessel. The results of these experiments were compared against different algorithms: mathematical programming, genetic algorithm, coevolutionary particle swarm optimization, nonlinear integer and discrete programming, to name a few. These first results showed that the algorithm is capable of being used in various types of problems. For example, the problem of measuring the similarity between two overlapping sets of images is known as template matching. The work in [35] used stochastic fractal search to solve this problem, comparing the experimental results with algorithms, such as artificial bee colony and imperialist competitive algorithm, among others. The results showed that the algorithm obtained a better performance in contrast to other works present in the literature. The work in [36] used stochastic fractal search to address the problem of the environmental–economic dispatch problem in power systems operations, considering factors, such as physical restrictions, pollution, and transmission losses. The results included a comparison with various optimization algorithms. For example, the genetic algorithm, gravitational search algorithm, and six other algorithms. The work confirmed the ability of the algorithm to achieve values close to the global optimum within a short time frame. Stochastic fractal search was used to address the problem of unmanned aerial vehicle path planning, finding good results in acceptable times [37]. The problem of modeling photovoltaic systems includes the estimation of parameters with the available values of voltage and current. In the work of [38], the stochastic fractal search was incorporated as a mechanism for estimating the parameters of the previously mentioned problem in order to obtain efficient models. The results demonstrated the effectiveness of the algorithm in improving the capacity of the models, showing better performance against other recently published algorithms. A solution to the permutation flowshop scheduling problem was presented in [39], using stochastic fractal search. To demonstrate the ability of the algorithm to solve this problem, several types of instances were used. The algorithm was able to find solutions close to the known optima, according to the results presented. The work presented in [40] used stochastic fractal search for the parameter estimation of the support vector regression algorithm. The latter is used in solving the bearing life prediction problem. The results obtained were consistent with those provided by other works in the literature. In the work of [41], the parameters of a control algorithm for automatic voltage regulator were estimated using stochastic fractal search. The results were compared with six other algorithms, showing an excellent ability to solve this problem. In [42], stochastic fractal search was proposed as a solution to the problem of visual tracking. The algorithm exhibited satisfactory results in difficult instances of this problem in comparison with other state-of-the-art algorithms. Another important aspect worth mentioning is the fact that stochastic fractal search was subject to modifications in some works. For example, the work in [43], for the first time, used the stochastic fractal search algorithm to solve complex multi-objective optimization problems. The incorporation of the differential evolution as a stochastic fractal search operator was proposed in [44]. The work in [45] used the chaotic maps of Chebyshev and Gauss/Mouse as modifiers of the equations in the diffusion and the first update processes. The focus on [46] incorporated Lévy flight and internal feedback information in the stochastic fractal search.
In the work carried out by [47], a series of integrations between optimization algorithms and machine learning techniques were exposed. One type of integration is where machine learning techniques act as low-level components in metaheuristics. There is a component category that performs the generation of initial solutions. In this type of component, several examples of the use of opposition-based learning hybridized with metaheuristics can be found in the literature. These works solve benchmark-type problems [48,49,50,51,52]; high-dimensional continuous optimization problems [53]; the reactive power dispatch problem [54]; symbolic regression [55]; and load frequency control [56]. The central idea in the use of opposition-based learning is that it provides complementary solutions to improve the convergence of the search process, increase search space coverage and increase the diversity of the population. To the best of our knowledge, there are no works in the literature that perform the integration between metaheuristics and opposition-based learning to solve the substitution box design problem.
Works that use stochastic fractal search and opposition-based learning allow us to affirm that the mentioned techniques are good candidates to present an integration between both. Our contribution is to present a new hybrid scheme, composed of the stochastic fractal search algorithm and opposition-based learning to solve the substitution box design problem, which presents excellent results in terms of performance. We also incorporated a tool that allows us to find an optimal algorithm configuration and thus establish a high quality of the experiments performed, achieving consistency in the performance of the algorithm. The resulting implementation, in conjunction with the formality of the experiments, led to obtaining competitive results in terms of nonlinearity of the substitution boxes found.

3. Substitution Box

Substitution boxes are the main component of an encryption system that allows us to guarantee its strength. Ensuring that a substitution box has a high nonlinearity [57], we can assert that the cryptographic system of which it is part will be resistant to various types of attack [58].
A substitution box S is defined as a mapping function, that takes n input bits and returns m output bits, S : Z 2 n Z 2 m . It can be implemented as a lookup table or it can be dynamically generated. Next, we present the mathematical basis of the substitution boxes and the definition of the objective function to use.

Preliminaries

  • Let f be a Boolean function defined as f : F 2 n F 2 m , where n is the input bits and m. We can mention several ways to represent a Boolean function: algebraic form, truth table, and hexadecimal form, to name a few.
  • The representation in its algebraic normal form is built on the basis of the operations of sum and product of the input variables. We can write f in the following way:
    f ( x 1 , , x n ) = a 0 a 1 x 1 a n x n a n 1 , n x n 1 x n a 1 , 2 n x 1 x 2 x n
    where a 0 , a 1 , a 1 , 2 , , n { 0 , 1 } * .
  • The decimal representation of a Boolean function is based on a vector of length 2 n , where n indicates the number of input bits. The elements of the vector are in decimal form.
  • The number of 1 present in the truth table representation of a Boolean function is defined as the Hamming weight.
  • If the elements present in the decimal representation are unique or the hamming weight is equal to 2 n 1 , the Boolean function satisfies the balance property.
  • The Hamming distance is calculated by counting all the differences in the output bits of two Boolean functions.
  • The maximum of the degrees of the monomials of the algebraic normal form is called the algebraic degree.
  • If the algebraic degree of a Boolean function is equal to one, the function is defined as an affine Boolean function. An affine Boolean function can be described as
    f a f f ( x 1 , x 2 , , x n ) = a n x n + a n 1 x n 1 + + a 2 x 2 + a 1 x 1 + a 0
    where a i { 0 , 1 } . When a 0 is zero, we get a linear Boolean function. A Boolean function of n input bits, can have 2 n + 1 affine Boolean functions.
  • The Walsh–Hadamard transformation F ^ f ( w ) of Boolean function f with n variables is defined as:
    F ^ f ( w ) = x B n f ^ ( x ) ( 1 ) < w , x > = x B n ( 1 ) f ( x ) < w , x > = x B n f ^ ( x ) l ^ w ( x )
    where f ^ is the polarity representation of a Boolean function, l ^ w ( x ) is the signed function of the linear function l w ( x ) = < w , x > , F ^ f ( w ) 2 n , 2 n , w B n and F ^ f ( w ) is known as a spectral walsh coefficient. The real-value vector of all 2 n spectral coefficients is referred to as the Walsh–Hadamard transformation spectrum. The maximum absolute value, taken by F ^ f , is given by: W H T m a x ( f ) = m a x ( w B n ) | F ^ f ( w ) | .
  • The Hadamard matrix, is a binary matrix of dimensions 2 n × 2 n . For the elements W ( i , j ) , where i represents the rows and j represents the columns,
    H 2 n = H 2 n 1 H 2 n 1 H 2 n 1 H 2 n 1
    where 2 n N .
  • In cryptography, one of the critical properties of a Boolean function is the nonlinearity. The nonlinearity is the minimum distance between a Boolean function and any affine Boolean function. A low nonlinearity value implies that a cryptographic algorithm may be weak against linear or differential attacks. The distance between a Boolean function f ( x ) and any affine Boolean function a ( x ) = a 0 + l ( x ) , can be calculated as follows:
    d ( f ( x ) , a ( x ) ) = w t ( f ( x ) a ( x ) ) = x = 0 2 n 1 ( f ( x ) a ( x ) ) = 1 2 x = 0 2 n 1 ( 1 ( 1 ) f ( x ) + a ( x ) ) = 2 n 1 1 2 ( 1 ) a 0 x = 0 2 n 1 ( 1 ) f ( x ) + l ( x )
    taking l ( x ) = w , x = w 1 x 1 w n x n , where w is the coefficient vector; we can rewrite the above result as
    d ( f ( x ) , a ( x ) ) = 2 n 1 1 2 ( 1 ) a 0 x = 0 2 n 1 ( 1 ) f ( x ) + w , x = 2 n 1 1 2 ( 1 ) a 0 S ( f ) ( w )
    where S ( f ) ( w ) is the Walsh–Hadamard transform of f ( x ) on w, w , x is the representation of all affine boolean functions and a 0 { 0 , 1 } . Finally, the nonlinearity is defined as follows:
    n l ( f ) = 2 n 1 1 2 m a x | S ( f ) ( w ) |
    The objective function to be used by the optimization algorithm is the nonlinearity.

4. Stochastic Fractal Search Algorithm with Opposition Based Learning

4.1. Stochastic Fractal Search Algorithm

The fractal concept helps us to describe the shape of an object, which, regardless of the level of visual distance we have from it, appears geometrically similar to the whole. Random fractals can be generated by various iterative methods, for example, Gaussian walks, trajectories of Brownian motion, and diffusion limited aggregation, among others.
In nature, there is a phenomenon known as dielectric breakdown (for example, lightning bolts and frost crystals), whose properties show that the branches that are generated can be modeled as stochastic patterns and also include fractal properties [59]. This phenomenon can be seen as a process of diffusion limited aggregation (DLA. Figure 1). The steps in the DLA process can be described as follows: consider an initial particle, then other particles are randomly generated around the initial particle by random walk, this process is repeated until a cluster is formed. This cluster will have a fractal shape.
The fractal search algorithm is inspired by this phenomenon. It takes the concept of diffusion limited aggregation as a search algorithm.
In [34], two metaheuristic algorithms are presented. The first one, fractal search, which is based on the properties of fractals, aims to use a few iterations to achieve a good level of efficiency and rapid convergence with adequate performance, but there are edges that allow improvements, for example, the high number of parameters that must be properly configured and the lack of communication between the solutions during the search process. For these reasons, a second algorithm was developed called stochastic fractal search, whose operators can be distinguished between two groups: diffusion and update.
The objective of the diffusion operator is exploitation, where each solution is diffused, in order to find a global minimum and also prevent the algorithm from stagnating at a local optimum. This operator generates new solutions by Gaussian walk from a particular solution. Figure 2 represents this operator. To keep the number of solutions constant, only the best solution generated by this process will be considered, and it will be compared with the original solution of the diffusion process, and in the event that the new solution has a better value of the objective function, the original solution will be replaced.
In this process, there are two parameters. Walk is a random number between 0 and 1 uniformly distributed, and establishes which formula will be used to generate a new solution, which can be (8) or (9). The second parameter involved is the maximum number of solutions that are generated from a solution. We call this parameter the maximum number of diffusion.
G W 1 = G a u s s i a n ( μ B P , σ ) + ( ϵ × B P ϵ × P i )
G W 2 = G a u s s i a n ( μ P , σ )
where ϵ and ϵ are random numbers uniformly distributed in the [ 0 , 1 ] interval. B P and P i are the best solution and the ith solution in the population, respectively. μ P is exactly equal to P i . The parameter μ B P is exactly equal to the best solution, B P . σ is the standard deviation which is calculated as follows:
σ = l o g ( j ) j × ( P i B P )
where j is the current iteration. To the extent that iterations increase, the term l o g ( j ) j is oriented to reduce the size of the Gaussian jumps.
The update operator is oriented so that the solutions modify their position based on the position of other solutions on the population. This operator allows us to comply with the quality of exploitation, which is determined by random walks using Gaussian distribution. Suppose we have a combinatorial optimization problem whose solutions can be represented by a vector of d dimensions, and the domain of the solutions is in the interval [ L B , U B ] .
P j = L B + ϵ × ( U B L B )
where LB is the lower bound, and UB is the upper bound of the domain. ϵ is a uniformly distributed random number defined in the range [ 0 , 1 ] . After generating the initial population and calculating the objective function of each of them, we proceed to identify the best solution B P . In the diffusion process, all the solutions have made a move either around their current position or the position of the best solution. The two updating processes are aimed at improving the exploratory capacity of the algorithm. The first update procedure is performed on each index of the solution vector, and the second procedure is aimed at modifying a solution based on other solutions of the population. This leads to an improvement in the exploration capacity, which increases the diversity of the population. The first task of the updating processes is to order the solutions based on a ranking formed by the value of the objective function (nonlinearity). Then, to each solution a probability is assigned, calculated by
P r o b i = r a n k ( P i ) N
where r a n k ( P i ) is the ranking of the solution P i in relation to the population and N is the total number of solutions. Then for each solution P i , the jth index is updated if the following condition is met:
P r o b i < ξ
where ξ is a random number, with uniform distribution, in the range [ 0 , 1 ] . To update the respective index, the following formula is applied:
P i ( j ) = P r ( j ) ϵ × ( P t ( j ) P i ( j ) )
where P i ( j ) is the new modified index of solution P i , P r ( j ) is j index of a random solution r, ϵ is a random number from an uniform distribution in the interval [ 0 , 1 ] , P t ( j ) is the j index of a random solution t, and P i ( j ) is the current j index of the analyzed solution.
At the beginning of the second update process, the solutions are ordered following the same logic as in the first process. Then, if the condition P r o b i < κ is satisfied for a solution P i , where κ is a uniform distributed random number in the interval [ 0 , 1 ] , the following equations can be applied:
P i = P i ϵ ^ × ( P t B P ) κ 0.5 P i + ϵ ^ × ( P t P r ) κ > 0.5
where P i is the modified solution, P t and P r are randomly selected solutions from the population, and ϵ ^ are random numbers generated by the Gaussian normal distribution. The modified solution P i will replace the original solution P i only in the case of improvement of the value of the target function.
In this work, we investigated the generation of the initial population under five schemes:
  • Using a combination of chaotic maps. The first map is the logistic map (16) which uses the parameter μ = [ 3.57 , 4.0 ] . This map will iterate 1000 times, and the output is used as input for the tent map (17). The tent map uses b = [ 0.5 , 1.5 ] and also iterates over 1000 times. The result of this operation allows us to form a vector of 256 unique elements in the interval [ 0 , 255 ] that will be our representation of a Boolean function.
    x n + 1 = μ x n ( 1 x n )
    x n + 1 = x n b , for x n [ 0 , b ] ( 1 x n ) 1 b , for x n [ b , 1 ]
  • Standard C++ functions for generating random numbers.
  • Generation of random solutions together with the respective opposite solutions and extracting half of each set, whose solutions present the best fitness to form the initial population.
  • Generation of random solutions in conjunction with the respective opposite solutions, combining this set and using the best solutions.
  • Generating random solutions in conjunction with the respective opposite solutions, combining this set, selecting a subset of good solutions, and extracting a random set from the latter to form the initial population.
The last scheme was the one that presented the best results in terms of average nonlinearity of the initial population, so this scheme is used by the hybrid algorithm.

4.2. Opposition Based Learning

The idea of opposition [60] has been present since ancient times. We can see this in different cultures, such as China, using the concept of Yin-Yang. This notion of the opposite is considered to generate a learning scheme which allows us to describe the perceived reality. These ideas are taken to the field of computing and are concretized with the definition of opposite number [61] as follows:
Let x ( x 1 , x 2 , , x d ) be a point in with d dimensions and x [ a i , b i ] , i = 1 , 2 , 3 , , d . The opposite of x is defined by x ˘ ( x 1 ˘ , x 2 ˘ , , x d ˘ ) as follows:
x ˘ = a i + b i x i
A two-dimensional representation can be seen in Figure 3. Opposition-based learning follows the reasoning that it is beneficial to explore the search space using random directions in conjunction with the opposite directions simultaneously, which could raise the probability of finding promising regions of the search space.

4.3. Integration

The use of opposition-based learning in our scheme occurs at the moment when the last operator of the optimization algorithm ends. After completing the update II process, the opposite population of the current population is generated. These two sets are combined and ordered according to the fitness function. Then, the best m solutions are selected for the next iteration. m is a parameter of stochastic fractal search that determines the number of solutions to be generated. Algorithm 1 shows the pseudocode of the hybrid implementation. At Lines 1–2, the parameters of stochastic fractal search are set, and the initial population is generated. At Line 3 begins the main iteration. Lines 4–6 apply the diffusion process for each solution in the population. Lines 7–9 execute the first update process for all the population, and then Lines 10–12 run the second update process for all solutions. Line 13 represents the process of opposition-based learning. In Figure 4, we can see a diagram of the proposed implementation. In the upper part of the image, we can see the mechanism for generating the initial population that will be processed by the optimization algorithm. The three operators of the optimization algorithm that operate sequentially are also expressed. Upon completion of the last operator, we determine whether the termination criteria have been met. If it is negative, the generation process of the opposite population is continued to later determine the solutions that will be incorporated again into the optimization process.
Algorithm 1 SFS OBL.
1:
Set parameters stochastic fractal search
2:
Generate initial population
3:
while ( i M a x i m u m I t e r a t i o n ) do
4:
   for  i = 1 : m (m number of solutions) do
5:
     Diffusion( s o l u t i o n i )
6:
   end for
7:
   for  i = 1 : m (m number of solutions) do
8:
     Update1( s o l u t i o n i )
9:
   end for
10:
   for  i = 1 : m (m number of solutions) do
11:
     Update1( s o l u t i o n i )
12:
   end for
13:
   Generate Oppossite Population and selectmbest solutions
14:
end while

4.4. Sequential Model-Based Algorithm Configuration

The no-free-lunch theorem [62] states that no optimization algorithm is capable of tackling all existing problems optimally. This theorem can be applied to the parameter configuration of optimization algorithms. For this reason, the present work deals with this problem using a tool to establish an adequate parameter configuration of the stochastic fractal search algorithm. The selected tool is sequential model-based optimization for general algorithm configuration, SMAC [63], whose strength lies in the use of Bayesian optimization and racing mechanisms. SMAC is an iterative procedure that uses a surrogate model to describe the way in which the optimization problem is related to the parameters of the algorithm and analyzes its performance. The substitute model is used to propose a good parameter setting. Table 1 shows the four parameters delivered to SMAC for the search for an optimal configuration. The objective of the execution was set at the value of the objective function (the alternative is to use the execution time of the optimization algorithm), and a budget of 30 SMAC executions were established. The optimal configuration of the stochastic fractal search is shown in Table 2.

5. Results

A substitution box must meet certain requirements to be classified as a strong substitution box. In the literature, a set of metrics is considered standard to evaluate the competence of the proposed substitution box. The metrics used are bijectivity, algebraic degree, the strict avalanche criterion, nonlinearity, the bit-independence criterion, differential approximation probability and linear approximation probability. The present scheme operates with 8-bit input and output substitution boxes. The implementation of this work was done in C++ with the support of a library [64], which allowed analyzing the results of the algorithm. The experiments were executed using a dual Intel Xeon E5-2690 with 32 GB of RAM running on Debian 10. The source code of this project is available in [65]. Regarding the results, we can mention that the proposed substitution box achieves a better nonlinearity compared to some works proposed in the literature. All generated substitution boxes satisfy the property of bijectivity. The resistance to algebraic attacks is demonstrated based on the value of algebraic immunity equal to 4. The strict avalanche criterion of the proposed substitution box is 0.5005 , whose difference is insignificant with respect to the ideal value. The resistance to differential attacks of the proposed substitution box is based on a low value of differential approximation probability equal to 0.046 . Regarding the tolerance of the proposed substitution box against linear attacks: this condition is fulfilled based on a low value of linear approximation probability equal to 0.125 .

5.1. Nonlinearity

The proposed S-box an its inverse representation are shown in Table 3 and Table 4 respectively. In Table 5 shows a comparison of different works using the average nonlinearity of the S-box coordinates only [66].

5.2. Bijectivity

The bijectivity of a substitution box is guaranteed when the following equation is satisfied:
w t i = 1 n a i f i = 2 n 1
where w t is the Hamming weight, a i { 0 , 1 } and ( a 1 , a 2 , , a n ) ( 0 , 0 , , 0 ) . All the results obtained comply with this property.

5.3. Algebraic Degree

The resistance to various types of attack of a substitution box can be analyzed in terms of the algebraic degree [94,95]. The proposed substitution box has an algebraic degree of d e g ( f ) = 7 , which is a good value for this metric. On the other hand, the criterion of algebraic immunity, which indicates the resistance to algebraic attacks [96,97] of the proposed substitution box, has a value of 4, which is the maximum value for a substitution box of the dimensions used.

5.4. Strict Avalanche Criterion

Webster and Tavares [98] introduced the definition of the strict avalanche criterion. This concept aims at the idea that if we change a single input bit, the output bits would change with a probability of 1 2 . The proposed substitution box is analyzed using the dependency matrix shown in Table 6. The strict avalanche criterion of the proposed substitution box is 0.5005 , which has a very low deviation from 0.5 , the ideal value. This allows us to establish that the proposed substitution box exhibits a good avalanche effect and meets the aforementioned criteria.

5.5. Bit-Independent Criterion

The bit-independent criterion, BIC, specifies that when any single input bit i is changed, the output bits j and k should change independently for all i, j and k. In Table 7, the results of this metric are presented.

5.6. Differential Approximation Probability

An S-box, having differential uniformity, establishes a unique correspondence between an input differential Δ x to an output differential Δ y . A low value of maximum differential approximation probability determines that the substitution box is immune against differential cryptanalysis. The differential uniformity of a substitution box is measured with differential approximation probability (DAP), which can be described as
D A P ( Δ x Δ y ) = # { x X | S ( x ) S ( x Δ x ) = y } 2 m
where X is the collection of all input values, and 2 m is the number of elements. The maximum D A P for the proposed S-box is 0.046 . The low value of this property confirms that the proposed substitution box is tolerant against differential attacks. Table 8 shows comparative results with other works.

5.7. Linear Approximation Probability

The maximum value of the imbalance of an event can be expressed with linear approximation probability LP. Two masks are applied to the parity of the input and output bits: Γ x , Γ y , respectively. In the work [4], the definition of L P is described by
L P = max Γ x , Γ y 0 | # { x X x · Γ x = S ( x ) · Γ y } 2 n 1 2 |
where X is the set of all possible inputs, and 2 n is the number of elements. A small value of this property confirms that the proposed substitution box is resistant to linear attacks. The maximum value of LP for our proposed S-box is 0.125 , and a comparison is shown in Table 9.

5.8. Comparison without Opposition Based Learning

Using the same parameters provided by SMAC, we carried out the execution of experiments, considering only the optimization algorithm.
We consider an effective operator as the one that has managed to find a better solution in a given iteration. The optimization algorithm is composed of three movements: diffusion, update I and update II. These three movements are represented in Figure 5. We observe the number of times an operator manages to find an improved solution in the respective iteration. We can see that the diffusion operator in the SFS version achieves a higher percentage of effectiveness in relation to the total number of operations performed in that version of the algorithm. In general, the update II operator has a low percentage of effectiveness in both algorithms, so it can be a study to improve in future work.
In Figure 6, we observe a comparison between the two versions of the algorithm in relation to the iterations carried out, and the best fitness found for each iteration. It can be seen that the hybrid algorithm has a better performance compared to the standard algorithm. We can attribute this behavior to the fact that the hybrid algorithm has a stronger diversification component, which allows us to explore the search space with greater efficiency. This feature ensures that the hybrid algorithm does not get caught in a local optimum.
During the execution of both algorithms, the population is stored for each iteration. With both sets, five solution clusters are generated for each one of them. Figure 7 shows the five clusters with the solutions generated by the hybrid version of the algorithm. Figure 8 displays the five clusters with the version of the algorithm that only includes SFS.
This comparison is useful to verify that the hybrid version has a better performance than the standard version. It is observed that the standard version does not generate solutions whose fitness is greater than 108. It is also established that there is a smaller number of inferior solutions in terms of fitness in the hybrid version.The SFS version generates solutions that are under the nonlinearity of 104, which does not happen in the hybrid version.

5.9. Brief Image Analysis

The proposed substitution box was used in a simple image encryption application. This consists of a substitution of the pixels of an image by the values present in the substitution box. We used four common images that can be seen in Table 10, along with the respective encryption. The proposed substitution box was compared with other well-known substitution boxes, such as AES, Camellia, Safer and Skipjack. To analyze the results, a set of metrics known as the majority logic criterion was used. This set includes entropy, correlation, contrast, energy, and homogeneity. We also included the analysis using the number of pixel change rate and the unified average changing intensity. We can observe that the performance of the proposed substitution box, in this brief analysis, is similar to that of substitution boxes known in the literature, even though in some cases, it has better attributes than the latter ones. The results in Table 11 show that the proposed substitution box is feasible to be included in the design of image encryption algorithms.
  • The randomness of the information present in the encrypted image is measured with entropy. Values close to 8 are preferable.
    E n t r o p y = i p ( x i ) l o g 2 1 p ( x i )
  • Comparing the values between neighboring pixels determines the degree of similarity between them, which is known as correlation.
    C o r r e l a t i o n = ( i μ i ) ( j μ j ) σ i σ j
  • The energy is a measure of the localized change of the image.
    E n e r g y = p ( i , j ) 2
  • Contrast is a measure of luminance that allows one object to be distinguished from another.
    C o n t r a s t = | i j | 2 p ( i , j )
  • Homogeneity determines the relationship between the elements of the gray level co-occurrence matrix with respect to its diagonal.
    H o m o g e n e i t y = p ( i , j ) 1 + | i j |
  • Number of pixel change rate are designed to test the number of changing pixels between two encrypted images.
    N P C R = i = 1 M j = 1 N d ( i , j ) M × N d ( i , j ) = 0 C 1 ( i , j ) = C 2 ( i , j ) 1 C 1 ( i , j ) C 2 ( i , j )
  • Unified average changing intensity is designed to test the number of mean intensities modified between two encrypted images.
    U A C I = 1 M × N i = 1 M j = 1 N C 1 ( i , j ) C 2 ( i , j ) 255

6. Conclusions

A strong substitution box allows us to establish a good degree of security for a symmetric block cipher. It is the only nonlinear component that contributes to the confounding property established by Shannon. For these reasons, a robust and efficient replacement box design is of vital importance.
In this work, we implemented a hybrid scheme using stochastic fractal search and opposition-based Learning, maximizing the nonlinearity property of the substitution boxes. Opposition-based learning allowed us to perform a much more comprehensive search space exploration in contrast to just using stochastic fractal search. The hybrid proposal establishes a clear improvement over the version that only uses stochastic fractal search, either in the greater quantity of good solutions found as well as in the superior quality of these. The use of sequential model-based algorithm configuration allowed us to establish a set of optimal parameters of the stochastic fractal search algorithm and carry out the execution of experiments in a standardized way.
The results obtained in this work prove to be competitive with other techniques present in the literature. Even so, there is room to incorporate improvements. For instance, using other opposition-based learning schemes, for example, quasi opposition, fitness-based opposition, reflected extended opposition, quasi-reflection, partial opposition, to name a few. Using several opposition-based learning schemes at the same time, we could establish a reward and punishment system that can identify which opposition algorithm to use at a given moment in the execution of the metaheuristic. We could also generate a parallel work scheme, where each thread or core works with a different opposition system and the resulting populations can be communicated between the different threads in order to generate an increase in the diversity of the total population and enhance the exploratory capacity of the scheme.

Author Contributions

All the authors of this work have collaborated equally in the development of this paper. All authors have read and agreed to the published version of the manuscript.

Funding

Francisco González is supported by Postgraduate Grant Pontificia Universidad Católica de Valparaso, Chile, 2021. Ricardo Soto is supported by Grant CONICYT/FONDECYT/REGULAR/1190129. Broderick Crawford is supported by Grant CONICYT/FONDECYT/REGULAR/1210810.

Institutional Review Board Statement

Not applicable.

Informed Consent Statement

Not applicable.

Data Availability Statement

Not applicable.

Conflicts of Interest

The authors declare no conflict of interest.

References

  1. Shannon, C.E. Communication theory of secrecy systems. Bell Syst. Tech. J. 1949, 28, 656–715. [Google Scholar] [CrossRef]
  2. Picek, S.; Cupic, M.; Rotim, L. A new cost function for evolution of s-boxes. Evol. Comput. 2016, 24, 695–718. [Google Scholar] [CrossRef]
  3. Biham, E.; Shamir, A.; Cryptol, J. Differential cryptanalysis of des. Like Cryptosyst. 1991, 4, 3. [Google Scholar]
  4. Matsui, M. Linear cryptanalysis method for des cipher. In Advances in Cryptology—EUROCRYPT’93; Springer: Berlin/Heidelberg, Germany, 1994; pp. 386–397. [Google Scholar]
  5. Zahid, A.H.; Arshad, M.J. An innovative design of substitution-boxes using cubic polynomial mapping. Symmetry 2019, 11, 437. [Google Scholar] [CrossRef] [Green Version]
  6. Zahid, A.H.; Arshad, M.J.; Ahmad, M. A novel construction of efficient substitution-boxes using cubic fractional transformation. Entropy 2019, 21, 245. [Google Scholar] [CrossRef] [Green Version]
  7. Khan, M.F.; Ahmed, A.; Saleem, K. A novel cryptographic substitution box design using gaussian distribution. IEEE Access 2019, 7, 15999–16007. [Google Scholar] [CrossRef]
  8. Akhtar, T.; Din, N.; Uddin, J. Substitution box design based on chaotic maps and cuckoo search algorithm. In Proceedings of the 2019 International Conference on Advanced Communication Technologies and Networking (CommNet), Rabat, Morocco, 12–14 April 2019; pp. 1–7. [Google Scholar]
  9. Jamal, S.S.; Anees, A.; Ahmad, M.; Khan, M.F.; Hussain, I. Construction of cryptographic s-boxes based on mobius transformation and chaotic tent-sine system. IEEE Access 2019, 7, 173273–173285. [Google Scholar] [CrossRef]
  10. Ahmed, H.A.; Zolkipli, M.F.; Ahmad, M. A novel efficient substitution-box design based on fire fly algorithm and discrete chaotic map. Neural Comput. Appl. 2019, 31, 7201–7210. [Google Scholar] [CrossRef]
  11. Jamal, S.S.; Shah, T. A novel algebraic technique for the construction of strong substitution box. Wirel. Pers. Commun. 2018, 99, 213–226. [Google Scholar]
  12. Ullah, A.; Javeed, A.; Shah, T. A scheme based on algebraic and chaotic structures for the construction of substitution box. Multimed. Tools Appl. 2019, 78, 32467–32484. [Google Scholar] [CrossRef]
  13. Ahmad, M.; Khaja, I.A.; Baz, A.; Alhakami, H.; Alhakami, W. Particle swarm optimization based highly nonlinear substitution-boxes generation for security applications. IEEE Access 2020, 8, 116132–116147. [Google Scholar] [CrossRef]
  14. Şengel, Ö.; Aydın, M.A.; Sertbaş, A. An efficient generation and security analysis of substitution box using fingerprint patterns. IEEE Access 2020, 8, 160158–160176. [Google Scholar] [CrossRef]
  15. Malik, M.S.M.; Ali, M.A.; Khan, M.A.; Ehatisham-Ul-Haq, M.; Shah, S.N.M.; Rehman, M.; Ahmad, W. Generation of highly nonlinear and dynamic aes substitution-boxes (s-boxes) using chaos-based rotational matrices. IEEE Access 2020, 8, 35682–35695. [Google Scholar] [CrossRef]
  16. Ibrahim, S.; Abbas, A.M. A novel optimization method for constructing cryptographically strong dynamic s-boxes. IEEE Access 2020, 8, 225004–225017. [Google Scholar] [CrossRef]
  17. Ahmad, M.; Al-Solami, E.; Alghamdi, A.M.; Yousaf, M.A. Bijective S-Boxes Method Using Improved Chaotic Map-Based Heuristic Search and Algebraic Group Structures. IEEE Access 2020, 8, 110397–110411. [Google Scholar] [CrossRef]
  18. Peng, J.; Pang, S.; Zhang, D.; Jin, S.; Feng, L.; Li, Z. S-boxes construction based on quantum chaos and pwlcm chaotic mapping. In Proceedings of the 2019 IEEE 18th International Conference on Cognitive Informatics Cognitive Computing (ICCI*CC), Milan, Italy, 23–25 July 2019; pp. 1–6. [Google Scholar]
  19. Freyre-Echevarría, A.; Martínez-Díaz, I.; Pérez, C.M.L.; Sosa-Gómez, G.; Rojas, O. Evolving nonlinear s-boxes with improved theoretical resilience to power attacks. IEEE Access 2020, 8, 202728–202737. [Google Scholar] [CrossRef]
  20. Alhadawi, H.S.; Lambić, D.; Zolkipli, M.F.; Ahmad, M. Globalized firefly algorithm and chaos for designing substitution box. J. Inf. Secur. Appl. 2020, 55, 102671. [Google Scholar] [CrossRef]
  21. Wang, Y.; Zhang, Z.; Zhang, L.Y.; Feng, J.; Gao, J.; Lei, P. A genetic algorithm for constructing bijective substitution boxes with high nonlinearity. Inf. Sci. 2020, 523, 152–166. [Google Scholar] [CrossRef]
  22. Farah, M.A.; Farah, A.; Farah, T. An image encryption scheme based on a new hybrid chaotic map and optimized substitution box. Nonlinear Dyn. 2020, 99, 3041–3064. [Google Scholar] [CrossRef]
  23. Bolufé-Röhler, A.; Tamayo-Vera, D. Machine learning based metaheuristic hybrids for s-box optimization. J. Ambient. Intell. Humaniz. Comput. 2020, 11, 5139–5152. [Google Scholar] [CrossRef]
  24. Khan, M. A novel image encryption scheme based on multiple chaotic s-boxes. Nonlinear Dyn. 2015, 82, 527–533. [Google Scholar] [CrossRef]
  25. Alanazi, A.S.; Munir, N.; Khan, M.; Asif, M.; Hussain, I. Cryptanalysis of novel image encryption scheme based on multiple chaotic substitution boxes. IEEE Access 2021, 9, 93795–93802. [Google Scholar] [CrossRef]
  26. Lorenz, E.N. Deterministic nonperiodic flow. J. Atmos. Sci. 1963, 20, 130–141. [Google Scholar] [CrossRef] [Green Version]
  27. Rössler, O.E. An equation for continuous chaos. Phys. Lett. A 1976, 57, 397–398. [Google Scholar] [CrossRef]
  28. Zahid, A.H.; Iliyasu, A.M.; Ahmad, M.; Shaban, M.M.U.; Arshad, M.J.; Alhadawi, H.S.; Abd El-Latif, A.A. A novel construction of dynamic s-box with high nonlinearity using heuristic evolution. IEEE Access 2021, 9, 67797–67812. [Google Scholar] [CrossRef]
  29. Kim, G.; Kim, H.; Heo, Y.; Jeon, Y.; Kim, J. Generating cryptographic s-boxes using the reinforcement learning. IEEE Access 2021, 9, 83092–83104. [Google Scholar] [CrossRef]
  30. Khan, L.S.; Hazzazi, M.M.; Khan, M.; Jamal, S.S. A novel image encryption based on rossler map diffusion and particle swarm optimization generated highly non-linear substitution boxes. Chin. J. Phys. 2021, 72, 558–574. [Google Scholar] [CrossRef]
  31. Zamli, K.Z.; Kader, A.; Din, F.; Alhadawi, H.S. Selective chaotic maps tiki-taka algorithm for the s-box generation and optimization. Neural Comput. Appl. 2021, 33, 16641–16658. [Google Scholar] [CrossRef]
  32. Siddiqui, N.; Naseer, A.; Ehatisham-ul-Haq, M. A novel scheme of substitution-box design based on modified pascal’s triangle and elliptic curve. Wirel. Pers. Commun. 2021, 116, 3015–3030. [Google Scholar] [CrossRef]
  33. Alhadawi, H.S.; Majid, M.A.; Lambić, D.; Ahmad, M. A novel method of s-box design based on discrete chaotic maps and cuckoo search algorithm. Multimed. Tools Appl. 2021, 80, 7333–7350. [Google Scholar] [CrossRef]
  34. Salimi, H. Stochastic fractal search: A powerful metaheuristic algorithm. Knowl.-Based Syst. 2015, 75, 1–18. [Google Scholar] [CrossRef]
  35. Luo, Q.; Zhang, S.; Zhou, Y. Stochastic fractal search algorithm for template matching with lateral inhibition. Sci. Program. 2017, 2017, 1803934. [Google Scholar] [CrossRef] [Green Version]
  36. Alomoush, M.I.; Oweis, Z.B. Environmental-economic dispatch using stochastic fractal search algorithm. Int. Trans. Electr. Energy Syst. 2018, 28, e2530. [Google Scholar] [CrossRef]
  37. Li, W.; Sun, S.; Li, J.; Hu, Y. Stochastic fractal search algorithm and its application in path planning. In Proceedings of the 2018 IEEE CSAA Guidance, Navigation and Control Conference (CGNCC), Xiamen, China, 10–12 August 2018; pp. 1–5. [Google Scholar]
  38. Rezk, H.; Babu, T.S.; Al-Dhaifallah, M.; Ziedan, H.A. A robust parameter estimation approach based on stochastic fractal search optimization algorithm applied to solar pv parameters. Energy Rep. 2021, 7, 620–640. [Google Scholar] [CrossRef]
  39. Sasmito, A.; Pratiwi, A.B. Stochastic fractal search algorithm in permutation flowshop scheduling problem. Aip Conf. Proc. 2021, 2329, 050003. [Google Scholar]
  40. Li, Y.; Huang, X.; Zhao, C.; Ding, P. Stochastic fractal search-optimized multi-support vector regression for remaining useful life prediction of bearings. J. Braz. Soc. Mech. Sci. Eng. 2021, 43, 414. [Google Scholar] [CrossRef]
  41. Çelik, E. Incorporation of stochastic fractal search algorithm into efficient design of pid controller for an automatic voltage regulator system. Neural Comput. Appl. 2018, 30, 1991–2002. [Google Scholar] [CrossRef]
  42. Charef-Khodja, D.; Toumi, A.; Medouakh, S.; Sbaa, S. A novel visual tracking method using stochastic fractal search algorithm. Signal Image Video Process. 2021, 15, 331–339. [Google Scholar] [CrossRef]
  43. Khalilpourazari, S.; Naderi, B.; Khalilpourazary, S. Multi-objective stochastic fractal search: A powerful algorithm for solving complex multi-objective optimization problems. Soft Comput. 2020, 24, 3037–3066. [Google Scholar] [CrossRef]
  44. Awad, N.H.; Ali, M.Z.; Suganthan, P.N.; Jaser, E. Differential evolution with stochastic fractal search algorithm for global numerical optimization. In Proceedings of the 2016 IEEE Congress on Evolutionary Computation (CEC), Vancouver, BC, Canada, 24–29 July 2016; pp. 3154–3161. [Google Scholar]
  45. Rahman, T.A.; Jalil, N.A.; As’Arry, A.; Ahmad, R.R. Chaos-enhanced stochastic fractal search algorithm for global optimization with application to fault diagnosis. In Materials Science and Engineering Conference Series; IOP Publishing: Bristol, UK, 2017; Volume 210, p. 012060. [Google Scholar]
  46. Zhou, C.; Sun, C.; Wang, B.; Wang, X. An improved stochastic fractal search algorithm for 3D protein structure prediction. J. Mol. Model. 2018, 24, 125. [Google Scholar] [CrossRef]
  47. Talbi, E.-G. Machine learning into metaheuristics: A survey and taxonomy. ACM Comput. Surv. 2021, 54, 1–32. [Google Scholar] [CrossRef]
  48. Ahandani, M.A. Opposition-based learning in the shuffled bidirectional differential evolution algorithm. Swarm Evol. Comput. 2016, 26, 64–85. [Google Scholar] [CrossRef]
  49. Rahnamayan, S.; Tizhoosh, H.R.; Salama, M.M. Opposition-based differential evolution. IEEE Trans. Evol. Comput. 2008, 12, 64–79. [Google Scholar] [CrossRef] [Green Version]
  50. Wang, H.; Wu, Z.; Rahnamayan, S.; Liu, Y.; Ventresca, M. Enhancing particle swarm optimization using generalized opposition-based learning. Inf. Sci. 2011, 181, 4699–4714. [Google Scholar] [CrossRef]
  51. Wang, H.; Li, H.; Liu, Y.; Li, C.; Zeng, S. Opposition-based particle swarm algorithm with cauchy mutation. In Proceedings of the 2007 IEEE Congress on Evolutionary Computation, Singapore, 25–28 September 2007; pp. 4750–4756. [Google Scholar]
  52. Si, T.; De, A.; Bhattacharjee, A.K. Particle swarm optimization with generalized opposition based learning in particle’s pbest position. In Proceedings of the 2014 International Conference on Circuits, Power and Computing Technologies [ICCPCT-2014], Nagercoil, India, 20–21 March 2014. [Google Scholar]
  53. Wang, H.; Wu, Z.; Rahnamayan, S. Enhanced opposition-based differential evolution for solving high-dimensional continuous optimization problems. Soft Comput. 2011, 15, 2127–2140. [Google Scholar] [CrossRef]
  54. Basu, M. Quasi-oppositional differential evolution for optimal reactive power dispatch. Int. J. Electr. Power Energy Syst. 2016, 78, 29–40. [Google Scholar] [CrossRef]
  55. Yazdani, S.; Shanbehzadeh, J. Balanced cartesian genetic programming via migration and opposition-based learning: Application to symbolic regression. Genet. Program. Evolvable Mach. 2015, 16, 133–150. [Google Scholar] [CrossRef]
  56. Shankar, G.; Mukherjee, V. Quasi oppositional harmony search algorithm based controller tuning for load frequency control of multi-source multi-area power system. Int. J. Electr. Power Energy Syst. 2016, 75, 289–302. [Google Scholar] [CrossRef]
  57. Carlet, C.; Dalai, D.K.; Gupta, K.C.; Maitra, S. Algebraic immunity for cryptographically significant boolean functions: Analysis and construction. IEEE Trans. Inf. Theory 2006, 52, 3105–3121. [Google Scholar] [CrossRef]
  58. Rodríguez-Henríquez, F.; Saqib, N.A.; Pérez, A.D.; Koc, C.K. Cryptographic Algorithms on Reconfigurable Hardware; Springer Science & Business Media: Berlin/Heidelberg, Germany, 2007. [Google Scholar]
  59. Niemeyer, L.; Pietronero, L.; Wiesmann, H. Fractal Dimension of Dielectric Breakdown. Phys. Rev. Lett. 1984, 52, 1033–1036. [Google Scholar] [CrossRef]
  60. Mahdavi, S.; Rahnamayan, S.; Deb, K. Opposition based learning: A literature review. Swarm Evol. Comput. 2018, 39, 1–23. [Google Scholar] [CrossRef]
  61. Tizhoosh, H.R. Opposition-based learning: A new scheme for machine intelligence. In Proceedings of the International Conference on Computational Intelligence for Modelling, Control and Automation and International Conference on Intelligent Agents, Web Technologies and Internet Commerce (CIMCA-IAWTIC’06), Vienna, Austria, 28–30 November 2005; Volume 1, pp. 695–701. [Google Scholar]
  62. Wolpert, D.H.; Macready, W.G. No free lunch theorems for optimization. IEEE Trans. Evol. Comput. 1997, 1, 67–82. [Google Scholar] [CrossRef] [Green Version]
  63. Hutter, F.; Hoos, H.H.; Leyton-Brown, K. Sequential model-based optimization for general algorithm configuration. In Learning and Intelligent Optimization, Coello, C.A.C., Ed.; Springer: Berlin/Heidelberg, Germany, 2011; pp. 507–523. [Google Scholar]
  64. Álvarez-Cubero, J.A.; Zufiria, P.J. Algorithm 959: Vbf: A library of c++ classes for vector boolean functions in cryptography. ACM Trans. Math. Softw. 2016, 42, 1–22. [Google Scholar] [CrossRef] [Green Version]
  65. Molina, F.G. Stochastic Fractal Search Algorithm improved with Opposition-Based Learning for solving the substitution box design problem. Figshare 2021. [Google Scholar] [CrossRef]
  66. Dimitrov, M.M. On the design of chaos-based s-boxes. IEEE Access 2020, 8, 117173–117181. [Google Scholar] [CrossRef]
  67. Khan, M.; Shah, T.; Batool, S.I. Construction of s-box based on chaotic boolean functions and its application in image encryption. Neural Comput. Appl. 2016, 27, 677–685. [Google Scholar] [CrossRef]
  68. Chen, G.; Chen, Y.; Liao, X. An extended method for obtaining sboxes based on three-dimensional chaotic baker maps. Chaos Solitons Fractals 2007, 31, 571–579. [Google Scholar] [CrossRef]
  69. Jakimoski, G.; Kocarev, L. Chaos and cryptography: Block encryption ciphers based on chaotic maps. IEEE Trans. Circuits Syst. I Fundam. Theory Appl. 2001, 48, 163–169. [Google Scholar] [CrossRef]
  70. Özkaynak, F.; Özer, A.B. A method for designing strong sboxes based on chaotic lorenz system. Phys. Lett. A 2010, 374, 3733–3738. [Google Scholar] [CrossRef]
  71. Asim, M.; Jeoti, V. Efficient and simple method for designing chaotic s-boxes. ETRI J. 2008, 30, 170–172. [Google Scholar] [CrossRef]
  72. Tang, G.; Liao, X. A method for designing dynamical s-boxes based on discretized chaotic map. Chaos Solitons Fractals 2005, 23, 1901–1909. [Google Scholar] [CrossRef]
  73. Khan, M.; Shah, T. A construction of novel chaos base nonlinear component of block cipher. Nonlinear Dyn. 2014, 76, 377–382. [Google Scholar] [CrossRef]
  74. Khan, M.; Shah, T. An efficient construction of substitution box with fractional chaotic system. Signal Image Video Process 2015, 9, 1335–1338. [Google Scholar] [CrossRef]
  75. Liu, G.; Yang, W.; Liu, W.; Dai, Y. Designing s-boxes based on 3-d four-wing autonomous chaotic system. Nonlinear Dyn. 2015, 82, 1867–1877. [Google Scholar] [CrossRef]
  76. Islam, F.U.; Liu, G. Designing sbox based on 4d-4wing hyperchaotic system. 3D Res. 2017, 8, 9. [Google Scholar] [CrossRef]
  77. Wang, X.; Çavuşoğlu, Ü.; Kacar, S.; Akgul, A.; Pham, V.T.; Jafari, S.; Alsaadi, F.E.; Nguyen, X.Q. S-box based image encryption application using a chaotic system without equilibrium. Appl. Sci. 2019, 9, 781. [Google Scholar] [CrossRef] [Green Version]
  78. Zengin, A.; Pehlivan, I.; Kaçar, S. A novel approach for strong s-box generation algorithm design based on chaotic scaled zhongtang system. Nonlinear Dyn. 2017, 87, 1081–1094. [Google Scholar] [CrossRef]
  79. Farah, T.; Rhouma, R.; Belghith, S. A novel method for designing s-box based on chaotic map and teaching learning-based optimization. Nonlinear Dyn. 2017, 88, 1059–1074. [Google Scholar] [CrossRef]
  80. Lambi, D. S-box design method based on improved one-dimensional discrete chaotic map. J. Inf. Telecommun. 2018, 2, 181–191. [Google Scholar] [CrossRef]
  81. Soto, R.; Crawford, B.; Molina, F.G.; Olivares, R. Human behaviour based optimization supported with self-organizing maps for solving the s-box design problem. IEEE Access 2021, 9, 84605–84618. [Google Scholar] [CrossRef]
  82. Özkaynak, F. Construction of robust substitution boxes based on chaotic systems. Neural Comput. Appl. 2019, 31, 3317–3326. [Google Scholar] [CrossRef]
  83. Lambi, D. A novel method of s-box design based on discrete chaotic map. Nonlinear Dyn. 2017, 87, 2407–2413. [Google Scholar] [CrossRef]
  84. Ye, T.; Zhimao, L. Chaotic s-box: Six-dimensional fractional lorenz duffing chaotic system and o-shaped path scrambling. Nonlinear Dyn. 2018, 94, 2115–2126. [Google Scholar] [CrossRef]
  85. Ahmad, M.; Bhatia, D.; Hassan, Y. A novel ant colony optimization based scheme for substitution box design. Procedia Comput. Sci. 2015, 57, 572–580. [Google Scholar] [CrossRef] [Green Version]
  86. Yi, L.; Tong, X.; Wang, Z.; Zhang, M.; Zhu, H.; Liu, J. A novel block encryption algorithm based on chaotic s-box for wireless sensor network. IEEE Access 2019, 7, 53079–53090. [Google Scholar] [CrossRef]
  87. Wang, K.-W.; Wong, Y.; Li, C.; Li, Y. A novel method to design sbox based on chaotic map and genetic algorithm. Phys. Lett. A 2012, 376, 827–833. [Google Scholar] [CrossRef]
  88. Zhang, X.; Zhao, Z.; Wang, J. Chaotic image encryption based on circular substitution box and key stream buffer. Signal Process. Image Commun. 2014, 29, 902–913. [Google Scholar] [CrossRef]
  89. Al Solami, E.; Ahmad, M.; Volos, C.; Doja, M.N.; Beg, M.M.S. A new hyperchaotic system-based design for efficient bijective substitution-boxes. Entropy 2018, 20, 525. [Google Scholar] [CrossRef] [Green Version]
  90. Lambi, D. A novel method of s-box design based on chaotic map and composition method. Chaos Solitons Fractals 2014, 58, 16–21. [Google Scholar] [CrossRef]
  91. Hussain, I.; Shah, T.; Gondal, M.A.; Mahmood, H. An efficient approach for the construction of lft s-boxes using chaotic logistic map. Nonlinear Dyn. 2013, 71, 133–140. [Google Scholar] [CrossRef]
  92. Hussain, I.; Shah, T.; Gondal, M.A.; Mahmood, H. Efficient method for designing chaotic s-boxes based on generalized baker’s map and tderc chaotic sequence. Nonlinear Dyn. 2013, 74, 271–275. [Google Scholar] [CrossRef]
  93. Belazi, A.; Abd El-Latif, A.A.; Diaconu, A.V.; Rhouma, R.; Belghith, S. Chaos-based partial image encryption scheme based on linear fractional and lifting wavelet transforms. Opt. Lasers Eng. 2017, 88, 37–50. [Google Scholar] [CrossRef]
  94. Boura, C.; Canteaut, A. On the influence of the algebraic degree of f-1 on the algebraic degree of gf. IEEE Trans. Inf. Theory 2013, 59, 691–702. [Google Scholar] [CrossRef]
  95. Boura, C.; Canteaut, A.; Cannière, C.D. Higher-order differential properties of keccak and luffa. In Fast Software Encryption; Springer: Berlin/Heidelberg, Germany, 2011; pp. 252–269. [Google Scholar]
  96. Courtois, N.T. Fast algebraic attacks on stream ciphers with linear feedback. In Advances in Cryptology—CRYPTO 2003; Boneh, D., Ed.; Springer: Berlin/Heidelberg, Germany, 2003; pp. 176–194. [Google Scholar]
  97. Courtois, N.T.; Meier, W. Algebraic attacks on stream ciphers with linear feedback. In Advances in Cryptology—EUROCRYPT 2003, International Conference on the Theory and Applications of Cryptographic Techniques, Warsaw, Poland, 4–8 May 2003; Springer: Berlin/Heidelberg, Germany, 2003; Volume 2656, pp. 345–359. [Google Scholar]
  98. Webster, A.F.; Tavares, S.E. On the design of s-boxes. In Advances in Cryptology—CRYPTO ’85 Proceedings; Springer: Berlin/Heidelberg, Germany, 1986; pp. 523–534. [Google Scholar]
  99. Ahmad, M.; Khan, P.M.; Ansari, M.Z. A simple and efficient key-dependent s-box design using fisher-yates shuffle technique. In Recent Trends in Computer Networks and Distributed Systems Security; Martínez Pérez, G., Thampi, S.M., Ko, R., Shu, L., Eds.; Springer: Berlin/Heidelberg, Germany, 2014; pp. 540–550. [Google Scholar]
  100. Gondal, M.A.; Raheem, A.; Hussain, I. A scheme for obtaining secure s-boxes based on chaotic baker’s map. 3D Res. 2014, 5, 17. [Google Scholar] [CrossRef]
  101. Zhang, Y.Q.; Hao, J.L.; Wang, X.Y. An efficient image encryption scheme based on s-boxes and fractional-order differential logistic map. IEEE Access 2020, 8, 54175–54188. [Google Scholar] [CrossRef]
  102. Bin Faheem, Z.; Ali, A.; Khan, M.A.; Ul-Haq, M.E.; Ahmad, W. Highly dispersive substitution box (s-box) design using chaos. ETRI J. 2020, 42, 619–632. [Google Scholar] [CrossRef] [Green Version]
  103. Hussain, S.; Jamal, S.S.; Shah, T.; Hussain, I. A power associative loop structure for the construction of non-linear components of block cipher. IEEE Access 2020, 8, 123492–123506. [Google Scholar] [CrossRef]
  104. El-Latif, A.; Ahmed, A.; Abd-El-Atty, B.; Amin, M.; Iliyasu, A.M. Quantum-inspired cascaded discrete-time quantum walks with induced chaotic dynamics and cryptographic applications. Sci. Rep. 2020, 10, 1930. [Google Scholar] [CrossRef]
  105. Yong, W.; Peng, L. An improved method to obtaining s-box based on chaos and genetic algorithm. HKIE Trans. 2012, 19, 53–58. [Google Scholar] [CrossRef]
  106. Ahmad, M.; Doja, M.N.; Beg, M.M. Abc optimization based construction of strong substitution-boxes. Wirel. Pers. Commun. 2018, 101, 1715–1729. [Google Scholar] [CrossRef]
  107. Zhang, T.; Chen, C.P.; Chen, L.; Xu, X.; Hu, B. Design of highly nonlinear substitution boxes based on i-ching operators. IEEE Trans. Cybern. 2018, 48, 3349–3358. [Google Scholar] [CrossRef] [PubMed]
  108. Alzaidi, A.A.; Ahmad, M.; Ahmed, H.S.; Solami, E.A. Sine-cosine optimization-based bijective substitution-boxes construction using enhanced dynamics of chaotic map. Complexity 2018, 2018, 9389065. [Google Scholar] [CrossRef]
Figure 1. Fractal example using DLA.
Figure 1. Fractal example using DLA.
Mathematics 10 02172 g001
Figure 2. Diffusion operator.
Figure 2. Diffusion operator.
Mathematics 10 02172 g002
Figure 3. Two-dimensional opposition.
Figure 3. Two-dimensional opposition.
Mathematics 10 02172 g003
Figure 4. Stochastic fractal search with opposition-based learning.
Figure 4. Stochastic fractal search with opposition-based learning.
Mathematics 10 02172 g004
Figure 5. Effective operators.
Figure 5. Effective operators.
Mathematics 10 02172 g005
Figure 6. Fitness per iteration.
Figure 6. Fitness per iteration.
Mathematics 10 02172 g006
Figure 7. SFS OBL clusters of solutions.
Figure 7. SFS OBL clusters of solutions.
Mathematics 10 02172 g007
Figure 8. SFS clusters of solutions.
Figure 8. SFS clusters of solutions.
Mathematics 10 02172 g008
Table 1. Scenario delivered to SMAC for execution.
Table 1. Scenario delivered to SMAC for execution.
ParameterRangeDefault
iterations[100, 400]150
number population[10, 50]25
walk[0.1, 1.0]0.3
max number diffusion[1, 5]1
Table 2. Results of SMAC execution.
Table 2. Results of SMAC execution.
ParameterValue
iterations183
number population36
walk0.583946
max number diffusion5
Table 3. Proposed S-box.
Table 3. Proposed S-box.
1397252466245893517020311112811525324126
12428139435134200112210142114837248205228
856515130219252382049680872321362342152
132167495325419720812184178226386811013042
182150186104989448815619016216525023315624
2013414071227631292924054251196189339361
816679173172138158230239212249123169120183113
1250214179237194145105322020922216017615959
137622135122318110821824740992425216869107
321021887818416358974100710975675791
1611620631149193021615368664734460
22229144153177198471751251712062212352441823
122114146202551118019177116119103106141217
23170832243919946211271412462258821545142
1915411812714310120714715795187164126908276
23618511710721339213115525519213524319517417
Table 4. Inverse S-box.
Table 4. Inverse S-box.
1672054612032016315496151243197112025169
16125519022416226176191793715216178735164
1449381717028592121372066319174222214182
70501131311405189196721581501271759512985
172334157601422098324417315215623920014798
417123821056321714222062371592469469233
40168138153229145203671192041431341556110
23111193122012422262021095519210716184236227
1186622474824521251441281011882217223228
1781181942312716565344717922524878232102126
12416074149235759749141108818510099254183
1251805711519813364110148241662341469273199
2501661172539153181213228019593930186230
541222421510513011422116820713536121187123132
21121958843117710320843774518824011638104
8814139252189521813629106769021352249
Table 5. Experimental Results.
Table 5. Experimental Results.
MethodMin NLMax NLACNV
[24,67]84106100.0
[68]100106103.0
[69]98108103.2
[70]100106103.2
[71]96108103.5
[72]101108103.8
[73]100106104.0
[74]100108104.75
[75]104108105.7
[76]102108106.0
[77]106108106.0
[78]104110106.2
[79]104110106.5
[80]106108106.5
[81]102110106.5
[82,83]106108106.7
[84]104108106.7
[85]106110107.0
[10]106108107.5
[86]106110107.75
[87]108108108.0
[88]104110108.0
[89]106110108.5
[90]108112109.0
This Work106112109.25
[91,92,93]112112112.0
[66]112112112.0
Table 6. Dependency matrix for avalanche effect.
Table 6. Dependency matrix for avalanche effect.
0.50000.42190.51560.46880.48440.45310.54690.4531
0.48440.50000.48440.56250.46880.53130.53130.4531
0.48440.53130.48440.48440.54690.53130.50000.4531
0.45310.45310.46880.57810.48440.53130.54690.5156
0.48440.46880.51560.46880.48440.56250.43750.5156
0.50000.50000.54690.50000.50000.46880.56250.4844
0.50000.50000.50000.57810.45310.50000.46880.4688
0.53130.51560.57810.51560.48440.50000.46880.5625
Table 7. Bit-independent criterion.
Table 7. Bit-independent criterion.
0104104104104108100106
104010210298104102100
1041020102106106106106
104102102010096106108
104981061000108106106
108104106961080104104
1001021061061061040102
1061001061081061041020
Table 8. Comparison of max differential probability of some S-boxes.
Table 8. Comparison of max differential probability of some S-boxes.
S-BoxDAP
This work0.046
[85]0.039
[69]0.046
[68]0.046
[71]0.039
[72]0.054
[70]0.039
[74]0.046
[99]0.046
[100]0.046
[13]0.031
[101]0.047
[102]0.039
[103]0.031
[104]0.055
[91]0.015
[92]0.015
[93]0.031
[88]0.046
[87]0.039
[79]0.039
[76]0.039
[75]0.039
[84]0.039
Table 9. Comparison of linear approximation probability of some S-boxes.
Table 9. Comparison of linear approximation probability of some S-boxes.
S-BoxLP
This work0.125
[90]0.093
[83]0.132
[80]0.132
[73]0.132
[11]0.132
[105]0.140
[106]0.125
[10]0.125
[107]0.132
[108]0.125
[13]0.132
[101]0.148
[102]0.137
[103]0.113
[104]0.132
[91]0.062
[92]0.142
[93]0.102
[88]0.139
[87]0.140
[79]0.117
[84]0.132
Table 10. Original image and encrypted versions using different substitution boxes.
Table 10. Original image and encrypted versions using different substitution boxes.
ImageProposedAESCamelliaSaferSkipjack
Mathematics 10 02172 i001 Mathematics 10 02172 i002 Mathematics 10 02172 i003 Mathematics 10 02172 i004 Mathematics 10 02172 i005 Mathematics 10 02172 i006
Mathematics 10 02172 i007 Mathematics 10 02172 i008 Mathematics 10 02172 i009 Mathematics 10 02172 i010 Mathematics 10 02172 i011 Mathematics 10 02172 i012
Mathematics 10 02172 i013 Mathematics 10 02172 i014 Mathematics 10 02172 i015 Mathematics 10 02172 i016 Mathematics 10 02172 i017 Mathematics 10 02172 i018
Mathematics 10 02172 i019 Mathematics 10 02172 i020 Mathematics 10 02172 i021 Mathematics 10 02172 i022 Mathematics 10 02172 i023 Mathematics 10 02172 i024
Table 11. Image analysis.
Table 11. Image analysis.
SboxImageEntropyCorrelationContrastHomogeneityEnergyNPCRUACI
Proposedcameraman7.89630.075614.39050.03040.00520.99570.3509
house7.80230.300837.73560.07980.00840.99440.3257
lena7.92330.211625.52240.09900.02120.99460.3089
baboon7.91070.124231.34740.04120.00550.99490.3009
Aescameraman7.86040.047514.16640.03090.00530.99820.3343
house7.79120.264240.30500.07940.00860.99820.3301
lena7.92890.202329.06300.10380.02220.99790.2956
baboon7.91080.077632.64600.04080.00540.99840.3039
Camelliacameraman7.87340.044012.35710.03130.00520.99480.2968
house7.82840.149536.76440.07820.00830.99800.3209
lena7.90140.168727.52300.09860.02140.99830.2754
baboon7.90590.077728.83190.04060.00560.99780.2715
Safercameraman7.86860.099212.23880.03170.00530.99590.3177
house7.76470.310832.54080.07670.00820.98780.3494
lena7.93380.192726.04480.09990.02160.99540.3185
baboon7.89830.154127.19820.04140.00540.99190.3018
Skipjackcameraman7.86240.05909.69590.03320.00550.99760.3309
house7.74180.236937.45160.08220.00900.99610.3553
lena7.91860.166023.10280.10380.02190.99460.2955
baboon7.90460.117127.85790.04380.00570.99440.2995
Publisher’s Note: MDPI stays neutral with regard to jurisdictional claims in published maps and institutional affiliations.

Share and Cite

MDPI and ACS Style

Gonzalez, F.; Soto, R.; Crawford, B. Stochastic Fractal Search Algorithm Improved with Opposition-Based Learning for Solving the Substitution Box Design Problem. Mathematics 2022, 10, 2172. https://doi.org/10.3390/math10132172

AMA Style

Gonzalez F, Soto R, Crawford B. Stochastic Fractal Search Algorithm Improved with Opposition-Based Learning for Solving the Substitution Box Design Problem. Mathematics. 2022; 10(13):2172. https://doi.org/10.3390/math10132172

Chicago/Turabian Style

Gonzalez, Francisco, Ricardo Soto, and Broderick Crawford. 2022. "Stochastic Fractal Search Algorithm Improved with Opposition-Based Learning for Solving the Substitution Box Design Problem" Mathematics 10, no. 13: 2172. https://doi.org/10.3390/math10132172

Note that from the first issue of 2016, this journal uses article numbers instead of page numbers. See further details here.

Article Metrics

Back to TopTop