Skip to content

Instantly share code, notes, and snippets.

View w2ak's full-sized avatar

Clément Durand w2ak

  • École polytechnique
  • Palaiseau, FRANCE
View GitHub Profile
#include <iostream>
#include <memory>
#include <list>
using namespace std;
#define SIZE 4
static int GID = 0;
struct X {
int id;
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA512
Mon Aug 13 12:03:33 JST 2018
For a number of reasons, I've set up a new PGP key for my e-mail address
<clement[at]neze[dot]fr>, and will be transitioning this ID away from my
old key.
The old key will continue to support the ID for some time but I would
@w2ak
w2ak / config
Last active January 31, 2018 09:41
Host *
IdentityFile ~/.ssh/id_rsa
Host c*-* enst
User cdurand
Host enst
Hostname ssh.enst.fr
Host c*-*
Hostname %h.enst.fr
ProxyCommand ssh -W %h:%p enst
@w2ak
w2ak / easyrsa-bash-bug.patch
Created December 3, 2017 21:01
easyrsa patch for bash bug and test function
---
easyrsa | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/easyrsa b/easyrsa
index e004e2b..785435b 100755
--- a/easyrsa
+++ b/easyrsa
@@ -641,7 +641,7 @@ $(display_dn req "$req_in")
*filter
:INPUT DROP
:FORWARD DROP
:OUTPUT ACCEPT
# Input requests setup
## Accept every local input (packets comming to the loopback interface)
-A INPUT -i lo -j ACCEPT
## Keep accepting already established connections
-A INPUT -m conntrack --ctstate RELATED,ESTABLISHED -j ACCEPT
## Reject invalid packets

Keybase proof

I hereby claim:

  • I am w2ak on github.
  • I am neze (https://keybase.io/neze) on keybase.
  • I have a public key ASDgmyRB22q3C1xfi8j1dBoYVolV7OrQNJxnP4Px03Uuswo

To claim this, I am signing this object:

@w2ak
w2ak / ssh.sh
Created October 16, 2017 14:42
SSH script to connect to ENST. ./ssh.sh -h for help.
#!/bin/sh
VNET_USER=""
TELECOM_USER=""
TELECOM_KEY=""
TELECOM_CONFIG=1
PROG="$(readlink -m $0)"
usage () {
cat << EOF >&2