Research Article

Hierarchical Hybrid Trust Management Scheme in SDN-Enabled VANETs

Algorithm 1

Inter-vehicular trust calculation.
Input LTD, OTV, vehicle ID, ROVij, QODij
Output ST, RT
if vehicle i receives interactive information from vehicle j then
 Calculate the distance between nodes and obtain the STW value according to equation (1)
 Check the local trust database (LTD) of vehicle i
 if IDj ∈ LTDi then
  Search OTVij
 else
  Take OTVini as the OTV value of vehicle i to vehicle j
 end if
 Upgrade the OTV information of vehicle i
 Calculate the ST of vehicle j using equation (3)
 if ROVij ≥ ROVthre then
  ROVij ⟵ ROVij + λ
 else
  ROVij ⟵ ROVij − μ
  if QODij ≥ QODthre then
   QODij ⟵ QODij + λ
  else
   QODij ⟵ QODij − μ
  end if
 end if
 Use equation (6) to calculate the trust score SP between vehicles
 Calculate the value of NT according to the value of SPij using equation (5)
 Determine the role type of vehicle j and use equation (4) to find RW
 Use equation (7) to calculate the RT of vehicle i to vehicle j
end if