Projects STRLCPY maigret Commits 1a77bc74
🤬
  • Spotify added, Steam ID processing updated

  • Loading...
  • Soxoj committed 4 years ago
    1a77bc74
    1 parent 8391d731
Revision indexing in progress... (symbol navigation in revisions will be accurate after indexed)
  • ■ ■ ■ ■ ■ ■
    maigret/activation.py
    skipped 27 lines
    28 28   site.headers['Authorization'] = 'jwt ' + jwt_token
    29 29   
    30 30   @staticmethod
     31 + def spotify(site, logger, cookies={}):
     32 + headers = dict(site.headers)
     33 + if 'Authorization' in headers:
     34 + del headers['Authorization']
     35 + r = requests.get(site.activation['url'])
     36 + bearer_token = r.json()['accessToken']
     37 + site.headers['authorization'] = f'Bearer {bearer_token}'
     38 + 
     39 + @staticmethod
    31 40   def xssis(site, logger, cookies={}):
    32 41   if not cookies:
    33 42   logger.debug('You must have cookies to activate xss.is parsing!')
    skipped 32 lines
  • ■ ■ ■ ■ ■ ■
    maigret/checking.py
    skipped 19 lines
    20 20   'vk_id',
    21 21   'ok_id',
    22 22   'wikimapia_uid',
     23 + 'steam_id',
    23 24  )
    24 25   
    25 26  common_errors = {
    skipped 306 lines
    332 333   
    333 334   cookie_jar = None
    334 335   if cookies:
     336 + logger.debug(f'Using cookies jar file {cookies}')
    335 337   cookie_jar = await import_aiohttp_cookies(cookies)
    336 338   
    337 339   session = aiohttp.ClientSession(connector=connector, trust_env=True, cookie_jar=cookie_jar)
    skipped 266 lines
  • ■ ■ ■ ■
    maigret/maigret.py
    skipped 66 lines
    67 67   action="store", metavar='TIMEOUT',
    68 68   dest="timeout", type=timeout_check, default=10,
    69 69   help="Time (in seconds) to wait for response to requests."
    70  - "Default timeout of 10.0s."
     70 + "Default timeout of 10.0s. "
    71 71   "A longer timeout will be more likely to get results from slow sites."
    72 72   "On the other hand, this may cause a long delay to gather all results."
    73 73   )
    skipped 338 lines
  • ■ ■ ■ ■ ■
    maigret/resources/data.json
    skipped 12227 lines
    12228 12228   "tags": [
    12229 12229   "music"
    12230 12230   ],
     12231 + "headers": {
     12232 + "authorization": "Bearer BQAlrJSKV_X_SgmGTiRWa2Q7FDLUFK6PiNNMhrdbhl0OccgNhCajMTaSPJuw18sckyjbw4j1nCYN-GmFBBs"
     12233 + },
    12231 12234   "errors": {
    12232 12235   "Spotify is currently not available in your country.": "Access denied in your country, use proxy/vpn"
    12233 12236   },
     12237 + "activation": {
     12238 + "method": "spotify",
     12239 + "marks": [
     12240 + "No token provided",
     12241 + "The access token expired"
     12242 + ],
     12243 + "url": "https://open.spotify.com/get_access_token?reason=transport&productType=web_player",
     12244 + "src": "accessToken",
     12245 + "dst": "authorization"
     12246 + },
     12247 + "urlProbe": "https://spclient.wg.spotify.com/user-profile-view/v3/profile/{username}?playlist_limit=10&artist_limit=10&market=EN",
    12234 12248   "checkType": "status_code",
    12235 12249   "alexaRank": 81,
    12236 12250   "url": "https://open.spotify.com/user/{username}",
    skipped 74 lines
    12311 12325   },
    12312 12326   "Steam": {
    12313 12327   "tags": [
    12314  - "gaming"
     12328 + "gaming",
     12329 + "steam"
    12315 12330   ],
    12316 12331   "checkType": "message",
    12317 12332   "absenceStrs": "The specified profile could not be found",
    skipped 5 lines
    12323 12338   },
    12324 12339   "SteamGroup": {
    12325 12340   "tags": [
    12326  - "us"
     12341 + "us",
     12342 + "steam"
    12327 12343   ],
    12328 12344   "checkType": "message",
    12329 12345   "absenceStrs": "No group could be retrieved for the given URL",
    skipped 4 lines
    12334 12350   "usernameUnclaimed": "noonewouldeverusethis7"
    12335 12351   },
    12336 12352   "Steamid": {
    12337  - "disabled": true,
    12338 12353   "tags": [
    12339  - "ru",
    12340  - "tr",
    12341  - "us"
     12354 + "gaming",
     12355 + "steam"
    12342 12356   ],
    12343 12357   "checkType": "message",
    12344 12358   "absenceStrs": "<div class=\"alert alert-warning\">Profile not found</div>",
    skipped 3 lines
    12348 12362   "usernameClaimed": "blue",
    12349 12363   "usernameUnclaimed": "noonewouldeverusethis7"
    12350 12364   },
     12365 + "Steamid (by id)": {
     12366 + "tags": [
     12367 + "gaming",
     12368 + "steam"
     12369 + ],
     12370 + "type": "steam_id",
     12371 + "checkType": "message",
     12372 + "absenceStrs": "<div class=\"alert alert-warning\">Profile not found</div>",
     12373 + "alexaRank": 265679,
     12374 + "url": "https://steamid.uk/profile/{username}",
     12375 + "urlMain": "https://steamid.uk/",
     12376 + "usernameClaimed": "76561197982198022",
     12377 + "usernameUnclaimed": "noonewouldeverusethis7"
     12378 + },
     12379 + "Steamidfinder": {
     12380 + "tags": [
     12381 + "gaming",
     12382 + "steam"
     12383 + ],
     12384 + "checkType": "message",
     12385 + "presenseStrs": [
     12386 + "se our custom tools to build a Steam profile badge"
     12387 + ],
     12388 + "absenceStrs": [
     12389 + "could not be found."
     12390 + ],
     12391 + "url": "https://steamidfinder.com/lookup/{username}",
     12392 + "urlMain": "https://steamidfinder.com",
     12393 + "usernameClaimed": "channel",
     12394 + "usernameUnclaimed": "noonewouldeverusethis7"
     12395 + },
     12396 + "Steamidfinder (by id)": {
     12397 + "tags": [
     12398 + "gaming",
     12399 + "steam"
     12400 + ],
     12401 + "type": "steam_id",
     12402 + "checkType": "message",
     12403 + "presenseStrs": [
     12404 + "se our custom tools to build a Steam profile badge"
     12405 + ],
     12406 + "absenceStrs": [
     12407 + "could not be found."
     12408 + ],
     12409 + "url": "https://steamidfinder.com/lookup/{username}",
     12410 + "urlMain": "https://steamidfinder.com",
     12411 + "usernameClaimed": "76561197982198022",
     12412 + "usernameUnclaimed": "noonewouldeverusethis7"
     12413 + },
    12351 12414   "Stereo": {
    12352 12415   "tags": [
    12353 12416   "nl",
    skipped 1117 lines
    13471 13534   "sec-ch-ua": "Google Chrome\";v=\"87\", \" Not;A Brand\";v=\"99\", \"Chromium\";v=\"87\"",
    13472 13535   "authorization": "Bearer AAAAAAAAAAAAAAAAAAAAANRILgAAAAAAnNwIzUejRCOuH5E6I8xnZz4puTs%3D1Zv7ttfk8LF81IUq16cHjhLTvJu4FA33AGWWjCpTnA",
    13473 13536   "user-agent": "Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_6) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/87.0.4280.88 Safari/537.36",
    13474  - "x-guest-token": "1362149064209559554"
     13537 + "x-guest-token": "1362450609757171713"
    13475 13538   },
    13476 13539   "errors": {
    13477 13540   "Bad guest token": "x-guest-token update required"
    skipped 359 lines
    13837 13900   "video"
    13838 13901   ],
    13839 13902   "headers": {
    13840  - "Authorization": "jwt eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJleHAiOjE2MTM1OTc1MjAsInVzZXJfaWQiOm51bGwsImFwcF9pZCI6NTg0NzksInNjb3BlcyI6InB1YmxpYyIsInRlYW1fdXNlcl9pZCI6bnVsbH0.dBxgHYOlLckB2zBh3mgINMKRXCIkWnAUQKUhn27_Zj0"
     13903 + "Authorization": "jwt eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJleHAiOjE2MTM2Njk0NjAsInVzZXJfaWQiOm51bGwsImFwcF9pZCI6NTg0NzksInNjb3BlcyI6InB1YmxpYyIsInRlYW1fdXNlcl9pZCI6bnVsbH0.EM5FY86CJ5Nel3U0l8GipXRSYYJoeDpS9QURBp5B-UM"
    13841 13904   },
    13842 13905   "activation": {
    13843 13906   "url": "https://vimeo.com/_rv/viewer",
    skipped 890 lines
    14734 14797   "usernameUnclaimed": "noonewouldeverusethis7"
    14735 14798   },
    14736 14799   "YandexLocal": {
     14800 + "disabled": true,
    14737 14801   "tags": [
    14738 14802   "ru"
    14739 14803   ],
    skipped 8577 lines
Please wait...
Page is in error, reload to recover