install
$ wget https://github.com/buger/gor/releases/download/v0.10.1/gor_0.10.1_x64.tar.gz
$ tar zxvf gor_0.10.1_x64.tar.gz
$ mv ./gor /usr/local/bin/
準備
$ sudo setcap CAP_NET_RAW=ep gor
run
$ make start-server
$ make start-gor-case1
$ http localhost:8081
$ sudo ngrep -d lo -W byline port 8081
interface: lo (127.0.0.0/255.0.0.0)
filter: ( port 8081 ) and (ip or ip6)
######
T 127.0.0.1:45925 -> 127.0.0.1:8081 [AP]
GET / HTTP/1.1.
Host: localhost:8081.
Connection: keep-alive.
Accept-Encoding: gzip, deflate.
Accept: */*.
User-Agent: HTTPie/0.9.2.
.
##
T 127.0.0.1:8081 -> 127.0.0.1:45925 [AP]
HTTP/1.1 200 OK.
Date: Wed, 25 Nov 2015 13:37:42 GMT.
Content-Length: 7.
Content-Type: text/plain; charset=utf-8.
.
server1
####
$ sudo ngrep -d lo -W byline port 8082
interface: lo (127.0.0.0/255.0.0.0)
filter: ( port 8082 ) and (ip or ip6)
#
T 127.0.0.1:51706 -> 127.0.0.1:8082 [AP]
GET / HTTP/1.1.
Host: :8082.
Connection: keep-alive.
Accept-Encoding: gzip, deflate.
Accept: */*.
User-Agent: HTTPie/0.9.2.
.
#
T 127.0.0.1:8082 -> 127.0.0.1:51706 [AP]
HTTP/1.1 200 OK.
Date: Wed, 25 Nov 2015 13:40:49 GMT.
Content-Length: 7.
Content-Type: text/plain; charset=utf-8.
.
server2
#
!
- macは対応していない
- gom使って落としてこようとしたら、あとソースからダウンロードしようとしたらこれにはまった
- urlの指定に注意
- server1-bad.goみたいに
localhost
を省略するとreplayができない
- server1-bad.goみたいに