Centroid.EU Blog

(this blog is mostly encrypted - adults only)

Previous Page

Slow Communication (ttldaemon.c)

November 11th, 2013

I have written a small daemon that changes the outgoing TTL on a FreeBSD host. It's a covert steganographic channel. When a bit is set the TTL is 65 and when it's 0 the TTL is 64. On the receiving end of a ping then perhaps you can make out the bits of a message:

jupiter$ ping -i 10 io.solarscale.de
PING io.solarscale.de ( 56 data bytes
64 bytes from icmp_seq=0 ttl=53 time=15.691 ms
64 bytes from icmp_seq=1 ttl=53 time=16.608 ms
64 bytes from icmp_seq=2 ttl=54 time=14.907 ms
64 bytes from icmp_seq=3 ttl=54 time=15.247 ms
64 bytes from icmp_seq=4 ttl=53 time=15.183 ms
64 bytes from icmp_seq=5 ttl=53 time=16.017 ms
64 bytes from icmp_seq=6 ttl=53 time=16.465 ms
64 bytes from icmp_seq=7 ttl=54 time=15.134 ms
64 bytes from icmp_seq=8 ttl=53 time=18.659 ms
64 bytes from icmp_seq=9 ttl=53 time=15.542 ms
64 bytes from icmp_seq=10 ttl=54 time=15.176 ms
64 bytes from icmp_seq=11 ttl=54 time=16.411 ms
64 bytes from icmp_seq=12 ttl=53 time=15.418 ms
64 bytes from icmp_seq=13 ttl=54 time=15.438 ms
64 bytes from icmp_seq=14 ttl=53 time=15.388 ms
64 bytes from icmp_seq=15 ttl=53 time=15.918 ms
64 bytes from icmp_seq=16 ttl=53 time=15.306 ms
64 bytes from icmp_seq=17 ttl=53 time=15.347 ms
Notice how the TTL changes here. If it's 54 then the original TTL was 65, so 1 bit. So what was gathered here was 001100010011010000. Eventually I'd like to write a client to record this. But I'm gonna cheat for now and give you the source code.

I just give greetings and peace wishes but with a bit of coding it could be changed to something very creative!


What's happening here?

November 11th, 2013

I think the medias need to step back a bit. We all know that the US is spying on us but we don't need to be spoon-fed the paranoia. It's causing illogical decisions (firewalled europe anyone?) on parts of big powerful corporations who see opportunity to take away everyones freedom. Let's get off this paranoid horses back! I love freedom personally.


talk(1) patch to display timestamps

November 9th, 2013

I have written a small patch to talk(1) as found in FreeBSD (yes for a change!) to display timestamps when someone wrote a line. It's a little buggy but it works.

Thanks goes to Dylan who I've been talk(1)ing with and gave me the idea.


Smithing tools to understand code

November 8th, 2013

Yesterday I looked at the traceroute(8) source code in order to look for attack vectors. I came out empty handed. But I smithed a tool for my work that can be reused later I think.

This tool helped me overcome reading the function print_exthdr() better and determining it was safe. Not many people admit to doing this kinda stuff but I think I'll leave this to the next person that doubts OpenBSD's traceroute.c. I'm not ashamed at all! Should I be?


Facilities and Priorities in syslog

November 4th, 2013

We had this problem in that we didn't know what facility a certain program was syslogging to, so we straced it (in linux), check a sample here:

root@raspberrypi:~# tail /tmp/blah.out
read(1, "TZif2\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\1\0\0\0\1\0\0\0\0"..., 4096) = 118
_llseek(1, -6, [112], SEEK_CUR)         = 0
read(1, "\nUTC0\n", 4096)               = 6
close(1)                                = 0
munmap(0xb6caf000, 4096)                = 0
connect(1, {sa_family=AF_FILE, path="/dev/log"}, 110) = 0
send(1, "<13>Nov  3 00:00:14 pi: hi", 26, MSG_NOSIGNAL) = 26
close(1)                                = 0
exit_group(0)                           = ?
That was produced with the input "strace -o blah.out logger hi". So syslog logs a number inside <> at the beginning to indicate what facility and priority it is. It's sorta a code. So I wrote the following BSD program to convert the number into their respective fac and pri. Enjoy!
root@raspberrypi:/tmp# ./facility 13
facility: (8)user, priority: (5)notice

For administrivia, how would you speed up this program? Take a look at /usr/include/syslog.h and think binary search.


Jupiter (computer) now on Radeon

November 3rd, 2013

After 3.5 years of Nvidia, the box is now running a low to medium end Sapphire Radeon HD5450 card. I'm saving a ton of electricity with this card too! And OpenBSD is fast again! Wonders!


Fast Hellos are on

November 1st, 2013

Yesterday I turned on fast hellos on my OSPF setup. This is what venus' ospfd.conf file looks like now:

... some cut ...
area {
        interface gif0 {
                router-priority 1
                metric 1
                router-dead-time 40
                auth-type simple
                auth-key $password
                router-dead-time minimal
                fast-hello-interval msec 333
        interface gif1 {
                router-priority 5
                metric 10
                router-dead-time 40
                auth-type simple
                auth-key $password
                router-dead-time minimal
                fast-hello-interval msec 333
Notice gif0 has a lower metric than gif1, fast-hello-interval time is 333 msecs.Which is also default so it needn't be there. The "router-dead-time minimal" causes fast hellos to go on. So when I watch the packets on gif1 which isn't used for traffic I see:
# netstat -nw 1 -I gif1
 gif1 in       gif1 out              total in      total out            
 packets  errs  packets  errs colls   packets  errs  packets  errs colls
  200827     0   209273     0     0  75406364     0 80678099     0     0
       3     0        3     0     0        29     0       29     0     0
       3     0        3     0     0        22     0       22     0     0
exactly 3 packets per second in either direction. I suspect now that when my LTE fritz!box crashes again that the failover to the gif1 link will be next to instant.


OpenBSD 5.4 released

November 1st, 2013

You can now download OpenBSD 5.4 from your favourite OpenBSD FTP mirror. I usually use ftp.eu.openbsd.org in europe but if I was in north america I'd use ftp.openbsd.org. Congratulations to the OpenBSD team for yet another great release!


Centroid blog now available in CVS

November 1st, 2013

I have decided to open source the PHP behind this blog. It's all about letting go and showing the innards isn't it? :-) Anyhow here are the sources. This PHP source code has never seen anyone's eyes but mine before this. Perhaps it's not great but it makes this blog the way it is.


A tiny blip on the W commit log screen

October 30th, 2013

Wildcarddnsd didn't get much commit time this year. But this time there was something. I committed support for Raspberry Pi running raspbian. That's gotta count for something, however small. Have fun with it!


Next Page


RSS Feed

Click here for RSS

On this day in

Other links

Have feedback?

By clicking on the header of an article you will be served a cookie. If you do not agree to this do not click on the header. Thanks!

Using a text-based webbrowser?

... such as lynx? Welcome back it's working again for the time being.

Older Blog Entries

Powered by BCHS