1 // Copyright 2020 The Chromium Authors. All rights reserved. 2 // Use of this source code is governed by a BSD-style license that can be 3 // found in the LICENSE file. 4 5 #ifndef CHROMECAST_MEDIA_CDM_CAST_CDM_ORIGIN_PROVIDER_H_ 6 #define CHROMECAST_MEDIA_CDM_CAST_CDM_ORIGIN_PROVIDER_H_ 7 8 namespace media { 9 namespace mojom { 10 class FrameInterfaceFactory; 11 } // namespace mojom 12 } // namespace media 13 14 namespace url { 15 class Origin; 16 } // namespace url 17 18 namespace chromecast { 19 20 class CastCdmOriginProvider { 21 public: 22 // Util function to call sync mojo API to get cdm origin. 23 // TODO(159346933) Remove once the origin isolation logic is moved outside of 24 // media service. 25 static bool GetCdmOrigin(::media::mojom::FrameInterfaceFactory* interfaces, 26 url::Origin* cdm_origin); 27 }; 28 29 } // namespace chromecast 30 31 #endif // CHROMECAST_MEDIA_CDM_CAST_CDM_ORIGIN_PROVIDER_H_ 32