-1

context:
i'm using robot framework + msedgedriver for e2e testing, my environment is docker in linux vm. So i can't run msedgedriver windows container in this vm. I decided to run ms edge driver on remote windows vm.

Problem:
in my windows server 2016 i execute the following cmd : msedgedriver.exe --whitelisted-ips="".
I configured my pfsense firewall to redirect trafic to this host, when i try to connect to msedgedriver i get the following error:

Starting MSEdgeDriver 96.0.1033.0 (87d233ad01b7c17f5f53b7dac130e44d5d4b67d6) on port 9515 All remote connections are allowed. Use an allowlist instead! Please see https://chromedriver.chromium.org/security-considerations for suggestions on keeping MSEdgeDriver safe. MSEdgeDriver was started successfully. [1633362838.713][SEVERE]: Rejecting request with host: ip_address:9515 address: ip_address

and I get the following error in the client:

Host header or origin header is specified and is not whitelisted or localhost.

P.S: I've added my IP address to the whitelisted Ips using --whitelisted-ips='' argument also i tried allowed-origins=* but no luck.
Any idea about it?

Chawki
  • 189
  • 2
  • 12
  • 1
    Here is [a similar case](https://bugs.chromium.org/p/chromedriver/issues/detail?id=3857), you can try adding the `allowed-origins` param, it is used to allow requests directed to host different from the local name. Setting the option to `*` disables origin host check and allows any origin host. – Xudong Peng Oct 05 '21 at 07:16
  • I forgot to mention that in my question, Unfortunately i already use allowed-origins=* param but also not working. I will edit question above. – Chawki Oct 05 '21 at 09:55
  • 1
    We tested the problem (window 2016 and Edgedriver 96.0.1033.0), but failed to reproduce your problem, it can run correctly. This is a [screenshot](https://i.stack.imgur.com/7g4He.png) of the result. Are you using the correct Edge version (consistent with Edge Driver)? If this is the case, I think the firewall settings may be related to the problem. – Xudong Peng Oct 11 '21 at 10:03
  • @XudongPeng it works now by downgrading to msedge driver version 96.0.1032.0, a lot of tries with other version in same release and other releases (95, 94) didn't work. Thank you for your response. – Chawki Oct 11 '21 at 17:49
  • I am glad that your problem has been resolved. If possible, you can post it as an answer to this thread, which may be able to help other members of the community, thank you for your understanding. – Xudong Peng Oct 12 '21 at 06:47

1 Answers1

-1

in the end the problem has been resolved by downgrading the msedg driver version to "96.0.1032.0".
many other version doesn't work in my case so i advise to try several version of MS Edge Driver ofc with installing the compatible version of edge browser.
Hope that is helpful.

Chawki
  • 189
  • 2
  • 12