ampproject / ampproject/amphtml

Master frame selection for amp-ad 3p vendors

Open
#35,099 2 comments 0 reactions 0 assignees View on GitHub
Stale Type: Bug WG: monetization
Dominant language
JavaScript
Stars
14.9k
Forks
4.1k
PR merge metrics
No merged PRs in 30d

Description

### Description

## Expected Behavior
One of the frames should be selected as master frame
## Actual Behavor
All the frames are selected as master frames in chrome v91

https://github.com/ampproject/amphtml/blob/main/3p/ampcontext-integration.js#L39 throws a security error even if the frame of the passed name is present in chrome v91. This causes every frame to become master frame

### Reproduction Steps

1. Navigate to any page using 3p amp-ad vendors
2. All the iframes are master frame

### Relevant Logs

```shell
Tested on Chrome Version 91.0.4472.114 and Version Version 91.0.4472.120
```

### Browser(s) Affected

Chrome

### OS(s) Affected

_No response_

### Device(s) Affected

_No response_

### AMP Version Affected

_No response_

Contributor guide

Open the contributing guide

Research direction

Start at 3p/ampcontext-integration.js around line 39 and reproduce the issue with a 3p amp-ad vendor in Chrome 91. Investigate why the frame lookup raises a security error when the named frame exists. Done means one frame is selected as the master frame rather than every iframe.

Written by the indexing model from the issue text.

Assessment

Tech stack
javascript
Domain
frontend
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.