Skip to content

Instantly share code, notes, and snippets.

182.92.24.51 gd2w.line.naver.jp
184.50.238.139 dl.profile.line.naver.jp
184.50.238.138 dl.stickershop.line.naver.jp
203.104.142.1 gd2.line.naver.jp
125.209.252.16 gd2g.line.naver.jp
125.209.252.12 gd2i.line.naver.jp
125.209.222.59 gd2k.line.naver.jp
203.104.168.11 gd2s.line.naver.jp
203.104.160.12 gd2u.line.naver.jp
no-route = 0.0.0.0/255.0.0.0
no-route = 1.0.0.0/255.128.0.0
no-route = 1.160.0.0/255.224.0.0
no-route = 1.192.0.0/255.224.0.0
no-route = 10.0.0.0/255.0.0.0
no-route = 14.0.0.0/255.224.0.0
no-route = 14.96.0.0/255.224.0.0
no-route = 14.128.0.0/255.224.0.0
no-route = 14.192.0.0/255.224.0.0
no-route = 27.0.0.0/255.192.0.0
@jerry74
jerry74 / gist:6ab9b7060eca5f85a77c
Created March 28, 2015 09:37
chnroute CID2Mast
#!/bin/bash
#wget -O- 'http://ftp.apnic.net/apnic/stats/apnic/delegated-apnic-latest' | awk -F\| '/CN\|ipv4/ { printf("%s/%d\n", $4, 32-log($5)/log(2)) }' > /etc/chnroute.txt
netcalc(){
local IFS='.' ip i
local -a oct msk
read -ra oct <<<"$1"
read -ra msk <<<"$2"
@jerry74
jerry74 / gist:fe657519f7f9620a804a
Last active August 29, 2015 14:06
Cloudflare DDNS
<?php
if( empty($_GET['key']) || $_GET['key'] != "Pv226Key" ) die("Not Authorized!");
$allips = array();
if (isset($_SERVER['HTTP_CLIENT_IP'])) {
array_push($allips, $_SERVER['HTTP_CLIENT_IP']);
}
if (isset($_SERVER['HTTP_X_FORWARDED_FOR'])) {
$proxyips = explode(',', $_SERVER['HTTP_X_FORWARDED_FOR']);
// ==UserScript==
// @name smzdm-login-mission
// @namespace userscript-smzdm-autologin
// @description auto-receives the login-mission-awards
// @match *://*.smzdm.com/
// ==/UserScript==
var load, execute, loadAndExecute;
load = function(a, b, c) {
var d;
@jerry74
jerry74 / gist:95fc5e031e0e887c7405
Created July 25, 2014 07:24
dnsmasq start script
#!/bin/sh
### BEGIN INIT INFO
# Provides: dnsmasq
# Required-Start: $network $remote_fs $syslog
# Required-Stop: $network $remote_fs $syslog
# Default-Start: 2 3 4 5
# Default-Stop: 0 1 6
# Description: DHCP and DNS server
### END INIT INFO
<?xml version="1.0" encoding="UTF-8"?>
<beans xmlns="http://www.springframework.org/schema/beans"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xmlns:util="http://www.springframework.org/schema/util"
xsi:schemaLocation="http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans-2.0.xsd
http://www.springframework.org/schema/util http://www.springframework.org/schema/util/spring-util-2.0.xsd">
<bean id="CheckRules" class="java.util.HashMap">
<constructor-arg>
/**
* 身份證字號與居留證(統一證)編號檢核
*
* @param id
* @return
*/
public static boolean isValidIDorRCNumber(String id)
{
id = id.toUpperCase();// 轉換大寫
char[] strArr = id.toCharArray();// 字串轉成char陣列