• 23-05-2023, 01:45:03
    #1
    instagram api/v1/web/accounts/login/ajax/ girişi yapabilen varmı? Coikes dışarı aktaracağım statüs ok oluyor ama sessionid felan çıkmıyor userid felan
  • 23-05-2023, 01:52:51
    #2
    Çerez bilgilerini (sessionid,csrftoken,mid,rur,ig_did vs. ) response olan header dan alabilirsin.
  • 23-05-2023, 01:57:01
    #3
    ByHazerfen adlı üyeden alıntı: mesajı görüntüle
    Çerez bilgilerini (sessionid,csrftoken,mid,rur,ig_did vs. ) response olan header dan alabilirsin.
    Hocam kullanıcı adı şifre ile instagrama login yapıp onun sessionid ve bilgilerni almak istiyorum da eğer http headers eklersem eklediğim kişinin bilgileri cıkıyor kullanıcı adı ve şifre yazdığım kişinin değil
  • 23-05-2023, 02:03:30
    #4
    yunusaksoy adlı üyeden alıntı: mesajı görüntüle
    Hocam kullanıcı adı şifre ile instagrama login yapıp onun sessionid ve bilgilerni almak istiyorum da eğer http headers eklersem eklediğim kişinin bilgileri cıkıyor kullanıcı adı ve şifre yazdığım kişinin değil
    $response = curl_exec($ch);
    preg_match_all('/^Set-Cookie:\s*([^;]*)/mi', $response, $matches); $cookies = array(); foreach($matches[1] as $item) { parse_str($item, $cookie); $cookies = array_merge($cookies, $cookie); }
    Hangi dil üzerinden istek gönderdiğinizi bilmediğim için php ile bu şekilde çerezleri diziye aktarıp istediğiniz çerezi kullanabilirsiniz.

    Yani giriş yaptığınız hesabın çerezlerine ulaşıyorsunuz istediğiniz gibi
  • 23-05-2023, 02:08:27
    #5
    yunusaksoy adlı üyeden alıntı: mesajı görüntüle
    instagram api/v1/web/accounts/login/ajax/ girişi yapabilen varmı? Coikes dışarı aktaracağım statüs ok oluyor ama sessionid felan çıkmıyor userid felan
    bu şekilde deneyin
    <?php
    $ch = curl_init();
    curl_setopt($ch, CURLOPT_URL, 'https://www.instagram.com/api/v1/web/accounts/login/ajax/');
    curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
    curl_setopt($ch, CURLOPT_CUSTOMREQUEST, 'POST');
    curl_setopt($ch, CURLOPT_HTTPHEADER, [
        'authority: www.instagram.com',
        'accept: */*',
        'accept-language: tr-TR,tr;q=0.9,en-US;q=0.8,en;q=0.7',
        'content-type: application/x-www-form-urlencoded',
        'origin: https://www.instagram.com',
        'referer: https://www.instagram.com/',
        'sec-ch-prefers-color-scheme: light',
        'sec-ch-ua: "Google Chrome";v="113", "Chromium";v="113", "Not-A.Brand";v="24"',
        'sec-ch-ua-full-version-list: "Google Chrome";v="113.0.5672.127", "Chromium";v="113.0.5672.127", "Not-A.Brand";v="24.0.0.0"',
        'sec-ch-ua-mobile: ?0',
        'sec-ch-ua-platform: "Windows"',
        'sec-ch-ua-platform-version: "10.0.0"',
        'sec-fetch-dest: empty',
        'sec-fetch-mode: cors',
        'sec-fetch-site: same-origin',
        'user-agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/113.0.0.0 Safari/537.36',
        'viewport-width: 1366',
        'x-asbd-id: 198387',
        'x-csrftoken: hqJ3wjPDXa1bzvJomMyVKj3T65BIxYFU',
        'x-ig-app-id: 936619743392459',
        'x-ig-www-claim: 0',
        'x-instagram-ajax: 1007538381',
        'x-requested-with: XMLHttpRequest',
        'accept-encoding: gzip',
    ]);
    curl_setopt($ch, CURLOPT_COOKIE, 'csrftoken=hqJ3wjPDXa1bzvJomMyVKj3T65BIxYFU; mid=ZDc9tAALAAEDNdNk_V8q0gJwQjyf; ig_did=95041F4B-C047-49ED-9277-34586883B48E; ig_nrcb=1; datr=sj03ZE3wrERybv0zaewrp-2g');
    curl_setopt($ch, CURLOPT_POSTFIELDS, 'enc_password=%23PWD_INSTAGRAM_BROWSER%3A10%3A1684796826%3AAcxQAH4wGBr7E0HI3pKEROb7oi9SA4vESnZNDjFLWJ8OQf1qtj%2FpbmJo5jn9h4vK5epgYKLUw8pZiQyfbzGeDphiH0dPZgbPxnd9RCpgt4WyFZugiISXUhCioOvq2x%2FDwnqBDvygIqd9cYK3fRUDXw%3D%3D&username=bhguyuggu&queryParams=%7B%7D&optIntoOneTap=false&trustedDeviceRecords=%7B%7D');
    $response = curl_exec($ch);
    curl_close($ch);
    print_r($response);
  • 23-05-2023, 02:28:09
    #6
    ByHazerfen adlı üyeden alıntı: mesajı görüntüle
    $response = curl_exec($ch);
    preg_match_all('/^Set-Cookie:\s*([^;]*)/mi', $response, $matches); $cookies = array(); foreach($matches[1] as $item) { parse_str($item, $cookie); $cookies = array_merge($cookies, $cookie); }
    Hangi dil üzerinden istek gönderdiğinizi bilmediğim için php ile bu şekilde çerezleri diziye aktarıp istediğiniz çerezi kullanabilirsiniz.

    Yani giriş yaptığınız hesabın çerezlerine ulaşıyorsunuz istediğiniz gibi
    sabah deneyeceğim hocam sağolun

    aslansoft adlı üyeden alıntı: mesajı görüntüle
    bu şekilde deneyin
    <?php
    $ch = curl_init();
    curl_setopt($ch, CURLOPT_URL, 'https://www.instagram.com/api/v1/web/accounts/login/ajax/');
    curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
    curl_setopt($ch, CURLOPT_CUSTOMREQUEST, 'POST');
    curl_setopt($ch, CURLOPT_HTTPHEADER, [
        'authority: www.instagram.com',
        'accept: */*',
        'accept-language: tr-TR,tr;q=0.9,en-US;q=0.8,en;q=0.7',
        'content-type: application/x-www-form-urlencoded',
        'origin: https://www.instagram.com',
        'referer: https://www.instagram.com/',
        'sec-ch-prefers-color-scheme: light',
        'sec-ch-ua: "Google Chrome";v="113", "Chromium";v="113", "Not-A.Brand";v="24"',
        'sec-ch-ua-full-version-list: "Google Chrome";v="113.0.5672.127", "Chromium";v="113.0.5672.127", "Not-A.Brand";v="24.0.0.0"',
        'sec-ch-ua-mobile: ?0',
        'sec-ch-ua-platform: "Windows"',
        'sec-ch-ua-platform-version: "10.0.0"',
        'sec-fetch-dest: empty',
        'sec-fetch-mode: cors',
        'sec-fetch-site: same-origin',
        'user-agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/113.0.0.0 Safari/537.36',
        'viewport-width: 1366',
        'x-asbd-id: 198387',
        'x-csrftoken: hqJ3wjPDXa1bzvJomMyVKj3T65BIxYFU',
        'x-ig-app-id: 936619743392459',
        'x-ig-www-claim: 0',
        'x-instagram-ajax: 1007538381',
        'x-requested-with: XMLHttpRequest',
        'accept-encoding: gzip',
    ]);
    curl_setopt($ch, CURLOPT_COOKIE, 'csrftoken=hqJ3wjPDXa1bzvJomMyVKj3T65BIxYFU; mid=ZDc9tAALAAEDNdNk_V8q0gJwQjyf; ig_did=95041F4B-C047-49ED-9277-34586883B48E; ig_nrcb=1; datr=sj03ZE3wrERybv0zaewrp-2g');
    curl_setopt($ch, CURLOPT_POSTFIELDS, 'enc_password=%23PWD_INSTAGRAM_BROWSER%3A10%3A1684796826%3AAcxQAH4wGBr7E0HI3pKEROb7oi9SA4vESnZNDjFLWJ8OQf1qtj%2FpbmJo5jn9h4vK5epgYKLUw8pZiQyfbzGeDphiH0dPZgbPxnd9RCpgt4WyFZugiISXUhCioOvq2x%2FDwnqBDvygIqd9cYK3fRUDXw%3D%3D&username=bhguyuggu&queryParams=%7B%7D&optIntoOneTap=false&trustedDeviceRecords=%7B%7D');
    $response = curl_exec($ch);
    curl_close($ch);
    print_r($response);
    Sabah deneyeceğim hocam çok sağolun