Commit Graph

224 Commits

Author SHA1 Message Date
Simon Giesecke
1e02318b49 Bug 1653335 - Replace MakeSpan uses by constructor calls. r=froydnj
Differential Revision: https://phabricator.services.mozilla.com/D83817
2020-08-07 07:49:47 +00:00
David Major
dd955b19e7 Bug 1646206 - Fix a vsnprintf lint in ClearKeyUtils.cpp r=bryce
We have a clang-plugin check that discourages raw `vsnprintf`, but for some reason it doesn't catch this before clang 11. I _think_ it's related to earlier versions not being able to see that `len` is a constant, but I'm not really sure.

Differential Revision: https://phabricator.services.mozilla.com/D79918
2020-06-16 23:06:22 +00:00
Bryce Seager van Dyk
defad44097 Bug 1623651 - Update enums that have changed with CDM header bump. r=alwu,dminor
The CDM header bump has moved some enums, as well as using enum classes instead
of old style enums. This patch updates consumers of these enums to be compatible
with the new headers.

Drive by remove `using namespace cdm` from a couple of files as
- In some places I'd already been using fully qualified names.
- I prefer the fully qualified names as they make it clear when enums are coming
  from the cdm namespace and `cdm::` is not a particularly more verbose thing to
  have on identifiers.

Differential Revision: https://phabricator.services.mozilla.com/D78343
2020-06-08 19:02:05 +00:00
Omri Sarig
a60ad3ae44 Bug 1626787 - ClearKeyDecryptionManager.cpp check emptiness by empty instead of by size. r=sylvestre
Emptiness of values should be checked using the `empty` method, and not
by comparing the size to 0. Fix such case in the code of
ClearKeyDecryptionManager.cpp module.

Differential Revision: https://phabricator.services.mozilla.com/D70206

--HG--
extra : moz-landing-system : lando
2020-04-08 15:47:17 +00:00
Jason
ea383d394a Bug 1516673 - Adds CBCS encryption scheme functionality. r=bryce
Differential Revision: https://phabricator.services.mozilla.com/D60053

--HG--
extra : moz-landing-system : lando
2020-03-26 20:53:59 +00:00
Simon Giesecke
810fd1f507 Bug 1613985 - Use default for equivalent-to-default constructors/destructors in media. r=bwc
Differential Revision: https://phabricator.services.mozilla.com/D65494

--HG--
extra : moz-landing-system : lando
2020-03-06 09:21:47 +00:00
Alex Henrie
7f77eac87f Bug 1608657 - Drop version check from WMFDecoderDllName and inline when possible. r=jya
Differential Revision: https://phabricator.services.mozilla.com/D59604

--HG--
extra : moz-landing-system : lando
2020-01-14 04:03:28 +00:00
shindli
a17667ebcc Backed out changeset 1b423cf63926 (bug 1608657) for causing windows build bustages CLOSED TREE 2020-01-14 03:59:22 +02:00
Alex Henrie
f2831b31e1 Bug 1608657 - Drop version check from WMFDecoderDllName and inline when possible. r=jya
Only Windows 7 and later are now supported.

Differential Revision: https://phabricator.services.mozilla.com/D59604

--HG--
extra : moz-landing-system : lando
2020-01-14 01:18:49 +00:00
Ryan Alderete
862aa4197f Bug 1579506 - Remove OpenAES source code and references r=bryce,mhoye
With NSS now being used to do the decryption in the Clearkey CDM, remove the
source and licensing information related to OpenAES.

Differential Revision: https://phabricator.services.mozilla.com/D45205

--HG--
extra : moz-landing-system : lando
2019-09-12 23:27:08 +00:00
Ryan Alderete
2e2b52b880 Bug 1572846 - Update Clearkey to use NSS for decryption instead of OpenAES r=bryce,jld
Clearkey previously relied on OpenAES to do its encryption.  In order to
facilitate future changes and the need for CBC support, switch to NSS, which
should be more flexible and actively maintained.

Differential Revision: https://phabricator.services.mozilla.com/D41993

--HG--
extra : moz-landing-system : lando
2019-09-05 19:19:06 +00:00
Eric Rahm
2f5a215771 Bug 1577885 - Remove using namespace std from GMP ClearKey r=bryce
Differential Revision: https://phabricator.services.mozilla.com/D44269

--HG--
extra : moz-landing-system : lando
2019-09-03 19:10:42 +00:00
Sylvestre Ledru
fc2eb5393c Bug 1562642 - Part 2 - Add missing MPL2 headers r=Gijs
Differential Revision: https://phabricator.services.mozilla.com/D37146

--HG--
extra : moz-landing-system : lando
2019-07-08 09:27:47 +00:00
Sylvestre Ledru
03fc65347c Bug 1542146 - Apply the change with the option StatementMacros from clang-format-8 r=andi
# ignore-this-changeset

Differential Revision: https://phabricator.services.mozilla.com/D26280

--HG--
extra : moz-landing-system : lando
2019-04-05 21:42:17 +00:00
Csoregi Natalia
ba58e936bd Backed out changeset 4ad80127f89f (bug 1519636) for bustage on MarkupMap.h and nsAccessibilityService.cpp. CLOSED TREE 2019-04-05 09:48:19 +03:00
Sylvestre Ledru
d1c1878603 Bug 1519636 - clang-format-8: Reformat recent changes to the Google coding style r=Ehsan
clang-format-8 upstream had some improvements wrt macros
See: https://reviews.llvm.org/D33440
This is why the diff is bigger than usual

# ignore-this-changeset

Differential Revision: https://phabricator.services.mozilla.com/D26098

--HG--
extra : moz-landing-system : lando
2019-04-04 21:36:16 +00:00
Narcis Beleuzu
24dbe577a5 Backed out changeset 389b6bbd76db (bug 1519636) for bustages on MarkupMap.h . CLOSED TREE 2019-04-05 00:27:56 +03:00
Sylvestre Ledru
399dbd28fe Bug 1519636 - clang-format-8: Reformat recent changes to the Google coding style r=Ehsan
clang-format-8 upstream had some improvements wrt macros
See: https://reviews.llvm.org/D33440
This is why the diff is bigger than usual

# ignore-this-changeset

Differential Revision: https://phabricator.services.mozilla.com/D26098

--HG--
extra : moz-landing-system : lando
2019-04-04 20:12:23 +00:00
Chris Pearce
2674fe3acc Bug 1528661 - Pass paths to i686 xul and plugin-container binaries to CDM in host verification paths. r=bryce
On Windows on ARM64 we will run the x86 Widevine DLL in an x86
plugin-container.exe with an x86 xul.dll. We therefore should also pass the
paths to these binaries to the CDM in the host files instead of the aarch64
plugin-container.exe. We should still pass the aarch64 xul.dll to the CDM,
as that's in use by the aarch64 firefox.exe.

Differential Revision: https://phabricator.services.mozilla.com/D21507

--HG--
extra : source : 4c22ddbf15b579a57d1790c1b4f6290e661da346
extra : histedit_source : 8f1f76f36c3a18681e8aa373e7cd117c41c11815
2019-02-15 21:27:01 +13:00
Ryan Hunt
d5e3e54658 Bug 1523969 part 15 - Move method definition inline comments to new line in 'media/'. r=jya
Differential Revision: https://phabricator.services.mozilla.com/D21116

--HG--
extra : rebase_source : bf7d4b2a09768420f8da04d82d34afed374d7961
2019-02-25 16:09:55 -06:00
Masatoshi Kimura
e25fbce870 Bug 1528651 - Re-enable warnings-as-errors on Windows in some directories. r=dmajor
--HG--
extra : source : ba86ea25070b37f4725834e1c2d9ec4c0783e119
2019-02-17 15:03:02 +09:00
Mike Hommey
ef3ad686ee Bug 1512504 - Remove support for MSVC. r=froydnj
Consequently, this removes:
- MOZ_LIBPRIO, which is now always enabled.
- non_msvc_compiler, which is now always true.
- The cl.py wrapper, since it's not used anymore.
- CL_INCLUDES_PREFIX, which was only used for the cl.py wrapper.
- NONASCII, which was only there to ensure CL_INCLUDES_PREFIX still
  worked in non-ASCII cases.

This however keeps a large part of detecting and configuring for MSVC,
because we still do need it for at least headers, libraries, and midl.

Depends on D19614

Differential Revision: https://phabricator.services.mozilla.com/D19615

--HG--
extra : moz-landing-system : lando
2019-02-14 21:45:27 +00:00
Ehsan Akhgari
e5e885ae31 Bug 1521000 - Part 2: Adjust our clang-format rules to include spaces after the hash for nested preprocessor directives r=sylvestre
# ignore-this-changeset

--HG--
extra : amend_source : 7221c8d15a765df71171099468e7c7faa648f37c
extra : histedit_source : a0cce6015636202bff09e35a13f72e03257a7695
2019-01-18 10:16:18 +01:00
Bryce Van Dyk
e41e35bf8d Bug 1516669 - Check init value of clearkey WMF decoder for failure. r=cpearce
We weren't checking this value and it was causing compiler warnings. Instead
this change means we check the value and log an error if init has failed.

Differential Revision: https://phabricator.services.mozilla.com/D15519

--HG--
extra : moz-landing-system : lando
2019-01-14 16:40:29 +00:00
Bryce Van Dyk
5aecaa0a28 Bug 1516669 - Update gmp-clearkey to use CDM10 interface. r=cpearce
Not much changed in the interface:
- CDM initialization takes a use hardware codecs arg, we pipe this through, but
  don't do anything more with it in the clearkey CDM.
- The CDM should call the hosts OnInitialized() when it's initialized. This is
  done is now done in the clearkey CDM once the session management is ready, as
  that is the last thing done during init.

Aside from the above, it's just updating interface usage. While the new CDM
interface adds support for different encryption schemes, this is not handled
here and will be done in follow up bug 1516673.

Differential Revision: https://phabricator.services.mozilla.com/D15518

--HG--
extra : moz-landing-system : lando
2019-01-14 16:40:04 +00:00
Sylvestre Ledru
265e672179 Bug 1511181 - Reformat everything to the Google coding style r=ehsan a=clang-format
# ignore-this-changeset

--HG--
extra : amend_source : 4d301d3b0b8711c4692392aa76088ba7fd7d1022
2018-11-30 11:46:48 +01:00
Ehsan Akhgari
ca162bee20 Bug 1508472 - Part 4: Fourth batch of comment fix-ups in preparation for the tree reformat r=sylvestre
This is a best effort attempt at ensuring that the adverse impact of
reformatting the entire tree over the comments would be minimal.  I've used a
combination of strategies including disabling of formatting, some manual
formatting and some changes to formatting to work around some clang-format
limitations.

Differential Revision: https://phabricator.services.mozilla.com/D13193

--HG--
extra : moz-landing-system : lando
2018-11-28 09:16:55 +00:00
Bryce Van Dyk
413ba3feef Bug 1487811 - P1: Update Widevine headers and C++ code to prepare for CDM interface 10 support. r=cpearce
Update content_decryption_module.h and other Widevine headers. This removes the
CDM8 interface and adds in the CDM10 and CDM11 interfaces. As such this patch
removes references to CDM8 from the code and adds some of the foundations for
supporting CDM10. Most of the CDM10 code will be implemented in another bug, but
there are a number of cases where it was straight forward to shuffle CDM8+9 code
-> CDM9+10, rather than deleting it and replacing it later.

Differential Revision: https://phabricator.services.mozilla.com/D5628

--HG--
extra : moz-landing-system : lando
2018-09-13 14:49:10 +00:00
Tom Ritter
7e0fefeaa0 Bug 1475566 Disable #pragma comments for MinGW Builds r=glandium
In the MinGW browser build job, we're going to use -fms-extensions,
which will tell clang to start processing these comments. Clang
cannot process them correctly (it's an upstream bug) but it doesn't
need to, because we include the libs we need in moz.build files.

So we exclude them for MinGW builds. mingw-clang gets them wrong and
mingw-gcc (which doesn't even work anymore on -central) ignored them.

In the future, with a llvm fix, we could clean up the moz.build
files and re-enable these comments.

Differential Revision: https://phabricator.services.mozilla.com/D3527

--HG--
extra : moz-landing-system : lando
2018-08-29 03:50:39 +00:00
Masatoshi Kimura
3b21b7868b Bug 1090497 - Re-enable warnings as errors on clang-cl. r=froydnj
--HG--
extra : rebase_source : c09366fb93e5b0f72abe1e99d3094e3d96a934fb
extra : intermediate-source : 5950c9d63c3b4fd63a25464a7b50944aaec7079f
extra : source : ca1b9a2bcc4381795f556fea2fb59066567c30f3
2018-07-31 22:10:07 +09:00
David Major
4197688bdf Bug 1478008 - Make gmp-clearkey use the same warnings under clang-cl as with clang. r=froydnj 2018-07-25 08:07:41 -04:00
Sebastian Hengst
0819f35e51 Backed out 4 changesets (bug 525063) on request from Andi. a=backout
Backed out changeset 516c4fb1e4b8 (bug 525063)
Backed out changeset 6ff8aaef2866 (bug 525063)
Backed out changeset bf13e4103150 (bug 525063)
Backed out changeset d7d2f08e051c (bug 525063)
2018-04-13 16:01:28 +03:00
Tristan Bourvon
a3a77c0312 Bug 525063 - Initialize uninitialized class attributes in m-c. r=ehsan 2018-04-10 21:11:02 +02:00
Masatoshi Kimura
a1d349bfab Bug 1426898 - Stop including Char16.h everywhere. r=Waldo
We had to force-include Char16.h to simulate char16_t on older MSVC versions.
But it is no longer the case. We should not rebuild the world whenever we
touch this file.

MozReview-Commit-ID: 1XY7tQD8LoK

--HG--
extra : rebase_source : a08ccfc9b6a4abf90f6f8b97a42079865724c9ec
2017-12-23 00:53:12 +09:00
Sylvestre Ledru
5de63ef061 Bug 1394734 - Replace CONFIG['MSVC'] by CONFIG['CC_TYPE'] r=glandium
MozReview-Commit-ID: 5orfnoude7h

--HG--
extra : rebase_source : 1ed9a6b56e1d27221a07624767a7fb0e6147117f
2017-12-08 13:46:13 +01:00
Sylvestre Ledru
9bfe27d903 Bug 1394734 - Replace CONFIG['GNU_C*'] by CONFIG['CC_TYPE'] r=glandium
MozReview-Commit-ID: 7duJk2gSd4m

--HG--
extra : rebase_source : 7312fe276e561e8c034a5f6749774ae812727f9c
2017-12-07 22:09:15 +01:00
James Cheng
1c2ea0c110 Bug 1417297 - Part1 - Convert gmp-clearkey to use Chromium ContentDecryptionModule_9 interface. r=cpearce
1. Make ClearKeyCDM inherits cdm::ContentDecryptionModule_9
2. Pass cdm::Host_9 instance instead of cdm::Host8
3. Modify the manifest to 1.4.9

MozReview-Commit-ID: JbeBm5YNZ22

--HG--
extra : rebase_source : feb6aa44e361cb68f8a75284e79b1617609438a4
2017-11-23 16:47:13 +08:00
James Cheng
f0a43c284e Bug 1409670 - Skip decrypting request when receiving an unencrypted sample in Clearkey implementation. r=cpearce
MozReview-Commit-ID: 5XIUeFc3PSD

--HG--
extra : rebase_source : a36e27b385f1622bc7125e8d7e8c1b1b6e930842
2017-10-19 16:45:21 +08:00
James Cheng
38c77e80cb Bug 1406080 - Part2 - Reject creating with unsupported cdm version in clearkey cdm and cdm-fake. r=cpearce
MozReview-Commit-ID: JvSsqZekRQ6

--HG--
extra : rebase_source : e80713dbf52aad29a32ff71a083c19479094b9a6
2017-10-07 00:06:06 +08:00
Chris Manchester
c0a229d4c3 Bug 1386876 - Replace all uses of DISABLE_STL_WRAPPING with a template, remove DISABLE_STL_WRAPPING. r=glandium
MozReview-Commit-ID: FMEtb5PY7iP

--HG--
extra : rebase_source : 3cdee7528846462c758e623d6bcd2e6e17dbabff
2017-09-11 11:33:26 -07:00
James Cheng
7d08d66397 Bug 1398072 - Fix an obvious leak in Cleakey CDM. r=cpearce
MozReview-Commit-ID: Ee9Me0MKpPU

--HG--
extra : rebase_source : 7a779780865ff00eb6154b3b601eed04541b7ac8
2017-09-08 17:34:48 +08:00
Tom Ritter
66e04df56d Bug 1395418 Revert a previous patch that disabled std::thread on MinGW because we didn't have it. Now we do. r=cpearce
MozReview-Commit-ID: 8ah0Unum1f2

--HG--
extra : rebase_source : 7054f778c0b8a2e4a831e379086243433cd219b8
2017-08-30 20:31:01 -05:00
James Cheng
10d6dbd3e6 Bug 1390453 - Don't call VerifyCdmHost_0 in non-official builds. r=cpearce
MozReview-Commit-ID: 3rzMDq0upBm
2017-08-17 14:41:54 -04:00
Sylvestre Ledru
9ce875d87a Bug 1387002 - Replace .size() by .empty() when applicable in gmp r=cpearce
MozReview-Commit-ID: HhYJ6BK4oOG

--HG--
extra : rebase_source : 8177ad33ebafafc27ba2f809743cfd2c223a10d7
2017-08-04 09:09:38 +02:00
Sylvestre Ledru
756cf62eca Bug 1372839 - SkipString; Exit early if sym is not found r=gerald
MozReview-Commit-ID: GnqPuW8FL5F

--HG--
extra : rebase_source : b3c44c8daecc5341957d5953a525af82afba705a
2017-08-10 09:34:34 +02:00
Jan Beich
5c4a94b509 Bug 1385115 - Unbreak build on Tier3 after bug 1382883. r=cpearce
MozReview-Commit-ID: ISTOw1qfxiy

--HG--
extra : rebase_source : 4444849c190f7128d67c53483866ac59c73b2eb9
2017-07-28 11:48:56 +00:00
Chris Pearce
0637427899 Bug 1382883 - Pass paths and open file handles to CDM host binaries on CDM startup. r=gerald
MozReview-Commit-ID: 9IhRqlFrNJf

--HG--
extra : source : de04ea0a90ae935bbc1d0f730332b034b5514f17
extra : intermediate-source : b18daff94ad3d832fcbd601d219c6db2eae46f90
2017-07-27 12:50:46 +12:00
Chris Pearce
c4af620223 Bug 1381720 - Update content_decryption_module.h. r=gerald
Update to chromium revision 6e4c388c0117fe408b66fbede91081fb1018c5fe.

Includes cdm::ContentDecryptionModule_9 and cdm::Host_9 definitions,
HDCP definitions, and 10 and 12 bit image format definitions.

MozReview-Commit-ID: bYH3OBSzuT

--HG--
extra : rebase_source : cfc291b3452c2154ecd1ca16a2ece0a5a42f0b5e
2017-05-29 17:14:26 +12:00
Wes Kocher
b1c83de1b7 Backed out 2 changesets (bug 1381720) for linux build failures in content_decryption_module.h a=backout
Backed out changeset e4d9cb334352 (bug 1381720)
Backed out changeset 69f177823866 (bug 1381720)

MozReview-Commit-ID: DctOanJkHh7
2017-07-17 23:21:49 -07:00
Chris Pearce
9901d75b55 Bug 1381720 - Update content_decryption_module.h. r=gerald
Update to chromium revision 6e4c388c0117fe408b66fbede91081fb1018c5fe.

Includes cdm::ContentDecryptionModule_9 and cdm::Host_9 definitions,
HDCP definitions, and 10 and 12 bit image format definitions.

MozReview-Commit-ID: bYH3OBSzuT

--HG--
extra : rebase_source : d062d233c9a2b59aa5ae5c6e0584ed13b7c83e6e
2017-05-29 17:14:26 +12:00