Skip to content

Microsoft & Privacy

Mein Firefox ist mit einem Addin ausgerüstet, das sich NoScript nennt. Dieses Addin blockiert alle Scripts und lässt sie nur auf expliziten Wunsch ausführen. Auf einer Microsoft Seite wurde ich dadurch auf ein lustiges kleines Script aufmerksam.

Ohne, dass der Besucher etwas merkt, wird, wenn er mit dem Internet Explorer unterwegs ist, ein kleines (1×1 Pixel grosses) Office ActiveX Objekt erstellt. Auf diesem wird eine Methode aufgerufen, die eine sonderbare Nummer in ein Coockie abspeichert, je nach installierter Office Version in eine andere Sektion.

Am 21.8.2007 13:20 Lokalzeit ist auf der Seite http://office.microsoft.com/ folgendes zu lesen:

<!DOCTYPE HTML PUBLIC '-//W3C//DTD HTML 4.0 Transitional//EN'>
<html>
<head>
        <meta http-equiv='content-type' content='text/html; charset=utf-8'>
</head>
<body>
        <noscript>
        <table border=0 height=95%>
                <tr><td valign=middle>
                        <div><center><b>One Moment Please...</b></center></div><br>
                        <div>To help optimize how your Web pages are displayed, we are checking to see if a 2007 Microsoft Office program is installed.</div><br>
                        <div>If this page does not automatically redirect, you have scripts disabled. <a href='/_services/errors/error.aspx?id=5'>See more information on scripts.</a></div><br>
                        <div><a href='http://office.microsoft.com/search/redir.aspx?assetid=FX010562591033'> Follow this link if the page is not redirected.</a></div>
                </td></tr>
        </table>
        </noscript>
<script language='JavaScript'><!--
function post()
{
        var cookies = document.cookie.split('; ');
        for (i = 0; i<cookies.length; i++) {
                if (cookies[i].indexOf('_ofcdet12=')==0) {
                        location.replace(location.href);
                        return;
                }
        }
        location.replace('/_Services/errors/errCookies.aspx');
}
//--></script> 

<script language='JavaScript'><!--
function ofcpost(x11, l11, _x12, _l12)
{
        var x12 = 'N';
        var l12 = '0';
        if (typeof(_x12) != 'undefined' && typeof(_l12) != 'undefined')
        {
                x12 = _x12;
                l12 = _l12;
        } 

        if ('N' != x11)
        {
                if (isNaN(Math.abs(x11)) || Math.abs(x11) < 39314)
                        x11 = 'N';
        } 

        if ('N' != x12)
        {
                if (isNaN(Math.abs(x12)) || Math.abs(x12) < 39314)
                        x12 = 'N';
        } 

        ofcstatus = (x11 != 'N' || x12 != 'N');
        ofcstatus12 = (x12 != 'N');
        document.cookie = '_ofcdet=x='+escape(x11)+'&l='+escape(l11)+'; path=/';
        document.cookie = '_ofcdet12=x='+escape(x12)+'&l='+escape(l12)+'; path=/';
        post();
}
//--></script>
<script language='VBScript'><!--
function ofctestax()
        on error resume next 

        set obj11 = document.createElement("object")
        document.body.appendChild(obj11)
        obj11.width = 1
        obj11.height = 1
        obj11.classid = "clsid:4453D895-F2A1-4A38-A285-1EF9BD3F6D5D"
        set ax11 = obj11.object
        x11 = ax11.GetOfficeX()
        l11 = ax11.GetOfficeLcid() 

        set obj12 = document.createElement("object")
        document.body.appendChild(obj12)
        obj12.width = 1
        obj12.height = 1
        obj12.classid = "clsid:C9712B19-838B-45A5-ABF2-9A315DDDED50"
        set ax12 = obj12.object
        x12 = ax12.GetOfficeX()
        l12 = ax12.GetOfficeLcid() 

        set obj12b = document.createElement("object")
        document.body.appendChild(obj12b)
        obj12b.width = 1
        obj12b.height = 1
        obj12b.classid = "clsid:6632AA50-49DC-475B-B911-A02B84C7C794"
        set ax12b = obj12b.object
        x12b = ax12b.GetOfficeX() 

        if IsEmpty(x11) then x11 = "N"
        if IsEmpty(x12) then x12 = "N"
        if IsEmpty(x12b) then x12b = x12
        if "N" = x12 or x12b > x12 then x12 = x12b 

        if IsEmpty(l11) then l11 = "0"
        if IsEmpty(l12) then l12 = "0" 

        ofcpost x11, l11, x12, l12
end function
//--></script> 

<script language='JavaScript'><!--
function IsOpera()
{
        if ('undefined' == typeof(navigator.appName) || null == navigator.appName)
                return false; 

        return (navigator.appName.toUpperCase().indexOf('OPERA') >= 0);
}
if (typeof(window.external)=='undefined') {
        if (navigator.mimeTypes['application/x-msoffice12'] != null && !IsOpera())
                document.write("<embed id='ofcnp' type='application/x-msoffice12' f='ofcpost' width='0' height='0'>");
        else if (navigator.mimeTypes['application/x-msoffice'] != null && !IsOpera())
                document.write("<embed id='ofcnp' type='application/x-msoffice' f='ofcpost' width='0' height='0'>");
        else
                ofcpost('N','0','N','0');
} else {
        if (typeof(ofctestax)!='undefined')
                ofctestax();
        else
                ofcpost('N','0','N','0');
}
//--></script> 

</body>

Das Coockie, das im IE Erzeugt wird, sieht etwa so aus:

awsuserguid
guid=*******
office.microsoft.com/
1024
2023980288
29945847
3588292880
29872220
*
_DetectCookies
Y
office.microsoft.com/
1024
208911616
30607079
3585012880
29872220
*
_ofcver12
x=2147483647&l=1033
office.microsoft.com/
1024
924677504
30023076
470248896
29876024
*
_ofcver
x=N&l=0
office.microsoft.com/
1024
924677504
30023076
470248896
29876024
*
_ofcresset
1
office.microsoft.com/
1088
547978112
29876253
4136781904
29876051
*
_ofcres
0000000
office.microsoft.com/
1088
3888987008
30022902
4137241904
29876051
*

Hier steht eine GUID. Darin ist die MAC Adresse der Netzwerkkarte, also eine eindeutige Kennung des PC’s, enthalten.

Office Version 12, sprich 2007
x= irgendeine Nummer, die das ActiveX Control zurückgibt
l= installierte Sprache

Office Version 11, Sprich 2003 füllt diesen Abschnitt
Auf dem PC, von dem das Coockie Stammt, ist diese Version nicht installiert