Blogs
Advertisement
Advertisement
IP Geolocation in Go
Using freegeoip.net we can get location information about hostnames or IP addresses. The service returns information like country name, latitude, and longitude. This example will use Go and its Unmarshal() function to decode the response in to a usable struct.
Packet Capture, Injection, and Analysis with Gopacket
The gopacket package provides a Go wrapper for libpcap written in C. It is more than just a simple wrapper though. It provides additional functionality and takes advantage of Go things like interfaces, which makes it incredibly powerful.
Using libpcap in C
libpcap allows us to capture or send packets from a live network device or a file. This tutorial and code examples will walk you through using libpcap to find network devices, get information about devices, process packets in real time or offline, send packets, and even listen to wireless traffic.
My First DEF CON
I went to DEF CON 23 this year. It was my first time to DEF CON and to Las Vegas. I paid on my own dime and it was not a company sponsored trip. I am sharing my personal experiences, opinions, and reflection on my first DEF CON. Others who will attend their first DEF CON might find some useful tips.
AI Chat Bot in Python with AIML
Daemonizing Ruby Scripts
Daemons are processes that run in the background. Typically they are services like a web server. You can easily take any Ruby script and turn it in to a daemon that you can control with easy commands like start and stop. These code snippets demonstrate just how easy it is.
Writing a Mumble Bot in Ruby
Mumble is an open-source voice communication tool with low latency ideal for gaming. It is an alternative to the non-free TeamSpeak and Skype options. The Ruby gem mumble-ruby provides a library to connect and interact with Mumble as a client. These code snippets demonstrate how to connect and communicate in a chat room and private messages. At the very end, there is a fully functional command line chat client that is ready to use to chat on the DevDungeon.com Mumble server!
Working with Images in Go
The Image interface is at the core of image manipulation in Go. No matter what format you want to import or export from, it ultimately ends up as an Image. This is where the beauty of Go interfaces really shines. Go comes with support for gif, jpeg, and png formats in the standard packages. These examples demonstrate how to programatically generate, encode, decode, write to file, and base64 encode images. We will also cover a little bit about interfaces.
CoffeeScript Basics
CoffeeScript is an evolution of JavaScript. It actually compiles down to optimized JavaScript. It feels a lot like Python because of the significant whitespace, and lack of semi-colon line endings and curly braces. The syntax is a lot sparser than JavaScript which lends to its readability and simplicity. CoffeeScript can be run as an interpreter or a compiler. You can write plugins for the GitHub Atom Editor using CoffeeScript. The compiled JavaScript can be used for a web application or for command line applications run by Node.js.
Advertisement
Advertisement