I am testing an app and as soon as I load the URL it redirects me to Cloudfare access page and asks me to signIn using Google. When I click on Google SignIn it asks for my email address and password. Now I don't want to expose my email ID and password in the code as it will run on test server and anyone can access it. SO is there a way to bypass or authenticate the cloudfare access page
2 Answers
I normally don't answer questions with a definitive no, but I think it's safe to say with this I can say no. If there was a way, Cloudflare wouldn't be in business, and they're kind of top of the line for this kind of thing.
That being said, there are some other ways around this - have you considered making a fake email and password?
-
I have not considered fake email ID. All the email IDs in my organisation are 2FA but l can talk to infra guys and see if they can skip 2FA for test email Thanks! Commented Sep 14, 2021 at 8:20
Grey box testing
Ask application development to provide you with an alternative way to get authorized / get a token that is only implemented for the test and development environments and does not require changing. Consider multiple accounts for different privileges and try and test with the minimum privilege you can, for example read only. Proxy servers and test accounts are a couple of the ways to implement this.