Brent Simmons’ weblog. I write NetNewsWire, a free RSS reader for Mac and iPhone.

All The Quickies
Borkware’s All The Quickies page has a ton of great tips for command line users and programmers. (I’m also a big fan of Mark’s Core Mac OS X and Unix Programming book.)
12:22 pm #

httpflow: how to view raw traffic
Since both MarsEdit and NetNewsWire make HTTP requests, I often have a need to see what the raw HTTP traffic looks like.

There are different ways to do this, but what I do is type httpflow on the command line, then type my password, and then watch the traffic.

httpflow on my machine is an alias—a command-line command alias, not a traditional Mac OS file alias—for the following command: sudo /usr/local/bin/tcpflow -c port 80

You’ll need tcpflow to make it work. Tcpflow isn’t a standard part of OS X—but you can get a copy from Marc Liyanage. (That’s the version I myself use.)

Sometimes I only need just a quick peek at the headers (for a feed, usually) to see if it’s redirecting or returning a 404-not-found or something. In that case I don’t need tcpflow—curl does the job. I type something like curl -I 'http://maccentral.macworld.com/mnn.cgi' to see what I get. (Curl comes with OS X, I believe.)
12:02 pm #

 

Software

NetNewsWire for Mac
NetNewsWire for iPhone

Me on

Twitter
Flickr

About me

I learned programming way back in 1980 on an Apple II Plus, and have been an Apple fan ever since.

I work for NewsGator Technologies, Inc.

I like cats and spaghetti and swimming in the ocean.

My favorite post

It’s so hard to teach squirrels to play baseball...

© Copyright 1999-2008 Brent Simmons.
Seattle, WA (Ballard)
All trademarks are property of their respective owners.