April 14th, 2006

UDP sendto in sbcl

From the SBCL commit log:

0.9.11.34:
        Add support for sending data over UDP sockets to SB-BSD-SOCKETS
        (finally). Thanks to Faré for the patch
This let me write a new program:
DNS> (cl-dig "static.flickr.com" :server #(192 168 1 2))
;;; Got a response (length=185) from #(192 168 1 2):53
;; ->>HEADER<<- opcode: QUERY, status: NOERROR, id 55367
;; flags: qr rd ra; QUERY: 1, ANSWER: 2, AUTHORITY: 5, ADDITIONAL: 0

;; QUESTION SECTION:
;static.flickr.com.             IN      A

;; ANSWER SECTION:
static.flickr.com.      45      IN      CNAME   storage1.flickr.vip.mud.yahoo.com.
storage1.flickr.vip.mud.yahoo.com. 900 IN A     68.142.213.135

;; AUTHORITY SECTION:
mud.yahoo.com.          87379   IN      NS      ns1.yahoo.com.
mud.yahoo.com.          87379   IN      NS      ns2.yahoo.com.
mud.yahoo.com.          87379   IN      NS      ns3.yahoo.com.
mud.yahoo.com.          87379   IN      NS      ns4.yahoo.com.
mud.yahoo.com.          87379   IN      NS      ns5.yahoo.com.

NIL

It's not really a replacement for gethostbyname, but it does enough for my nefarious purposes.