Skip to content
This repository has been archived by the owner on Dec 11, 2019. It is now read-only.

Added Widevine support for Amazon Prime Video #5233

Closed
alexwykoff opened this issue Oct 28, 2016 · 7 comments
Closed

Added Widevine support for Amazon Prime Video #5233

alexwykoff opened this issue Oct 28, 2016 · 7 comments

Comments

@alexwykoff
Copy link
Contributor

Did you search for similar issues before submitting this one?
Yes

Describe the issue you encountered:
Brave is not detecting the need for Widevine on Amazon Prime Video.

Expected behavior:
Brave should detect when Widevine is needed and prompt appropriately like we do for Flash.

  • Platform (Win7, 8, 10? macOS? Linux distro?):
    Tested on OS X.
  • Brave Version:
    0.12.8
  • Steps to reproduce:
    1. Visit Amazon Prime, login.
    2. Attempt to watch a prime video.
  • Screenshot if needed:
    screen shot 2016-10-28 at 12 35 43 pm
  • Any related issues:
@bbondy
Copy link
Member

bbondy commented Oct 29, 2016

Test Plan:
The heuristic is not super good for determining if widevine prompt should come up so we really need to make sure it doesn't come up on other amazon pages, but does come up on Amazon prime video related pages. I suggest testing this with disabled widevine so you get the dialog and know when the heuristic is hit
Other heuristics I tried that didn't work was URLs /dp/ (some other
products have this), and s=instant_video (some videos don't have this)

@bbondy
Copy link
Member

bbondy commented Nov 4, 2016

I reverted this because it needs a better metric. I'm moving git to 0.12.9 instead, possibly it'll be moved later even.

@bbondy bbondy modified the milestones: 0.12.9dev, 0.12.8dev Nov 4, 2016
@bbondy
Copy link
Member

bbondy commented Nov 4, 2016

Problems with the current one:
It was working for me on amazon prime videos
Alex wasn't getting URLs on amazon prime videos in the same format
Ayumi was seeing the prompt on aws pages.

I also tried various other heuristics before, so I think we need to find something in the page instead of using the URL as the heuristic.

@srirambv
Copy link
Collaborator

srirambv commented Dec 15, 2016

@BrendanEich
Copy link
Member

This issue needs attention in 1.0 timeframe.

@bbondy bbondy modified the milestones: 1.0.0, Backlog Mar 16, 2017
@alexwykoff
Copy link
Contributor Author

alexwykoff commented Apr 1, 2017

Adding a few DOM elements which we might be able to look for:

<span class="a-declarative" data-action="dv-record-reftag" data-dv-record-reftag="{&quot;reftag&quot;:&quot;atv_dp_stream_prime_movie&quot;}">
    <a href="/dp/B01M2YXBZV/?autoplay=1" onclick="if (!window.wbClicked &amp;&amp; window.ue){window.wbClicked=true;uet('bb','watch-clicked',{wb:1});P.when('dv-player-integration-layer').execute(function(i){i.logClientSideMetrics('watch-clicked');});}" class="dv-play-btn-content" data-asin="B01M2YXBZV" data-clickstream-ref="atv_dp_stream_prime_movie" data-fallback-url="" data-is-avod="" data-page-asin="B01M2YXBZV" data-resume-time="0" data-session-id="165-2615247-5598458" data-sign-in-url="" data-token="">
            <span class="dv-icon dv-icon-watch"></span>
            Watch Now
    </a>
    </span>

<html class="a-ws a-js a-audio a-video a-canvas a-svg a-drag-drop a-geolocation a-history a-webworker a-autofocus a-input-placeholder a-textarea-placeholder a-local-storage a-gradients a-hires a-transform3d a-touch-scrolling a-text-shadow a-text-stroke a-box-shadow a-border-radius a-border-image a-opacity a-transform a-transition" data-19ax5a9jf="dingo" data-aui-build-date="3.16.1.5-2016-10-26" style="overflow: hidden;"><!--<![endif]--><head><script async="" src="https://images-na.ssl-images-amazon.com/images/G/01/AUIClients/ClientSideMetricsAUIJavascript-c8621177540f3abe0e5f4606c5f35dad04257105._V2_.js"></script>

var ue_url='/**gp/product**/B06W9P3V2Z/ref=dv_web_wtls_list_ovl_wn_wnzw/uedata/unsticky/165-2615247-5598458/Video/ntpoffrw',

<script type="application/ld+json"> {"productionCompany":{"name":"Amazon Studios","@type":"Organization"},"video":{... </script>

<link rel="stylesheet" type="text/css" href="https://avodassets-a.akamaihd.net/playback/web_player/ATVWebPlayer/1.0.743.13/css/ATVWebPlayer.css">

<script src="https://www.amazon.com/gp/video/streaming/player-token.json?callback=onWebToken_b622bc0a4b4f4fda84aee59159e8b2ed"></script><script crossorigin="anonymous" src="blob:https://www.amazon.com/f61e9a72-cf73-4ece-972d-f86ff66b696d">
<link rel="stylesheet" type="text/css" href="https://avodassets-a.akamaihd.net/playback/web_player/ATVWebCascadesPlayer/1.2.892.0/css/ATVWebCascadesPlayer.css">
<link rel="stylesheet" href="https://images-na.ssl-images-amazon.com/images/G/01/AUIClients/DigitalVideoCarouselAUI-a923621c1c6f8f9147e6cc1ad6c015ff9d779e4a._V2_.css#AUIClients/DigitalVideoCarouselAUI.us.secure.min">

<div id="dv-player-content" class="dv-player-content tv" data-auto-play="

<div id="dv-web-player" data-config="

<div class="overlaysContainer hideCursor" data-reactid=".0.0"><div class="heroImageOverlay" data-reactid=".0.0.0"><div class="heroImageSurface" data-reactid=".0.0.0.0"></div></div><div class="gradientOverlay hide" data-reactid=".0.0.1"></div><div class="overlay" data-reactid=".0.0.2"><div class="loadingSpinner whiteSpinner" style="display: none;" data-reactid=".0.0.2.0"><img class="svgBackground"

Enter your 5-digit Amazon Video PIN
    <div class="dv-pin-modal">
        <div id="pin-wrap"></div>
        <a href="https://www.amazon.com/gp/video/settings/ref=dp_pct_pin_chg#aiv-settings-parental-controls">Forgotten your PIN?</a>
        or
        <a href="https://www.amazon.com/gp/video/settings/ref=dp_pct_pin_chg#aiv-settings-parental-controls">Change your purchase restriction settings?</a>
    </div>
    <div class ="dv-pin-pop-status-msg"></div>

<div class="aiv-wrapper">
    <div class="aiv-container-limited tancaccept">
        By placing your order or playing a video, you agree to our <a href="https://www.amazon.com/dv/tou?_encoding=UTF8&amp;ref=dv_dp_terms">Terms of Use</a>. Sold by Amazon Digital Services LLC. Additional taxes may apply.
    </div>
</div>

<div class="a-section a-spacing-small aiv-container-limited">

            <div class="dv-season-selector-no-drop-down" )="">
                Season 1<i class="a-icon a-icon-prime dv-season-selector-prime"></i>
            </div>
</div>
<div class="dv-play-button-radial deeplinkable aok-clearfix">
    <span class="a-declarative" data-action="dv-record-reftag" data-dv-record-reftag="{&quot;reftag&quot;:&quot;atv_dp_stream_prime_tv_el&quot;}">
        <a href="/dp/B06W5K36PZ/?autoplay=1" class="aok-float-right dv-playback-container" data-asin="B06W5K36PZ" data-lcid="" data-resume-time="0" data-fallback-url="" data-sign-in-url="" data-session-id="165-2615247-5598458" data-clickstream-ref="atv_dp_stream_prime_tv_el">
        <span class="dv-playback-icon-outer">
            <span class="dv-playback-icon-arrow"></span>
        </span>
    </a>
    </span>
</div>
</div> <!-- End Status -->

    <div class="dv-el-packshot"> <!-- Image -->
        <div class="dv-el-packshot-image" style="background-image: url(https://images-na.ssl-images-amazon.com/images/I/71gH9ZKc5NL._SX180_.jpg);"></div>
    </div><!-- End Image -->

<div class="dv-el-title-data">
    <div class="dv-el-title"> <!-- Title -->
        1. Oasis
    </div> <!-- End Title-->
    <div class="dv-el-synopsis-wrapper"> <!-- Synopsis -->
        <div class="dv-el-synopsis-content">
            <p class="a-color-base a-text-normal">Set in the near future, Oasis tells the story of priest Peter Leigh, who is called to a remote planet where a mysterious multinational company is building the first permanent off-Earth human colony. The planet, Oasis, is humanity's last chance to escape from Earth's impending collapse, but it quickly becomes apparent that it may not be as hospitable to humanity as it seems... [Like this Pilot? Go to www.amazon.com/pilotseason to take the survey.]</p>
                <span class="dv-el-badge dv-tv_ma">
                    TV-MA
                </span>
                <span class="dv-el-badge dv-el-subtitles-icon">
                    CC
                </span>
                <span class="dv-el-attr-key">
                    Language:
                </span>
                <span class="dv-el-attr-value">
                    English
                </span>
                <span class="dv-el-attr-key">
                    Runtime:
                </span>
                <span class="dv-el-attr-value">
                    59 minutes
                </span>
                <span class="dv-el-attr-key">
                    Release date:
                </span>
                <span class="dv-el-attr-value">
                    March 16, 2017
                </span>
        </div>
    </div> <!-- End Synopsis -->
</div>

@tbates
Copy link

tbates commented Feb 8, 2018

I'm getting this blocking dialog when trying to watch amazon prime video.

Your web browser is missing a digital rights component. Go to chrome://components and under WidevineCdm, click Check for update.

The instructions don't work, because chrome://components is not a working url in Brave

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.