Archive for the ‘CLI’ Category

Sam Trenholme of MaraDNS fame has updated his "world's smallest useful DNS server". It is so small, that the code fits right here:

/*Placed in the public domain by Sam Trenholme*/
#include <arpa/inet.h>
#include <string.h>
#include <stdint.h>
#define Z struct sockaddr
#define Y sizeof(d)
int main(int a,char **b){uint32_t i;char q[512]
,p[17]="\xc0\f\0\x01\0\x01\0\0\0\0\0\x04";if(a>
1){struct sockaddr_in d;socklen_t f=511;bzero(&
d,Y);a=socket(AF_INET,SOCK_DGRAM,0);*((uint32_t
*)(p+12))=inet_addr(b[1]);d.sin_family=AF_INET;
d.sin_port=htons(53);bind(a,(Z*)&d,Y);for(;;){i
=recvfrom(a,q,255,0,(Z*)&d,&f);if(i>9&&q[2]>=0)
{q[2]|=128;q[11]?q[3]|=4:1;q[7]++;memcpy(q+i,p,
16);sendto(a,q,i+16,0,(Z*)&d,Y);}}}return 0;}

Compile it (cc nanodns.c) and run it (./a.out 1.2.3.4) [...]

Thursday, August 5th, 2010 at 15:04 | 0 comments
Categories: CLI, DNS
Tags:

Remember this? For those too young to remember, it is a rotary dial phone, and I assume many young people wouldn't even know how to use it. To dial a number, you looked up the phone number in a telephone directory (or your little black book), picked up the handset, pushed your finger into the [...]

Thursday, July 29th, 2010 at 14:09 | 0 comments
Categories: CLI, Database, LDAP, Mobile, Voip

Martin introduced me to the Samhain file integrity monitor a while back — an impressive bit of software with which I've spent some quality time. I was much impressed with the features of the software, and I thought I'd spread the word a bit, so I wrote a short introductory article to it. The article [...]

Thursday, July 8th, 2010 at 09:52 | 1 comment
Categories: CLI, Linux, MacOSX, Security

A FRITZ!Box Fon WLAN 7270 has a built-in telephone directory which is maintained via a Web interface, from which I can create, edit, remove and backup telephone directory entries used by attached DECT phones.

That is all fine and dandy, but I want to be able to populate that directory from existing an existing database, and [...]

Friday, June 25th, 2010 at 09:52 | 0 comments
Categories: CLI, Hardware, Software, Voip

Services in the cloud are great, and I make some us of them when I find them appropriate or particularly useful. One of the cloud services I've used with some frequency is the del.icio.us bookmarking service, because I can access the bookmarks from any location. Having my data in "the cloud" means it isn't really [...]

Tuesday, May 25th, 2010 at 20:39 | 3 comments
Categories: Backup, CLI, Database, NoSQL

Update notifications sent by a database allow me to react to changes submitted to it in almost real-time without having to continuously (or periodically) poll said database. Note, that update notifications are not the same thing as database triggers as known in the relational database world: update notifications are submitted after a database modification has [...]

Monday, May 10th, 2010 at 10:40 | 0 comments
Categories: CLI, Database, NoSQL

Do you want to quickly experience CouchDB's powerful replication? Jan Lehnardt, one of the people behind CouchDB, announced yesterday that he'd made a copy of the very good book Pro Git available as a CouchDB Application (a CouchApp). There are two ways you can go about getting that:

Follow his instructions on getting the app with [...]

Tuesday, May 4th, 2010 at 09:21 | 0 comments
Categories: Books, CLI, Database, MacOSX, NoSQL

For experimenting, I wanted a source of data. Lots of data. For my application it would be trivial to generate such data, but I wanted lots of randomness in it, so I tapped into a bit of the Twitter firehose. This firehose is the full feed of tweets (somewhere about 50 million (!) tweets per [...]

Tuesday, April 27th, 2010 at 12:17 | 0 comments
Categories: CLI, Database
Tags: ,