Giter Site home page Giter Site logo

chatgpt-webapi's Issues

Access denied to ChatGPT

Is there anything I can do about it? I configured all cookies as described in the README. Looks like Cloudflare is blocking me.

2023/04/23 11:48:11 http response info: 
HTTP/2.0 403 Forbidden
Alt-Svc: h3=":443"; ma=86400, h3-29=":443"; ma=86400
Cache-Control: private, max-age=0, no-store, no-cache, must-revalidate, post-check=0, pre-check=0
Cf-Mitigated: challenge
Cf-Ray: 7bc5307aed96cb11-DUS
Content-Type: text/html; charset=UTF-8
Cross-Origin-Embedder-Policy: require-corp
Cross-Origin-Opener-Policy: same-origin
Cross-Origin-Resource-Policy: same-origin
Date: Sun, 23 Apr 2023 09:48:11 GMT
Expires: Thu, 01 Jan 1970 00:00:01 GMT
Permissions-Policy: accelerometer=(),autoplay=(),camera=(),clipboard-read=(),clipboard-write=(),fullscreen=(),geolocation=(),gyroscope=(),hid=(),interest-cohort=(),magnetometer=(),microphone=(),payment=(),publickey-credentials-get=(),screen-wake-lock=(),serial=(),sync-xhr=(),usb=()
Referrer-Policy: same-origin
Server: cloudflare
Set-Cookie: __cf_bm=XXXXXXX; path=/; expires=Sun, 23-Apr-23 10:18:11 GMT; domain=.chat.openai.com; HttpOnly; Secure; SameSite=None
Vary: Accept-Encoding
X-Frame-Options: SAMEORIGIN
X-Robots-Tag: nofollow


2023/04/23 11:48:11 http response info: <html>
  <head>
    <style global>body{font-family:Arial,Helvetica,sans-serif}.container{align-items:center;display:flex;flex-direction:column;gap:2rem;height:100%;justify-content:center;width:100%}@keyframes enlarge-appear{0%{opacity:0;transform:scale(75%) rotate(-90deg)}to{opacity:1;transform:scale(100%) rotate(0deg)}}.logo{color:#8e8ea0}.scale-appear{animation:enlarge-appear .4s ease-out}@media (min-width:768px){.scale-appear{height:48px;width:48px}}.data:empty{display:none}.data{border-radius:5px;color:#8e8ea0;text-align:center}@media (prefers-color-scheme:dark){body{background-color:#343541}.logo{color:#acacbe}}</style>
  
</head>
....
      <div class="data"><form id="challenge-form" class="challenge-form" action="/api/auth/session?__cf_chl_f_tk=2qQUwEBfpgXHMEERbqIHxaQ45cLMnMjZX9tpDHYDf.M-1682243291-0-gaNycGzNFuU" method="POST" enctype="application/x-www-form-urlencoded">
    <div id="cf-please-wait">
        <div id="spinner">
            <div id="cf-bubbles">
                <div class="bubbles"></div>
                <div class="bubbles"></div>
                <div class="bubbles"></div>
            </div>
        </div>
        <p id="cf-spinner-please-wait">Please stand by, while we are checking your browser...</p>
        <p id="cf-spinner-redirecting" style="display:none">Redirecting...</p>
    </div>
....
2023/04/23 11:48:11 get chat text failed: send message failed: get accessToken failed: invalid session data: 

HTTP/2.0 403 Forbidden

按照demo的代码填写了自己的cookie,依然被CF拦截了。

返回了一段403的HTML代码,其中内容有:Checking if the site connection is secure

感觉还是没能绕过CF,或许需要添加更多的头部?

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.