Skip to content

Instantly share code, notes, and snippets.

@aflyhorse
aflyhorse / gist:d9b871d449c50264f9df
Last active September 12, 2016 02:16
Secure SSL for Nginx
openssl dhparam -out dhparams.pem 2048
ssl_ciphers 'ECDHE-RSA-AES128-GCM-SHA256:ECDHE-ECDSA-AES128-GCM-SHA256:ECDHE-RSA-AES256-GCM-SHA384:ECDHE-ECDSA-AES256-GCM-SHA384:DHE-RSA-AES128-GCM-SHA256:DHE-DSS-AES128-GCM-SHA256:kEDH+AESGCM:ECDHE-RSA-AES128-SHA256:ECDHE-ECDSA-AES128-SHA256:ECDHE-RSA-AES128-SHA:ECDHE-ECDSA-AES128-SHA:ECDHE-RSA-AES256-SHA384:ECDHE-ECDSA-AES256-SHA384:ECDHE-RSA-AES256-SHA:ECDHE-ECDSA-AES256-SHA:DHE-RSA-AES128-SHA256:DHE-RSA-AES128-SHA:DHE-DSS-AES128-SHA256:DHE-RSA-AES256-SHA256:DHE-DSS-AES256-SHA:DHE-RSA-AES256-SHA:AES128-GCM-SHA256:AES256-GCM-SHA384:AES128-SHA256:AES256-SHA256:AES128-SHA:AES256-SHA:AES:CAMELLIA:DES-CBC3-SHA:!aNULL:!eNULL:!EXPORT:!DES:!RC4:!MD5:!PSK:!aECDH:!EDH-DSS-DES-CBC3-SHA:!EDH-RSA-DES-CBC3-SHA:!KRB5-DES-CBC3-SHA';
ssl_prefer_server_ciphers on;
ssl_dhparam /etc/ssl/private/dhparams.pem;
ssl_session_cache shared:SSL:50m;
ssl_session_timeout 5m;
Thanks:
https://www.ssllabs.com/ssltest/index.html
@aflyhorse
aflyhorse / rrsync
Last active September 22, 2016 08:47
A script to spur on rsync
#!/bin/bash
# A script to spur on rsync.
# Released under GPLv3, copyright LunarShaddow
# retry cap
MAXTRY=10
# safety-keep sleep interval
SLEEPSEC=600
RVALUE=0
@aflyhorse
aflyhorse / gnushogi.spec
Last active January 23, 2018 06:27
RPM spec of gnushogi for Fedora
Name: gnushogi
%global commit 5bb0b5b2f6953b3250e965c7ecaf108215751a74
%global shortcommit %(c=%{commit}; echo ${c:0:7})
Version: 1.5
Release: 0.2.git%{shortcommit}%{?dist}
Summary: Shogi, the Japanese version of chess
License: GPLv3+