Upgrade to Pro
— share decks privately, control downloads, hide ads and more …
Speaker Deck
Features
Speaker Deck
PRO
Sign in
Sign up for free
Search
Search
[EN] ChromeDriver Jailbreak (short)
Search
Alexander Bayandin
November 16, 2016
Programming
0
210
[EN] ChromeDriver Jailbreak (short)
SeleniumConf UK 2016 Lightning Talk
Video:
https://youtu.be/FoTCmWvaQME?t=24m51s
Alexander Bayandin
November 16, 2016
Tweet
Share
More Decks by Alexander Bayandin
See All by Alexander Bayandin
Нетрадиционное использование автотестов
bayandin
0
32
Chrome DevTools в Selenium тестах
bayandin
0
250
[RU] ChromeDriver Jailbreak
bayandin
0
120
Mobile Web: to the Desktop!
bayandin
1
29
JavaScript + Webdriver = ♥ (v1.1)
bayandin
1
240
JavaScript + Webdriver = ♥
bayandin
1
860
Other Decks in Programming
See All in Programming
KMP와 kotlinx.rpc로 서버와 클라이언트 동기화
kwakeuijin
0
280
Kaigi on Railsに初参加したら、その日にLT登壇が決定した件について
tama50505
0
140
ゆるやかにgolangci-lintのルールを強くする / Kyoto.go #56
utgwkk
2
880
Go の GC の不得意な部分を克服したい
taiyow
3
1k
shadcn/uiを使ってReactでの開発を加速させよう!
lef237
0
270
선언형 UI에서의 상태관리
l2hyunwoo
0
260
テストコード書いてみませんか?
onopon
2
310
月刊 競技プログラミングをお仕事に役立てるには
terryu16
1
1.2k
毎日13時間もかかるバッチ処理をたった3日で60%短縮するためにやったこと
sho_ssk_
1
510
為你自己學 Python
eddie
0
510
オニオンアーキテクチャを使って、 Unityと.NETでコードを共有する
soi013
0
360
PSR-15 はあなたのための ものではない? - phpcon2024
myamagishi
0
380
Featured
See All Featured
Bash Introduction
62gerente
610
210k
Easily Structure & Communicate Ideas using Wireframe
afnizarnur
191
16k
Principles of Awesome APIs and How to Build Them.
keavy
126
17k
The Power of CSS Pseudo Elements
geoffreycrofte
74
5.4k
Side Projects
sachag
452
42k
What’s in a name? Adding method to the madness
productmarketing
PRO
22
3.2k
How STYLIGHT went responsive
nonsquared
96
5.3k
Why You Should Never Use an ORM
jnunemaker
PRO
54
9.1k
The Language of Interfaces
destraynor
155
24k
Docker and Python
trallard
43
3.2k
Building a Modern Day E-commerce SEO Strategy
aleyda
38
7k
Design and Strategy: How to Deal with People Who Don’t "Get" Design
morganepeng
127
18k
Transcript
ChromeDriver Jailbreak Alexander Bayandin
Jailbreak?
Jailbreak? It allows us to use Chrome features which are
not available through ChromeDriver. 3
Driver architecture
+------+ +------------+ +------+ |Client|<------>|ChromeDriver|<------>|Chrome| +------+ +------------+ +------+
+------+ +------------+ +------+ |Client|<------>|ChromeDriver|<------>|Chrome| +------+ +------------+ +------+ WebDriver Protocol Chrome
Debugging Protocol (over WebSockets) Selenium or test
Chrome Debugging Protocol 7 Chrome DevTools uses it.
What if… 8 Send a custom request?
+-+ +-+ +--------+ +------------+ |C| |T|<---->|Selenium|<---->|ChromeDriver|<------->|h| |e| +--------+ +------------+ |r|
|s| |o| |t|<------------------------------------------->|m| +-+ |e| +-+ WebSocket Connection
+-+ +-+ +--------+ +------------+ |C| |T|<---->|Selenium|<---->|ChromeDriver|<------->|h| |e| +--------+ +------------+ |r|
|s| |o| |t|<------------------------------------------->|m| +-+ |e| +-+ WebSocket Connection
+-+ +-+ +-+ +--------+ +------------+ |P| |C| |T|<---->|Selenium|<---->|ChromeDriver|<->|r| |h| |e|
+--------+ +------------+ |o|<->|r| |s| |x| |o| |t|<------------------------------------->|y| |m| +-+ +-+ |e| +-+ WebSocket Connection
devtools-proxy ✦ devtools-proxy ✦ chrome-wrapper.sh 12
Examples
devtools-proxy examples 14 ✦ Chrome Debugging protocol methods, for example
CPU Throttling
# https://chromedevtools.github.io/debugger-protocol-viewer/ > { "id":0, "method":"Emulation.setCPUThrottlingRate", "params":{ "rate": 10 }
}
None
devtools-proxy examples 17 ✦ Chrome Debugging protocol methods, for example
CPU Throttling ✦ See HTTP requests during test run
None
devtools-proxy examples 19 ✦ Chrome Debugging protocol methods, for example
CPU Throttling ✦ See HTTP requests during test run ✦ See what’s going on (like Remote Debugging Android Devices)
None
Interested?
Good to know before ✦ Almost no docs ✦ Doesn’t
support Windows yet ✦ Chromium / Google Chrome only 22
Good to know before ✦ Almost no docs ✦ Doesn’t
support Windows yet ✦ Chromium / Google Chrome only ✦ Has some bugs, probably 23
Good to know before ✦ Almost no docs ✦ Doesn’t
support Windows yet ✦ Chromium / Google Chrome only ✦ Has some bugs, probably ✦ Selenium Python test suite passes 24
Good to know before ✦ Almost no docs ✦ Doesn’t
support Windows yet ✦ Chromium / Google Chrome only ✦ Has some bugs, probably ✦ Selenium Python test suite passes ✦ Python 25
Download bayandin/devtools-proxy 26
Thank you! abayandin bayandin alexander.bayand.in
Thank you! BadooTech Badoo techblog.badoo.com