Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Sign in
Toggle navigation
L
lcc-reese84
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
wangmingming
lcc-reese84
Commits
30f54cbf
Commit
30f54cbf
authored
Sep 20, 2024
by
wang
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
test
parent
6e4b96ff
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
53 additions
and
60 deletions
+53
-60
reese84_bypass.py
src/reese84_bypass.py
+52
-59
run.js
src/run.js
+1
-1
No files found.
src/reese84_bypass.py
View file @
30f54cbf
...
@@ -7,7 +7,6 @@ import tempfile
...
@@ -7,7 +7,6 @@ import tempfile
import
time
import
time
from
pathlib
import
Path
from
pathlib
import
Path
import
requests
import
tls_client
import
tls_client
# import tls_client
# import tls_client
# from curl_cffi import requests
# from curl_cffi import requests
...
@@ -53,26 +52,28 @@ class Reese84ByPass(object):
...
@@ -53,26 +52,28 @@ class Reese84ByPass(object):
self
.
log
.
info
(
f
'proxy:{proxy} target:{target}'
)
self
.
log
.
info
(
f
'proxy:{proxy} target:{target}'
)
self
.
_cache_md5
=
''
self
.
_cache_md5
=
''
self
.
add_header
=
{
self
.
add_header
=
headers
=
{
"authority"
:
"
www.transav
ia.com"
,
"authority"
:
"
book.virginaustral
ia.com"
,
"accept"
:
"*/*"
,
"accept"
:
"*/*"
,
"accept-language"
:
"en,en-US;q=0.9,zh-CN;q=0.8,zh;q=0.7,ru;q=0.6"
,
"accept-language"
:
"en,en-US;q=0.9,zh-CN;q=0.8,zh;q=0.7,ru;q=0.6"
,
"application-id"
:
"SWS1:SBR-DigConShpBk:fd34efe9a9"
,
"authorization"
:
"Bearer Basic anNvbl91c2VyOmpzb25fcGFzc3dvcmQ="
,
"cache-control"
:
"no-cache"
,
"cache-control"
:
"no-cache"
,
"content-type"
:
"application/x-www-form-urlencoded; charset=UTF-8"
,
"content-type"
:
"application/json"
,
"origin"
:
"https://www.transavia.com"
,
"execution"
:
"7635bd62-c905-467d-aac8-55e8d4094f73"
,
"origin"
:
"https://book.virginaustralia.com"
,
"pragma"
:
"no-cache"
,
"pragma"
:
"no-cache"
,
"referer"
:
"https://www.transavia.com/en-UK/book-a-flight/flights/search/"
,
"referer"
:
"https://book.virginaustralia.com/dx/VADX/"
,
"request-context"
:
"appId=cid-v1:942f733a-0e08-45b5-a6e2-53089f65a4b2"
,
"request-id"
:
"|3651048e1bbe4dc38890f5cba115b92f.11b030bc635d49f3"
,
"sec-ch-ua"
:
"
\"
Not_A Brand
\"
;v=
\"
8
\"
,
\"
Chromium
\"
;v=
\"
120
\"
,
\"
Google Chrome
\"
;v=
\"
120
\"
"
,
"sec-ch-ua"
:
"
\"
Not_A Brand
\"
;v=
\"
8
\"
,
\"
Chromium
\"
;v=
\"
120
\"
,
\"
Google Chrome
\"
;v=
\"
120
\"
"
,
"sec-ch-ua-mobile"
:
"?0"
,
"sec-ch-ua-mobile"
:
"?0"
,
"sec-ch-ua-platform"
:
"
\"
macOS
\"
"
,
"sec-ch-ua-platform"
:
"
\"
macOS
\"
"
,
"sec-fetch-dest"
:
"empty"
,
"sec-fetch-dest"
:
"empty"
,
"sec-fetch-mode"
:
"cors"
,
"sec-fetch-mode"
:
"cors"
,
"sec-fetch-site"
:
"same-origin"
,
"sec-fetch-site"
:
"same-origin"
,
"traceparent"
:
"00-3651048e1bbe4dc38890f5cba115b92f-11b030bc635d49f3-01"
,
"ssgtoken"
:
"undefined"
,
"ssotoken"
:
"undefined"
,
"user-agent"
:
"Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_7) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/120.0.0.0 Safari/537.36"
,
"user-agent"
:
"Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_7) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/120.0.0.0 Safari/537.36"
,
"x-
requested-with"
:
"XMLHttpRequest
"
"x-
sabre-storefront"
:
"VADX
"
}
}
def
start
(
self
):
def
start
(
self
):
...
@@ -110,13 +111,13 @@ class Reese84ByPass(object):
...
@@ -110,13 +111,13 @@ class Reese84ByPass(object):
self
.
_session
.
cookies
.
clear
()
self
.
_session
.
cookies
.
clear
()
t1
=
time
.
time
()
t1
=
time
.
time
()
r1
=
self
.
_session
.
get
(
r1
=
self
.
_session
.
get
(
'https://
www.transavia.com/rgeonseart-Cawdor-mine-no-our-selfe-Wife-comfort
'
,
headers
=
{
'https://
book.virginaustralia.com/side-you-ares-may-Exit-sition-Alaruern-Naugmen-G
'
,
headers
=
{
"authority"
:
"
www.transav
ia.com"
,
"authority"
:
"
book.virginaustral
ia.com"
,
"accept"
:
"*/*"
,
"accept"
:
"*/*"
,
"accept-language"
:
"en,en-US;q=0.9,zh-CN;q=0.8,zh;q=0.7,ru;q=0.6"
,
"accept-language"
:
"en,en-US;q=0.9,zh-CN;q=0.8,zh;q=0.7,ru;q=0.6"
,
"cache-control"
:
"no-cache"
,
"cache-control"
:
"no-cache"
,
"pragma"
:
"no-cache"
,
"pragma"
:
"no-cache"
,
"referer"
:
"https://
www.transavia.com
/"
,
"referer"
:
"https://
book.virginaustralia.com/dx/VADX
/"
,
"sec-ch-ua"
:
"
\"
Not_A Brand
\"
;v=
\"
8
\"
,
\"
Chromium
\"
;v=
\"
120
\"
,
\"
Google Chrome
\"
;v=
\"
120
\"
"
,
"sec-ch-ua"
:
"
\"
Not_A Brand
\"
;v=
\"
8
\"
,
\"
Chromium
\"
;v=
\"
120
\"
,
\"
Google Chrome
\"
;v=
\"
120
\"
"
,
"sec-ch-ua-mobile"
:
"?0"
,
"sec-ch-ua-mobile"
:
"?0"
,
"sec-ch-ua-platform"
:
"
\"
macOS
\"
"
,
"sec-ch-ua-platform"
:
"
\"
macOS
\"
"
,
...
@@ -150,16 +151,16 @@ class Reese84ByPass(object):
...
@@ -150,16 +151,16 @@ class Reese84ByPass(object):
# print(len(data['solution']['interrogation']['p']))
# print(len(data['solution']['interrogation']['p']))
t3
=
time
.
time
()
t3
=
time
.
time
()
url
=
"https://
www.transavia.com/rgeonseart-Cawdor-mine-no-our-selfe-Wife-comfort?d=www.transav
ia.com"
url
=
"https://
book.virginaustralia.com/side-you-ares-may-Exit-sition-Alaruern-Naugmen-G?d=book.virginaustral
ia.com"
response
=
self
.
_session
.
post
(
url
,
headers
=
{
response
=
self
.
_session
.
post
(
url
,
headers
=
{
"authority"
:
"
www.transav
ia.com"
,
"authority"
:
"
book.virginaustral
ia.com"
,
"accept"
:
"application/json; charset=utf-8"
,
"accept"
:
"application/json; charset=utf-8"
,
"accept-language"
:
"en,en-US;q=0.9,zh-CN;q=0.8,zh;q=0.7,ru;q=0.6"
,
"accept-language"
:
"en,en-US;q=0.9,zh-CN;q=0.8,zh;q=0.7,ru;q=0.6"
,
"cache-control"
:
"no-cache"
,
"cache-control"
:
"no-cache"
,
"content-type"
:
"text/plain; charset=utf-8"
,
"content-type"
:
"text/plain; charset=utf-8"
,
"origin"
:
"https://
www.transav
ia.com"
,
"origin"
:
"https://
book.virginaustral
ia.com"
,
"pragma"
:
"no-cache"
,
"pragma"
:
"no-cache"
,
"referer"
:
"https://
www.transavia.com
/"
,
"referer"
:
"https://
book.virginaustralia.com/dx/VADX
/"
,
"sec-ch-ua"
:
"
\"
Not_A Brand
\"
;v=
\"
8
\"
,
\"
Chromium
\"
;v=
\"
120
\"
,
\"
Google Chrome
\"
;v=
\"
120
\"
"
,
"sec-ch-ua"
:
"
\"
Not_A Brand
\"
;v=
\"
8
\"
,
\"
Chromium
\"
;v=
\"
120
\"
,
\"
Google Chrome
\"
;v=
\"
120
\"
"
,
"sec-ch-ua-mobile"
:
"?0"
,
"sec-ch-ua-mobile"
:
"?0"
,
"sec-ch-ua-platform"
:
"
\"
macOS
\"
"
,
"sec-ch-ua-platform"
:
"
\"
macOS
\"
"
,
...
@@ -241,50 +242,42 @@ class Reese84ByPass(object):
...
@@ -241,50 +242,42 @@ class Reese84ByPass(object):
# t = i.index('=')
# t = i.index('=')
# cks[i[:t]] = i[t+1:]
# cks[i[:t]] = i[t+1:]
# self._session.cookies.update(cks)
# self._session.cookies.update(cks)
headers
=
{
url
=
"https://book.virginaustralia.com/api/graphql"
"authority"
:
"www.transavia.com"
,
"accept"
:
"text/html,application/xhtml+xml,application/xml;q=0.9,image/avif,image/webp,image/apng,*/*;q=0.8,application/signed-exchange;v=b3;q=0.7"
,
"accept-language"
:
"en,en-US;q=0.9,zh-CN;q=0.8,zh;q=0.7,ru;q=0.6"
,
"cache-control"
:
"no-cache"
,
"pragma"
:
"no-cache"
,
"referer"
:
"https://www.transavia.com/home/en-uk"
,
"sec-ch-ua"
:
"
\"
Not_A Brand
\"
;v=
\"
8
\"
,
\"
Chromium
\"
;v=
\"
120
\"
,
\"
Google Chrome
\"
;v=
\"
120
\"
"
,
"sec-ch-ua-mobile"
:
"?0"
,
"sec-ch-ua-platform"
:
"
\"
macOS
\"
"
,
"sec-fetch-dest"
:
"document"
,
"sec-fetch-mode"
:
"navigate"
,
"sec-fetch-site"
:
"same-origin"
,
"upgrade-insecure-requests"
:
"1"
,
"user-agent"
:
"Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_7) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/120.0.0.0 Safari/537.36"
}
url
=
"https://www.transavia.com/en-UK/book-a-flight/flights/search/"
params
=
{
"r"
:
"False"
,
"ap"
:
"1"
,
"cp"
:
"0"
,
"ip"
:
"0"
,
"ds"
:
"EDI"
,
"as"
:
"ORY"
,
"fb"
:
"false"
}
response
=
self
.
_session
.
get
(
url
,
headers
=
headers
,
params
=
params
)
_token
=
re
.
findall
(
'ionToken" type="hidden" value="(.+?)"'
,
response
.
text
)[
0
]
print
(
_token
)
# print(response)
url
=
"https://www.transavia.com/en-UK/book-a-flight/flights/SingleDayAvailability/"
data
=
{
data
=
{
"selectSingleDayAvailability.JourneyType"
:
"OutboundFlight"
,
"operationName"
:
"bookingAirSearch"
,
"selectSingleDayAvailability.Date.DateToParse"
:
"2024-09-15"
,
"variables"
:
{
"selectSingleDayAvailability.AutoSelect"
:
"true"
,
"airSearchInput"
:
{
"__RequestVerificationToken"
:
_token
"cabinClass"
:
"First"
,
"awardBooking"
:
False
,
"promoCodes"
:
[],
"searchType"
:
"BRANDED"
,
"itineraryParts"
:
[
{
"from"
:
{
"useNearbyLocations"
:
False
,
"code"
:
"ADL"
},
"to"
:
{
"useNearbyLocations"
:
False
,
"code"
:
"ASP"
},
"when"
:
{
"date"
:
"2024-10-24"
}
}
],
"passengers"
:
{
"ADT"
:
1
}
}
},
"extensions"
:
{},
"query"
:
"query bookingAirSearch($airSearchInput: CustomAirSearchInput) {
\n
bookingAirSearch(airSearchInput: $airSearchInput) {
\n
originalResponse
\n
__typename
\n
}
\n
}"
}
}
response
=
self
.
_session
.
post
(
url
,
headers
=
self
.
add_header
,
json
=
data
)
response
=
self
.
_session
.
post
(
url
,
headers
=
self
.
add_header
,
data
=
data
)
# _token = re.findall('ionToken" type="hidden" value="(.+?)"', response.text)[0]
print
(
response
.
text
)
print
(
response
.
text
)
self
.
log
.
debug
(
f
"resp {'Flight Search Results' in response.text}"
)
print
(
self
.
_get_cookie
())
if
__name__
==
'__main__'
:
if
__name__
==
'__main__'
:
...
@@ -298,6 +291,6 @@ if __name__ == '__main__':
...
@@ -298,6 +291,6 @@ if __name__ == '__main__':
r
=
Reese84ByPass
(
'https://www.transavia.com/'
,
'http://127.0.0.1:8890'
)
r
=
Reese84ByPass
(
'https://www.transavia.com/'
,
'http://127.0.0.1:8890'
)
# r = Reese84ByPass('https://www.transavia.com/', f'http://uni00001_custom_zone_US_sid_{random.randint(67336718, 67336728)}_time_5:q39CEBTs5A@us.foxyip.com:7778')
# r = Reese84ByPass('https://www.transavia.com/', f'http://uni00001_custom_zone_US_sid_{random.randint(67336718, 67336728)}_time_5:q39CEBTs5A@us.foxyip.com:7778')
# while True:
# while True:
#
r.start()
r
.
start
()
for
i
in
range
(
10
):
for
i
in
range
(
10
):
r
.
_test
()
r
.
_test
()
src/run.js
View file @
30f54cbf
...
@@ -1312,7 +1312,7 @@ const {
...
@@ -1312,7 +1312,7 @@ const {
const dom = new JSDOM(
const dom = new JSDOM(
'\n' +
'\n' +
' <!DOCTYPE html> <html lang="en" en-sg IR> <head><script src="/
xildrong-in-I-confusing-freene-of-Duncannothin-b
" async></script> <meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1" /> <meta charset="utf-8" /><script type="text/html" id="sf-tracking-consent-manager">\n' +
' <!DOCTYPE html> <html lang="en" en-sg IR> <head><script src="/
side-you-ares-may-Exit-sition-Alaruern-Naugmen-G
" async></script> <meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1" /> <meta charset="utf-8" /><script type="text/html" id="sf-tracking-consent-manager">\n' +
'\t<div id="tracking-consent-dialog" style="display:none;" class="hidden"> \n' +
'\t<div id="tracking-consent-dialog" style="display:none;" class="hidden"> \n' +
'</div>\n' +
'</div>\n' +
'</script><script type="text/javascript" src="/rgeonseart-Cawdor-mine-no-our-selfe-Wife-comfort">\n' +
'</script><script type="text/javascript" src="/rgeonseart-Cawdor-mine-no-our-selfe-Wife-comfort">\n' +
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment