Prebid.js
Prebid.js copied to clipboard
Insticator Bid Adapter: faulty video param validation leads to rejected bids
Type of issue
bug
Description
- for several video params, the validation added in this PR seems incorrect:
- #10969
- https://github.com/prebid/Prebid.js/blob/28cceb9a17cfa3048d9211ef9f0c27fc012828cd/modules/insticatorBidAdapter.js#L15-L42
- the
isSubarray()helper is used for params it doesn't make sense for, and because it uses a.every()check, it rejects valid bids - example:
-
protocols(oRTB spec list) - for a config with:
protocols: [1,2,3,4,5,6,7,8] - even though valid protocols are allowed, just because
1and4are also allowed, the.every()check fails and the adapter rejects the bid - a
.some()check makes more sense here, would recommend at least a separate helper for some of these params
-
- similarly for:
-
api(oRTB spec list) - if the list includes both supported & unsupported apis, the bid gets rejected -
playbackmethod(oRTB spec list)- for playbackmethod, possibly this one is correct and what they mean, just are losing out on bids if not supporting values: 5-7
-
Expected results
- expect a bid that allows at least some of the supported values for the mentioned params to be valid
Actual results
- bid gets rejected as invalid
Platform details
v8.33.0 +
Other information
#10969
FYI @shubhamc-ins
@andyblackwell if you PR the adapter we're happy to contact them before merging
Thanks @andyblackwell for the details.
Actually we have the validation in that particular way since we don't support, e.g [1, 4] for protocols.
But I see your point as well, We will add a patch for it and pass through the values which we support if in case the array contains both supported and unsupported values.