geckodriver icon indicating copy to clipboard operation
geckodriver copied to clipboard

Security Error thrown when trying to take a Screenshot on Firefox with an iFrame in focus

Open AutomatedTester opened this issue 3 years ago • 2 comments

System

  • Version:
  • Platform:
  • Firefox:
  • Selenium: 4.5

Testcase

Testcase available on the Nightwatch repo https://github.com/nightwatchjs/nightwatch/issues/3512

Stacktrace

Error
     Response 500 GET /session/97e7684a-f42d-45f0-9428-5f957de28cc4/screenshot (3ms)
   {
     value: {
       error: 'unknown error',
       message: 'SecurityError: Permission denied to access property "pageXOffset" on cross-origin object',
       stacktrace: ''
     }
  }
    Error   Error while running .getScreenshot() protocol action: SecurityError: Permission denied to access property "pageXOffset" on cross-origin object

  Error

Trace-level log

None provided

AutomatedTester avatar Dec 13 '22 11:12 AutomatedTester

@AutomatedTester, other Any updates on this item? Do you have any work around to overcome it, because it seems Gecko team has not put this item into the fixing plan. Many thanks in advance.

minhdoan159 avatar May 26 '23 05:05 minhdoan159

This most likely happens because of https://bugzilla.mozilla.org/show_bug.cgi?id=1493650.

whimboo avatar May 26 '23 08:05 whimboo