Skip to content

Instantly share code, notes, and snippets.

View Herts's full-sized avatar
🏠
Working from home

Hanzhe Li Herts

🏠
Working from home
View GitHub Profile
@boypt
boypt / gist:80d9ecaaa7f3c799c525e91f3c0b35d1
Created February 22, 2019 14:27
v2ray-core 流量统计 StatsService 使用要点
StatsService API获得数据统计功能,配置里面必须满足以下条件
1. `"stats":{}`对象的存在
2. `"api"`配置对象里面有`StatsService`
3. `"policy"`中的统计开关为true,除了各个用户的统计,还有全局统计
4. clients里面要有email
5. 有个专用的`dokodemo-door`协议的入口,tag为api
6. routing里面有inboundTag:api -> outboundTag:api的规则
另外:
@jakebathman
jakebathman / StateBoundaries.sql
Last active February 12, 2024 00:14
The approximate max/min latitude and longitude for all states and major territories
-- Create the table
CREATE TABLE IF NOT EXISTS `StateBoundaries` (
`State` varchar(10) DEFAULT NULL,
`Name` varchar(255) DEFAULT NULL,
`MinLat` varchar(50) DEFAULT NULL,
`MaxLat` varchar(50) DEFAULT NULL,
`MinLon` varchar(50) DEFAULT NULL,
`MaxLon` varchar(50) DEFAULT NULL
) ENGINE=InnoDB DEFAULT CHARSET=utf8;
@pwlin
pwlin / gist:8a0d01e6428b7a96e2eb
Last active May 4, 2024 07:08
Android : add cert to system store
https://code.google.com/p/android/issues/detail?id=32696#c5
If you have a certificate that is not
trusted by Android, when you add it, it goes in the personal cert store.
When you add a cert in this personal cert store, the system requires a
higher security level to unlock the device. But if you manage to add your
cert to the system store then you don't have this requirement. Obviously,
root is required to add a certificate to the system store, but it is quiet
easy.