QOAuth2AuthorizationCodeFlow::granted is not working with NGROK
-
I am implementing the "Apple Login" in my deskop app.
Due to the fact that Apple does not allow to set the redirect url to http://localhost:port, I am using (just for testing) NGROK to redirect the traffic to my local port (5476) and I set this url as redirect url in the Apple developer console.In my code I have
// Reply handler auto replyHandler = new QOAuthHttpServerReplyHandler(5476, this); m_oauth->setReplyHandler(replyHandler); connect(m_oauth, &QOAuth2AuthorizationCodeFlow::granted, this, &AppleLogin::onGranted);
While I can see the received traffic in the NGROK console:
state=0SajhHkd&code=c49365639c5644b3a80fd3659f294c2b1.0.mrsqv.BVX-As8PsnmH5Oha5Zcgww&user=%7B%22name%22%3A%7B%22firstName%22%3A%22Franco%22%2C%22lastName%22%3A%22Amato%22%7D%2C%22email%22%3A%22f.amato%40beastburst.com%22%7D
The reply handler seems not catching the traffic and thus the granted signal is not emitted.
How can I solve this problem to test my software? Is there a better way to get the traffic without using ngrok? -
Hi,
Did you consider using something like noip to have an address that you can point to your machine ?
-
Hi @SGaist no I don't know how noip works