RESOLVED FIXED 135798
[GTK] Subtle-crypto feature off by default and add a new configure flag to enable it
https://bugs.webkit.org/show_bug.cgi?id=135798
Summary [GTK] Subtle-crypto feature off by default and add a new configure flag to en...
Eduardo Lima Mitev
Reported 2014-08-11 06:06:56 PDT
Now that patches for subtle crypto from bug 133122 are starting to land, it has been recommended to turn OFF the feature by default while the implementations for the different crypto algorithms are not there. Currently, the feature is ON by default and there are stubs for all algorithm implementations. But we still want the build and tests bots to pick up this feature, so we need to add a new configure flag to enable it on specific builds.
Attachments
Patch (3.07 KB, patch)
2014-08-11 06:16 PDT, Eduardo Lima Mitev
no flags
Patch (3.10 KB, patch)
2014-08-11 10:56 PDT, Eduardo Lima Mitev
no flags
Patch (3.26 KB, patch)
2014-08-12 01:45 PDT, Eduardo Lima Mitev
no flags
Patch (3.26 KB, patch)
2014-08-12 01:52 PDT, Eduardo Lima Mitev
no flags
Eduardo Lima Mitev
Comment 1 2014-08-11 06:16:13 PDT
Philippe Normand
Comment 2 2014-08-11 06:32:51 PDT
Comment on attachment 236365 [details] Patch View in context: https://bugs.webkit.org/attachment.cgi?id=236365&action=review > Tools/Scripts/webkitperl/FeatureList.pm:380 > + define => "ENABLE_SUBTLE_CRYPTO", default => 0, value => \$subtleCrypto }, Having a default value of 0 here will disable the feature unless --enable-subtle-crypto is explicitely passed. So I think you need to have isGtk() at least. Is the feature enabled on Mac as well? If so the value would need to be (isGtk() || isMac())
Eduardo Lima Mitev
Comment 3 2014-08-11 07:28:28 PDT
Philippe, good catch! Indeed, at least the Mac port has it on and also iOS (per Source/WebCore/Configurations/FeatureDefines.xcconfig). I think the default value is: default => isAppleMacWebkit() || isIOSWebKit() but it would be nice to have confirmation from someone more familiar with these ports. Neither EFL nor Window seem to implement the feature.
Eduardo Lima Mitev
Comment 4 2014-08-11 10:56:25 PDT
Philippe Normand
Comment 5 2014-08-11 23:10:33 PDT
Comment on attachment 236382 [details] Patch View in context: https://bugs.webkit.org/attachment.cgi?id=236382&action=review > Tools/Scripts/webkitperl/FeatureList.pm:380 > + define => "ENABLE_SUBTLE_CRYPTO", default => isAppleMacWebKit() || isIOSWebKit(), value => \$subtleCrypto }, I still don't understand why isGtk() is not there. Or you plan to enable it later?
Eduardo Lima Mitev
Comment 6 2014-08-11 23:52:53 PDT
"default" is the default value for the flag. If the flag is not explicitly set in the command line of your build-webkit call (either --subtle-crypto or --no-subtle-crypto), that's the assumed value. Now, we want the GTK port to have it off by default, hence isGtk() is not there. And to activate it one must explicitly add --subtle-crypto, and then is enabled.
Eduardo Lima Mitev
Comment 7 2014-08-12 01:43:04 PDT
Ok, I understood things wrongly. You meant having the flag on by default for GTK builds using build-webkit. Release builds don't use that so it is safe. The result is the same as I originally intended: The feature is available only to developers and build/test bots, but not present in releases. Submitting new patch adding isGtk() :). Sorry for the noise.
Eduardo Lima Mitev
Comment 8 2014-08-12 01:45:16 PDT
Philippe Normand
Comment 9 2014-08-12 01:49:12 PDT
Comment on attachment 236432 [details] Patch View in context: https://bugs.webkit.org/attachment.cgi?id=236432&action=review > Tools/Scripts/webkitperl/FeatureList.pm:380 > + define => "ENABLE_SUBTLE_CRYPTO", default => isGtk() || isAppleMacWebKit() || isIOSWebKit(), value => \$subtleCrypto }, Sorry I should have mentioned that earlier, other options enclose the default value between parenthesis, check the video option for instance. No idea if it's really needed but would be good to have it for consistency at least.
Eduardo Lima Mitev
Comment 10 2014-08-12 01:52:55 PDT
WebKit Commit Bot
Comment 11 2014-08-12 02:35:52 PDT
Comment on attachment 236433 [details] Patch Clearing flags on attachment: 236433 Committed r172439: <http://trac.webkit.org/changeset/172439>
WebKit Commit Bot
Comment 12 2014-08-12 02:35:57 PDT
All reviewed patches have been landed. Closing bug.
Note You need to log in before you can comment on or make changes to this bug.