Skip to content

Instantly share code, notes, and snippets.

View fzipi's full-sized avatar

Felipe Zipitría fzipi

View GitHub Profile
@fzipi
fzipi / sign-crs-release.sh
Created March 21, 2024 11:57
Script for signing CRS releases
#!/usr/bin/env bash -e
#
# Script to download the release from GitHub and sign it using the coreruleset GPG key
#
GPG_OPTIONS="-b --default-key security@coreruleset.org --status-fd 0 --armor"
version=$1
formats=("zip" "tar.gz")
echo "CRS Sign release script"
echo "======================="
@fzipi
fzipi / generate-crs-agenda.sh
Last active October 2, 2022 11:54
Generates the CRS agenda for the monthly meeting.
#!/usr/bin/env bash
export GH_PAGER=cat
if [ ! $(which gh) ]; then
echo "We need the gh command for this."
exit 1
fi
lastmeeting=$1
@fzipi
fzipi / re2-supported-syntax.md
Last active January 22, 2022 20:54
re2 supported syntax

RE2 regular expression syntax reference

Single characters:

. any character, possibly including newline (s=true)
[xyz] character class
[^xyz] negated character class
\d, Perl character class
@fzipi
fzipi / coreruleset-tests.patch
Last active March 17, 2021 23:45
Patch for the coreruleset tests so they can be used with go-ftw
diff -ru ../coreruleset/tests/regression/tests/REQUEST-920-PROTOCOL-ENFORCEMENT/920100.yaml tests/REQUEST-920-PROTOCOL-ENFORCEMENT/920100.yaml
--- ../coreruleset/tests/regression/tests/REQUEST-920-PROTOCOL-ENFORCEMENT/920100.yaml 2020-07-09 08:24:15.700645956 -0300
+++ tests/REQUEST-920-PROTOCOL-ENFORCEMENT/920100.yaml 2021-03-17 20:41:25.140883675 -0300
@@ -41,7 +41,7 @@
uri: "/"
version: "HTTP/1.1"
output:
- status: 400
+ status: [400]
-
@fzipi
fzipi / 0001-fix-zeromq-backport-zeromq-patch.patch
Created October 2, 2020 15:37
Patch for zeromq problems in Salt
From 77d023b73b37ac4989aa4fd6ca119c62eeca7b97 Mon Sep 17 00:00:00 2001
From: Felipe Zipitria <fzipitria@perceptyx.com>
Date: Fri, 2 Oct 2020 12:33:08 -0300
Subject: [PATCH] fix(zeromq): backport zeromq patch
Signed-off-by: Felipe Zipitria <fzipitria@perceptyx.com>
---
salt/scripts.py | 21 ++++++++++++++++-----
salt/transport/zeromq.py | 14 ++++++++++++++
2 files changed, 30 insertions(+), 5 deletions(-)

Keybase proof

I hereby claim:

  • I am fzipi on github.
  • I am fzipitria (https://keybase.io/fzipitria) on keybase.
  • I have a public key ASB_oHz2d172tw2zDZy5B5BoIIE4bzWu-_FMINhOZU6bPgo

To claim this, I am signing this object:

@fzipi
fzipi / ssl.cnf
Created March 27, 2018 21:33 — forked from WebPlatformDocs/ssl.cnf
Create MariaDB/MySQL self-signed SSL certificates through Salt. Full procedure at https://renoirboulanger.com/blog/2015/01/create-mariadb-cluster-replication-ssl-salt-stack/
[client]
ssl
ssl-cert=/etc/mysql/client-cert.pem
ssl-key=/etc/mysql/client-key.pem
[mysqld]
ssl
ssl-cipher=DHE-RSA-AES256-SHA
ssl-ca=/etc/mysql/ca-cert.pem
ssl-cert=/etc/mysql/server-cert.pem
@fzipi
fzipi / openvpn.md
Created February 18, 2018 01:58 — forked from Morley93/openvpn.md
This is how you can take an openvpn .ovpn config file and extract the certificates/key required to import the profile into NetworkManager.

OpenVPN .ovpn manipulation.

This is how you can take an OpenVPN .ovpn config file and extract the certificates/keys required to import the profile into NetworkManager.

  • Download the .ovpn file. Save it somewhere you can store it permanently (I use ~/.vpn).
  • Copy from between <ca> tags into ca.crt, remove <ca> tags.
  • Copy from between <cert> tags into client.crt, remove <cert> tags.
  • Copy from between <key> tags into client.key, remove <key> tags.
  • Copy from between <tls-auth> tags into ta.key, remove <tls-auth> tags.
  • Remove the line "key-direction 1"
  • Above "# -----BEGIN RSA SIGNATURE-----" insert the following lines.
@fzipi
fzipi / participant.html
Created December 7, 2017 18:19
Hugo Template for Participant
<!DOCTYPE html>
<html>
<head>
{{ partial "header.html" . }}
</head>
<body>
{{ partial "menu.html" . }}
<div class="page-content">
<div class="participants">
<div class="container">
@fzipi
fzipi / nginx.conf
Created November 2, 2017 01:54
Base nginx
user www-data;
worker_processes auto;
pid /run/nginx.pid;
events {
worker_connections 768;
# multi_accept on;
}
http {