html-proofer 3.12.1 → 3.12.2

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 04d2b18950f5d8c6b2bcfadb24dec58d50d7c2fd8997977506a79a22d24aeeef
4
- data.tar.gz: f33be2af98f5a199b563eb78aef31518c94b304c1fd120985dc3ee2febee233f
3
+ metadata.gz: 0cfdbe4be04941b199d07fc15a237d5696d06980acde4192c0604935126e00ce
4
+ data.tar.gz: 8a682b08550dae3ea1a823b66251dc5bddffb27ab8e431d98d4b9a1152e721d4
5
5
  SHA512:
6
- metadata.gz: 1e9fd7e64a8c76c74351128fd63a25c1c56ce11351fc8cd4ce0e91ee793586ab71609ae247d3fa66615b089546887a330cb2eeec9550888ebbf9f8abb59b628d
7
- data.tar.gz: bed4a30375077f6bfd35900f75976e9f960deb316421e113b65b33ad7d61f9084be427f5241c3700aa1d8fbd717d4104389855db71a43f60f846af58c3a6694b
6
+ metadata.gz: 8c4c9ab7f8f225325ead82e8a2da9b7c11bd7d2e7aa9d03edb041cb96ffd6099f40489acd85325b591952b79aaffa8e10558fffd07c883f01966d6dcc087126e
7
+ data.tar.gz: 772d2e3c9ba8fcd4f5678767f876e1f51ebd5bbe957fdf5a6687b65f2cba2b981e3067b07a2c08ff79f67b085b2b1bf81b0c54f1584ee945cff3aeecd46e44dc
@@ -129,10 +129,12 @@ class LinkCheck < ::HTMLProofer::Check
129
129
  html.xpath(*xpaths)
130
130
  end
131
131
 
132
- IGNORABE_REL = %(canonical alternate next prev previous icon manifest apple-touch-icon)
132
+ # Whitelist for affected elements from Subresource Integrity specification
133
+ # https://w3c.github.io/webappsec-subresource-integrity/#link-element-for-stylesheets
134
+ SRI_REL_TYPES = %(stylesheet)
133
135
 
134
136
  def check_sri(line, content)
135
- return if IGNORABE_REL.include?(@link.rel)
137
+ return unless SRI_REL_TYPES.include?(@link.rel)
136
138
  if !defined?(@link.integrity) && !defined?(@link.crossorigin)
137
139
  add_issue("SRI and CORS not provided in: #{@link.src}", line: line, content: content)
138
140
  elsif !defined?(@link.integrity)
@@ -1,5 +1,5 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  module HTMLProofer
4
- VERSION = '3.12.1'.freeze
4
+ VERSION = '3.12.2'.freeze
5
5
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: html-proofer
3
3
  version: !ruby/object:Gem::Version
4
- version: 3.12.1
4
+ version: 3.12.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - Garen Torikian