The Difference Engine: Charles Babbage and the Quest to Build the First Computer is ½ nineteenth-century biography and ½ modern-day struggle to realize Babbage's design. this book took me longer to finish than usual... some of the details in the telling of Babbage's life drag on and i ended up skipping them. the modern half, the project by the Science Museum of London to construct the first full implementation of Babbage's Difference Engine No. 2 is quite interesting. this book does a good job of putting Mr. Babbage in his place. he designed a limited programmable computing machine... but is not the father of the modern computer. he was a very, very smart man... but not alone in mechanizing arithmetic in the nineteenth century. he visualized a working machine completely in his head... but failed to implement it.
room_type 0 in your console (hit the ~ key) will disable the annoying Counter-Strike echo bug
#define xstr(s) str(s)
#define str(s) #s
#define foo 4
str (foo)
==> "foo"
xstr (foo)
==> xstr (4)
==> str (4)
==> "4"
restrict Qualifier in C
America's Secret War, written by a private security consultant to the government, provided me with answers as to how the United States is conducting its "War on Terror". Thankfully, the book is written in a fairly politically nuetral way, and aims to explain rather than to slander or lay blame (which is all one gets from the media). I now feel like I have a reasonable 10,000-foot view on how and why al Queda was created and why the United States invaded Afghanistan and Iraq. The one piece of mis-information that is passed on as legitimate (and only i believe due to the publishing date) was the reiteration that Saddam Hussein was found hiding in a hole, which is not true.
over the weekend. mediocre far-fetched, semi-illogical science/political/military/conspiracy/detective-type thriller. certainly no Tom Clancy... on par with perhaps some of Michael Crichton's worse books. same author as The Da Vinci Code, which is better. supposedly Angels and Demons is far better, i'll have to give that one a try sometime.
over the period of a few months i guess, finished it off on vacation on the plane. found this because it's edited by Bill Bryson, a talented and likable travel writer. the stories take us all over the place, from Nantucket to a sailboat race down the coast of Mexico to the hills of Coast Rica to the forests of Bhutan to the streets of India to the desert wastelands of Mauritania. they exposed me to all kinds of interesting data... people, places, food, politics that I would never have known about. while some of the stories are better than others, a fascinating read.
The Code Book covers the history of cryptography. It was a good read, very accessible and I found that I want to know more.
$ uname -a && echo -e "#include <stdio.h>\n#include <limits.h>\nmain(void){ \
return printf(\"ULONG_MAX: %lu\\\n\", ULONG_MAX); }" > limits.c \
&& gcc -o limits limits.c && ./limits
Linux deepthought 2.6.13 #4 Sun Sep 4 00:15:08 PDT 2005 x86_64 AMD Athlon(tm)
64 Processor 3200+ AuthenticAMD GNU/Linux
ULONG_MAX: 18446744073709551615

$ sudo ftp ftp://ftp.openbsd.org/pub/OpenBSD/3.7/packages/i386/
ftp> get bash-3.0.16p0.tgz "|pkg_add -v -"
i need the following data for research, if you're interested: network captures (.pcap format if possible, check out ethereal) of basic network activity (web browsing, pings/pongs) from a known machine or machines along with a list of IPs -> Operating System. be as specific as possible with OS, WinXP won't cut it,--> i need Windows XP Pro 2002 Service Pack 2 + firewall. i'm not interested in the content of the web page you're browsing, or to whom you're sending PINGs; i'm interested in the actual structure of the packet headers. in particular i'd like caps of the following OSes:
lanmap should compile and run on Linux, Windows and the BSDs (including OS X); lemme know. you'll need:
svn co svn://parseerror.dyndns.org/lanmap/trunk/ lanmap
NOTE: sorry, but my svn server is currently my laptop, which travels with me; this won't always work. best bet is weeknights, EST. need to find a real home for this project.
*nix users can just type make, windows users need Visual Studio .NET to compile the .sln
(the .proj might work in VS6, haven't tried)
on *nix, run with superuser privileges (yes, that sucks and is inherently more dangerous)
every 60 seconds(default) the file graph/lanmap.png will be updated with the latest and greatest picture of the network, as the box you're running on sees things.
it is amazing what machines will send out to the network... ethernet manufacturer is mantainable by MAC address prefix, most OSes will send out OS name and version in the "vendor class" entry of a BOOTP message, OS hints can be found in ICMP echo requests (pings) and traceroute pings. OS is determinable from most HTTP User-Agent strings. some of that is easily faked. p0f on the other hand, can detect most OSes purely by analyzing TCP SYN headers against a database of known fingerprints, and can also detect things like NAT and firewalls, not quite sure how yet.
other things i need to figure out is how better to handle traffic to/from gateways, and also come up with a more informative visual representation of machines based on what i know about them. also, identification of printers, and better handling of bridges and routers.
this graph was generated using graphviz's `twopi` program, which generates a circular undirected graph... the `neato` program generates better output, but crashes when using external images as nodes, i'm trying to debug and correct this error...
svn co svn://parseerror.dyndns.org/lanmap/trunk/ lanmap
so far the code has been compiled using gcc 3.3.5 on linux and gcc 4.0 on mac os x. the project isn't mature or robust, but it probably won't crash, definitely won't disrupt your network and just might show you something interesting. if you can compile it and run it i'd be interested to see what your graphs look like.
javascript:void(window.g_sDisableWGACheck='all')
man 1 fuser
time `cat /var/log/apache2/access_log | webalizer -o . -`
we can do better.
links -g is still nice...
I've also been listening to N.W.A lately. Straight Outta Compton has some great, catchy songs, and Dr. Dre's beats are sweet. I gotta say, I like Mc. Ren. "Ren is the villain and you're just a hostage, so whenever I'm steppin' cover your head like an ostrich"
C:\cygwin\home\Ryan\src>strings c:\WINDOWS\system32\ftp.exe | grep @
PASS %s@%s
Ph@'
V@9E
V@Pj
@(#) Copyright (c) 1983 The Regents of the University of California.
$ xset r on
pizza@sauce:~
$ mkdir /tmp/expandthis && cd /tmp/expandthis && touch ls foo
pizza@sauce:/tmp/expandthis
$ * -l
-rw-r--r-- 1 pizza users 0 Apr 28 00:48 foo
pizza@sauce:/tmp/expandthis
$ touch -- -l
pizza@sauce:/tmp/expandthis
$ ls *
-rw-r--r-- 1 pizza users 0 Apr 28 01:02 ls
-rw-r--r-- 1 pizza users 0 Apr 28 01:02 foo
pizza@sauce:/tmp/expandthis
$ ls -l -- *
-rw-r--r-- 1 pizza users 0 Apr 28 01:03 -l
-rw-r--r-- 1 pizza users 0 Apr 28 01:02 ls
-rw-r--r-- 1 pizza users 0 Apr 28 01:02 foo
pizza@sauce:/tmp/expandthis
$
it has to do with bash's tendency to expand (i just found GLOBIGNORE...)
and the -l thing has to do with GNU-style argument handling
That reminds me, I'm out of books. I finished Peter Matthiessen's The Snow Leopard. The book is really less about animals and more about the author's spiritual journey into the mountains of Nepal. A serious student of Zen and a Buddhist, Matthiessen reflects in his work much more than the beautiful land, hard journey and people around him. I hate traditional religion, but what Matthiessen talks about is much less about God than it is understanding the world around him and his own soul. The book is quite deep, although I find myself unable to succinctly sum up what is inside. Nonetheless, an excellent book for anyone who loves travel.
The only question is what to read next. I had some really excellent, smooth, tasty sake over the weekend which made me realize how shitty the sake was that I used to get at my regular sushi place back in Las Vegas. I think I'll read up on sake. I also have never read Machiavelli's The Prince, so what the hell. I need to find a library around here.
2005-03-17
aw yeah, firefox is sexy. this is a listing (in IE(!)) of files from kirk's counter-strike stats analysis tool; it generates a boatload of files, but it's oh-so-informative! my current K/D ratio: 1.38, much improved from my initial 0.62. in other news, i forgot an #ifndef X #define X #endif wrapper in one of my new .h files and Visual Studio just sat compiling the .c file, chewing up cpu and memory. Very sweet.
i've already start on my next read, The Snow Leopard by Peter Matthiessen about a zoologist and a Buddhist outdoorsman/writer who travel to Nepal in the 1970s to study Himalayan blue sheep and to try and catch a glimpse of the near-mythical snow leopard. i'm interested in travel, mountains, Buddhism and to a lesser extent animals; the book comes highly recommended.
woke up saturday morning very hungry (no dinner on friday), thought it would be thematic to buy tangerines and go look at The Gates in Central Park. i walked a block, bought some tangerines at a fruit stand, walked another 1/2 block towards CP, turned around and went back. it was so brutally, unbelievably cold i could not go any further. it was so cold my eyes were trying to cry but everything was frozen. too cold for sitting in the park and eating frickin tangerines.
put on my warmest attire; hit up nearby deli/resturant for split pea soup. one pint, $3.50. walked a few brutally cold blocks to the park. saw The Gates. walked for a bit, found a bench, ate soup. tried to eat soup. in the 5 minutes i had walked the piping hot soup had gone luke-warm. yuck. choked down a few spoonfuls and threw it out. chose a direction and just walked. the orange gates were everywhere. as a NYTimes editorial noted the gates are not 'saffron', but orange. the color of Home Depot; the color of traffic cones. i noticed after walking for a bit that they were of varying width, greatly varying in some instances. i took my glove off and grabbed the cloth of one of the gates. it was soft and had texture; like a thick dishtowel. i walked for what seemed like no time at all and i ran out of park. i was at Columbus Circle, at the southwest corner. i had walked a dozen blocks without even noticing. i hopped up on a stone wall and just sat there taking in the circle. i looked up at Trump Tower on my right. people were everywhere. cops were everywhere. everyone was taking touristy pictures of each other at the The Gates. i wonder how many people came to NYC just for them.
i would have sat longer, just taking it all in, but the stone wall on which i was sitting was so cold it went right through my jeans, through my gloves and my hands, and completely froze my ass. as i walked the dozen blocks northwards on Central Park West rubbing my ass the whole way.
next up: shopping. i'm not a big shopper. i own one pair of jeans which i've used for work and play for over one year. i have clothes hanging around that my mom has bought me, simply because they still fit and look decent. many people i know treat clothes like a car lease or an apartment. they pay and pay and pay, use them for a few months and then get all-new ones. i don't know how such people get rid of their clothes... do they throw them out? i hardly buy any clothes and i still have too many. perhaps i just don't throw them out fast enough.
if you're this kind of person, the next time you're getting rid of your clothes make sure to give them to a charitable organization like the Salvation Army or Goodwill, because this is where i buy clothes. don't feel pity for me, i have enough money so that i could afford to buy a few pairs of jeans every year for $100/each. button-down shirts at __Mall_Store_Here__ for $40 apiece. Shoes for $80. But I won't. I just think it's silly.
but first i needed to find a thriftshop. i'm looking after my girl's apartment; i swear i've seen a yellow pages here somewhere, but after 15 minutes of not finding it i'm begininng to doubt my memory. i run downstairs to the store on the first floor, they are thoroughly nice and i borrow their yellow pages for 10 minutes while i listen to some fat loser next to me drone on to his 'woman' about how "if you're going to to leave me you need to tell me you're leaving and if you're not going to leave me then you need to tell me". i write down the names of a dozen thrift shops, thank the guys for the favor and get the hell out of there. most of the thrift shops are more or less clustered within 10 blocks on the east side; i am on the west side, and there are about 4 shops spread out at 15 block intervals along it. being a man of lowest-common-denominators i just walk to the closest shop, about 7 blocks away. inside is junk, lots of it. women's junk. more women's junk. i find the men's junk after more than a little confusion. i find 2 shirts that are decent and most importantly one of those dark jackets with big buttons and most importantly it was almost a great fit, which is a big deal for me, so i grabbed that stuff and got the hell outta there. 2 button-up shirts and a warm, jacket that didn't make me look like a criminal (like my current one seemed to) for $60. on the way back i noticed a basement barber giving $15 haircuts, and since i needed one i figure what the hell. the man next to me got a middle-eastern barber with a sense of humor and a mouth that wouldn't shut. i got an eastern european girl who was all business. she frowned and fretted as i took off my hat; i hadn't had a haircut in months. no non-logistical discussion whatsoever. but she was alright at what she did, so it's ok to be serious. but it made me realize that being too serious about your job can put other people off.
i was hoping to cook some asian-style food, but as i went through my girlfriend's food i realized that while i am good at eating it i don't know my way around real asian food at all; not enough to cook any of it. so i got some mexican food and watched the Univ. of Virginia basketball team give Maryland a real fight for 2 hours and then completely fall to pieces in double overtime. as for the rest of the game, the announcers would have you believe the kids are walking on water, but here are grown men, many of them making more money than i do, missing layups and free-throws in a serious manner. american basketball players are so fundamentally unsound it pains me to watch it. if you notice the college players execute their dunks will greater fluidicity than they do their free-throws, which just goes to show you what their priorities are.
i rented Troy, and i must say it was extremely mediocre. i suppose psuedo-historical war flicks are forced into a certain style, but even Gladiator had more of a soul than this. Brian Cox's Agamemnon was just horribly written and i feel sorry for him because he is a very good actor whose talent was wasted. Orlando Bloom on the other hand did a terrific job playing the weak-willed-creepy-teenage-boyfriend role of Paris, which i definately don't mean as a compliment. that guy cannot act. legolas was his high-point; an absolutely perfect role for him. Brad Pitt's Achilles was of course the only somewhat interesting thing in the entire movie, because he occasionally got suited up for battle and inflicted death and destruction, and because everything else in the movie was so monotonous that was all there was of which to look forward.
The was the end of my day, I wanted to make a trip to the bookstore but due to poor planning on my part it was too late. the next morning i woke up, did my chores and took the train home.
wget and curl commands to retrieve different collections
of files on the 'net. very cool idea. technical, creative and most of all: cmdline-savvy.
2005-01-27
spent the majority of today trying to figure out why my code didn't work on a combination of win2k and a certain
serial↔ethernet bridge. it worked on the bridge with xp and it worked with win2k with a different model bridge.
spent a lot of time in ethereal... and guess what? it helped me figure out
the problem in a big way... i dunno what i'd do without it.
it looks like xp would re-send the app protocol's sync message, whereas 2k would only send it once (i only
logically called a single send)... so i added a second call and it magically works... sigh. well, at least i
fixed it — but it bothers me because i don't know why xp would send the message twice... also, during the
experience i noticed that win2k sends a RST, ACK to any connection to a non-listening port, whereas
winxp sends nothing; it was also interesting to observe the bridge behavior as it cycled from ports 1023…900
and then started over again
a lot has happened to me in the past few months; the most interesting is that i've gotten into programming C more. a lot more. and i've gotten much more comfortable with it. and i like it. a lot. if you don't like C, then you'll be very bored by this page because most of the things i post will likely be related.