Skip to content

Instantly share code, notes, and snippets.

View wcc526's full-sized avatar

chi-chi weng wcc526

View GitHub Profile
@wcc526
wcc526 / html.md
Created September 26, 2015 06:50
html.md

CSS Convention

  • 一律使用 SCSS 撰寫 CSS
  • CSS 裡用到的圖片放在 assets/stylesheets/images
  • 站上的圖片如 logo.pngsearch.png 放在 assets/images
  • 永遠不會改的靜態檔案如 robots.txtfavicon.ico 放在 public/ 下
  • 太大的圖片也放在 public/ 下
@wcc526
wcc526 / scss.md
Created September 26, 2015 06:49
scss.md

scss

sass --watch style.scss:style.css --style expanded
sass --watch style.scss:style.css --style compressed
@wcc526
wcc526 / wed.md
Created September 26, 2015 06:47
web.md

缓存

强制刷新的话,会在请求头部添加

Pragma:no-cache 和 Cache-Control:no-cache 字段

Last-Modified

表示资源的最后修改时间,浏览器在请求的时候会在请求头中添加一个 If-Modified-Since 字段,查询是否是最新的,如果是返回304

@wcc526
wcc526 / html_workflow.md
Created September 26, 2015 06:46
html workflow

常见 workflow

assets

  • icons
  • logos
  • stock

html

@wcc526
wcc526 / xss-ie.md
Created September 26, 2015 06:44
xss-ie

IE

<img ... title=""onerror="alert(1)">
<img ... title=``onerror=`alert(1)`>
@wcc526
wcc526 / blsql.py
Last active April 7, 2023 15:30
Blind SQL injection Python shell
#!/usr/bin/env python
'''
Blind SQL injection Python shell
BSIShell is a simple python script that permits blind SQL injection.
by Rodrigo Marcos
'''
description = [[ Attempt to get App ]]
author = "wcc526 <949409306@qq.com>"
license = "Same as Nmap"
categoriese = {"default","discovery","safe"}
local shortport = require "shortport"
local http = require "http"
portrule = shortport.port_or_service({80,8081},{"http"})
-- The Head Section --
-- https://thesprawl.org/research/writing-nse-scripts-for-vulnerability-scanning/
description = [[Sample script to detect a fictional vulnerability
in a fictional ArcticFission 1.0 web server]]
---
-- @usage
-- nmap --script http-vuln-check <target>
-- @output
-- PORT STATE SERVICE
1. alpha release
example 1.2a1
unstable missing features
2. beta release
example 2.3.1b2
feature complete still buggy
3. release candidate
@wcc526
wcc526 / gist:50a2ab1651d9ccaa0afb
Created June 22, 2015 13:41
sysbench 性能测试
sysbench --test=cpu --cpu-max-prime=20000 run
sysbench --test=fileio --num-threads=16 --file-rw-ratio=5 \
--file-total-size=300M --file-test-mode=rndrw prepare
sysbench --test=fileio --num-threads=16 --file-rw-ratio=5 \
--file-total-size=300M --file-test-mode=rndrw run
sysbench --test=memory --num-threads=16 \
--memory-block-size=8192 --memory-total-size=1G run