Skip to content

Instantly share code, notes, and snippets.

View MegaByte875's full-sized avatar
🎯
Focusing

MegaByte875

🎯
Focusing
  • Vesoft Inc.
  • HangZhou, China
View GitHub Profile
@joelonsql
joelonsql / PostgreSQL-EXTENSIONs.md
Last active May 8, 2025 08:12
1000+ PostgreSQL EXTENSIONs

🗺🐘 1000+ PostgreSQL EXTENSIONs

This is a list of URLs to PostgreSQL EXTENSION repos, listed in alphabetical order of parent repo, with active forks listed under each parent.

⭐️ >= 10 stars
⭐️⭐️ >= 100 stars
⭐️⭐️⭐️ >= 1000 stars
Numbers of stars might not be up-to-date.

@Hakky54
Hakky54 / openssl_commands.md
Last active May 15, 2025 10:08 — forked from p3t3r67x0/openssl_commands.md
OpenSSL Cheat Sheet

OpenSSL Cheat Sheet 🔐

Install

Install the OpenSSL on Debian based systems

sudo apt-get install openssl
@xjdrew
xjdrew / client.go
Last active February 9, 2025 16:52
golang tls client and server, require and verify certificate in double direction
package main
import (
"crypto/tls"
"crypto/x509"
"flag"
"io"
"io/ioutil"
"log"
"os"
@nerdalert
nerdalert / Netfilter-IPTables-Diagrams.md
Last active April 29, 2025 05:23
Linux NetFilter, IP Tables and Conntrack Diagrams

Linux NetFilter, IP Tables and Conntrack Diagrams

IPTABLES TABLES and CHAINS

IPTables has the following 4 built-in tables.

1) Filter Table

Filter is default table for iptables. So, if you don’t define you own table, you’ll be using filter table. Iptables’s filter table has the following built-in chains.

#!/bin/bash
#
# Copyright (c) 2015, Intel Corporation
#
# Redistribution and use in source and binary forms, with or without
# modification, are permitted provided that the following conditions are met:
#
# * Redistributions of source code must retain the above copyright notice,
# this list of conditions and the following disclaimer.
# * Redistributions in binary form must reproduce the above copyright
@cloudnull
cloudnull / neutron-vpnaas-fwaas-lbaas-configSetup.rst
Last active September 4, 2019 08:53
Setup Openstack Havana with Neutron using VPNaaS (VPN as a Service), FWaaS (Firewall as a Service), LBaaS (Load Balancer as a Service).

Installing Openstack VPNaaS, LBaaS, and FWaaS

This brief overview assumes that Openstack Havana has been installed and setup with Neutron Networking. If you have not already done this, you could use "https://github.com/cloudnull/rcbops_allinone_inone" or devstack to setup a dev box and then perform the following actions.


  • install "openswan":

    # (apt-get install openswan neutron-plugin-vpn-agent) || (yum install openswan openstack-neutron-vpn-agent && chkconfig neutron-vpn-agent on)
    
@klange
klange / _.md
Last active December 23, 2024 14:40
It's a résumé, as a readable and compilable C source file. Since Hacker News got here, this has been updated to be most of my actual résumé. This isn't a serious document, just a concept to annoy people who talk about recruiting and the formats they accept résumés in. It's also relatively representative of my coding style.

Since this is on Hacker News and reddit...

  • No, I don't distribute my résumé like this. A friend of mine made a joke about me being the kind of person who would do this, so I did (the link on that page was added later). My actual résumé is a good bit crazier.
  • I apologize for the use of _t in my types. I spend a lot of time at a level where I can do that; "reserved for system libraries? I am the system libraries".
  • Since people kept complaining, I've fixed the assignments of string literals to non-const char *s.
  • My use of type * name, however, is entirely intentional.
  • If you're using an older compiler, you might have trouble with the anonymous unions and the designated initializers - I think gcc 4.4 requires some extra braces to get them working together. Anything reasonably recent should work fine. Clang and gcc (newer than 4.4, at le
@jboner
jboner / latency.txt
Last active May 15, 2025 07:53
Latency Numbers Every Programmer Should Know
Latency Comparison Numbers (~2012)
----------------------------------
L1 cache reference 0.5 ns
Branch mispredict 5 ns
L2 cache reference 7 ns 14x L1 cache
Mutex lock/unlock 25 ns
Main memory reference 100 ns 20x L2 cache, 200x L1 cache
Compress 1K bytes with Zippy 3,000 ns 3 us
Send 1K bytes over 1 Gbps network 10,000 ns 10 us
Read 4K randomly from SSD* 150,000 ns 150 us ~1GB/sec SSD