Skip to content

Instantly share code, notes, and snippets.

View pstjuste's full-sized avatar

Pierre St Juste pstjuste

View GitHub Profile
# start docker
sudo start docker
# stop docker
sudo stop docker
# list images
sudo docker images
# list containers
@pstjuste
pstjuste / cmd.sh
Last active December 15, 2018 18:45
These are a bunch of small scripts that I use, I figured it would be better to have them publicly as gists :)
# create certificate
openssl rsa -in old.key -des3 -out new.key
openssl pkcs12 -export -chain -in old.crt -inkey new.key -CAfile ca.crt -out new.p12
# self sign certificate
openssl req \
-x509 -nodes -days 365 \
-newkey rsa:1024 -keyout mycert.pem -out mycert.pem
# clear chromeos partition
@pstjuste
pstjuste / l2capsender.c
Last active May 15, 2017 06:05
WebRTC session creation over command line
#include <unistd.h>
#include <stdio.h>
#include <string.h>
#include <stdlib.h>
#include <fcntl.h>
#include <errno.h>
#include <sys/un.h>
#include <sys/ioctl.h>
#include <sys/types.h>
@pstjuste
pstjuste / gnu_crawl.py
Last active August 25, 2018 17:16
This code runs on appengine and provides a simple IP lookup service for my machines.
#!/usr/bin/env python
"""
This link below is where to get a list of Gnutella web caches
http://gwebcaches.pongwar.com/gnutella.html
This is an example of how to obtain a list of Gnutella nodes
curl 'http://gwc.gofoxy.net:2108/gwc/cgi-bin/fc?hostfile=1'
"""