Skip to content

Instantly share code, notes, and snippets.

View karangoel16's full-sized avatar
🎯
Focusing

Karan Goel karangoel16

🎯
Focusing
View GitHub Profile
@irbull
irbull / OpenSSLExample.cpp
Created August 11, 2016 18:32
Code signing and verification with OpenSSL
#include <iostream>
#include <openssl/aes.h>
#include <openssl/evp.h>
#include <openssl/rsa.h>
#include <openssl/pem.h>
#include <openssl/ssl.h>
#include <openssl/bio.h>
#include <openssl/err.h>
#include <assert.h>
@jisaacstone
jisaacstone / elixir_distributed.ex
Last active July 10, 2018 18:26
programmatic node startup in elixir
defmodule ExDistUtils do
def start_distributed(appname) do
unless Node.alive?() do
local_node_name = generate_name(appname)
{:ok, _} = Node.start(local_node_name)
end
cookie = Application.get_env(appname, :cookie)
Node.set_cookie(cookie)
end