Skip to content

Instantly share code, notes, and snippets.

.SUFFIXES: .ko
CFLAGS_MODULE += -DCONFIG_NET_FOU_IP_TUNNELS
obj-m:= fou.o sit.o ip_tunnel.o
all: fou.ko sit.ko ip_tunnel.ko
.c.ko:
make -C /lib/modules/`uname -r`/build M=/home/alprut/proj/tunnel/test CONFIG_IPV6=y CONFIG_NET_FOU_IP_TUNNELS=y modules

Using Grafana Worldmap with Rails

Installation of worldmap panel plugin

$ grafana-cli plugins install grafana-worldmap-panel

Or install a plugin under development which replaces the map by Google Maps Satellite View with the following command.

$ sudo grafana.grafana-cli -pluginUrl https://github.com/ammpio/worldmap-panel/archive/master.zip plugins install grafana-worldmap-panel

AES decryption in a Lua plugin of Wireshark on Mac

Confirmed environment

Item version
OS macOS Catalina
Wireshark 3.6.2
Lua for building luagcrypt 5.2.4
luagcrypt https://github.com/Lekensteyn/luagcrypt 5763e94b751e6ff0dcf20e328c299d49eb8fcbce
@alprut
alprut / contiki-ng-1001-nodes.md
Last active September 23, 2019 10:27
1001 nodes simulation with Contiki-NG

1001 nodes simulation with Contiki-NG

Simulation speed result

4.893 seconds simulation took about 20 minutes. Cooja GUI showed the speed under 0.40% in most periods.

Statistics

At about 1 second simulation

@alprut
alprut / gen-json.tcl
Created May 1, 2013 12:07
a tcl script to output node IDs and links of NS2 network topology by d3.js JSON format.
Simulator instproc gen-json {fp} {
$self instvar link_
puts $fp "{"
puts $fp "\"links\":\["
set prev ""
foreach li [array names link_] {
set nodes [split $li ":"]
set src [lindex $nodes 0]
set dst [lindex $nodes 1]
if { $src < $dst } {
@alprut
alprut / bookdir.rb
Created November 2, 2011 16:43
A ruby script to get book information from AWS using barcode in preface images of books
#!/usr/bin/ruby
require 'rubygems'
require 'amazon/aws'
require 'amazon/aws/search'
require 'csv'
require 'fileutils'
$KCODE="UTF8"