Skip to content

Instantly share code, notes, and snippets.

View xream's full-sized avatar

xream xream

View GitHub Profile
@xream
xream / cname_http_meta_beta.js
Last active November 5, 2024 01:15
HTTP META
/**
* @Sub-Store-Page
* CNAME 接口查询去重/重命名 2023-11-16 20:34:08
* - 入口查询[国内spapi 识别到国外为ip-api] 落地查询[ip-api]
* - 根据接口返回的真实结果,重新对节点命名。
* - 添加入口城市、落地国家或地区、国内运营商信息,并对这些数据做持久化缓存(48小时有效期),减少API请求次数,提高运行效率。
* - 仅兼容 Surge, Loon 客户端。
* - Surge 需要固定带 ability 参数版本。
* 特别说明:
* - 符号:🅳电信 🅻联通 🆈移动 🅶广电 🅲公司 🆉直连 🎮游戏
@xream
xream / readme.md
Created October 12, 2023 16:35 — forked from firexcy/readme.md
DIY a Rewind.ai

This Gist provides a solution to periodically capture screenshots of your Mac, and create therefrom a searchable PDF archive so that you can always get an answer to the “what, when, and where” questions about your usages.

To use these scripts:

  1. Download the shell script rewind, then:
    1. put it under ~/bin (or other fixed path you prefer);
    2. execute
@xream
xream / sojson.v5.decrypt.js
Created September 12, 2023 06:29 — forked from zhangshine/sojson.v5.decrypt.js
sojson.v5 解密
// 用法 console.log(decrypt(加密的js内容))
// console里面输出的内容就是解密后的内容,解密后的内容里面仍然含有 _0xXXXX 这样的混淆后的字符串, 需要一点点进行重命名
// 下面的代码以前从网上找的,已经找不到出处了。。。
function decrypt(js_body) {
// 脱壳 && 解密
let js_arr = js_body.split("\n").pop().split(';'),
fun_name = /var\s+(_0x[a-z0-9]+)=/.exec(js_arr[6])[1],
reg_str = fun_name + '\\(' + "'([^']+)',\s*'([^']+)'" + '\\)',
js_str = js_arr.slice(54, js_arr.length - 4).join(' ;'),
@xream
xream / Keystone 5 - Secure Cookies and Reverse Proxies.md
Created May 6, 2020 02:46 — forked from molomby/Keystone 5 - Secure Cookies and Reverse Proxies.md
Background and instructions for fixing cookie issues encountered when deploying Keystone 5 apps behind a reverse proxy (like nginx)

Keystone 5: Secure Cookies and Reverse Proxies

Can't sign in, eh?

TL;DR

When...

  • Keystone sessions are being used (eg. for authentication)
  • secureCookies Keystone config is true (the default when NODE_ENV is 'production')
@xream
xream / global.css
Created January 17, 2020 10:01
global.css
body {
-webkit-font-smoothing: subpixel-antialiased !important;
font-family: 'PingFang SC';
}
@font-face {
font-family: 'Arial Black';
unicode-range: U+2E80-FFFF;
src: local('PingFang SC');
}
@font-face {
@xream
xream / usersrcipt.js
Created September 18, 2019 08:35
Add Install Button for VSCode Insiders(Dirty and quick)
// ==UserScript==
// @name Add Install Button for VSCode Insiders
// @namespace http://tampermonkey.net/
// @version 0.1
// @description
// @author @xream
// @match https://marketplace.visualstudio.com/items*
// @grant none
// ==/UserScript==
@xream
xream / gist:88559091be365b72c94d606c2b310aed
Created September 12, 2019 16:33
UserScript: VSCode Insiders Install Btn
// ==UserScript==
// @name VSCode Insiders Install Btn
// @namespace http://tampermonkey.net/
// @version 0.1
// @description try to take over the world!
// @author You
// @match https://marketplace.visualstudio.com/items*
// @grant none
// ==/UserScript==
@xream
xream / Sub-Store-1.stoverride
Last active October 7, 2023 07:04
Sub-Store-Stash
name: Sub-Store(latest)
desc: 后端切换为 https://sub2.store
http:
mitm:
- sub2.store
script:
- match: ^https?:\/\/sub2\.store\/((download)|api\/(preview|sync|(utils\/node-info)))
name: sub-store-1-sub2
type: request
@xream
xream / Advertising.list
Last active May 23, 2019 12:32
Advertising.list
DOMAIN-SUFFIX,wxsnsdythumb.wxs.qq.com
DOMAIN-SUFFIX,gorgon.youdao.com
@xream
xream / gist:5f4cda0f482c493a8293d5078d0dab7d
Created November 23, 2017 01:08 — forked from Blankwonder/gist:cd9fa1987e41cf1a1f1df50583ba1d9c
client-side SSL/TLS certificate validation
[Proxy]
TestTLS = https, 192.168.20.6, 443, client-cert=item
[Keystore]
item = password=123456, base64=MIILqQIBAzCCC28GCSqGSIb3DQEHAaCCC2AEggtcMIILWDCCBg8GCSqGSIb3DQEHBqCCBgAwggX8AgEAMIIF9QYJKoZIhvcNAQcBMBwGCiqGSIb3DQEMAQYwDgQIh4LPGCPkcqkCAggAgIIFyDOP/a/YB66H0jctVC5/D3ZF98es9Xtf60hqDokaekMp7VlKhr7EEvf1GrmxOY9XqO1dSR0F2C17yefazR7lZVDwfmNvU8eEpIPrBAnqSnCFyMZGXjcu9aoEySkwRlSclqg9lbFhp9XZG4F4qRuo94mlTPDy47dvdzyiPAQPBIq2DOE/qbRVHqrbnZMkUZi1lxihRRcQv7YJAfLEP2VHffjZTYzlBMi/ldKyD4ZQdpM7mdBtHXFa21ZV9j4oqM2PWWToHwIxkeiS6J2SgfEg501QEy4kbihlp+pSK4OMrj33DrVFP9rOMDnkJtQ+EP0LXXQBaF+7rRp+dekcH+sYBQF0cDMhNEkHEBL8LoQ96hZxIDxE3YQ6fq9KGi4TV8Ktkgb2l0G5DoavN8dhCKS5Gx0nexDT8vj91Js94Xt4tFThSyoc4ZmZvN+b2ugqVvYsnWaKqS8UeAjIAFsZCiLgj4OG6frrAxI+V3c8kL9FrwfFQcL9eWoqVfhBv8SKzMYObTv9FwyJn/fyGdtoT19OpyWiP1+nU+WY7e5KjcJNsKeYolgpgHDXdOSYCakQfesENeeKqvzMA6Quj7g7gZl/AB/GjRybyAXfkxyYBLk5cz7MuDcM1nk6DR47IuHBHyrwOATXyejWYrlK0QUVUsFEmM2vjl38jU8+qxjVWDTFu3gQkFBERncJp1XnKSTueDEPkdeq1BzV1SZ1m1KHNPNI4h2lPa+IKvpYbnDure9n1VV7fk2ySJrBFT5pYonXdpyaCTAvTEFk