Skip to content

Instantly share code, notes, and snippets.

View gslin's full-sized avatar

Gea-Suan Lin gslin

View GitHub Profile
gslin@home [~] [04:45/W3] dig techcrunch.com aaaa @ns1.wordpress.com
; <<>> DiG 9.10.3-P4-Ubuntu <<>> techcrunch.com aaaa @ns1.wordpress.com
;; global options: +cmd
;; Got answer:
;; ->>HEADER<<- opcode: QUERY, status: NOERROR, id: 30391
;; flags: qr aa rd; QUERY: 1, ANSWER: 0, AUTHORITY: 1, ADDITIONAL: 1
;; WARNING: recursion requested but not available
;; OPT PSEUDOSECTION:
@gslin
gslin / 168.95.1.1
Created November 22, 2017 22:11
Query 24h.pchome.com.tw
$ repeat 100 time dig 24h.pchome.com.tw aaaa @168.95.1.1 > /dev/null
dig 24h.pchome.com.tw aaaa @168.95.1.1 > /dev/null 0.00s user 0.01s system 0% cpu 5.030 total
dig 24h.pchome.com.tw aaaa @168.95.1.1 > /dev/null 0.01s user 0.00s system 0% cpu 6.148 total
dig 24h.pchome.com.tw aaaa @168.95.1.1 > /dev/null 0.01s user 0.00s system 0% cpu 1.954 total
dig 24h.pchome.com.tw aaaa @168.95.1.1 > /dev/null 0.01s user 0.00s system 0% cpu 5.673 total
dig 24h.pchome.com.tw aaaa @168.95.1.1 > /dev/null 0.01s user 0.00s system 33% cpu 0.024 total
dig 24h.pchome.com.tw aaaa @168.95.1.1 > /dev/null 0.00s user 0.00s system 38% cpu 0.021 total
dig 24h.pchome.com.tw aaaa @168.95.1.1 > /dev/null 0.01s user 0.00s system 0% cpu 5.029 total
dig 24h.pchome.com.tw aaaa @168.95.1.1 > /dev/null 0.01s user 0.00s system 0% cpu 3.229 total
dig 24h.pchome.com.tw aaaa @168.95.1.1 > /dev/null 0.02s user 0.00s system 50% cpu 0.032 total
#!/usr/bin/env python
# -*- coding: utf-8 -*-
import lxml.html
import re
import requests
import sqlite3
def procedure():
url = 'https://24h.pchome.com.tw/?m=store&f=book_show&RG_NO=DJAZ&pageType=0'
// ==UserScript==
// @name Quick Open Tabs in Alabout
// @namespace https://blog.gslin.org/quick-open-tabs-alabout
// @include http://alabout.com/*
// @version 1
// @grant GM_openInTab
// ==/UserScript==
(function(){
window._quick_open_tabs = function (el) {
gslin@Gea-suandeMacBook-Pro [~] [01:26/W2] mtr --report 139.175.1.1
Start: Sun Nov 27 01:26:25 2016
HOST: Gea-suandeMacBook-Pro.local Loss% Snt Last Avg Best Wrst StDev
1.|-- 192.168.1.1 0.0% 10 7.6 6.2 1.3 33.0 9.6
2.|-- h254.s98.ts.hinet.net 0.0% 10 8.6 12.3 8.0 33.7 7.9
3.|-- tpe4-3302.hinet.net 0.0% 10 8.0 10.5 7.8 19.4 4.0
4.|-- 220-128-11-226.hinet-ip.h 0.0% 10 30.0 16.1 8.1 35.0 10.1
5.|-- tpdt-3012.hinet.net 0.0% 10 12.5 16.3 9.5 39.7 8.9
6.|-- r4001-s2.tp.hinet.net 0.0% 10 9.4 13.3 8.3 29.2 6.1
7.|-- r4001-s2.tp.hinet.net 0.0% 10 11.8 11.5 8.1 22.8 4.2
gslin@Gea-suandeMacBook-Pro [~] [13:17/W2] curl https://httpbin.org/ip
{
"origin": "54.250.252.97"
}
gslin@Gea-suandeMacBook-Pro [~] [13:18/W2] host 54.250.252.97
97.252.250.54.in-addr.arpa domain name pointer ec2-54-250-252-97.ap-northeast-1.compute.amazonaws.com.
gslin@Gea-suandeMacBook-Pro [~] [13:18/W2] host ec2-54-250-252-97.ap-northeast-1.compute.amazonaws.com
ec2-54-250-252-97.ap-northeast-1.compute.amazonaws.com has address 54.250.252.97
#!/usr/bin/env python3
from ggplot import *
from pandas import DataFrame
data = DataFrame([
{
'year': 1905,
'number': 3039751,
},
gslin@Gea-suandeMacBook-Pro [~] [03:14/W2] mtr --report -n i.kfs.io
Start: Sat Sep 17 03:14:54 2016
HOST: Gea-suandeMacBook-Pro.local Loss% Snt Last Avg Best Wrst StDev
1.|-- 192.168.2.1 0.0% 10 9.5 9.6 1.9 23.3 5.7
2.|-- 210.153.249.235 0.0% 10 19.3 13.4 9.5 19.3 3.6
3.|-- 210.153.249.153 0.0% 10 11.1 11.7 8.1 17.9 3.4
4.|-- 210.153.255.93 0.0% 10 19.4 13.9 7.9 21.3 4.5
5.|-- 210.165.241.202 0.0% 10 10.3 12.5 7.2 18.0 4.0
6.|-- 210.165.241.61 0.0% 10 10.1 12.1 6.9 17.6 3.9
7.|-- 210.165.241.21 0.0% 10 9.8 13.9 8.9 26.9 5.7

Keybase proof

I hereby claim:

  • I am gslin on github.
  • I am gslin (https://keybase.io/gslin) on keybase.
  • I have a public key whose fingerprint is 14F8 AE85 2B2D CAF5 7DC8 299C 9AA2 4684 D233 BE5F

To claim this, I am signing this object:

<?xml version="1.0"?>
<!DOCTYPE fontconfig SYSTEM "fonts.dtd">
<fontconfig>
<!-- serif -->
<match target="pattern">
<test qual="any" name="family">
<string>serif</string>
</test>
<edit name="family" mode="prepend" binding="strong">
<string>Contra</string>