Hair cut
Well, I got a haircut. I like it. I had to touch it up a bit in the front when I got home, though; my bangs were slanted. Oh well, it turned out alright. Here’re some awesome photographs:


Aint it grand?
Well, I got a haircut. I like it. I had to touch it up a bit in the front when I got home, though; my bangs were slanted. Oh well, it turned out alright. Here’re some awesome photographs:


Aint it grand?
I just bought Ghosts I-IV from Amazon, for $5, as online MP3. Pretty sweet. It’s an all-instrumental 36-track album. I’m listening to it now, on track 8. It’s pretty great. Nine Inch Nails, awesome as always.
It may just be that the wireless driver is fux0red. I got it to work, somehow, when I lived at Winding Woods though. Oh well.
UPDATE:
I still can’t decide whether it is the wireless drivers or not. SSH stalled on the wrong places. Over the ethernet port, everything seemed fine. I guess there’s one test I can make: I’ll put tautology behind the DLink box, and see if I can ssh into it then. That will tell me pretty definitively whether it is the wifi driver or outside interference.
Well, I’ve encountered a nasty security problem here at home. Somebody is interfering with the wireless. Somebody is interfering with ssh, specifically. On the box I just set up, ssh both incoming and outbound hangs whenever it uses the wireless for its connection. However, it uses the wireless to do http just fine.
I tried connecting it through my laptop, itself connected through EVDO. Magically, it worked perfectly. I also tried sshing into the box from the laptop when they were connected by the ethernet cable instead of over the wifi. That worked perfectly too. But as soon as I switch to the wireless connection, everything fails.
It’s like somebody is blocking packets. Everything is incredibly slow, for no apparent reason. But only on the wifi.
A few days ago I bought a collection of the complete symphonies of Mozart. It’s pretty awesome. It’s been pretty much all I listen to recently. 41 is a lot. It’s something like 11 hours of classical music. Most excellent. :)
As part of my duties as a TA for CS367, I need to be able to help the students with their homeworks. This most recent assignment has been a devil. I can’t for the life of my figure out the last part. The gist of it is this:
Students are given a customized executable “bomb”. This is a program which takes six inputs from the user in sequence. Each input must be correct, or the “bomb” will “explode” and they lose 1/4 point on the homework. There is also a “quiet” bomb that won’t report their failures to the teacher, but won’t report their successes either. Each correct input earns them 10 points.
The students are not given the source code for the bomb. They have to figure out what it does and how it does it by themselves. Armed with a trusty copy of gdb, they are to disassemble the bomb, trace through its execution, and otherwise scrutinize it in order to figure out what the correct inputs are.
Because I am a sneaky guy, and it wasn’t forbidden, I took the liberty of applying a decompiler to the bomb. It helped a lot in defusing input 4, which became trivial once I saw the decompiled source. Of course, you need to know C inside and out to understand the decompiler’s outputted source, because the stuff is in many cases practically unreadable.
I have the disassembled and decompiled source code for phase 6, but I have yet to understand what the heck they are doing. The decompiled source isn’t much help either. It’s a mess, and barely better than the assembler version. I’ve been busting my brain about how this sucker works, and haven’t figured it out. I’ve spent a good 3 or 4 hours on this one phase, and I’ve gotten nowhere.
Just for grins, here’s the relevant assembler and source code:
08048d12 <phase_6>:
8048d12: 55 push %ebp
8048d13: 89 e5 mov %esp,%ebp
8048d15: 83 ec 08 sub $0x8,%esp
8048d18: 6a 00 push $0x0
8048d1a: 6a 0a push $0xa
8048d1c: 6a 00 push $0x0
8048d1e: ff 75 08 pushl 0x8(%ebp)
8048d21: e8 da fa ff ff call 8048800 <__strtol_internal@plt>
8048d26: 83 c4 10 add $0x10,%esp
8048d29: a3 1c a6 04 08 mov %eax,0x804a61c
8048d2e: 68 1c a6 04 08 push $0x804a61c
8048d33: e8 8a ff ff ff call 8048cc2 <fun6>
8048d38: ba 01 00 00 00 mov $0x1,%edx
8048d3d: 83 c4 04 add $0x4,%esp
8048d40: 8b 40 08 mov 0x8(%eax),%eax
8048d43: 42 inc %edx
8048d44: 83 fa 04 cmp $0x4,%edx
8048d47: 7e f7 jle 8048d40 <phase_6+0x2e>
8048d49: 8b 00 mov (%eax),%eax
8048d4b: 3b 05 1c a6 04 08 cmp 0x804a61c,%eax
8048d51: 74 05 je 8048d58 <phase_6+0x46>
8048d53: e8 3a 06 00 00 call 8049392 <explode_bomb>
8048d58: c9 leave
8048d59: c3 ret
08048cc2 <fun6>:
8048cc2: 55 push %ebp
8048cc3: 89 e5 mov %esp,%ebp
8048cc5: 56 push %esi
8048cc6: 53 push %ebx
8048cc7: 8b 75 08 mov 0x8(%ebp),%esi
8048cca: 8b 5e 08 mov 0x8(%esi),%ebx
8048ccd: c7 46 08 00 00 00 00 movl $0x0,0x8(%esi)
8048cd4: 85 db test %ebx,%ebx
8048cd6: 74 34 je 8048d0c <fun6+0x4a>
8048cd8: 89 f2 mov %esi,%edx
8048cda: 89 f1 mov %esi,%ecx
8048cdc: 85 f6 test %esi,%esi
8048cde: 74 15 je 8048cf5 <fun6+0x33>
8048ce0: 8b 06 mov (%esi),%eax
8048ce2: 3b 03 cmp (%ebx),%eax
8048ce4: 7e 0f jle 8048cf5 <fun6+0x33>
8048ce6: 89 d1 mov %edx,%ecx
8048ce8: 8b 52 08 mov 0x8(%edx),%edx
8048ceb: 85 d2 test %edx,%edx
8048ced: 74 06 je 8048cf5 <fun6+0x33>
8048cef: 8b 02 mov (%edx),%eax
8048cf1: 3b 03 cmp (%ebx),%eax
8048cf3: 7f f1 jg 8048ce6 <fun6+0x24>
8048cf5: 39 d1 cmp %edx,%ecx
8048cf7: 74 05 je 8048cfe <fun6+0x3c>
8048cf9: 89 59 08 mov %ebx,0x8(%ecx)
8048cfc: eb 02 jmp 8048d00 <fun6+0x3e>
8048cfe: 89 de mov %ebx,%esi
8048d00: 8b 4b 08 mov 0x8(%ebx),%ecx
8048d03: 89 53 08 mov %edx,0x8(%ebx)
8048d06: 89 cb mov %ecx,%ebx
8048d08: 85 c9 test %ecx,%ecx
8048d0a: 75 cc jne 8048cd8 <fun6+0x16>
8048d0c: 89 f0 mov %esi,%eax
8048d0e: 5b pop %ebx
8048d0f: 5e pop %esi
8048d10: c9 leave
8048d11: c3 ret
// address: 0x8048d12
void phase_6(int param2, int param1) {
int local0; // r24{40}
int local1; // r24{54}
int local10; // r26
int local11; // r28
int local2; // r24{33}
int local3; // r26{55}
int local4; // r24{28}
int local7; // local1{54}
int local8; // r24
*(int*)(local11 - 4) = param1;
*(int*)(local11 - 16) = 0;
*(int*)(local11 - 20) = 10;
*(int*)(local11 - 24) = 0;
*(int*)(local11 - 28) = param2;
__strtol_internal();
node0[0] = local8;
*(int*)(local11 - 16) = 0x804a61c;
local4 = fun6(0x804a61c, local8);
local7 = local4;
local10 = 1;
do {
local1 = local7;
local3 = local10;
local2 = *(int*)(local1 + 8);
local10 = local3 + 1;
local7 = local2;
} while (local3 + 1 <= 4);
local0 = *(int*)*(int*)(local1 + 8);
if (local0 != local8) {
explode_bomb(local11 - 4);
}
return;
}
// address: 0x8048cc2
fun6(int param1, int param2) {
int local10; // r30
int local3; // r27{58}
int local4; // m[r27 + 8]{39}
int local5; // r26{65}
int local6; // r25
int local7; // r26
int local8; // r27
int local9; // r28
local10 = param1;
local8 = *(int*)(param1 + 8);
*(int*)(param1 + 8) = 0;
if (local8 != 0) {
do {
local3 = local8;
local7 = local10;
local6 = local10;
if (local10 != 0) {
param2 = *(int*)local10;
if (*(int*)local10 > *(int*)local3) {
do {
local5 = local7;
local6 = local5;
local7 = *(int*)(local5 + 8);
if (*(int*)(local5 + 8) == 0) {
goto L4;
}
param2 = *(int*)*(int*)(local5 + 8);
} while (param2 > *(int*)local3);
}
}
L4:
if (local6 == local7) {
local10 = local3;
} else {
*(int*)(local6 + 8) = local3;
}
local4 = local7;
local8 = *(int*)(local3 + 8);
} while (*(int*)(local3 + 8) != 0);
}
return local10;
}
As you can see, the stuff is practically useless. fun6, in particular, is bizarre beyond measure. The assembler is riddled with things that don’t do anything, and the decompiled source looks like somebody took a crap on a keyboard.
Oh well.
Well, I just got hit by another car. It wasn’t too bad though. I stopped at a yellow light, they ran into me. Thwump!
My car had the license plate and some clips that hold it get bent. The other guy’s car looked pretty trashed, but he said that it was from hitting a deer previously. The cops came, and gave him a warning, because there was so little damage; he said his car wasn’t damaged at all.
Here’s a shot of my license plate. The paint on the bumper was already gone.
