Skip to content

Instantly share code, notes, and snippets.

@brettp
Created May 15, 2014 16:14
Show Gist options
  • Save brettp/1a80438d3e2c7c64f2fc to your computer and use it in GitHub Desktop.
Save brettp/1a80438d3e2c7c64f2fc to your computer and use it in GitHub Desktop.
Tracking JS that Hughesnet inserts into the <head> of each page
<script type="text/javascript">
/* <![CDATA[ */
Math.random = function (a, c, d, b) {
return function () {
return 300 > d++ ? (a = (1103515245 * a + 12345) % b, a / b) : c()
}
}(1287608430, Math.random, 0, 1 << 21);
(function () {
function b() {
try {
if (top.window.location.href == c && !0 != b.a) {
var a = -1 != navigator.userAgent.indexOf('MSIE') ? new XDomainRequest : new XMLHttpRequest;
a.open('GET', 'http://1.2.3.4/cserver/clientresptime?cid=CID5266760.AID1400103747.TID2716&url=' + encodeURIComponent(c) + '&resptime=' + (new Date - d) + '&starttime=' + d.valueOf(), !0);
a.send(null);
b.a = !0
}
} catch (e) {}
}
var d = new Date,
a = window,
c = document.location.href,
f = 'undefined';
f != typeof a.attachEvent ? a.attachEvent('onload', b) : f != typeof a.addEventListener && a.addEventListener('load', b, !1)
})(); /* ]]> */
</script>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment