Skip to content

Instantly share code, notes, and snippets.

View bitsmanent's full-sized avatar

Claudio Alessi bitsmanent

View GitHub Profile
@bitsmanent
bitsmanent / nginx.conf
Created June 2, 2017 09:54 — forked from plentz/nginx.conf
Best nginx configuration for improved security(and performance). Complete blog post here http://tautt.com/best-nginx-configuration-for-security/
# to generate your dhparam.pem file, run in the terminal
openssl dhparam -out /etc/nginx/ssl/dhparam.pem 2048
@bitsmanent
bitsmanent / hash.js
Last active May 2, 2024 20:20 — forked from zazapeta/auth.js
Hashing and verifying in Node.js using pbkdf2
const crypto = require("crypto");
const config = {
hashBytes: 32,
saltBytes: 16,
iterations: 300000,
digest: "sha512"
};
function hashPassword(pwd) {