ensors' weight was updated by considering both the historical and the current spectrum sensing data. Finally, an SSDF attack behavior recognition algorithm based on the proposed framework was designed to identify SSDF attacks more accurately than offline learning. 11.2.2.2 Reputation-Based Detection Methods One of the critical issues in combating SSDF attacks is distinguishing the attackers' error reports from the SUs' reports in the FC. A Bayesian reputation model-based SSDF defense scheme for CRNs was proposed in [131]. The proposed method modeled cooperation as a service-evaluation process and SUs' reputation degrees reflected their service quality. Reputation degrees of SUs were updated based on the Bayesian reputation model, and the behaviors of malicious SUs could be effectively tracked by this means. In [83], a three-layer Bayesian model was designed to combat SSDF attacks. The model consisted of a processing layer, an integrating layer, and an inferring layer. The process- ing layer was based on the HMM model, where original data was used to train parameters and the trained emission distributions were then passed to the second layer. By employing different algorithms in the integrating layer, emission distributions were processed to obtain reputation values, balance values, and specificity values of different SUs. By using different thresholds, these continuous values could be rendered discrete and then transferred to the inferring layer. Finally, by using the discrete values as evidence, a Bayesian network was built in the third layer to calculate the safety probabilities of SUs. In [160], several ML techniques such as SVM, Neural Network, Naive Bayes, and Ensem- ble classifiers were implemented to detect SSDF attacks in a CRN. The learning techniques 11 Secure Spectrum Sharing with Machine Learning: Methodologies were investigated under two experimental scenarios: (i) the training and test data were drawn from the same data-set, and (ii) separate datasets were used for training and test- ing. The robust