Allow trials to be enabled in insecure contexts
Previously, origin trials could only be enabled in secure contexts. This restriction makes sense for new, experimental features. However, for trials to extend the use of deprecated features, this restriction is less useful. See crbug.com/1027546 for details. This CL removes the global restriction to secure contexts. Instead, it is now possible to allow specific trials to be used in insecure contexts. For now, only a single test trial is hard-coded to allow insecure contexts. A follow-up CL will implement configuration for deprecation trials to allow insecure contexts. NOTE: All tokens will now be parsed and validated in insecure contexts. Previously, the insecure context check happened first, and would exit early before token validation. This means extra work is done for regular trial tokens. That can't really be avoided, as the token has to be parsed to get the trial name. Bug: 1027546 Change-Id: Ia37422ade598561909006425464fad20775eb44a Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/1932241 Commit-Queue: Jason Chase <chasej@chromium.org> Reviewed-by:Dave Tapuska <dtapuska@chromium.org> Reviewed-by:
Ian Clelland <iclelland@chromium.org> Cr-Commit-Position: refs/heads/master@{#721877}
Showing
Please register or sign in to comment