Skip to content

Instantly share code, notes, and snippets.

@vjt
vjt / remote-tcpdump.md
Last active August 1, 2024 09:20
tcpdump on remote host

Running tcpdump on remote hosts with no storage

If you have tcpdump on your embedded home router and you want to see what traffic your crippled phone is doing, you can dump traffic on the router and visualise it on your main workstation using wireshark.

Ensure that you can log on to the remote host without a password, e.g. by using SSH keys.

  1. On the remote host, create a FIFO
@waveform80
waveform80 / motion_215.py
Last active September 8, 2021 16:23
Motion detection with a circular buffer and file recording in picamera
#!/usr/bin/env python
import io
import time
import picamera
import picamera.array
import numpy as np
from PIL import Image, ImageDraw
@derrickorama
derrickorama / make-cert-and-pk.md
Last active September 14, 2024 13:33
Extracting certs/private keys from certificates that disable private key exporting

Situation

  • I have to use a Windows client to install a certificate (say via the Magnum PKI Client)
  • I cannot export the private key for this certificate
  • I am a Linux user that needs to have the cert and private key

Solution (steps)

Install/export certificate using Windows VM

@ChickenProp
ChickenProp / gist:3050085
Created July 4, 2012 23:35
Simple Raspberry Pi GPIO example

Introduction

This is a dead-simple way to test that GPIO on the Raspberry Pi is working. I have an SKPang Raspberry Pi starter kit A. But all you need is

  • A Raspberry Pi.
  • An LED.
  • A button.
  • A resistor, approximately 270Ω.
  • Some way to connect these to each other and the GPIO pins.