diff --git a/.gitignore b/.gitignore index f242497..50114e4 100644 --- a/.gitignore +++ b/.gitignore @@ -1,5 +1,8 @@ .idea/ bin/ +releases/ +free-icon-robotic-leg-4829820.png + # Created by .ignore support plugin (hsz.mobi) __pycache__/ *.py[cod] diff --git a/Makefile b/Makefile index a737a24..8f52ea3 100644 --- a/Makefile +++ b/Makefile @@ -1,4 +1,4 @@ all: rm -f selenium_helper.xpi - zip -x "*.xpi" -x "Makefile" -r selenium_helper.zip . + zip -i "data/*" -i "_locales/*" -i "icon.png" -i "manifest.json" -i "README.md" -r selenium_helper.zip . mv selenium_helper.zip selenium_helper.xpi diff --git a/README.md b/README.md index 9612e75..64c2d53 100644 --- a/README.md +++ b/README.md @@ -1,3 +1,5 @@ +https://addons.mozilla.org/ru/firefox/addon/selenium-helper/ + Дополнение дает возможность установить в браузер прокси с авторизацией по логину и паролю, куки без предварительного открытия страницы для которой эти куки предназначены и заголовки браузера такие как User-Agent и/или Referer. Пример в директории example. diff --git a/_locales/en/messages.json b/_locales/en/messages.json index de5421b..30896e1 100644 --- a/_locales/en/messages.json +++ b/_locales/en/messages.json @@ -1,8 +1,8 @@ { "name": { - "message": "Selenium helper for setup proxy and cookies" + "message": "Selenium Helper" }, "description": { - "message": "Setup proxy with authentication and cookies" + "message": "Setup proxy with authentication, cookies and support bypass hСaptcha" } } diff --git a/_locales/ru/messages.json b/_locales/ru/messages.json index c5b85ef..e75e625 100644 --- a/_locales/ru/messages.json +++ b/_locales/ru/messages.json @@ -1,8 +1,8 @@ { "name": { - "message": "Selenium helper" + "message": "Selenium Helper" }, "description": { - "message": "Это расширение дает возможность установить в браузер прокси с авторизацией и куки без предварительного открытия страницы для которой эти куки предназначены." + "message": "Помогает установить прокси с авторизацией и куки. А теперь еще и помогает обойти hCaptcha." } } diff --git a/app128.png b/app128.png deleted file mode 100644 index cb199c3..0000000 Binary files a/app128.png and /dev/null differ diff --git a/app32.png b/app32.png deleted file mode 100644 index 509604f..0000000 Binary files a/app32.png and /dev/null differ diff --git a/app64.png b/app64.png deleted file mode 100644 index 66dad89..0000000 Binary files a/app64.png and /dev/null differ diff --git a/data/hcaptcha/background.js b/data/hcaptcha/background.js new file mode 100644 index 0000000..26e3d46 --- /dev/null +++ b/data/hcaptcha/background.js @@ -0,0 +1,20 @@ +function interceptor(details) { + let response = browser.webRequest.filterResponseData(details.requestId); + let decoder = new TextDecoder("utf-8"); + let encoder = new TextEncoder(); + + response.ondata = event => { + let str = decoder.decode(event.data, {stream: true}); + str = str.replace('