Skip to main content

Posts

A change-gas

The danger of reading Randall Hyde’s book, The Art of Assembly is that it contains addictive substances. Yesterday, I have decided to joset@kee $ su -c "emerge -C nasm" After cleaning up, a tune-up followed .data msg: .ascii "A small step for me is a big leap for... me!\n" len = . - msg .text .global _start _start: # write string to stdout movl $len, %edx movl $msg, %ecx movl $1, %ebx movl $4, %eax int $0x80 # exit movl $0, %ebx movl $1, %eax int $0x80 Now I have finally made a change-gas. Expecting a lot of maintenance work to follow.

ADZU openlab scutworks

I really do not enjoy network administration a lot but the tasks listed below are rewarding. Let optimism light the path. 0] Tweak and secure box 1] Video screen capture 2] ADZU Debian repository 3] OpenAFS and Kerberos 4] IPv6 5] Honeypot 6] SETI Expect postponement of blog posts. Everything will be documented here upon completion. Signing off through a quote by Mr. Oscar Wilde Experience is one thing you can’t get for nothing.

Verify user in /etc/passwd

This is a product of wonder. In file verify.c #include <stdio.h> #include <string.h> #define MAX_LENGTH 1024 int is_local(char *user) { FILE *fd; char line[MAX_LENGTH]; int local = 0; if(!(fd = fopen("/etc/passwd", "r"))) { puts("Can't read /etc/passwd, exiting."); exit(1); } while(fgets(line, MAX_LENGTH, fd) > 0) { if(!strncmp(line, user, strlen(user))) { local = 1; break; } } fclose(fd); return local; } Use at your own risk. Disclaimer: Please refer to my first post ‘General notice’ Posted using Scott Yang’s mtsend.py python script. Thanks to Niel for his cool vim mappings.

A hidden post made visible

I was afraid to make this available in public. When I tried to browse some counterpart of it in other distros, I have realized that there are a lot of similar topics found even in the official forums of major distros. There are many people doing this already. So for people ranging from lowerclass to middleclass, who can not afford a digital subscriber line, here is a wiser alternative. If you have a Smartlink chipset winmodem in possession, then you are a bit luckier than those who own a Conexant chipset winmodem. Smartlink drivers are available for free eversince. Conexant drivers (lin*xant) were freely distributed during the 2.4 series era. This means, 2.4 kernels can still abuse the driver’s full-functionality. Bad news for 2.6 starters, 2.4-2.6 shifters, and 2.4 starters who hold Conexant chipset winmodems. Why? 1. Free drivers for 2.4 series are no longer available in the official repository. 2. Drivers for 2.6 are free but limit your bandwidth to 14.4kbps. Free isn...

Test mtsend

mtsend.py is a command line tool written in python. It uses Movable Type’s XML-RPC interface. It appears that it also works with WordPress’ XML-RPC interface. So I have decided to give it a try. In file ~/.mtsendrc [global] default=eradicus [site-blogsome] url=http://eradicus.blogsome.com/xmlrpc.php username=***** password=***** encoding=UTF-8 [blog-eradicus] site=blogsome blogid=1 It works! joset@kee$ ./mtsend.py -B blogsome +----+-----------+-------------------------------+ | ID | Blog Name | URL | +----+-----------+-------------------------------+ | 1 | Sophie | http://eradicus.blogsome.com/ | +----+-----------+-------------------------------+ joset@kee$ ./mtsend.py -C +----+----------------------+ | ID | Category Name | +----+----------------------+ | 5 | Healthy Vices | | 2 | Of Love and Romance | | 1 | Progressive Studies | | 3 | Uncategorized | | 6 | Unsolicited Opinions | +----+------------------...

Queued tasks

Hopefully these features would be added on the game soon. 1. Nick completion 2. Default turn time limit 300/150 3. Display number of players 4. Notify if a player leaves 5. Sortable columns in lobby The root of all evil in programming starts at early optimization in coding. - Donald E. Knuth

Wesnoth terrain

How are maps created? How are terrains organized? These questions are no way different from asking how GNU/Linux works. The brief explanation is, it is very complicated! Conceptually it works like this: Terrains are defined in terrain.cfg . They get assigned ID, name, char, etc. A snippet of terrain.cfg # Terrain configuration file. Defines how the terrain _work_ in the game. How # the terrains _look_ is defined in terrain_graphics.cfg . # NOTE: terrain id's are used implicitly by the in-game help: # each "[terrain] id=some_id" corresponds to "[section] id=terrain_some_id" # or "[topic] id=terrain_some_id" identifying its description in [help] [terrain] symbol_image=void id=shroud name= _ "Shroud" char=" " [/terrain] [terrain] symbol_image=fog id=fog name= _ "Fog" char="~" [/terrain] [terrain] symbol_image=ocean id=deep_water name= _ "Deep Water" char=s submerge=0.5 unit_height_adjust=-3...