Skip to content

Instantly share code, notes, and snippets.

View bitbeans's full-sized avatar

Christian Hermann bitbeans

View GitHub Profile
@Belphemur
Belphemur / build_nginx.sh
Last active November 13, 2022 13:05 — forked from MattWilcox/build_nginx.sh
Compiling Nginx with LibreSSL (and http2)
#!/usr/bin/env bash
# names of latest versions of each package
export NGINX_VERSION=1.15.5
export VERSION_NGINX=nginx-$NGINX_VERSION
export VERSION_LIBRESSL=libressl-2.8.1
export VERSION_PCRE=pcre-8.42
#export NPS_VERSION=1.9.32.10
#export VERSION_PAGESPEED=v${NPS_VERSION}-beta
@claws
claws / zmq.sls
Created July 12, 2014 12:10
This gist shows a method for using Saltstack to automate the build and install of libsodium, libzmq, czmq and pyzmq. This state can be used to keep the ZMQ stack up to date.
#
# Author: Chris Laws
#
# This saltstack state automates the build and install of the
# current version of the Github master branch for libsodium,
# libzmq, czmq and pyzmq (for both python2 and python3).
#
# This state is part of a suite of states I use to recreate my
# development machine and keep it up to date. It contains some
# configuration instructions that slightly beyond the common
# Install dependencies
#
# * checkinstall: package the .deb
# * libpcre3, libpcre3-dev: required for HTTP rewrite module
# * zlib1g zlib1g-dbg zlib1g-dev: required for HTTP gzip module
apt-get install checkinstall libpcre3 libpcre3-dev zlib1g zlib1g-dbg zlib1g-dev && \
mkdir -p ~/sources/ && \
# Compile against OpenSSL to enable NPN
@jogleasonjr
jogleasonjr / SlackClient.cs
Last active October 20, 2023 15:54
A simple C# class to post messages to a Slack channel. You must have the Incoming WebHooks Integration enabled. This class uses the Newtonsoft Json.NET serializer available via NuGet. Scroll down for an example test method and a LinqPad snippet. Enjoy!
using Newtonsoft.Json;
using System;
using System.Collections.Specialized;
using System.Net;
using System.Text;
//A simple C# class to post messages to a Slack channel
//Note: This class uses the Newtonsoft Json.NET serializer available via NuGet
public class SlackClient
{
@plentz
plentz / nginx.conf
Last active April 30, 2025 08:40
Best nginx configuration for improved security(and performance)
# to generate your dhparam.pem file, run in the terminal
openssl dhparam -out /etc/nginx/ssl/dhparam.pem 2048
@CodesInChaos
CodesInChaos / ArrayHelpers.cs
Created July 25, 2012 12:43
Base58 encoding in C# (Used for BitCoin addresses)
using System;
using System.Diagnostics.Contracts;
using System.Linq;
namespace Merkator.Tools
{
public class ArrayHelpers
{
public static T[] ConcatArrays<T>(params T[][] arrays)
{
@lpar
lpar / md5daemon
Created June 17, 2011 20:23
Automatic MD5 checksum generating daemon for use with vsftpd
#!/usr/bin/env ruby
# encoding: UTF-8
'di '
'ig00 '
# VSFTPD auto-MD5 program
#
# Run man -l <this file> for documentation
require 'rb-inotify'