Skip to content

Instantly share code, notes, and snippets.

View hongry18's full-sized avatar

hongry hongry18

View GitHub Profile
@hongry18
hongry18 / GeoIP.module.install.md
Last active April 24, 2018 02:03
GeoIP module install
@hongry18
hongry18 / haproxy.cfg.md
Last active April 4, 2018 02:30
haproxy setting was, websocket

haproxy.cfg

global
    tune.ssl.default-dh-param 2048
    log               127.0.0.1 local0 notice
    user              root
    group             root

defaults
    mode              http
@hongry18
hongry18 / nginx.conf
Created February 8, 2018 04:24 — forked from Stanback/nginx.conf
Example Nginx configuration for adding cross-origin resource sharing (CORS) support to reverse proxied APIs
#
# CORS header support
#
# One way to use this is by placing it into a file called "cors_support"
# under your Nginx configuration directory and placing the following
# statement inside your **location** block(s):
#
# include cors_support;
#
# As of Nginx 1.7.5, add_header supports an "always" parameter which
@hongry18
hongry18 / epoll.go
Created January 26, 2018 09:50 — forked from tevino/epoll.go
Golang example for using epoll
package main
import (
"fmt"
"net"
"os"
"syscall"
)
const (
@hongry18
hongry18 / osx.route.md
Created January 22, 2018 01:56
맥 인터넷 무선, 유선 사용시 라우팅

sudo route -n add 출발지 목적지

example

내부망 192.168.0.0 ~ 192.168.255.255 연결할 게이트웨이 192.168.100.1

sudo route -n add 192.168.0.0/16 192.168.100.1

등록된 라우트 인터페이스 삭제

sudo route delete 192.168.0.0/16

@hongry18
hongry18 / websocketserver.py
Created January 8, 2018 05:21 — forked from qirt/websocketserver.py
Simple WebSockets RFC 6455 in Python
import array
import time
import socket
import hashlib
import sys
from select import select
import re
import logging
from threading import Thread
import signal
@hongry18
hongry18 / crypto.md
Last active January 6, 2023 01:07
javascript aes, rsa crypto
@hongry18
hongry18 / ssh.tunneling.md
Last active February 12, 2018 07:39
ssh.tunneling.md

SSH Tunneling

  • -L Option: Local Port Forwarding
  • -R Option: Remote Port Forwarding
  • -N: Do not execute a remote command

command

create single tunnel

ssh -N -LPort:host:Port2 user@host
@hongry18
hongry18 / tomcat-file-encoding.md
Created November 21, 2017 22:37
tomcat file encoding

edit catalina.sh

JAVA_OPTS="$JAVA_OPTS $JSSE_OPTS -Dfile.encoding=UTF-8 -Dfile.client.encoding=UTF-8 -Dclient.encoding.override=UTF-8"