Research Article

Network Traffic Obfuscation against Traffic Classification

Algorithm 2

Improved MIM using method 1.
Input: classifier f; loss function J; original sample x; authentic label y; disturbance size α; fixed number of iterations n; number of iterations T; attenuation factor μ.
output: adversarial sample.
(1);
(2);
(3) for to do
(4)  get gradient of func f with respect to ;
(5)  //update momentum
(6)  
(7)  //update adversarial sample
(8)  
(9)  if then
(10)   //modify
(11)
(12) set all elements greater than 0 in the vector to
(13)0;
(14)  ;
(15) end if
 end for.
 return.