Skip to content

Instantly share code, notes, and snippets.

View solicomo's full-sized avatar

Soli Como solicomo

View GitHub Profile
@miguelmota
miguelmota / rsa_util.go
Last active April 21, 2024 15:10
Golang RSA encrypt and decrypt example
package ciphers
import (
"crypto/rand"
"crypto/rsa"
"crypto/sha512"
"crypto/x509"
"encoding/pem"
"log"
)
@borgle
borgle / X-Apple-I-FD-Client-Info.js
Last active October 4, 2023 02:27
在访问 https://appleid.apple.com/account?&localang=CN-ZH 这个页面的时候,页面会ajax一个特殊的header请求,其中的X-Apple-I-FD-Client-Info信息是一个json对象,本gist是整理后的F值获取方式源码。
(function(m) {
function g(e) {
try {
if (navigator.plugins && navigator.plugins.length)
for (var t = 0; t < navigator.plugins.length; t++) {
var n = navigator.plugins[t];
if (n.name.indexOf(e) >= 0)
return n.name + (n.description ? "|" + n.description : "")
}
} catch (r) {}
@jarthod
jarthod / browser-mockup.png
Last active October 31, 2022 09:23
Pure CSS browser mockups
browser-mockup.png
@lavoiesl
lavoiesl / bs3-stacked-tabs.less
Created September 18, 2013 15:21
Add tabs-left, tabs-right and tabs-below in bootstrap 3 Credit: http://stackoverflow.com/questions/18432577/stacked-tabs-in-bootstrap-3
// http://stackoverflow.com/questions/18432577/stacked-tabs-in-bootstrap-3
.tabs-below, .tabs-right, .tabs-left {
.nav-tabs {
border-bottom: 0;
}
}
.tab-content > .tab-pane,
.pill-content > .pill-pane {
display: none;
@kzk
kzk / evhttp-multh-thread-httpd.cpp
Created November 6, 2010 13:53
Multi-Threaded HTTPServer using evhttp
#include <event.h>
#include <evhttp.h>
#include <pthread.h>
#include <errno.h>
#include <string.h>
#include <fcntl.h>
#include <sys/socket.h>
#include <sys/types.h>
#include <netinet/in.h>
#include <iostream>