## 3 Design and Methodology
### On/Off Attack  
In this type of attack, malicious behavior is exhibited by the user of the cloud system in a short time frame. They begin by exhibiting good conduct so that they can deceive the trust system and gain a good reputation. This kind of attack mostly occurs when proper behavior is initially shown by a malicious cloud service user for some time to attain a good reputation and gain the trust of other users. The user then starts taking advantage of this trust. Malicious users win the trust of the TMS in most cases by behaving properly in minor interactions. However, when they get an opportunity for a major interaction, their malicious intent becomes evident. The opportunistic but malicious behavior of various nodes is characteristic of attacks that are made through direct trust, including the trust of the system. There is a shift in the good and bad behavior of switches, which creates a disguise, and the node is considered trustworthy despite its inappropriate behavior [4]. For instance, malicious behavior can be exhibited by a node that is considered trustworthy on an e-commerce website. This behavior may not be identified because the node was initially considered trustworthy by the system. The interaction trust (IT) will initially be computed by the trust model system, which offers an accurate result for the trust value of every cloud service consumer (CR) by calculating the service provider's (SP's) interaction importance (II). The feedback (F) with respect to an interaction is presented as a percentage. Equation (1) is used to compute the IT. \[\mathrm{IT}(\mathrm{CR}) =\sum\limits_{\mathrm{i=1}}^{n-1}\frac{\alpha_{\mathrm{i}}^{ \mathrm{t}}(\mathrm{CR})+\mathrm{P}_{\mathrm{CR}}}{\left(\alpha_{\mathrm{i}}^{ \mathrm{t}}(\mathrm{CR})+\mathrm{P}_{\mathrm{CR}}\right)+\left(\beta_{\mathrm{ i}}^{\mathrm{t}}(\mathrm{CR})+\mathrm{N}_{\mathrm{CR}}\right)} \tag{1}\] \[\sum\limits_{\mathrm{i=1}}^{n}\alpha_{\mathrm{i}}^{\mathrm{t}}( \mathrm{CR}) = \begin{array}{c}\mathrm{CR}_{1}\\ \mathrm{CR}_{2}\\ \vdots\\ \mathrm{CR}_{n}\end{array} \left( \begin{array}{ccccc}\mathrm{v}_{1,1}& \mathrm{v}_{1,2}&\cdots&\mathrm{v}_{1,n-1}&\mathrm{V}_{1,n}\\ \mathrm{V}_{2,1}&\mathrm{V}_{2,2}&\cdots&\mathrm{V}_{2,n-1}&\mathrm{V}_{2,n} \\ \vdots&\vdots&\ddots&\vdots&\vdots\\ \mathrm{V}_{n,1}&\mathrm{V}_{n,2}&\cdots&\mathrm{V}_{n,n-1}&\mathrm{V}_{n,n} \end{array} \right)\] \[\sum\limits_{\mathrm{i=1}}^{n}\beta_{\mathrm{i}}^{\mathrm{t}}( \mathrm{CR}) = \begin{array}{c}\mathrm{CR}_{1}\\ \mathrm{CR}_{2}\\ \vdots\\ \mathrm{CR}_{n}\end{array} \left( \begin{array}{ccccc}\mathrm{v}_{1,1}& \mathrm{v}_{1,2}&\cdots&\mathrm{v}_{1,n-1}&\mathrm{V}_{1,n}\\ \mathrm{V}_{2,1}&\mathrm{V}_{2,2}&\cdots&\mathrm{V}_{2,n-1}&\mathrm{V}_{2,n} \\ \vdots&\vdots&\ddots&\vdots&\vdots\\ \mathrm{V}_{n,1}&\mathrm{V}_{n,2}&\cdots&\mathrm{V}_{n,n-1}&\mathrm{V}_{n,n} \end{array} \right)\] \[\mathrm{P}_{\mathrm{CR}} =\frac{\alpha_{\mathrm{n}}^{\mathrm{t}}(\mathrm{CR})\times\Pi}{ \mathrm{NF}}\] \[\mathrm{N}_{\mathrm{CR}} =\frac{\beta_{\mathrm{n}}^{\mathrm{t}}(\mathrm{CR})\times\Pi}{ \mathrm{NF}}\]  
Here, positive feedback in a given time is shown by \(\alpha^{\mathrm{t}}\); negative feedback in a given time is shown by \(\beta^{\mathrm{t}}\); P denotes the value of the new positive recommender feedback, N represents the value of the new negative recommender feedback; the Interaction Importance value is shown with \(\Pi\), and the feedback numbers are denoted by NF. The risk of on/off attacks \(\left(\mathrm{O}^{2}\right)\) can be prevented by incorporating the penalty for the on/off attack \(\left(\mathrm{PO}^{2}\right)\). This penalty is fixed from one to n, where one refers to no risk from this user and n represents high interaction importance multiplied by the danger rate \(\left(\mathrm{DR}\right)\). \(\mathrm{PO}^{2}\) for any customer is calculated with the trust model using a novel process in which \(\mathrm{PC}^{\mathrm{O}^{2}}\) is the smallest value of the greatest interactions.