Associate
- Joined
- 30 Aug 2009
- Posts
- 467
Here is the javascript from the bottom of the Barclays Online Banking website.
What I would like to know is if it seems to be setting a cookie?
I'd like to know this as I am planning on reporting Barclays to the ICO if Barclays don't comply with cookie legislation as of the 26th May this year.
The reason that I want to take that action is the following thread over at the Ghostery plugin discussion forum: here
What I would like to know is if it seems to be setting a cookie?
I'd like to know this as I am planning on reporting Barclays to the ICO if Barclays don't comply with cookie legislation as of the 26th May this year.
The reason that I want to take that action is the following thread over at the Ghostery plugin discussion forum: here
Code:
var gDomain="statse.webtrendslive.com";var gDcsId="dcssxcr8i00000stlemt7jpvp_8c9t";var gFpc="WT_FPC";var gConvert=true;var gFpcDom=".barclays.co.uk";if((typeof(gConvert)!="undefined")&&gConvert&&(document.cookie.indexOf(gFpc+"=")==-1)&&(document.cookie.indexOf("WTLOPTOUT=")==-1)){document.write("<SCRIPT TYPE='text/javascript' SRC='http"+(window.location.protocol.indexOf("https:")==0?"s":"")+"://"+gDomain+"/"+gDcsId+"/wtid.js'></SCRIPT>")};
Code:
var gService=true;var gTimeZone=0;function dcsCookie(){if(typeof(dcsOther)=="function"){dcsOther()}else{if(typeof(dcsPlugin)=="function"){dcsPlugin()}else{if(typeof(dcsFPC)=="function"){dcsFPC(gTimeZone)}}}}function dcsGetCookie(b){var d=document.cookie.indexOf(b+"=");if(d!=-1){var c=d+b.length+1;var a=document.cookie.indexOf(";",c);if(a==-1){a=document.cookie.length}return unescape(document.cookie.substring(c,a))}return null}function dcsGetCrumb(d,c){var b=dcsGetCookie(d).split(":");for(var e=0;e<b.length;e++){var a=b[e].split("=");if(c==a[0]){return a[1]}}return null}function dcsGetIdCrumb(c,b){var e=dcsGetCookie(c);var f=e.substring(0,e.indexOf(":lv="));var a=f.split("=");for(var d=0;d<a.length;d++){if(b==a[0]){return a[1]}}return null}function dcsFPC(g){if(typeof(g)=="undefined"){return}if(document.cookie.indexOf("WTLOPTOUT=")!=-1){return}var a=gFpc;var l=new Date();var j=(l.getTimezoneOffset()*60000)+(g*3600000);l.setTime(l.getTime()+j);var e=new Date(l.getTime()+315360000000);var k=new Date(l.getTime());WT.co_f=WT.vt_sid=WT.vt_f=WT.vt_f_a=WT.vt_f_s=WT.vt_f_d=WT.vt_f_tlh=WT.vt_f_tlv="";if(document.cookie.indexOf(a+"=")==-1){if((typeof(gWtId)!="undefined")&&(gWtId!="")){WT.co_f=gWtId}else{if((typeof(gTempWtId)!="undefined")&&(gTempWtId!="")){WT.co_f=gTempWtId;WT.vt_f="1"}else{WT.co_f="2";var m=l.getTime().toString();for(var h=2;h<=(32-m.length);h++){WT.co_f+=Math.floor(Math.random()*16).toString(16)}WT.co_f+=m;WT.vt_f="1"}}if(typeof(gWtAccountRollup)=="undefined"){WT.vt_f_a="1"}WT.vt_f_s=WT.vt_f_d="1";WT.vt_f_tlh=WT.vt_f_tlv="0"}else{var b=dcsGetIdCrumb(a,"id");var d=parseInt(dcsGetCrumb(a,"lv"));var n=parseInt(dcsGetCrumb(a,"ss"));if((b==null)||(b=="null")||isNaN(d)||isNaN(n)){return}WT.co_f=b;var f=new Date(d);WT.vt_f_tlh=Math.floor((f.getTime()-j)/1000);k.setTime(n);if((l.getTime()>(f.getTime()+1800000))||(l.getTime()>(k.getTime()+28800000))){WT.vt_f_tlv=Math.floor((k.getTime()-j)/1000);k.setTime(l.getTime());WT.vt_f_s="1"}if((l.getDay()!=f.getDay())||(l.getMonth()!=f.getMonth())||(l.getYear()!=f.getYear())){WT.vt_f_d="1"}}WT.co_f=escape(WT.co_f);WT.vt_sid=WT.co_f+"."+(k.getTime()-j);var c="; expires="+e.toGMTString();document.cookie=a+"=id="+WT.co_f+":lv="+l.getTime().toString()+":ss="+k.getTime().toString()+c+"; path=/"+(((typeof(gFpcDom)!="undefined")&&(gFpcDom!=""))?("; domain="+gFpcDom):(""));if(document.cookie.indexOf(a+"=")==-1){WT.co_f=WT.vt_sid=WT.vt_f_s=WT.vt_f_d=WT.vt_f_tlh=WT.vt_f_tlv="";WT.vt_f=WT.vt_f_a="2"}}function dcsMultiTrack(){if(arguments.length%2==0){for(var b=0;b<arguments.length;b+=2){if(arguments[b].indexOf("WT.")==0){WT[arguments[b].substring(3)]=arguments[b+1]}else{if(arguments[b].indexOf("DCS.")==0){DCS[arguments[b].substring(4)]=arguments[b+1]}else{if(arguments[b].indexOf("DCSext.")==0){DCSext[arguments[b].substring(7)]=arguments[b+1]}}}}var a=new Date();DCS.dcsdat=a.getTime();dcsFunc("dcsCookie");dcsTag()}}function dcsAdv(){dcsFunc("dcsET");dcsFunc("dcsCookie");dcsFunc("dcsAdSearch");dcsFunc("dcsTP")}var gImages=new Array;var gIndex=0;var DCS=new Object();if(typeof(WT)=="undefined"){var WT=new Object()}var DCSext=new Object();var gQP=new Array();var gI18n=false;if(window.RegExp){var RE={"%09":/\t/g,"%20":/ /g,"%23":/\#/g,"%26":/\&/g,"%2B":/\+/g,"%3F":/\?/g,"%5C":/\\/g,"%22":/\"/g,"%7F":/\x7F/g,"%A0":/\xA0/g};var I18NRE={"%25":/\%/g}}function dcsVar(){var b=new Date();WT.tz=b.getTimezoneOffset()/60*-1;if(WT.tz==0){WT.tz="0"}WT.bh=b.getHours();WT.ul=navigator.appName=="Netscape"?navigator.language:navigator.userLanguage;if(typeof(screen)=="object"){WT.cd=navigator.appName=="Netscape"?screen.pixelDepth:screen.colorDepth;WT.sr=screen.width+"x"+screen.height}if(typeof(navigator.javaEnabled())=="boolean"){WT.jo=navigator.javaEnabled()?"Yes":"No"}if(document.title){WT.ti=gI18n?dcsEscape(dcsEncode(document.title),I18NRE):document.title}WT.js="Yes";WT.jv=dcsJV();if(document.body&&document.body.addBehavior){document.body.addBehavior("#default#clientCaps");WT.ct=document.body.connectionType||"unknown";document.body.addBehavior("#default#homePage");WT.hp=document.body.isHomePage(location.href)?"1":"0"}else{WT.ct="unknown"}if(parseInt(navigator.appVersion)>3){if((navigator.appName=="Microsoft Internet Explorer")&&document.body){WT.bs=document.body.offsetWidth+"x"+document.body.offsetHeight}else{if(navigator.appName=="Netscape"){WT.bs=window.innerWidth+"x"+window.innerHeight}}}WT.fi="No";if(window.ActiveXObject){for(var d=10;d>0;d--){try{var c=new ActiveXObject("ShockwaveFlash.ShockwaveFlash."+d);WT.fi="Yes";WT.fv=d+".0";break}catch(g){}}}else{if(navigator.plugins&&navigator.plugins.length){for(var d=0;d<navigator.plugins.length;d++){if(navigator.plugins[d].name.indexOf("Shockwave Flash")!=-1){WT.fi="Yes";WT.fv=navigator.plugins[d].description.split(" ")[2];break}}}}if(gI18n){WT.em=(typeof(encodeURIComponent)=="function")?"uri":"esc";if(typeof(document.defaultCharset)=="string"){WT.le=document.defaultCharset}else{if(typeof(document.characterSet)=="string"){WT.le=document.characterSet}}}WT.tv="8.0.2";DCS.dcsdat=b.getTime();DCS.dcssip=window.location.hostname;DCS.dcsuri=window.location.pathname;if(window.location.search){DCS.dcsqry=window.location.search;if(gQP.length>0){for(var d=0;d<gQP.length;d++){var h=DCS.dcsqry.indexOf(gQP[d]);if(h!=-1){var f=DCS.dcsqry.substring(0,h);var a=DCS.dcsqry.substring(h+gQP[d].length,DCS.dcsqry.length);DCS.dcsqry=f+a}}}}if((window.document.referrer!="")&&(window.document.referrer!="-")){if(!(navigator.appName=="Microsoft Internet Explorer"&&parseInt(navigator.appVersion)<4)){DCS.dcsref=gI18n?dcsEscape(window.document.referrer,I18NRE):window.document.referrer}}}function dcsA(b,a){return"&"+b+"="+dcsEscape(a,RE)}function dcsEscape(a,d){if(typeof(d)!="undefined"){var c=new String(a);for(var b in d){c=c.replace(d[b],b)}return c}else{return escape(a)}}function dcsEncode(a){return(typeof(encodeURIComponent)=="function")?encodeURIComponent(a):escape(a)}function dcsCreateImage(a){if(document.images){gImages[gIndex]=new Image;gImages[gIndex].src=a;gIndex++}else{document.write('<IMG ALT="" BORDER="0" NAME="DCSIMG" WIDTH="1" HEIGHT="1" SRC="'+a+'">')}}function dcsMeta(){var a;if(document.all){a=document.all.tags("meta")}else{if(document.documentElement){a=document.getElementsByTagName("meta")}}if(typeof(a)!="undefined"){for(var b=1;b<=a.length;b++){var c=a.item(b-1);if(c.name){if(c.name.indexOf("WT.")==0){WT[c.name.substring(3)]=(gI18n&&(c.name.indexOf("WT.ti")==0))?dcsEscape(dcsEncode(c.content),I18NRE):c.content}else{if(c.name.indexOf("DCSext.")==0){DCSext[c.name.substring(7)]=c.content}else{if(c.name.indexOf("DCS.")==0){DCS[c.name.substring(4)]=(gI18n&&(c.name.indexOf("DCS.dcsref")==0))?dcsEscape(c.content,I18NRE):c.content}}}}}}}function dcsTag(){if(document.cookie.indexOf("WTLOPTOUT=")!=-1){return}var a="http"+(window.location.protocol.indexOf("https:")==0?"s":"")+"://"+gDomain+(gDcsId==""?"":"/"+gDcsId)+"/dcs.gif?";for(var b in DCS){if(DCS[b]){a+=dcsA(b,DCS[b])}}for(b in WT){if(WT[b]){a+=dcsA("WT."+b,WT[b])}}for(b in DCSext){if(DCSext[b]){a+=dcsA(b,DCSext[b])}}if(a.length>2048&&navigator.userAgent.indexOf("MSIE")>=0){a=a.substring(0,2040)+"&WT.tu=1"}dcsCreateImage(a)}function dcsJV(){var h=navigator.userAgent.toLowerCase();var s=parseInt(navigator.appVersion);var f=(h.indexOf("mac")!=-1);var n=(h.indexOf("firefox")!=-1);var c=(h.indexOf("firefox/0.")!=-1);var i=(h.indexOf("firefox/1.0")!=-1);var d=(h.indexOf("firefox/1.5")!=-1);var g=(n&&!c&&!i&!d);var b=(!n&&(h.indexOf("mozilla")!=-1)&&(h.indexOf("compatible")==-1));var e=(b&&(s==4));var p=(b&&(s>=5));var r=((h.indexOf("msie")!=-1)&&(h.indexOf("opera")==-1));var j=(r&&(s==4)&&(h.indexOf("msie 4")!=-1));var q=(r&&!j);var m=(h.indexOf("opera")!=-1);var l=(h.indexOf("opera 5")!=-1||h.indexOf("opera/5")!=-1);var k=(h.indexOf("opera 6")!=-1||h.indexOf("opera/6")!=-1);var a=(m&&!l&&!k);var o="1.1";if(g){o="1.7"}else{if(d){o="1.6"}else{if(c||i||p||a){o="1.5"}else{if((f&&q)||k){o="1.4"}else{if(q||e||l){o="1.3"}else{if(j){o="1.2"}}}}}}return o}function dcsFunc(a){if(typeof(window[a])=="function"){window[a]()}}dcsVar();dcsMeta();dcsFunc("dcsAdv");dcsTag();
Code:
WT=new Object();DCS=new Object();DCSext=new Object();function dcsAjax(){var a=$("#_wt");if(a.length){var d=a.metadata(),e,b;for(b in d){e=d[b];if(b.indexOf("WT.")==0){WT[b.substring(3)]=(gI18n&&(b.indexOf("WT.ti")==0))?dcsEscape(dcsEncode(e),I18NRE):e}else{if(b.indexOf("DCSext.")==0){DCSext[b.substring(7)]=e}else{if(b.indexOf("DCS.")==0){DCS[b.substring(4)]=(gI18n&&(b.indexOf("DCS.dcsref")==0))?dcsEscape(e,I18NRE):e}}}}DCS.dcssip=window.location.hostname;if(_wt.dcsurl!==undefined&&_wt.dcsurl!==""){$.url.setUrl(_wt.dcsurl);var c=$.url.attr("query");if(c!==null){c="?"+c}DCS.dcsqry=c;DCS.dcsuri=$.url.attr("path");if(DCS.dcsuri===""){DCS.dcsuri=_wt.dcsurl}}if(_wt.dcsref===undefined||_wt.dcsref===""){DCS.dcsref=window.location.href}else{DCS.dcsref=_wt.dcsref}a.remove()}}function dcsPageComplete(){dcsVar();dcsAjax();dcsFunc("dcsAdv");dcsTag()};
Code:
iBarclays.WebAnalytics=(function(){function d(){b("DCS.dcsuri","TaskView/ModuleMenu","DCSext.TaskView-AccountManagement","ModuleMenu","WT.dl","11","WT.seg_1","Editor")}function f(){b("DCS.dcsuri","TaskView/ModuleMenu","DCSext.TaskView-AccountManagement","ModuleMenu","WT.dl","11","WT.seg_1","Editor")}function e(i,j){j=$.trim(j);b("DCS.dcsuri","TaskView/Modules","WT.seg_1","Editor","DCSext.ModuleAdded",j)}function h(i,j){j=$.trim(j);b("DCS.dcsuri","TaskView/Modules","WT.seg_1","Editor","DCSext.ModuleRemoved",j)}function c(){var j=$("meta[name=WT.dcsvid]").attr("content");var i=$("meta[name=WT.seg_2]").attr("content");dcsMultiTrack("DCS.dcsuri","Accounts/See Statements","WT.dcsvid",j,"WT.seg_2",i,"WT.ti","","WT.seg_1","Money Manager","DCSext.StatementsView","eStatements")}function b(){var k,j;if(arguments.length%2==0){for(k=0;k<arguments.length;k+=2){if(arguments[k].indexOf("WT.")==0){WT[arguments[k].substring(3)]=arguments[k+1]}else{if(arguments[k].indexOf("DCS.")==0){DCS[arguments[k].substring(4)]=arguments[k+1]}else{if(arguments[k].indexOf("DCSext.")==0){DCSext[arguments[k].substring(7)]=arguments[k+1]}}}}WT.dcsvid=$("meta[name=WT.dcsvid]").attr("content");WT.seg_2=$("meta[name=WT.seg_2]").attr("content");j=new Date();DCS.dcsdat=j.getTime();dcsFunc("dcsCookie");dcsTag();WT=new Object();DCS=new Object();DCSext=new Object()}}function a(){WT={};DCS={};DCSext={};dcsPageComplete()}function g(){$(document).bind("modal.open.complete.webtrends",a);$(document).bind("takeover.open.complete.webtrends",a);$(document).bind("modal.open.complete.webtrends",iBarclays.TouchClarity.log);$(document).bind("takeover.open.complete.webtrends",iBarclays.TouchClarity.log);$(document).bind("drawer.opened",d);$(document).bind("drawer.closed",f);$(document).bind("module.opened",e);$(document).bind("module.closed",h);$(document).bind("pdf.download.webtrends",c)}$(g)})();
Last edited: