Google-Hoax mit Schrecken

Heute morgen in meinem Mail-Postfach:


Betreff: Entfernung Ihrer Webseite www.fm-berger.de aus dem Google Index

Sehr geehrter Seiteninhaber oder Webmaster der Domain www.fm-berger.de,

bei der Indexierung Ihrer Webseiten mussten wir feststellen, dass auf
Ihrer Seite Techniken angewendet werden, die gegen unsere Richtlinien
verstossen. Sie finden diese Richtlinien unter folgender Webadresse:
[...]
Wir haben auf Ihren Seiten insbesondere die Verwendung folgender Techniken
festgestellt:
*Seiten wie z. B. fm-berger.de, die zu Seiten wie z. B.
http://www.fm-berger.de/index.htm mit Hilfe eines Redirects
weiterleiten, der nicht mit unseren Richtlinien konform ist.
[...]

Der Text ist wirklich in gutem Deutsch verfasst. Welcher Webmaster würde bei einer Mail mit diesem Inhalt keinen Schreck bekommen? Erst ein Blick auf heise.de (Gefälschte Google-Rauswurf-Mails sorgen erneut für Verunsicherung) brachte dann die Erleichterung. Die Prüfung des Header der Mail offenbart, das die Mail in meinem Fall aus China (Jiangsu Provinz) stammte.

Dies ist wirklich ein gutes Beispiel für Mails, bei denen die Authentizität des Absenders über eine PGP oder S/MIME Signatur sichergestellt werden sollte.

Oracle SQLPlus / Unix Shell Script interaction

Sometimes you need interaction between between sqlplus and unix shell scripts, like passing some shell variables to sqlplus or executing shell scripts based on the output of an SQL-Select statement.

I used the following demo table:

[frank@w0004 ~]$ sqlplus /nolog
SQL> connect foo/bar
SQL> create table foobar (line varchar2(20));
SQL> insert into foobar values('test1');
SQL> insert into foobar values('test2');
SQL> insert into foobar values('test3');
SQL> commit;

And here comes the shell script I used:

#!/bin/bash
username=foo
password=bar

sqlplus -s /nolog << EOF | grep -v 'Connected' > tmpout.txt
set pagesize 0 feedback off verify off head off echo off
connect $username/$password
whenever sqlerror exit 1
select line from foobar;
exit;
EOF

if [ -f tmpout2 ]; then 
  rm tmpout2.txt 
fi

for i in `cat tmpout.txt`; do
sqlplus -s /nolog << EOF | grep -v 'Connected' >> tmpout2.txt
set pagesize 0 feedback off verify off head off echo off
connect $username/$password
whenever sqlerror exit 1
select * from foobar where line = '$i';
exit;
EOF
echo $i "row";
done

Cyrus 2.3.8 and Thunderbird 2.0 ACL Problem

I am currently moving my IT infrastructure to a new server. That included also an switch to Cyrus IMAP 2.3.8 - which comes with Fedora Core 6. After an smooth and short move I have seen - so far - on problem in combination with Thunderbird 2.0. I could move mails to the trash, but all "Delete Mail" buttons are disabled. :-(

It turned out that Cyrus 2.3.8 has a few more ACLs and to resolve that issue I had to add those ACLs to my mailboxes. You have a lot of users with many mailboxes? Jo Rhett has posted a short Perl-Script on the info-cyrus maillinglist http://lists.andrew.cmu.edu/pipermail/info-cyrus/2007-April/025878.html.

VMware Server under FC6 Kernel 2.6.19

Sometimes the Linux Kernel can be a little bit painful in my opinion. Just tried to compile the VMware Server Kernel Modules under 2.6.19 and got:

make[1]: Entering directory `/usr/src/kernels/2.6.19-1.2911.6.5.fc6-i686'
  CC [M]  /tmp/vmware-config0/vmnet-only/driver.o
  CC [M]  /tmp/vmware-config0/vmnet-only/hub.o
  CC [M]  /tmp/vmware-config0/vmnet-only/userif.o
/tmp/vmware-config0/vmnet-only/userif.c: In function ‘VNetCopyDatagramToUser’:
/tmp/vmware-config0/vmnet-only/userif.c:629: error: ‘CHECKSUM_HW’ undeclared 
(first use in this function)
/tmp/vmware-config0/vmnet-only/userif.c:629: error: (Each undeclared identifier is 
reported only once
/tmp/vmware-config0/vmnet-only/userif.c:629: error: for each function it appears in.)
make[2]: *** [/tmp/vmware-config0/vmnet-only/userif.o] Error 1
make[1]: *** [_module_/tmp/vmware-config0/vmnet-only] Error 2

If you search for the error message in google you can already find some patches for the VMware Kernel Modules. But I preferred to get it working manually...

I added CHECKSUM_HW to /lib/modules/2.6.19-1.2911.6.5.fc6/build/include/linux/skbuff.h:


#define CHECKSUM_NONE 0
#define CHECKSUM_PARTIAL 1
#define CHECKSUM_HW 1
#define CHECKSUM_UNNECESSARY 2
#define CHECKSUM_COMPLETE 3

Since config.h is missing as well, I gave config.h an touch as well:

touch /lib/modules/2.6.19-1.2911.6.5.fc6/build/include/linux/config.h

Now the Kernel Modules compile and VMware Server is up and running :-D

23C3 - Brain Overflow Mitigation

Die Aufnahmefähigkeit des menschlichen Gehirns ist doch sehr begrenzt und so kommt es beim Besuch einer Messe oder einer Konferenz wie dem 23C3 schnell zur Überlastung. Die Halbwertszeit des aufgenommenen Wissens sinkt dann sehr schnell auf unter 30 Minuten. Aus diesem Grund habe ich mich zur möglichst schnellen Aufbereitung der Vortragsinhalte - unter anderem mit diesem Blog - entschlossen.

Ich bin echt begeistert vom bisherigen Verlauf des 23C3. Die Organistation ist gut und bisher scheint alles glatt und ohne Zwischenfälle zu verlaufen.

Today I had a few minutes of spare time and coded my first test program in Groovy, which uses GSQL and Groovy closures to access an Oracle database via JDBC:

import groovy.sql.Sql;

def my_id = 3;
def sql = Sql.newInstance("jdbc:oracle:thin:@localhost:1521:XE",
            "DS2", "DS2", "oracle.jdbc.driver.OracleDriver");

println("Printout all Products:");
sql.eachRow("SELECT prod_id, title from products order by prod_id") {
    println("${it.prod_id}, ${it.title}");
}

println("Printout Product with Prod_id=3:");
sql.eachRow("SELECT prod_id, title from products where prod_id = ${my_id}") {
    println("${it.prod_id}, ${it.title}");
}

I am really impressed by Groovy. Nice scripting language and if you know Java it is quite easy to get started! But be careful with it. The power of that language comes from heavy usage of OO techniques like Introspection and Reflection. Extensive usage can make a program quite slow. So it is up to you and your requirements...

Yesterdays presentation on "JSON RPC - Cross Site Scripting and Client Side Web Services" by Steffen Meschkat gave some inside information of the Google Maps API. He described in depth their approach with is very similar to an XSRF attack. They create SCRIPT-Tags on the fly to circumvent the same origin policy.

Again my stack for today: