Online-Banking Bank Austria die 2.


Jetzt habe ich gerade einige Überweisungsvorlagen geändert. Man muss sich jedesmal durch das ganze Menu hangeln, wenn man gerade eine Vorlage editiert hat — eine normale Browser-Navigation mit dem “Zurück”-Knopf ist unmöglich. Navigation von einer Vorlage zur nächsten braucht > 5 Klicks — von denen jeder einige (zig) Sekunden dauert, weil das neue System so langsam ist.

Aber viel skurriler: Ich habe einige Vorlagen deren Name mit einem großen “Ö” beginnt. Nun würde ich es verstehen, wenn das System keine Umlaute mag und diese einfach am Anfang oder Ende einsortiert (also vor dem “A” oder nach dem “Z”) wenn schon nicht in der Nähe von “O”. Aber bei der Bank Austria muss man das “Ö” zwischen dem “R” und dem “S” suchen. Ich habe mich einmal durch alle meine (mehr als 80) Vorlagen geklickt um die mit dem “Ö” zu finden.

Sehr kreativ.

Online-Banking Bank Austria


Ich bin (noch?) Kunde der Bank Austria. In der Presse konnte man ja schon lesen, dass das neue Online-Banking ein “Epic Fail” ist. Was mich wundert: Warum hat da nicht jemand mal einfach nur die generierten Konto-Auszüge angesehen? Da braucht es keinen Super Test, man sieht sofort mit blosem Auge (oder bei Vergleich mit den alten Kontoauszügen) dass das b0rken ist:

  • Auf den Kontoauszügen fehlt bei allen Überweisungen der Zahlungsempfänger, im Buchungstext steht dann z.B. nur “Online Auftrag vom …” und ich muss woanders (in meiner Buchhaltung oder im Online Banking) nachsehen an wen ich da überwiesen habe
  • Die letzte Zeile auf der Seite wird vom Seitenrand durchgestrichen
  • Datum ist mal durch Punkt, mal durch / getrennt
  • Beträge sind nicht aligned sondern in der Spalte zentriert (!)
  • Der neue Ausdruck ist wesentlich mehr Platzverschwendend als der alte durch die teilweise unnützen Spalten (Währung) und das Querformat.

Kontoauszug: Beispiel

Diese Defekte sind auch beim letzten Software-Rollout nicht gefixt. Die Anordnung der Buchungszeilen hat sich leicht geändert, aber die letzte wird immer noch durchgestrichen — der Strich ist jetzt etwas dünner so dass man die Zeile zumindest lesen kann.

Was mich auch stört:

  • Direkt drucken wie im alten online Banking geht nicht, man muss immer zuerst ein PDF generieren (Im Filesystem, ein inline-View funktioniert offensichtlich nicht, ist aber möglicherweise ein Browser setting)

Nachdem mir das das erstemal passiert ist (einige Tage nach dem initialen Rollout) habe ich versucht, über das neue System eine eMail an meinen Betreuer zu schicken. Nachdem ich fertig war und auf “Senden” gedrückt habe, bekam ich die Meldung “Die online Aktivitätszeit ist abgelaufen” und meine Mail war weg.

Man fragt sich wer da was getestet hat — offensichtlich wurden nichtmal die alten Konto-Listings mit den neuen verglichen.

SIGALRM blocked forever -- by init


I’m working on an embedded Linux system which allows to chose the root filesystem to boot from (flash card or NAND flash) early in the boot process. Now I was trying to get ppp (for a GSM/GPRS connection) working. But the chat-script hangs forever, it does not get a timeout. Turns out, chat uses alarm(2) to wait for a timeout. After quite some time of debugging I found out that SIGALRM is blocked (look for SigBlk in /proc/pid/status, this is the mask of blocked signals for process with pid).

After some googling I came across a blog entry (look for September 5, 2011) that describes a bug in bash: Bash, when calling “read” with a timeout, will install a signal handler for SIGALRM and longjump out of the signal handler, leaving SIGALRM blocked forever.

The boot-script runs as init (with pid 1) and therefore will leave SIGALRM blocked for all children. My immediate workaround is to read the filesystem to boot in a sub-shell…seems the bug is fixed with newer versions of bash.

Skype Compression Now Published


A while ago I blogged about the first published information about reverse-engineering of Skype (Skypes Flux Capacitor has been released, Skypes Flux Capacitor: UDP). A missing piece in the puzzle was the arithmetic compression algorithm used by Skype, details about which were first published in Silver Needle in the Skype. Meanwhile I’ve seen source code of the compression algorithm from two different sources — one of them on a blog on Open Source Skype, although that version doesn’t seem to be available any longer on that page, try the usual sources to find “removed” internet-information. The code is both versions is different. I’ve not yet had the time to further look into this (and try out the code on actual Skype packets) but from what I’ve seen the code looks genuine. There are some questions, though, if the code works with later versions of Skype, it seems the protocol was slightly changed recently.
There is also some press coverage from the interview with Efim Bushmanov, the author of the menioned blog:

So we now have alle the pieces of the puzzle to start writing a plugin for Wireshark to give us a tool to further analyze the network traffic produced by Skype. Maybe an open source client is on the horizon now (there’s still a long way to go since we don’t know the binary formats used by the voice and video codecs in Skype, but maybe keyboard-chat is within reach now). Shameless Plug: If you have resources (money or time) to help writing a Wireshark plugin for Skype, please contact me, I’m trying to coordinate efforts in this direction.
That said, there are rumors that (one of) the Skype Certificate-Authority-Key (the Root key in a certificate chain) was leaked. Lets see what comes from this… leaking the key could make communications available to third parties or forge identities. But be aware that the makers of Skype probably already do have the mechanisms in place to listen into the contents of Skype traffic as was first hinted at by the Silver Needle in the Skype presentation and which I’ve mentioned in my talks on Skype (presentation material linked from my home page).
Looks like Microsoft has aquired a piece of software here that perfectly fits its security record so far — this could be helped by letting independent researchers look at the Skype protocol design, but may well uncover further problems down the road. We again see here that secrecy won’t help security in the long run, we may view this as a generalisation of Kerckhoffs’ Principle. Opening the procotol like speculated in the article Skype reverse-engineered by Russian geek is still a very unlikely move by Microsoft, in my view… but I would certainly welcome this.

LILO "junk in compressed archive" and Grub2 "out of disk" error


I’ve recently upgraded a Debian/Asterisk Installation on an older Soekris Net 4501 embedded hardware. After the upgrade the device didn’t boot anymore. The installed LILO bootloader produced the error message:

Initramfs unpacking failed: junk in compressed archive

and later failed with a kernel panic


VFS: Unable to mount root fs on unknown-block(0,0)

Googling for the error message found a blog entry that indicated a missing LILO option “large-memory” — which wasn’t the problem in my case, the option was already present.
So I booted into GRML and installed grub2 instead of LILO. After a reboot, Grub2 ended up in rescue mode with the error message:

error: out of disk.
grub rescue>

I could display the partitions with ls and also get a listing from my root partition but trying to list other directories produces the “out of disk” error again:


grub rescue> ls
(hd0) (hd0,msdos1) (hd1) (hd2) (hd3) 
…
grub rescue> ls (hd0,msdos1)/
./ ../ lost+found/ var/ etc/ media/ initrd.img usr/
…

grub rescue> ls (hd0,msdos1)/boot

error: out of disk.

So my diagnosis was that the BIOS of the Soekris box is unable to address the whole (in this case 60GB) harddisk. The install had only worked before because the kernel and the /boot directory where within the BIOS-accessible area on the disk. So there are still BIOSes out there that don’t support large harddisks — I didn’t find out until now what the limit of the Soekris BIOS is. The fix after this diagnosis was easy: Shrink the root filesystem using resize2fs, create a new root partition and copy the shrunken filesystem there, resize2fs to the new partition size. Create a new small /boot partition at the start of the disk and copy the contents of the old /boot directory there. Of course this is only possible with a working rescue system, my rescue system of choice is a GRML netboot setup which enables me to quickly boot any x86-based system that supports network boot.
Lesson learned: For small X86 embedded hardware it still makes sense to have a small /boot partition.

Thomas Greco in Vienna


Yesterday evening Thomas Greco was in Vienna. We were a mixed audience coming from different fields all interested in the money problem.
Thomas started by introducing himself and his history. He has an engineering background and worked as a college professor. Got “yanked out of the matrix in 1974″, seeing that not everything we see is as it appears. Started asking questions about problems like war, poverty, exploitation and how to solve these problems.
One day he had a book in the mail “In the Wake of Inflation Can the Church Remain Silent?”, he checked the few references and found (some of) them sound. The question why they allow the money-system to exist kept gnawing at him and he got in touch with the author, they eventually became good friends. He helped put out a second edition of the book. His questions were why the church doesn’t mention usury and why social justice if not part of their program.
He participated in several land-trust, school of living and other projects and his focus narrowed down to money and banking. Over the time he helped starting several local currency projects and wrote several books which document what was learned (a joke was that much was learned from failed projects). The first two books can be downloaded from reinventingmoney.com, the third is available as an EBook-Excerpt, for the fourth there is an excerpt at google books. I’ve read the fourth and can recommend it as one of the most systematic treatments of our current money system problem I know. Books are:

  • Money and Dept: A Solution to the Global Crisis (2nd ed. 1990)
  • New Money for Healthy Communities 1994
  • Money — Understanding and Creating Alternatives to Legal Tender 2001
  • The End of Money and the Future of Civilization 2009

Tom then proceed to outline the history of money: It started out with barter exchange, the first form of money was commodity-money, various commodities like tobacco (cigarettes), flour or grain, nails and precious metals like silver and gold (highly valued in small amounts, portable, durable) served as money. What follows is symbolic money: the first bankers were goldsmiths depositing gold for their customers, the receipt from the bank about the deposit of gold served as a place-holder for the gold. When goldsmiths discovered that they could give receipts not only to people depositing gold, but also to people who came to borrow it, credit money (the 3rd form) was born. The last form is credit clearing where we keep only an account for each member and incoming money is added while outgoing money is subtracted. The main problem of credit is interest which exploits people.
Then a discussion where Franz Nahrada claimed that money is always an alienation ensued. Thomas explained that the farther the relationships among people are, the higher the need for money: In the family we don’t need (and don’t want) money. With a close neighbor we expect some reciprocity (we keep in mind if the other person is always taking). For dealing with people you don’t know we need some kind of formalized structure. But he agreed that a closer community relationship is a good goal. It was mentioned that experiences without money (where you lose your wallet and have to find your way without money for some time) can be a lasting positive experience, on the other hand money may cut through relationships…
In the discussion I asked about Toms view about demurrage, a negative interest rate on money. He answered that demurrage is an unnecessary “stamp scrip” (so called because some demurrage currencies use stamps that have to be bought and affixed to the banknotes) first introduced by Silvio Gesell and that it’s unfortunate that demurrage is the only one of his proposals that is generally remembered. Demurrage currencies where successful in a time where any kind of exchange medium would have been successful. The problem demurrage tries to solve, the prevention of hording (mainly of paper currencies) could be solved by reallocating excess money to (new) businesses. I noted that Gesell also had this in mind when he argues that when depositing excess money in a bank for re-lending, he proposes that there should be no demurrage. (I’m still not fully convinced that demurrage might not be a good tool at times) We agreed that a shortcoming of Gesell is that he can only envision a central banking system while Thomas recommends the separation of money and state (I also think this currently is our best option). There is also a blog post on demurrage by Tom.
During the discussion Tom remarked that due to the “Bubble and Bust Cycle” of our current money system, banks always have to find new ways to indept the people. When he studied, there were no student loans. This is a new idea that came up in the 60s. In the 90s we had the dot com bubble and the recent crisis in 2008 added a lot more dept to the private sector. He thinks we reached the end of the line, the dollar will probably be inflated out of existence. One of the outcomes of a hyper-inflation like Weimar in the 1920s is that the middle class gets wiped out. They still have savings but these won’t buy anything. Maybe the plan for after the inflation is a global currency. A question about the timeframe for these predicted events was answered that it’s hard to say, but China already has satisfied its appetite on US government bonds now buying gold. Maybe an America-wide new currency (Amero) or a global currency will be the plan. This would wipe out everyones savings and re-start the game, hopefully not everybody will go along with this.
In the later discussion I asked — when Tom had talked about the Government and the central banks cooperating — that up until now I had seen the private banking as the problem and the state more in the role of a victim. Tom replied that they are cooperating and that this cooperation was introduced in the early days of the Bank of England (when the king needed money for war). In a blog post When will the dollar die? Greco also outlines a facet of that cooperation: “National governments are unique in being able to play this role [of borrower of last resort] because of their collusive arrangement with the banking cartel.”
We also had some discussions on emerging trends, barter exchanges (which aren’t really barter in the original sense of the word). Tom said that if businesses are not involved early on in an alternative currency project, it is bound to fail. Barter exchanges that only involve retailers can work to a certain degree of circulation. But for a robust system, manufacturers, employess are needed to close the circle. Not all suppliers are within a region, so we have to get regions to cooperate. Mistakes that have been made by some local exchanges (which is detrimental to their own business and the whole “industry”) are:

  • competition with members (taking the best things for themselves)
  • too much credit for themselves (debasing their own currency)

Tom also mentioned Argentina during the discussion which had a strong social currency movement in the early 2000s with dozens of trade exchanges. The system (nearly) collapsed due to mis-managed, my question if this was induced by outsiders was answered that there were accusations of counterfeiting by the central government or other authorities but it is unclear if this is true. When he visited Argentina, there already was counterfeiting in some of the largest exchanges and they didn’t do anything about it. Now they have better safeguards.
The following links are taken from the discussions (no particular order, Tom is not affiliated with any of them as far a I know but knows some of the creators as “cooperatively minded entrepreneurs”), during the discussion I noted that we would need a common protocol among different barter and community currency enterprises, so that not everybody builds his own “walled garden” which was agreed… I’ve written about that problem before when writing about cloud computing.

  • Cyclos, a system for manageing lets trading circles
  • zacle.com an newly started web-based exchange (this takes ages to load for me with layers upon layers of javascript, that by default isn’t enabled when I surf with noscript, so not a site I’d ever use)
  • poiu.com , another trading system
  • community exchange network www.ces.org.za
  • getsplus.com: a proprietary platform where a lot of money was invested, it’s a cashless trading platform which might eventually become open source
  • virtualbarter.net an online barter exchange
  • imsbarter.com one of the biggest US barter companies
  • www.favors.org a social network by Sergio Lub
  • www.livingdirectory.org one of the first social networks with 60.000 people worldwide participating, has levels “identified” (a real person), “sponsor” (trust someone to sponsor other people) and “networker” (full access to the system).

At the end we watched the short film The Essence of Money (4:13) that outlines how money works. In my opinion it’s also a good illustration how a distributed money system — where every player in the game can issue his/her own money — could work. With todays electronic systems we maybe can come up with a solution that is distributed: compare this to file-sharing systems that started out as centralized systems like Napster and evolved into distributed systems like Gnutella today. The film Money as Dept was recommended, there seems to be a sequel, the original seems to be available in several places on the net.

Unix Domain Sockets


I recently had to find a solution for a communication problem: An application running on a web-server should update configuration files that are only readable by a privileged user and these should not be directly writeable by the web-server user.
So the idea was to write an update-server running under the privileged account which receives update requests (and can perform additional checks) from the unprivileged web server user.
One of the checks I wanted to make was that only the web-server user (www-data on debian) should be able to send update requests. So I had to find out the user sending a request via the Unix-domain socket. Google found a nice socket howto on Henning Makholm’s blog which told me most of what I needed to know: “so I ended up just checking the EUID of the client process after the connection has been accept()ed. For your reference, the way to do this is getsockopt() with SO_PEERCRED for Linux”.
But one issue was remaining: I didn’t need a SOCK_STREAM socket but wanted to send datagrams to the other side (and didn’t want to fiddle with implementing my own datagram layer on top of a stream socket). With normal SOCK_DGRAM datagram sockets there is no connection — and therefore I can’t determine the user sending the datagram from the other side of the socket.
Looking further I discovered that Linux has connection-oriented datagram sockets for quite some time under the name SOCK_SEQPACKET. With this type of socket you first connect() to the other side and then you send a datagram. Since now there is a connection the trick with SO_PEERCRED as described above works, too.
Code for Server (python):


from socket import socket, SOCK_SEQPACKET, AF_UNIX, SOL_SOCKET
from struct import unpack
try :
    # Not implemented in python 2.6, maybe higher
    from socket import SO_PEERCRED
except ImportError :
    SO_PEERCRED = 17 # Linux
sock = socket (AF_UNIX, SOCK_SEQPACKET)
path = ‘/path/to/socket’
try :
    os.remove (path)
except OSError :
    pass
sock.bind (path)
conn, adr = self.sock.accept ()
ucred = conn.getsockopt (SOL_SOCKET, SO_PEERCRED, 12)
pid, uid, gid = unpack (‘LLL’, ucred)
if uid… check uid:
    error…
    conn.close ()

data = conn.recv (4096)

Code for client (python):


from socket import socket, SOCK_SEQPACKET, AF_UNIX
s = socket (AF_UNIX, SOCK_SEQPACKET)
s.connect (‘path/to/socket’)
s.send (…..)
s.close ()

Skypes Flux Capacitor: UDP


I recently wrote about the broken network obfuscation code (aka Flux Capacitor) of Skype published by Sean O’Neil. At the time I wasn’t able to decrypt UDP packets. Now I’ve looked a little more closely into the Vanilla Skype documentation — which also includes some code to decrypt Skype credentials on harddisk. This code contains a CRC implementation called CRC32. I had wrongly asumed that CRC32 of Skype would be the same as the crc32 implementation of pkzip, Ethernet, png, the POSIX cksum command etc. which is listed as “crc32″ in the CRC article on Wikipedia and which is standardized in e.g. IEEE 802.3.
The crc32 from the standards above inverts all the bits of the seed before using it (it uses an XOR mask of 0xFFFFFFFF) and does this again before returning the result of the CRC computation to the caller. But it uses the same polynomial as skype. So we can use an existing standard CRC implementation (e.g from the zlib library) as follows for computing the skype CRC:

def skype_crc (s, seed = 0xFFFFFFFF) :
    return (crc32 (s, seed ^ 0xFFFFFFFF)) ^ 0xFFFFFFFF

With this crc implementation I’m now able to also decrypt UDP (see updated code) packets. I’ve shown this some days ago at my talk @linuxwochenende, for slides see my events page.

Skypes Flux Capacitor has been released


Skype uses an obfuscation layer for making it harder for others to analyze the Skype network traffic. This obfuscation layer has been called “Flux Capacitor” by the authors of the 2006 publications “Silver Needle in the Skype” and “Vanilla Skype”, Philippe Biondi, Fabrice Desclaux, and Kostya Kortchinsky, see the Wikipedia article on Skype for references about their publications. They discovered this flux capacitor code when reverse engineering the Skype binary program but didn’t dare to publish it for fear of others attacking the Skype network. They hinted at all sorts of bad things that were possible when knowing the Skype prototocol, the least of which is scanning networks behind firewalls (Skype is well known to be able to connect to the internet even in the presence of firewalls).
Now this Flux Capacitor code has been released by a group called “Skype Reverse Engineering Team” in a blog post Skype’s Biggest Secret Revealed by Sean O’Neil claiming that the code was already leaked and used by spammers. But they didn’t tell us how to use that code and defer further information to the next Chaos Communication Congress 27C3.
I certainly hope that the security holes in Skype are not that bad as feared by others. Some good can come out of it: maybe we’ll see a free Skype client in the not-too-far future. A good plan now would be to write a Wireshark dissector for Skype so that we can analyze the network traffic. Unfortunately the authors didn’t tell us yet how to call that code to de-obfuscate Skype traffic. But there is plenty of information in the aforementioned publications. So I’ve written a Makefile to create a shared library from the now released code and a Python wrapper that decrypts a single packet from a Skype network dump called SkypeIRC.cap published on the Wireshark page. This at least proves that the code works — the first several bytes of a Skype TCP stream decrypt to a known value.
Maybe others want to use this as a starting point before more is released by the authors at the Chaos Communication Congress 27C3.