Posts

Showing posts from 2015

fail2ban recipes

Here are some fail2ban recipes. I will update this post as I find some more.


- Add an IP/range in the recidive chaik

      fail2ban-client -vvv set recidive banip ip_address

      ip_address can be a single IP or a range (like 62.210.6.0/24)


SNMP proxy configuration

Image
Ok, let's say you have a server or gateway that you already monitor using SNMP, but you need to also monitor other devices (switches, AP,...). There are two major ways to do it:

The first if to map all devices to their own external UDP port and make your monitoring software (Cacti, Zabbix,...) fetch the data on this port. Easy enough, but sometimes you do not have this luxury. Also it opens up the firewall on a bunch of ports which I personally don't like.

The second it to configure the SNMP server on the server or gateway so that it proxies specific communities to internal devices.

Let's take the following network architecture:
The Cacti server is already monitoring the Firewall (a Linux host). So in the Firewall snmpd configuration, you simply have to add:
view    systemview     included      .1.3.6.1 com2sec notConfigUser  default       public group   notConfigGroup v1            notConfigUser
Then for Switch1:
# Setting up the proxy configuration for Switch1 com2sec -Cn swi…

ESP8266 WiFi module intro

Image
So I received yesterday 2 of these nice ESP8266 WiFi module:


Bought it from Ebay at 3.58$ each including shipping:
http://www.ebay.ca/itm/131334864936?_trksid=p2060353.m2749.l2649&ssPageName=STRK%3AMEBIDX%3AIT
It did take about 5 weeks to get here, but I was in no rush.
One thing to be carefull, this is a 3.3v device do do not plug it to anything that will bring 5v to it's inputs or you will destroy it.
Found this nice how to on using simple resistor voltage divisor and transistor to drive this module from anything 5v:
http://iot-playground.com/2-uncategorised/17-esp8266-wifi-module-and-5v-arduino-connection
Will update in a later post my progress on using this what seems to be pretty versatile module.

IoT/IoE, hardware, electronics...And some Ruby to rule them all !

Image
So last night (May 19th 2015) did a small talk at the Montreal.rb meetup (www.montreal.rb).

(Photo from @Blanckus)

While most talk at these meetup are Ruby/Rails related my talk was more on electronics, DIY/Maker stuff, IoT/IoE and yes how to use Ruby to work/control these embedded platforms.

The following is a link to the PDF version of the slides used during the presentation:

IoT-IoE, hardware, electronics...And some Ruby to rule them all ! 

Also during the presentation my small CreeperBot telepresence robot was shown:


I have committed all the files for this project to my GitHub:
GitHub: CreeperBot
Feel free to fork it and do whatever you want with it !

If you have any questions, comments, recommendations or find errors in any of the documents supplied, please feel free to drop me a line.