Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

how do I fix ngrok invalid HTTP response error

Tags:

ngrok

I am using zphisher. when i create a link to ngrok, the link is generated, but on opening it it says ngrok gateway error The server returned an invalid or incomplete HTTP response. I got to know from ngrok error documentation that it is error 3004. they tell the error code and message but no possible way to fix the error. can someone help me please. I think my brother watches YouTube during his online classes and I want to conform it. No phishing. Please. I got absolutely no help from anywhere. Just one of my friend told me that i need an ngrok account for that. tried it, doesn't work.

like image 262
Pranay Chopra Avatar asked Jul 20 '21 18:07

Pranay Chopra


People also ask

Why is Ngrok not working?

When an Ngrok connection reaches this length it stops working, and the only way to restore it is by stopping and restarting the ngrok command, which causes a new randomly generated URL to be used. You can always check the Ngrok output to see when a connection is due to expire.

How do I fix error Ngrok 6022?

This error in general happens even if you have your authtoken under ngrok. yml but are running your tunneling under your application(my case is simply a jsonserver) folder. Simply solution is to run your tunneling, under the same folder where indeed this ngrok.

Is it possible to use ngrok without authentication?

If you do not need to use Authentication you can add configs to ngrok commands But in this case Authentication will not work on your website because ngrok rewriting headers and session is not valid for your ngrok domain If you are using webpack you can add the following configuration

Why is my ngrok client session cookie not valid?

Your account account is limited to max simultaneous ngrok client session plural . msg The authentication payload you specified is not valid. This usually indiciates a bug in the client's protocol implementation. The parsing error encountered was: err The session cookie you specified is not valid.

How do I request access to my ngrok agent?

Email [email protected] to request access. Your account is not authorized to stop or restart the agent. Email [email protected] to request access. Your account is not authorized to update the agent. Email [email protected] to request access. You have reached the maximum of max IP Policies on a restriction.

Why is my ngrok account suspended?

This is usually the result of an unpaid bill or violating the ngrok Terms of Service. Email [email protected] if you think your suspension is an error. The authentication you specified is actually a tunnel credential.


4 Answers

After some time I got it fixed doing 2 things:

  1. Make sure my local site is http (not https)
  2. Running command ngrok http -host-header=rewrite localhost:PORT
like image 82
Leonel waisblatt Avatar answered Oct 20 '22 12:10

Leonel waisblatt


For me, this command worked when I was receiving the 3004 error message and trying to access HTTPS on https://localhost:3000:

./ngrok http https://localhost:3000
like image 24
Mike Dubs Avatar answered Oct 20 '22 12:10

Mike Dubs


I found an answer in this link and it solved my problem.

According to this you can use this command instead:

ngrok http https://localhost:[port]
like image 29
cerebrum Avatar answered Oct 20 '22 12:10

cerebrum


If your site using https://localhost:port below really works for me

ngrok http https://localhost:port --host-header=rewrite
like image 32
csharpQ Avatar answered Oct 20 '22 11:10

csharpQ