Reputation-Based Spectrum Sensing Strategy Selection in Cognitive Radio Ad Hoc Networks

Spectrum sensing plays an essential role in the detection of unused spectrum whole in cognitive radio networks, including cooperative spectrum sensing (CSS) and independent spectrum sensing. In cognitive radio ad hoc networks (CRAHNs), CSS enhances the sensing performance of cognitive nodes by exploring the spectrum partial homogeneity and fully utilizing the knowledge of neighboring nodes, e.g., sensing results and topological information. However, CSS may also open a door for malicious nodes, i.e., spectrum sensing data falsification (SSDF) attackers, which report fake sensing results to deteriorate the performance of CSS. Generally, the performance of CSS has an inverse relationship with the fraction of SSDF attackers. On the contrary, independent spectrum sensing is robust to SSDF attacks. Therefore, it is desirable to choose a proper sensing strategy between independent sensing and collaborative sensing for CRAHNs coexisting with various fractions of SSDF attackers. In this paper, a novel algorithm called Spectrum Sensing Strategy Selection (4S) is proposed to select better sensing strategies either in a collaborative or in an independent manner. To derive the maximum a posteriori estimation of nodes’ spectrum status, we investigated the graph cut-based CSS method, through which the topological information cost function and the sensing results cost function were constructed. Moreover, the reputation value was applied to evaluate the performance of CSS and independent sensing. The reputation threshold was theoretically analyzed to minimize the probability of choosing the sensing manner with worse performance. Simulations were carried out to verify the viability and the efficiency of the proposed algorithm.

essential for cognitive radio to exploit spectrum holes. To avoid interfering with the PU, the spectrum sensing algorithm should be able to detect white holes efficiently and effectively.
Due to the spacious coverage of ad hoc networks, each SU may receive varying PU signal powers and thus undergo diverse spectral status in cognitive radio ad hoc networks (CRAHNs). However, neighboring SUs are spatially close and prefer to experience identical spectral status. This characteristic of ad hoc networks is called spectrum partial homogeneity [4]. Cooperative spectrum sensing (CSS) takes full advantage of this prior information to improve the performance of malfunctioning SUs with poor wireless propagation characteristics, such as those nodes experiencing deep shading. It is unlikely that all SUs undergo severe fading. Therefore, it is feasible for SUs to exploit sensing performance gain from adjacent nodes through cooperation. In the first step of collaborative sensing, each SU reports the local independent spectrum sensing decision to the data fusion center through control channels. Then, the data fusion center generalizes the cooperation of the local decision according to given rules, such as Majority criteria, Or criteria, And criteria, Bayes criterion, and so on [5]. The decision results are broadcast back to each SU node via the control channels.
On one hand, introducing cooperation during sensing provides CRAHNs with enormous performance improvement; on the other hand, it also opens the door to spectrum sensing data falsification (SSDF) attackers, which aim to undermine the sensing performance of CRAHNs. Moreover, ad hoc networks are more likely to sustain SSDF attack due to the openness and dynamics of CRAHNs. Hence, it is crucial to design robust collaborative sensing algorithms to suppress SSDF attackers. The issue of how to eliminate the interference of SSDF attackers in cognitive radio has attracted the attention of many researchers [6][7][8][9][10]. Reputation value theory (RVT)-based algorithms against SSDF attacks are commonly applied in cognitive radio networks to detect and remove malicious nodes [11,12]. However, existing RVT algorithms cannot detect all malicious SUs and even regard honest SUs as malicious nodes by mistake. Residual malicious nodes and mis-detected honest nodes will inevitably degrade the sensing performance. In Reference [13], the maximum likelihood estimation method is combined with reputation theory to eliminate SSDF attackers. The performance of independent sensing is compared with the performance of CSS under SSDF attack in Reference [14]. Unfortunately, the independent sensing results, which perform better when the fraction of SSDF attackers is high, are not used in the proposed algorithm [14]. Different from previous researches, this paper mainly concentrates on the problem of choosing the sensing strategy between either independent spectrum sensing or CSS from the view of honest Sus, rather than how to reject malicious nodes from the view of the data fusion center.
The contributions of this article are as follows: • The theoretical deduction of the maximum posterior probability estimation based on image segmentation in CRAHNs is introduced. • This paper proposes a spectrum sensing strategy selection algorithm based on the reputation value theory. Moreover, the theoretical derivation and simulation verification of the optimal threshold value are completed.
The arrangement of this paper is as follows: Section 2 establishes the system model of a cognitive radio network. Section 3 introduces the spectrum sensing methods in cognitive radio networks, and Section 4 proposes the selection strategy of spectrum sensing methods. Section 5 investigates the optimal threshold for the spectrum sensing strategy selection algorithm. Simulation results are given, and conclusions are drawn in Section 6. Finally, Section 7 discusses the potential future works that may be needed.

System Model
This paper considers a centralized CRAHN model, consisting of a PU, a fusion center (FC), and N SUs with N − M Honest Secondary Users (HSUs) and M malicious secondary users (MSUs). As shown in Figure 1, parts of the secondary users are affected by severe fading and uncertain noise, resulting in false sensing decisions. Thereby, we exploit the prior information of the spectral state consistency of CRAHNs to improve the performance of these fading nodes via cooperation. Although the cognitive nodes of different location may experience different spectrum status, topologically adjacent nodes tend to be in the same spectrum occupancy status. In other words, CRAHNs are composed of several 'same spectrum status' patches. Therefore, malfunctioning SUs under deep fading can cooperate with neighboring nodes to rectify the local erroneous spectrum sensing results.  In the first step of CSS, the SUs carry out independent spectrum sensing, and then send the local sensing decisions to the FC through the ideal control channels. In ad hoc networks, the topology information is relatively easy to acquire. Based on the accepted local sensing results and known topology information, the FC makes a final decision, and then broadcasts the sensing decisions to all SUs.
At each cognitive node, independent spectrum sensing can be considered as a binary hypothesis testing problem defined as: the spectrum is occupied the spectrum is idle The power of the PU signal received at the cognitive node not only depends on the distance between the PU and the SU, but also relates to other wireless propagation characteristics, such as shadow fading, multipath, and noise. According to References [15,16], the formulation among the level of fading and the related parameters at SUs is as follows: Assume that SUs detect the PUs based on energy detection with a threshold  . Hence, the probability of detection of the i -th SU can be formulated as: In the first step of CSS, the SUs carry out independent spectrum sensing, and then send the local sensing decisions to the FC through the ideal control channels. In ad hoc networks, the topology information is relatively easy to acquire. Based on the accepted local sensing results and known topology information, the FC makes a final decision, and then broadcasts the sensing decisions to all SUs.
At each cognitive node, independent spectrum sensing can be considered as a binary hypothesis testing problem defined as: the spectrum is idle The power of the PU signal received at the cognitive node not only depends on the distance between the PU and the SU, but also relates to other wireless propagation characteristics, such as shadow fading, multipath, and noise. According to References [15,16], the formulation among the level of fading and the related parameters at SUs is as follows: Path loss PL(d) is a function of d, which denotes the distance between the PU and the SU. X σ is subject to Gaussian distribution with a mean value of 0 and a variance of σ, i.e., X σ ∼ N 0, σ 2 . d 0 and n represent the reference distance and the path loss factor, respectively.
Assuming that P t denotes the transmission power of the primary user, when the PU is present, the power received at the i-th SU can be expressed as P i r (d i ) = P t − PL(d i ). When the PU is absent, Assume that SUs detect the PUs based on energy detection with a threshold λ. Hence, the probability of detection of the i-th SU can be formulated as: where Q(z) = 1/ √ 2π ∞ z exp −x 2 /2 dx denotes the complementary distribution function of standard normal distribution. Similarly, the probability of a false alarm of the i-th SU can be expressed as: Although CSS may improve the sensing performance, it also provides SSDF attackers with the opportunity to undermine the sensing performance due to its nature of openness. SSDF attackers can mislead the FC and deteriorate the CSS performance by means of reporting false sensing results. Thereby, the CSS algorithm must be robust to SSDF attacks. Although some algorithms can detect malicious nodes [11], the residual malicious nodes will still affect the spectrum sensing performance. As the fraction of malicious nodes rises in cognitive radio networks, the probability of CSS detection decreases. Meanwhile, the probability of CSS false alarm ascends. Therefore, different sensing strategies are needed under different fractions of malicious nodes.

Collaborative Spectrum Sensing in CRAHNs
In this section, the graph cut algorithm used regularly in computer vision is introduced into CSS, where the graph cut-based maximum a posteriori estimation of spectrum occupancy states is realized. In the field of computer vision, graph cut algorithms are often used to derive the minimum energy of an image [17,18], and divide this image into 'foreground' and 'background'. Similarly, in CSS, all SUs nodes are expected to decide whether the PU is 'absent' or 'present' at each node.
Based on the spectrum state of each node in CRAHNs, a graph of spectrum occupancy status is constructed in this section. Each SU is regarded as a graph pixel and links v i , v j between neighboring nodes i and j are established based on their topology information. Hence, an undirected graph of spectrum occupancy status (GSOS) can be built. In computer vision, two terminals (source and sink) are added to the image, and each node in the image relates to two terminals [17]. Similarly, source node O, denoting spectrum occupied, and terminal node U, denoting spectrum unoccupied, and the connection between each node and two endpoints l v o , v j , l v j , v u are added in the GSOS. In this way, dividing SU status in CSS is equivalent to image segmentation in computer vision, and can be further processed by existing graph cut algorithms.

Maximum a Posteriori Probability of CSS
Given the spectrum state of the i-th secondary user x i , where {x i = 1, 0} meaning that its spectrum is occupied or vacant, respectively, the PU signal energy y i received at the i-th secondary user is conditionally dependent on x i , and the conditional probability density function is f {y i |x i }. Therefore, considering a cognitive radio network with N SU nodes with spectrum state x = {x 1 , x 2 , . . . , x N }, the power density function of the signal power received by each SU node is denoted as: where y = {y 1 , y 2 , . . . , y N }. In cognitive radio networks, the prior distribution of SU nodes can be considered as a conditional Markov random field (MRF) [19], which is a commonly used model for location scenes with numerable patches having the same spectrum status. Thereby, the prior distribution of each node state p(x) can be expressed as follows [19]: where β ij stands for the relationship between two SU nodes. When the i-th secondary user and j-th secondary user are adjacent nodes, we have According to the Bayes criterion, the posterior probabilities of the spectrum state of the network nodes p(x|y) can be written as: Namely, the logarithm of the posterior probability, ln p(x|y), can be formulated as: where represents the likelihood ratio of the SUs. The constant K, which is independent of the spectrum states, can be expressed as:

Parameter Setting of the Graph Cut
The minimum energy of the graph according to the maximum flow/minimum cut algorithm [18] can be written as [20]: where L = L p , p ∈ P , D p (·), V p,q (·), and φ denote the value of each pixel of the penalty function for each node's value, the interaction function between the pixels p and q, and the set of all adjacent nodes, respectively. This paper makes some adoptions to build the connection between the results of graph cut and the maximum a posteriori estimation of the SUs' spectrum status in CSS. Similarly with the penalty function D p (·) and the interaction function V p,q (·) in the graph cut, the sensing result cost functions c(v i , v o ), c(v u , v i ) and the topological information cost function c v i , v j are introduced, respectively.
1. Sensing results cost function: where η is set to 1, and thus c(v u , v i ) = 0. From Equations (10) and (11), we can derive that when , the i-th node prefers to decide that the spectrum status at the i-th node is idle, which is equal to the decision of the independent spectrum sensing. When it comes to making a hard decision, c (v i , v o ) = 1 and c (v u , v i ) = 0 when the likelihood ratio function is greater than 1; otherwise, c (v i , v o ) = 0 and c (v u , v i ) = 1. Thus, the cognitive node reports this 1-bit hard decision data to the FC.
The topological information cost function denotes the correlation of the spectrum status between two nodes. The topological information cost function c v i , v j is equal to β when the i-th node and j-th node are neighbors to each other topologically. It is reasonable that adjacent nodes prefer to undergo the same spectrum status and thus β > 0.
Based on the aforementioned cost functions, the energy function of GSOS can be written as: which differs from the negative part of the posterior probability function −L(x) by a constant K.
In other words, graph cut algorithms minimize the energy function of an image, C(x), and consequently derive the maximum a posteriori estimation in CSS.

Spectrum Sensing Strategy Selection Based on Reputation Value
In the field of CSS, reputation value theory is often applied to distinguish HSUs from SSDF attackers [21,22]. In this section, reputation value theory is innovatively adopted to a select sensing strategy between CSS and independent sensing.
Massive MSUs in CRAHNs will deteriorate the performance of CSS dramatically, which contradicts the belief that CSS should improve the sensing performance. Different from CSS, independent sensing ensures the independence of each node's sensing results, which means that MSUs have no chance to interfere with HSUs in independent sensing. Therefore, it is advisable to select independent spectrum sensing when enormous malicious nodes exist, and vice versa. However, the fraction of MSUs in CRAHNs is not easy to determine.
Though the fraction of MSUs is unknown for each SU, local sensing data and CCS results can be easily obtained at an HSU without additional hardware costs. This information can be further exploited to evaluate the performance of independent spectrum sensing and CSS. At each SU node, the performance of independent sensing is compared with that of CSS. When the results of the former are the same as those of the latter, the reputation value is increased by 1; when they are different, the reputation value is reduced by 1. Therefore, collaborative sensing results are trustworthy when the reputation value is high. Likewise, independent sensing decisions are reliable when the reputation value is low. Thereby, a specific reputation threshold should be investigated. CSS results are selected when the reputation value exceeds the reputation threshold, and independent sensing results are chosen when the reputation value is below the threshold.
To elaborate upon the sensing strategies selection, the reputation value is analyzed at an honest node. Assuming that the sensing result at moment t is denoted as u t with detection probability P I d and false alarm probability P I f , g t represents the CSS result at moment t with P C d and P C f representing the detection probability and false alarm probability, respectively. Let e t denote the comparison between the sensing result of the FC and the sensing result of the cognitive node.
It is assumed that the result of independent spectrum sensing is equals to that of CSS at moment t, denoted as: P{e t = 1} = p represents the probability that the CSS result will be identical to the independent spectrum sensing result, and it can be written as follows: P{e t = 0} = q denotes the probability that the CSS result will be different from the independent spectrum sensing result, and it can be formulated as follows: The partial derivative of p on P C d and P C f can be expressed as: ∂p where it is reasonably assumed that 1 > and ∂p ∂P C f < 0 hold true. p decreases with the increase of P C d at interval [0.5, 1]. Likewise, p increases with the increase of P C f at interval [0.5, 1]. When P C d , P C f = (0.5, 0.5), p achieves the minimum P min , which can be denoted as: When P C d , P C f = P A d , P A f , P thr is derived as: When P C d , P C f = (1, 0), the maximum of p is formulated as: Obviously, p ≥ P Thr is obtained when Therefore, p can be used as a performance metric to compare the performance of CSS and that of independent spectrum sensing. When p ≥ P Thr , CSS outperforms independent sensing; when p < P Thr , independent spectrum sensing outperforms CSS. To achieve better sensing performance, the CSS results rather than the independent sensing results are chosen as the final decision when p ≥ P Thr ; meanwhile, the independent spectrum sensing results are selected when p < P Thr . The abovementioned procedure is termed the spectrum sensing strategies selection (4S) algorithm.

Selection of Reputation Value Threshold
For the purpose of obtaining optimal sensing results, the 4S algorithm is expected to select the CSS results when the results of CSS are excellent; the independent spectrum sensing decision is deemed as the final decision in the 4S algorithm when independent sensing outperforms CSS. The first type of sensing error P e1 and the second type of sensing error P e2 are defined as the choice of the independent spectrum sensing results when the CSS decisions are optimal and should be selected, and the selection of the CSS results when the performance of the independent sensing is better than that of CSS, respectively. To reduce the sum of the first type of strategy selection error and second type of strategy selection error for the i-th SU, i.e., P i e = P e1 + P e2 , an optimal reputation value threshold can be designed as follows. Definition 1. The reputation value of the i-th SU-E is recorded by comparing the sensing results of the FC with the local sensing results, i.e., e t over a limited time window from t 0 to t 0 + T.
where e t follows the Bernoulli distribution with the parameter ρ. Therefore, E is subject to the binomial distribution. According to Reference [23], when T, P{e t = 1} = p, and P{e t = 0} = q satisfy the following condition, E approximately follows a normal distribution, i.e., E ∼ N (Tp, T pq). The probability density functions of E can be formulated as: Considering that p q, it's reasonable to assume that q/p ≈ 0. Thus, the formula (23) can be simplified as Under the condition from Equation (25), an appropriate reputation value threshold can be derived to minimize the probability of total strategy selection error.
For the i-th SU, when p > P Thr , the CSS results are optimal, and the detection probability of CSS the false alarm probability of independent sensing are greater than the detection probability of independent sensing and the false alarm probability of CSS, respectively, i.e., P C d > P I d and P C f < P I f ; conversely, the independent spectrum sensing performance is better and P C d < P I d , P C f > P I f . A proper reputation value threshold is η investigated for E, and the cooperative spectrum sensing results are chosen when E > η; conversely, the independent spectrum sensing results should be selected when E < η. Thus another definition of the first type of sensing error can be expressed as the probability of E > η when p is less than a given threshold P Thr , i.e., P{E > η|p < P Thr }; the second type of sensing error can be denoted as the probability of E < η when p > P Thr , i.e., P{E < η|p > P Thr }.
The probability of the first type of sensing error, P{E > η|p < P Thr } can be formulated as: The probability of the second type of sensing error, P{E < η|p > P Thr } can be formed as: Let us assume that the cognitive radio network has a massive amount of honest cognitive nodes, thus P C d max ≈ 1 and P C f min ≈ 0 according to Reference [24]. In accordance with Reference [16], under the best SSDF attack, the performance of the cognitive radio network is at its worst with P C d min = 0.5 and P C f max = 0.5.
Given that θ(p) represents the probability density function of P{e t = 1} = p, it is assumed that p is subject to uniform distribution at [P min , P max ] under the attack of malicious nodes; that is: Therefore, the total strategy selection error probability for the i-th SU P i e can be written as: The partial derivative of the total strategy selection error probability over the reputation value threshold η can be computed as: (30) Proposition 1. The solution for the optimal reputation value exists.

Proof. See Appendix A.
According to Proposition 1, the solution of The solution of the above equation is the optimal reputation threshold of the 4S algorithm. To reduce the computational complexity, an error function is applied to approximate the formula ∂P i e ∂η = 0 as follows (see Appendix B): where erf(x) is the error function. We define optimal threshold function h(η) as: It can be seen that h(η) is equal to zero when η = η 0 , ∂P i e ∂η < 0 when η < η 0 , and ∂P i e ∂η > 0 when η > η 0 . Namely, the total strategy selection error probability monotonically decreases at interval (0.5, η 0 ) and ascends at interval (η 0 , 1). Accordingly, the total strategy selection error probability for the i-th SU reaches its minimum at η = η 0 .

Performance Analysis
This section analyzes and investigates the performances of independent spectrum sensing, CSS, and the proposed 4S algorithm in CRAHNs under various SSDF attack strategies.

Parameter Setting
In this section, a centralized cognitive radio network is considered, where three sensing algorithms are applied and simulated. The PU is assumed to be located at the center of the cognitive radio network, and accesses the licensed band with a probability of 0.5. The power and the bandwidth of the PU emitted to the cognitive radio network reaches 20 watts and 900 MHz, respectively. All of the SUs' locations, including HSUs and MSUs, are subject to a Poisson point process with a density of 8 × 10 −5 /m 2 . Wireless channel propagation is modeled as Rayleigh distribution with mean of 1, and the path loss factor is 4. Background noise n(t) follows normal distribution with N 0, 10 −14 . Prior information about partial spectrum homogeneity, β, is equal to 0.4.

SSDF Attack Strategies
At first, spectrum sensing is implemented at each node. Afterwards, SSDF attackers resolve their report data based on their sensing results and attacking strategies. SSDF attacking strategies can be divided into four ways [25], listed as follows.
1. "Always occupied" attack: To access spectrum resources alone, MSUs send reports of being occupied by the PU to force the FC to regard the spectrum status as always occupied. Thus, SUs have no privilege to access the spectrum band. Therefore, the total spectrum utilization efficiency is reduced.
2. "Always idle" attack: When the spectrum status is occupied, malicious nodes send 'idle' reports to deliberately mislead the FC to allocate spectrum resources to SUs. As a result, the quality of communication is worsened.
3. "Always false" attack: Sensing data reported to the FC by MSUs is always completely contrary to the sensing results. That is, when the malicious user detects the existence of the PU, the malicious user sends an 'idle' report to the FC; if the malicious user finds that the spectrum status is idle, the malicious user sends an 'occupied' report to the FC.
4. Possible attack: To avoid being detected and eliminated by the FC, the malicious user reports not only false results but also true results under a specific probability.

Simulation Results
Considering the goal of minimizing the average total strategy selection error probability for all HSUs, P e , we employ the probability of correctness for HSUs as a performance metric, which is given by: where Pb i C and Pb i I denote the sensing error of CSS and the sensing error of independent sensing, respectively; κ i = 0 and κ i = 1 indicate that the CSS results are selected and that the independent sensing results are selected for i-th SU, respectively.
Assuming that the sensing method with better performance is always chosen in the 4S algorithm, we can derive the upper bound of the probability of correctness, P c , which is given by: When the number of SUs, N, is constant, the fraction of SSDF attackers is denoted as: α = number of SSDF attackers number of honest SUs + number of SSDF attackers .
(36) Figure 2 shows that independent spectrum sensing is not affected by the fraction of MSUs at all and that CSS is sensitive to the fraction of MSUs and performs worse when it comes to a high fraction of MSUs. Moreover, 'always occupied' attacks have greatest impacts on CSS and 'always idle' attacks have the lowest effects on CSS. This is mainly due to the large coverage area of CRAHNs, which means that most cognitive nodes are out of the PU's coverage and may fall into an 'idle' status. MSUs out of the PU's coverage, which adopt an 'always idle' strategy, report errorless data to the FC, and vice versa. In Figure 2a, when the fraction of SSDF attackers is high, the performance of CSS is low and thus independent sensing is selected as the final decision of the 4S algorithm. Therefore, the performance of the 4S algorithm converges with the performance of independent sensing. In Figure 2b, the flattening of the plots is caused because SUs out of the PU's coverage report errorless data to the FC. The convergence value depends on the ratio of the number of SUs out of the PU's coverage to the number of SUs in the PU's coverage.
It also can be seen from Figure 2 that there is a gap between the performance of the 4S algorithm and the upper bound of the 4S algorithm. Firstly, we assume that P C d max ≈ 1 and P C f min ≈ 0; when these are not perfectly satisfied, the threshold selection is not optimal. Secondly, in the above discussion, the total strategy selection error P i e reaches a minimum value, which is equal to 0. This means that there are still some cases in which SUs make the wrong choice in strategy selection. Therefore, the upper bound of the 4S algorithm cannot be reached.
Overall, Figure 2 proves that the 4S algorithm performs much better than CSS when the fraction of MSUs is high and slightly worse than CSS in the case of a limited fraction of MSUs. Moreover, the 4S algorithm is almost always superior to independent spectrum sensing, except in the case of moderate to high fractions of MSUs under an "always occupied" attack. Figures 3 and 4 show the influence of probabilistic attacks on the performance of three sensing algorithms with a hard decision and with a soft decision [4], respectively. It was demonstrated that CSS with a soft decision is vulnerable to malicious attacks and the performance of CSS with a soft decision is worse than that of CSS with a hard decision. This is mainly due to the robustness of the hard decision topological information cost function. Compared with the soft decision topological information function, the hard one causes information losses to MSUs, which results in the poor performance of MSUs. Therefore, CSS with a hard decision perform better than CSS with a soft decision under a high fraction of MSUs. Although the performance of the 4S algorithm decays as a result of the decline of the CSS performance as the fraction of MSUs rises, the former still outperforms CSS and independent spectrum sensing. As the probability of attack increases, the curve of the 4S algorithm merges with that of independent sensing, which means that the 4S algorithm selects the independent sensing results when the CSS results are deeply affected by malicious nodes.
algorithms with a hard decision and with a soft decision [4], respectively. It was demonstrated that CSS with a soft decision is vulnerable to malicious attacks and the performance of CSS with a soft decision is worse than that of CSS with a hard decision. This is mainly due to the robustness of the hard decision topological information cost function. Compared with the soft decision topological information function, the hard one causes information losses to MSUs, which results in the poor performance of MSUs. Therefore, CSS with a hard decision perform better than CSS with a soft decision under a high fraction of MSUs. Although the performance of the 4S algorithm decays as a result of the decline of the CSS performance as the fraction of MSUs rises, the former still outperforms CSS and independent spectrum sensing. As the probability of attack increases, the curve of the 4S algorithm merges with that of independent sensing, which means that the 4S algorithm selects the independent sensing results when the CSS results are deeply affected by malicious nodes.    Owing to spectrum heterogeneity in CRAHNs and various fractions of MSUs, the performance of CSS and independent sensing among cognitive nodes differs. In the 4S algorithm, when the fraction of MSUs is relatively low in networks, the majority of SUs tend to select the CSS results as the final decision; thus, the performance of the 4S algorithm is roughly the same as that of CSS. When the number of MSUs increases, the performance of CSS gets worse. Therefore, it is reasonable for the 4S algorithm to select the insensitive independent sensing results as the final decision rather than the CSS results. To sum up, the 4S algorithm shows robustness under SSDF attack.

Conclusions
In this paper, we developed an adaptive deciding mechanism against SSDF attacks. Independent sensing and CSS have different sensitivities to the fraction of malicious nodes. We proposed the 4S algorithm, in which spectrum sensing is designed to adaptively select the better results between CSS and independent sensing under various attacking fractions of MSUs. The algorithm evaluates the performance of CSS and independent sensing through comparing reputation values. The simulation results clearly verified the effectiveness of the proposed 4S algorithm under varying malicious node attack strategies. The performance of the 4S algorithm is comparable ti that of CSS when the fraction of MSUs is high and it outperforms CSS when there is a low fraction of malicious nodes.

Conflicts of Interest:
The authors declare no conflict of interest.  Owing to spectrum heterogeneity in CRAHNs and various fractions of MSUs, the performance of CSS and independent sensing among cognitive nodes differs. In the 4S algorithm, when the fraction of MSUs is relatively low in networks, the majority of SUs tend to select the CSS results as the final decision; thus, the performance of the 4S algorithm is roughly the same as that of CSS. When the number of MSUs increases, the performance of CSS gets worse. Therefore, it is reasonable for the 4S algorithm to select the insensitive independent sensing results as the final decision rather than the CSS results. To sum up, the 4S algorithm shows robustness under SSDF attack.

Conclusions
In this paper, we developed an adaptive deciding mechanism against SSDF attacks. Independent sensing and CSS have different sensitivities to the fraction of malicious nodes. We proposed the 4S algorithm, in which spectrum sensing is designed to adaptively select the better results between CSS and independent sensing under various attacking fractions of MSUs. The algorithm evaluates the performance of CSS and independent sensing through comparing reputation values. The simulation results clearly verified the effectiveness of the proposed 4S algorithm under varying malicious node attack strategies. The performance of the 4S algorithm is comparable ti that of CSS when the fraction of MSUs is high and it outperforms CSS when there is a low fraction of malicious nodes.

Conflicts of Interest:
The authors declare no conflict of interest.
Thus, the above inequation is proven if the following inequation is proved to be true: where p = P max −P thr P thr −P min (ω − P min ). That is, From the above equation, we can obtain: It is assumed that T is large enough, thus ∂P i e ∂η η=P max ≥ 0 . Similarly, ∂P i e ∂η ≤ 0 when η = P min can be proved.

Appendix B
It is difficult to solve Equation (31), hence we derive an approximation of Equation (31) with a sufficiently large T.