Notes
Notes - notes.io |
// @name ZyXEL VMG3312 Improved
// @description ZyXEL VMG3312 - auto refreshes modem info , easily get rid of down msg (very useful if you run bridge mode), get xDSL statistics, change advanced configuration of xDSL, WMM and TR064 parameters
// @copyright 2016-2017+, Volkan K.
// @include http://192.168.1.1/*
// @include https://192.168.1.1/*
// @include http://*/*
// @include https://*/*
// @version 3.7
// @run-at document-end
// @namespace https://greasyfork.org/users/4151
// @require https://cdnjs.cloudflare.com/ajax/libs/jquery/2.1.4/jquery.min.js
// @require https://cdnjs.cloudflare.com/ajax/libs/jqueryui/1.12.1/jquery-ui.min.js
// @grant GM_xmlhttpRequest
// @grant GM_registerMenuCommand
// @grant GM_getValue
// @grant GM_setValue
// @connect self
// @connect 192.168.1.1
// ==/UserScript==
this.$ = this.jQuery = jQuery.noConflict(true);
var debug_internal = 1; // 1=enable debug , 0 =disable debug
function debugLog(message) {
if (debug_internal == 1) {
console.log("USER-SCRIPT VMG3312 | " + message);
}
}
$.fn.val_ch = function(value) {
//this.trigger( "click" );
old_val = this.val();
new_val = this.val.apply(this, arguments);
if (old_val != new_val) {
this.trigger("change");
}
return new_val;
};
function readyFn() {
//alert('smth1'); // for debug
// Code to run when the document is ready.
//alert($("#mainFrame"));
$("#mainFrame").contents().find("#XDSL_RefreshList, #Sys_RefreshList").val_ch("1");
$("#mainFrame").contents().find("div#downMsg > div.button_position > input").click(function() {
$(this).parents("div#downMsg").fadeOut().remove();
});
}
function readyFn_w() {
readyFn();
for (i = 1; i <= 10; i++) {
setTimeout(readyFn, i * 1000);
}
}
function show_disabled() {
$("#s1, #s2").show();
$("input[name=dslBonding],
input[name=enblAdslPTM],
input[name=enblAnnexM],
input[name=USPhyR],
input[name=DSPhyR],
input[name=adslSra],
input[name=wlWme]").prop('disabled', false);
}
function show_hidden_page(url) {
// do stuff
if ($("#mainFrame").length < 1) {
alert("couldnt find #mainFrame. please login to firmware!");
debugLog("couldnt find #mainFrame. please login to firmware!");
return false;
}
if (!$("#mainFrame")[0].src.includes("tabFW/tabFW.html")) {
/*alert("you must be in one of firmware tabs (other than connection status). thanks!");
debugLog($("#mainFrame")[0].src+" => you must be in one of firmware tabs (other than connection status). thanks!");
return false;*/
get_loading_mask();
$("#mainFrame").contents().find("#XDSL_RefreshList, #Sys_RefreshList").val_ch("0");
$("#mainFrame").contents().find("div.refreshFrame").remove();
}
if (!(/advanced_cfg.html$/i.test(url))) {
$("#mainFrame").contents().find(".panes").empty();
//$("#mainFrame").contents().find(".panes").eq(0).load(url);
$("#mainFrame")[0].contentWindow.eval('$(".panes").eq(0).load("'+url+'")');
return null;
}
GM_xmlhttpRequest({
method: "GET",
headers: {
'Referer': 'http://192.168.1.1/index.html'
},
url: url,
onerror: function(oEvent) {
debugLog("Error " + oEvent.target.status + " occurred while receiving the document.");
},
onload: function(response) {
if (response.status == 200) {
var response_parsed = $.parseHTML(response.responseText, document, true);
debugLog(url+"="+response.responseText);
console.log(response_parsed);
var my_s1 = $(response_parsed).filter('.content_frame');
if (my_s1.length<1){
my_s1 = $(response_parsed).filter('form');
}
var my_sc = $(response_parsed).filter('script');
console.log(my_s1); console.log(my_sc); // for debug
var myregexp = /id="sessionKey" value="(d+)">/i;
var match = myregexp.exec(response.responseText);
var myregexp2 = /var adslFlag = '(d+)';/i;
var match2 = myregexp2.exec(response.responseText);
if (/advanced_cfg.html$/i.test(url) && match != null && match2 != null) {
sessionKey = match[1];
pre_sess_html = "PGRpdiBjbGFzcz0iY29udGVudF9mcmFtZSIgPgo8IS0tVW5pdCBFeHBsYWluIHN0YXJ0LS0+CjxkaXYgY2xhc3M9ImV4cGxhaW4iPgo8ZGl2PjxiIGNsYXNzPSJyMSI+PC9iPjxiIGNsYXNzPSJyMiI+PC9iPjxiIGNsYXNzPSJyMyI+PC9iPjxiIGNsYXNzPSJyNCI+PC9iPjxiIGNsYXNzPSJyNCI+PC9iPjwvZGl2Pgo8ZGl2IGNsYXNzPSJleHBsYWluX3RleHQiPkRTTCBCb25kaW5nIGR1cnVtd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mFtZT0iQ2FuY2VsIiB2YWx1ZT0iJiMzMDQ7cHRhbCBldCIgdHlwZT0iYnV0dG9uIiBvbkNsaWNrPSdmcm1Mb2FkKCk7Jy8+PC9kaXY+PC9saT4NCjwhLS1CdXR0b24gZGVmaW5lIGVuZC0tPg0KPC91bD48L2Rpdj4NCjwvZm9ybT4NCjwhLS1TZXQgYXJlYSBlbmQtLT4NCjwvZGl2Pg0K";
custom_html = window.atob(pre_sess_html)+sessionKey+window.atob(post_sess_html);
debugLog("SHOWING CUSTOM HTML = "+custom_html);
$("#mainFrame").contents().find(".panes").eq(0).html(custom_html);
adslFlag = match2[1];
var upprocess = /var upprocess = '(d+)';/i;
var match3 = upprocess.exec(response.responseText);
if (match3 != null) {
upprocess = match3[1];
}
var usphyr = /var USPhyR = '(d+)';/i;
var match4 = usphyr.exec(response.responseText);
if (match4 != null) {
usphyr = match4[1];
}
var dsphyr = /var DSPhyR = '(d+)';/i;
var match5 = dsphyr.exec(response.responseText);
if (match5 != null) {
dsphyr = match5[1];
}
var adslptm = /var enblAdslPTM = '(d+)';/i;
var match6 = adslptm.exec(response.responseText);
if (match6 != null) {
adslptm = match6[1];
}
beginning_sc = "var bonding = ''; var upprocess = '"+upprocess+"'; var isSupportbonding = '0'; var USPhyR = '"+usphyr+"'; var DSPhyR = '"+dsphyr+"'; var enblAdslPTM = '"+adslptm+"'; var enblAnnexM = '0'; var customizationFlag = '24576';";
pre_flag_sc = "ZnVuY3Rpb24gcmVib290KCkgew0KCXZhciBsb2MgPSAnL2xvZ2luL2xvZ2luLmh0bWwnOw0KCXZhciBjb2RlID0gJ3dpbmRvdy50b3AubG9jYXRpb249IicgKyBsb2MgKyAnIic7DQoNCglldmFsKGNvZGUpOw0KfQ0KDQpmdW5jdGlvbiBidG5BcHBseSgpDQp7ICANCiAgIHZhciBhZHNsRmxhZ1RlbXAgPSAwOw0KICAgd2l0aCAoIGRvY3VtZW50LmZvcm1zWzBdICkgew0KICAgICAgaWYgKEdEbXRbM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AgICAgICAgICQoImlucHV0W25hbWU9J1ZEU0w4YSddIikuZ2V0KDEpLmNoZWNrZWQgPSB0cnVlOw0KCSAgJCgiaW5wdXRbbmFtZT0nVkRTTDhiJ10iKS5nZXQoMSkuY2hlY2tlZCA9IHRydWU7DQoJICAkKCJpbnB1dFtuYW1lPSdWRFNMOGMnXSIpLmdldCgxKS5jaGVja2VkID0gdHJ1ZTsNCgkgICQoImlucHV0W25hbWU9J1ZEU0w4ZCddIikuZ2V0KDEpLmNoZWNrZWQgPSB0cnVlOw0KCSAgJCgiaW5wdXRbbmFtZT0nVkRTTDEyYSddIikuZ2V0KDEpLmNoZWNrZWQgPSB0cnVlOw0KCSAgJCgiaW5wdXRbbmFtZT0nVkRTTDEyYiddIikuZ2V0KDEpLmNoZWNrZWQgPSB0cnVlOw0KCSAgJCgiaW5wdXRbbmFtZT0nVkRTTDE3YSddIikuZ2V0KDEpLmNoZWNrZWQgPSB0cnVlOw0KCSAgJCgiaW5wdXRbbmFtZT0nVkRTTDMwYSddIikuZ2V0KDEpLmNoZWNrZWQgPSB0cnVlOw0KCSAgJCgiaW5wdXRbbmFtZT0nVkRTTFVTMCddIikuZ2V0KDEpLmNoZWNrZWQgPSB0cnVlOw0KICAgICAgfQ0KfQ0KDQokKGRvY3VtZW50KS5yZWFkeShmdW5jdGlvbigpIHsNCiAJdmFyIGVyck1zZyA9ICIiOw0KCWZybUxvYWQoKTsNCglpZiAoZXJyTXNnICE9ICcnKQ0KCXsNCgkJaGNpQWxlcnQoZXJyTXNnLCAyKTsNCgl9DQp9KTsNCg0K";
custom_script=beginning_sc+window.atob(pre_flag_sc)+adslFlag+window.atob(post_flag_sc);
debugLog("EXECUTING CUSTOM SCRIPT = "+custom_script);
$("#mainFrame")[0].contentWindow.eval(custom_script);
return null;
}
$("#mainFrame").contents().find(".panes").eq(0).html(my_s1);
//$("#mainFrame").contents().find(".panes").eq(0).append(my_sc);
if (my_sc.length>0) {
$("#mainFrame")[0].contentWindow.eval(my_sc.html());
}
}
}
});
}
function get_loading_mask () {
// debugLog("get_loading_mask () called");
if (typeof ($("#mainFrame")[0].contentWindow.$.openLoadingMask) == "undefined") {
// define loadingMask
//debugLog("defining loadingMask");
$("#mainFrame")[0].contentWindow.eval("$.openLoadingMask=window.parent.$.openLoadingMask");
}
}
if (document.location.hostname.match("192.168.1.")) {
$(document).ready(readyFn_w);
$(window).load(readyFn_w);
$("iframe").load(readyFn_w);
$("iframe").on('readystatechange', readyFn_w);
setInterval(show_disabled, 1000);
GM_registerMenuCommand("show xDSL config", function() {
show_hidden_page('/pages/network/broadband/advanced_cfg.html');
});
GM_registerMenuCommand("show TR064 config", function() {
show_hidden_page('/pages/maintenance/tr064/tr064.html');
});
GM_registerMenuCommand("show TR069 config", function() {
show_hidden_page('/pages/maintenance/tr069Client/tr069Client.html');
});
GM_registerMenuCommand("show WMM config", function() {
show_hidden_page('/pages/network/wireless/wmm.html');
});
}
function addStyle_external(css_link, once) {
var head, style;
head = document.getElementsByTagName('head')[0];
if (!head) {
return;
}
if (once && $("link[href='"+css_link+"']").length>0) {
return;
}
style = document.createElement('link');
style.setAttribute("rel", "stylesheet");
style.setAttribute("type", "text/css");
style.setAttribute("id", "gm_added_style1");
style.setAttribute("href", css_link);
head.appendChild(style);
}
function addGlobalStyle(css, once,id) {
var head, style;
head = document.getElementsByTagName('head')[0];
if (!head) {
return;
}
if (once && document.getElementById(id)) {
return;
}
style = document.createElement('style');
style.setAttribute("type", "text/css");
style.setAttribute("id", id);
style.innerHTML = css;
head.appendChild(style);
}
GM_registerMenuCommand("show xDSL statistics", function() {
function login_and_retry(pass){
if (pass==null || pass==""){
pass="ttnet";
}
GM_xmlhttpRequest({
method: "POST",
data: "AuthName=admin&AuthPassword="+pass,
headers: {
'Referer': 'http://192.168.1.1/index.html',
'Content-Type': 'application/x-www-form-urlencoded'
},
url: 'http://192.168.1.1/login/login-page.cgi',
onload: function(response) {
if (response.status == 200) {
debugLog("login-page.cgi="+response.responseText);
getxdslstat();
}
}
});
}
getxdslstat = function(fail_func) {
GM_xmlhttpRequest({
method: "GET",
headers: {
'Referer': 'http://192.168.1.1/index.html'
},
url: 'http://192.168.1.1/pages/systemMonitoring/xdslStatistics/GetxdslStatistics.html',
onerror: function(oEvent) {
debugLog("Error " + oEvent.target.status + " occurred while receiving the document.");
},
onload: function(response) {
if (response.status == 200) {
debugLog("GetxdslStatistics.html="+response.responseText);
if (response.responseText.includes("/login/login.html")){
if(fail_func==1){
login_and_retry();
} else {
var pass = prompt("Please enter your password for admin user. Leave blank to exit.");
if (pass != null && pass!="") {
login_and_retry(pass);
}
}
return false;
}
addStyle_external('https://cdnjs.cloudflare.com/ajax/libs/jqueryui/1.12.1/jquery-ui.css', true);
var maxZ = Math.max.apply(null,
$.map($('body *'), function(e,n) {
if ($(e).css('position') != 'static')
return parseInt($(e).css('z-index')) || 1;
}
)
);
addGlobalStyle(".ui-dialog { z-index: "+(maxZ+1)+"; position: absolute} #trsm2017 {background-color: white; font-size: 14px;}", true,'gm_added_style2');
pre_stats = $("<pre title='xDSL statistics' id='trsm2017'>" + response.responseText + "</pre>").dialog({
width: "auto"
}); // width & height: auto, set child height.
pre_stats.height(400).width("50%");
if (pre_stats.width() < 650) {
pre_stats.width(650);
}
pre_stats.parent().position({
my: "center center",
at: "center center",
of: window
});
}
}
});
}
getxdslstat(1);
});
|
Notes.io is a web-based application for taking notes. You can take your notes and share with others people. If you like taking long notes, notes.io is designed for you. To date, over 8,000,000,000 notes created and continuing...
With notes.io;
- * You can take a note from anywhere and any device with internet connection.
- * You can share the notes in social platforms (YouTube, Facebook, Twitter, instagram etc.).
- * You can quickly share your contents without website, blog and e-mail.
- * You don't need to create any Account to share a note. As you wish you can use quick, easy and best shortened notes with sms, websites, e-mail, or messaging services (WhatsApp, iMessage, Telegram, Signal).
- * Notes.io has fabulous infrastructure design for a short link and allows you to share the note as an easy and understandable link.
Fast: Notes.io is built for speed and performance. You can take a notes quickly and browse your archive.
Easy: Notes.io doesn’t require installation. Just write and share note!
Short: Notes.io’s url just 8 character. You’ll get shorten link of your note when you want to share. (Ex: notes.io/q )
Free: Notes.io works for 12 years and has been free since the day it was started.
You immediately create your first note and start sharing with the ones you wish. If you want to contact us, you can use the following communication channels;
Email: [email protected]
Twitter: http://twitter.com/notesio
Instagram: http://instagram.com/notes.io
Facebook: http://facebook.com/notesio
Regards;
Notes.io Team