Skip to content

Instantly share code, notes, and snippets.

View instagrim-dev's full-sized avatar

Jonathan Maye-Hobbs instagrim-dev

  • .local
View GitHub Profile
@instagrim-dev
instagrim-dev / how-to-generate-and-use-private-keys-with-openssl-tool.md
Created January 23, 2023 04:41 — forked from briansmith/how-to-generate-and-use-private-keys-with-openssl-tool.md
How to generate & use private keys using the OpenSSL command line tool

How to Generate & Use Private Keys using OpenSSL's Command Line Tool

These commands generate and use private keys in unencrypted binary (not Base64 “PEM”) PKCS#8 format. The PKCS#8 format is used here because it is the most interoperable format when dealing with software that isn't based on OpenSSL.

OpenSSL has a variety of commands that can be used to operate on private key files, some of which are specific to RSA (e.g. openssl rsa and openssl genrsa) or which have other limitations. Here we always use

@instagrim-dev
instagrim-dev / CMakeLists.txt
Created January 18, 2023 23:32 — forked from kwk/CMakeLists.txt
Fix for "undefined reference to dlopen" in CMake projects
project(testlink)
add_executable(testlink main.cpp)
target_link_libraries(testlink)
@instagrim-dev
instagrim-dev / CMakeLists.txt
Created January 18, 2023 23:32 — forked from kwk/CMakeLists.txt
Fix for "undefined reference to dlopen" in CMake projects
project(testlink)
add_executable(testlink main.cpp)
target_link_libraries(testlink)
@instagrim-dev
instagrim-dev / README.md
Created September 26, 2022 16:07 — forked from darvin/README.md
Travis CI + iOS code signing

Build ios app for iphoneos sdk with signing using Travis ci.

  1. Export your private key that you are going to use for signing from Keychain Access app to ~/privateKey.p12 with export password __YourRandomPass22
  2. Fetch script and run it from your Travis-enabled target iOS app repo: IOS_IDENTITY_KEY=~/privateKey.p12 IOS_IDENTITY_KEY_PASSWORD=__YourRandomPass22 bash <(curl -s https://gist.githubusercontent.com/darvin/96a3af399d0b970a59b1/raw/setup_travis_ios_signing.sh)
  3. Review changes and commit. It suppose to work now.
Network::Address::InstanceConstSharedPtr
RedisCluster::RedisDiscoverySession::RedisDiscoverySession::ProcessCluster(
const NetworkFilters::Common::Redis::RespValue& value) {
if (value.type() != NetworkFilters::Common::Redis::RespType::Array) {
return nullptr;
}
auto& array = value.asArray();
if (array.size() < 2 || array[0].type() != NetworkFilters::Common::Redis::RespType::BulkString ||
array[1].type() != NetworkFilters::Common::Redis::RespType::Integer) {
class LoginBonusMaster(Base):
__tablename__ = 'login_bonus_master'
id = Column(Integer, primary_key=True, index=True)
message_title = Column(Text)
message_content = Column(Text)
_daily_reward_id_list = Column('daily_reward_id_list')
termview_flag = Column(Integer)
infinite_flag = Column(Integer)
@instagrim-dev
instagrim-dev / .gitconfig
Created January 10, 2020 19:47 — forked from johnpolacek/.gitconfig
My current .gitconfig aliases
[alias]
co = checkout
cob = checkout -b
coo = !git fetch && git checkout
br = branch
brd = branch -d
brD = branch -D
merged = branch --merged
st = status
aa = add -A .
@instagrim-dev
instagrim-dev / xxtea.py
Created December 8, 2019 21:55 — forked from syndrill/xxtea.py
cocos2d-x implementation of XXTEA
#!/usr/bin/env python
# -*- coding: UTF-8 -*-
import struct
_DELTA = 0x9E3779B9
def _long2str(v, w):
n = (len(v) - 1) << 2
if w:
@instagrim-dev
instagrim-dev / slack_webhook_post.py
Created August 31, 2018 19:10 — forked from devStepsize/slack_webhook_post.py
POST a JSON payload to a Slack Incoming Webhook using Python requests
'''
This is an example of how to send data to Slack webhooks in Python with the
requests module.
Detailed documentation of Slack Incoming Webhooks:
https://api.slack.com/incoming-webhooks
'''
import json
import requests
@instagrim-dev
instagrim-dev / 1) Install
Created March 8, 2017 21:03 — forked from nghuuphuoc/1) Install
Install Redis on Centos 6
// --- Compiling ---
$ wget http://download.redis.io/releases/redis-2.8.3.tar.gz
$ tar xzvf redis-2.8.3.tar.gz
$ cd redis-2.8.3
$ make
$ make install
// --- or using yum ---
$ rpm -Uvh http://download.fedoraproject.org/pub/epel/6/x86_64/epel-release-6-8.noarch.rpm
$ rpm -Uvh http://rpms.famillecollet.com/enterprise/remi-release-6.rpm