Dienstag, 26. März 2013

Facebook March 26, 2013 at 11:05AM

Unser Gast hat sich eingerichtet und es schmeckt ihm :)

Montag, 25. März 2013

Facebook March 25, 2013 at 04:25PM

und während ich mit Jehovas Zeugen am Zaun plaudere, bringt Spitzerl eine Maus(?) nach Hause. Hab zuerst geglaubt sie ist tot, aber dann hat sie zu quieken begonnen. Jetzt sitzt sie in einer Schachtel...

Windows 8 Time

Time has always been wrong on my Windows computers and the internet time synchronization has always been error prone.
I don't know why microsoft was not able to fix that in the last decade, because this can be a real pain in the neck, especially if one has to rely on exact time keeping.

Anyway today I've found this link:
Configure a manual time source for a selected client computer

In essence it explains two things:
  1. How to test if another computer (on the LAN) can be used as time server:

    w32tm /stripchart /computer:target /samples:n /dataonly

    where target is the name or IP of the time server and n the number of times to query it

  2. How to set another computer (on the LAN) as time server:

    w32tm /config /manualpeerlist:peers /syncfromflags:manual /update


    Actually it is set up as peer and does not appear in the list of servers (in the property of the clock), but

    w32tm /query /peers


    lists it, if the call to  w32tm /config succeeded. Note that it must be run as administrator!
    peers may contain a list of names/IP addresses in a quotes string with space as deliminator (e.g. "time1 time2 time3")

As time server I use a linux box with openntpd (does not listen to connections by default, so make sure to enable that in /etc/openntpd if you want to see it).

Now I'll have to see if it actually works...

Freitag, 22. März 2013

Facebook March 22, 2013 at 02:41PM

es brummt im Vorzimmer - Spitzerl hat schon wieder einen (toten) Vogel nach Hause gebracht :(

Mittwoch, 20. März 2013

Facebook March 20, 2013 at 08:51AM



Aus der Reihe 12 Praktische Anwendungsbeispiele Für Wasserbomben #4 Schutz verletzter Finger vor Schmutz, Chemikalien & Feuchtigkeit (Katzenkisterl ausräumen, zähneputzen, duschen,...) P.S.: Aufpassen mit dem V-Hobel!

Sonntag, 3. März 2013

Spritpreis - Cosm

Hab' mir vor kurzem Arexx Temperatur Logger gekauft, um die Temperatur im Haus zu überwachen und zu sehen, wie die Heizung arbeitet. Dazu hab' ich bei Cosm ein Konto angelegt, um dir Messwerte zu als Kurve anschauen zu können.
Damit das so funktioniert, wie ich mir das vorstelle, hab' ich eine Java-Applikation geschrieben, die die Messwerte nicht nur lokal speichert, sondern auch zum Cosm überträgt. Die original Arexx Software hab' ich ohne USB Verbindung nicht verwenden können. Abgesehen davon benötigt sie Windows..

Nach dem ich also die Cosm-Verbindungfür die Temperaturmesswerte implementiert hatte und schon früher mit www.spritpreisrechner.at herum gespielt und dafür Java-Applikationen entwickelt habe, hab' ich die beiden kurzerhand verbunden, wodurch das entstanden ist:
https://cosm.com/feeds/105138
Ist ganz nett u Trends zu erkennen, aber noch lange nicht das, was ich eigentlich will. Momentan spiel' ich mit der Idee, einen universellen Datenlogger zu machen, der nicht nur Werte verschiedener Quellen lesen kann, sondern das ganze dann auch graphisch aufbereiten und auswerten kann.

OpenVPN and Android

Last week I finally got around to set up a working VPN for my android phone. I can now not only securely connect to my hone network and access my NAS, satellite receiver, mail server, etc. but also route the phones internet traffic through my home router and thus use any (open) WiFi without fearing that someone can steal my data.

 This is how I did it:
  1. Server
    I've been using OpenVPN for some quite time to connect to a friend and my companies server so I did not need to set up a server. It's running on a linux box that runs all the time so the VPN is always available. Setting up OpenVPN is quite easy - I used the Ubuntu package and customized it to my needs. In essence it contains these entries:

    proto udp
    dev tun
    ca /etc/openvpn/server/2.0/keys/
    myvpn_ca.crt
    cert /etc/openvpn/server/2.0/keys/myvpn.crt
    key /etc/openvpn/server/2.0/keys/
    myvpn.key
    dh /etc/openvpn/server/2.0/keys/dh1024.pem
    server 10.10.1.0 255.255.255.0
    ifconfig-pool-persist ipp.txt
    push "route 192.168.10.0 255.255.255.0"
    comp-lzo
    user openvpn
    group openvpn
    persist-key
    persist-tun


    I 've generated a key for my phone to access the VPN some time ago and don not remember how, but as I recall that was not a problem either

    The ticky part, besides configuring the phone, was to set up routing and the firewall correctly.
    I have a hardware firewall behind my DSL routers so I first had to set up port forwarding for UDP port 1194 to the firewall. Since the firewall was configured to log dropped packets it was not hard to find out how to configure the firewall. And finally I had to create a static route to the VPN via the linux box so the hosts on my LAN find the phone.
  2. Client i.e. phone
    On the phone I use OpenVPN Connect to access the VPN. I've created a configuration file (must end in .ovpn) which in essence contains these entries:

    client
    dev tun
    proto udp
    redirect-gateway def1 bypass-dhcp
    dhcp-option DNS 192.168.10.1
    resolv-retry infinite
    nobind
    persist-key
    persist-tun
    ca
    myvpn_ca.crt
    cert
    myvpn_phone.crt
    key
    myvpn_phone.key
    comp-lzo


    I copied the certs, keys and config to a directory on the phones SD card and the imported the .ovpn file into OpenVPN Connect.
    The redirect-gateway option makes the VPN server the default gateway i.e. routes all traffic through the VPN tunnel. The dhcp-option DNS sets the DNS server to that in my LAN so I can access my private hosts by their names. The rest is standard setup.

    Besides checking if I can reach hosts and services on my LAN by their name, I used http://http://ct.de/ip to check if all traffic is routed via the VPN.
    Once that all worked I was happy :)