Pacific Simplicity is the home to my tech blog of sorts, aiming to assist and provide information easily to other Linux users and Open Source hackers out there.  It contains articles on Linux, system admin hints, scripting, programming embedded systems, OpenWRT and of course Drupal . Check it out and don't forget to comment!

Posted: Tue, 05/24/2016 - 15:55

Working on a project and supervising an intern - I decided that it would be nicer if I had a good example of a detached thread generator which also provided a parameter (as a structure).

#include <pthread.h>
#include <stdio.h>
#include <stdlib.h>
#include <stdint.h>

/* This is the structure you could use to pass parameters to the threads */
typedef struct thread_params_s {
        int param;
} threat_params_t;

Posted: Tue, 05/24/2016 - 09:30

I recently ordered several BT adapters which have the CSR chip in them, but the ALL have the same address. Here is a simple little hacky script I made:

Posted: Wed, 05/18/2016 - 15:15

Simple read XML example written in C using Libxml2 - notice recursions for hosts etc...

Posted: Wed, 05/18/2016 - 12:11

Here is an extended example using some base-code borrowed from https://github.com/carsonmcdonald/bluez-ibeacon. This code wasn't all that well written and needed ALTBEACON support - so here it is with my changes.

The most notable parts are:

Posted: Mon, 05/16/2016 - 15:13

Hello all - here is my modified version of the SNMP demoapp.c. It includes V3 auth and crypto, verified with Wireshark.

#include <net-snmp/net-snmp-config.h>
#include <net-snmp/net-snmp-includes.h>
#include <net-snmp/library/snmpv3.h>
#include <net-snmp/library/snmpusm.h>
#include <string.h>

const char *our_v3_passphrase = "my_password";