evergreen icon indicating copy to clipboard operation
evergreen copied to clipboard

[Bug]: API endpoints behind CloudFlare are requiring javascript to be enabled.

Open tylermiranda opened this issue 1 year ago • 3 comments

What happened?

A bit of a weird one here. I can hit the API endpoints just fine using Invoke-ResthMethod from my home machine and my work machine when I egress through my home internet or my work internet. On my Azure machines however, egressing through the Azure internet connection, it appears CloudFlare DDOS protection is kicking in and requiring the use of javascript. Guessing the Azure public ip block triggers an automatic protection.

image

Version

v2404.928

What PowerShell edition/s are you running Evergreen on?

Windows PowerShell

Which operating system/s are you running Evergreen on?

Windows 10+

Have you reviewed the documentation?

  • [X] Troubleshooting at: https://stealthpuppy.com/evergreen/troubleshoot/
  • [X] Known issues at: https://stealthpuppy.com/evergreen/issues/

Verbose output

This is the API endpoint so no output.

tylermiranda avatar Apr 24 '24 19:04 tylermiranda

I'd say the Javascript requirement there is because the challenge page uses Javascript to do some detection on the endpoint, but that typically runs in the browser. Bot protection is likely running across my entire domain, so I'll have to see how I can disable that just for the domain the API runs on.

aaronparker avatar Apr 25 '24 01:04 aaronparker

It's no biggie. In this environment I can use the module for now to get around it. Thanks!

tylermiranda avatar Apr 25 '24 01:04 tylermiranda

FYI we are using pwsh 7.x which is fully functionally with the API and methods. Alternatively you could enforce the user-agent version, which seems to be the issue.

42uhybrider avatar Jun 12 '24 08:06 42uhybrider