nokogiri 1.16.8 → 1.18.9
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/Gemfile +11 -19
- data/LICENSE-DEPENDENCIES.md +6 -6
- data/README.md +8 -5
- data/dependencies.yml +6 -6
- data/ext/nokogiri/extconf.rb +189 -151
- data/ext/nokogiri/gumbo.c +69 -53
- data/ext/nokogiri/html4_document.c +10 -4
- data/ext/nokogiri/html4_element_description.c +18 -18
- data/ext/nokogiri/html4_sax_parser.c +40 -0
- data/ext/nokogiri/html4_sax_parser_context.c +48 -58
- data/ext/nokogiri/html4_sax_push_parser.c +25 -24
- data/ext/nokogiri/libxml2_polyfill.c +114 -0
- data/ext/nokogiri/nokogiri.c +9 -2
- data/ext/nokogiri/nokogiri.h +18 -33
- data/ext/nokogiri/xml_attr.c +1 -1
- data/ext/nokogiri/xml_cdata.c +2 -10
- data/ext/nokogiri/xml_comment.c +3 -8
- data/ext/nokogiri/xml_document.c +163 -156
- data/ext/nokogiri/xml_document_fragment.c +10 -25
- data/ext/nokogiri/xml_dtd.c +1 -1
- data/ext/nokogiri/xml_element_content.c +9 -9
- data/ext/nokogiri/xml_encoding_handler.c +4 -4
- data/ext/nokogiri/xml_namespace.c +6 -6
- data/ext/nokogiri/xml_node.c +134 -103
- data/ext/nokogiri/xml_node_set.c +46 -44
- data/ext/nokogiri/xml_reader.c +54 -58
- data/ext/nokogiri/xml_relax_ng.c +35 -56
- data/ext/nokogiri/xml_sax_parser.c +156 -88
- data/ext/nokogiri/xml_sax_parser_context.c +219 -131
- data/ext/nokogiri/xml_sax_push_parser.c +68 -49
- data/ext/nokogiri/xml_schema.c +50 -85
- data/ext/nokogiri/xml_syntax_error.c +19 -11
- data/ext/nokogiri/xml_text.c +2 -4
- data/ext/nokogiri/xml_xpath_context.c +103 -100
- data/ext/nokogiri/xslt_stylesheet.c +8 -8
- data/gumbo-parser/src/ascii.c +2 -2
- data/gumbo-parser/src/error.c +76 -48
- data/gumbo-parser/src/error.h +5 -1
- data/gumbo-parser/src/nokogiri_gumbo.h +11 -2
- data/gumbo-parser/src/parser.c +63 -25
- data/gumbo-parser/src/tokenizer.c +6 -6
- data/lib/nokogiri/class_resolver.rb +1 -1
- data/lib/nokogiri/css/node.rb +6 -2
- data/lib/nokogiri/css/parser.rb +6 -4
- data/lib/nokogiri/css/parser.y +2 -2
- data/lib/nokogiri/css/parser_extras.rb +6 -66
- data/lib/nokogiri/css/selector_cache.rb +38 -0
- data/lib/nokogiri/css/tokenizer.rb +4 -4
- data/lib/nokogiri/css/tokenizer.rex +9 -8
- data/lib/nokogiri/css/xpath_visitor.rb +43 -6
- data/lib/nokogiri/css.rb +86 -20
- data/lib/nokogiri/decorators/slop.rb +3 -5
- data/lib/nokogiri/encoding_handler.rb +2 -2
- data/lib/nokogiri/html4/document.rb +44 -23
- data/lib/nokogiri/html4/document_fragment.rb +124 -12
- data/lib/nokogiri/html4/encoding_reader.rb +1 -1
- data/lib/nokogiri/html4/sax/parser.rb +23 -38
- data/lib/nokogiri/html4/sax/parser_context.rb +4 -9
- data/lib/nokogiri/html4.rb +9 -14
- data/lib/nokogiri/html5/builder.rb +40 -0
- data/lib/nokogiri/html5/document.rb +61 -30
- data/lib/nokogiri/html5/document_fragment.rb +130 -20
- data/lib/nokogiri/html5/node.rb +4 -4
- data/lib/nokogiri/html5.rb +114 -72
- data/lib/nokogiri/version/constant.rb +1 -1
- data/lib/nokogiri/xml/builder.rb +8 -1
- data/lib/nokogiri/xml/document.rb +70 -26
- data/lib/nokogiri/xml/document_fragment.rb +84 -13
- data/lib/nokogiri/xml/node.rb +82 -11
- data/lib/nokogiri/xml/node_set.rb +9 -7
- data/lib/nokogiri/xml/parse_options.rb +1 -1
- data/lib/nokogiri/xml/pp/node.rb +6 -1
- data/lib/nokogiri/xml/reader.rb +46 -13
- data/lib/nokogiri/xml/relax_ng.rb +57 -20
- data/lib/nokogiri/xml/sax/document.rb +174 -83
- data/lib/nokogiri/xml/sax/parser.rb +115 -41
- data/lib/nokogiri/xml/sax/parser_context.rb +116 -8
- data/lib/nokogiri/xml/sax/push_parser.rb +3 -0
- data/lib/nokogiri/xml/sax.rb +48 -0
- data/lib/nokogiri/xml/schema.rb +112 -45
- data/lib/nokogiri/xml/searchable.rb +38 -42
- data/lib/nokogiri/xml/syntax_error.rb +22 -0
- data/lib/nokogiri/xml/xpath_context.rb +14 -3
- data/lib/nokogiri/xml.rb +13 -24
- data/lib/nokogiri/xslt.rb +3 -9
- data/lib/xsd/xmlparser/nokogiri.rb +3 -4
- data/patches/libxml2/0019-xpath-Use-separate-static-hash-table-for-standard-fu.patch +244 -0
- data/patches/libxml2/0020-CVE-2025-6021-tree-Fix-integer-overflow-in-xmlBuildQ.patch +54 -0
- data/patches/libxml2/0021-CVE-2025-6170-Fix-potential-buffer-overflows-of-inte.patch +102 -0
- data/patches/libxml2/0022-CVE-2025-49795-schematron-Fix-null-pointer-dereferen.patch +69 -0
- data/patches/libxml2/0023-CVE-2025-49794-CVE-2025-49796-schematron-Fix-xmlSche.patch +182 -0
- data/ports/archives/libxml2-2.13.8.tar.xz +0 -0
- data/ports/archives/libxslt-1.1.43.tar.xz +0 -0
- metadata +18 -13
- data/ext/nokogiri/libxml2_backwards_compat.c +0 -121
- data/patches/libxml2/0003-libxml2.la-is-in-top_builddir.patch +0 -25
- data/ports/archives/libxml2-2.12.9.tar.xz +0 -0
- data/ports/archives/libxslt-1.1.39.tar.xz +0 -0
metadata
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
|
2
2
|
name: nokogiri
|
|
3
3
|
version: !ruby/object:Gem::Version
|
|
4
|
-
version: 1.
|
|
4
|
+
version: 1.18.9
|
|
5
5
|
platform: ruby
|
|
6
6
|
authors:
|
|
7
7
|
- Mike Dalessio
|
|
@@ -17,10 +17,9 @@ authors:
|
|
|
17
17
|
- Sergio Arbeo
|
|
18
18
|
- Timothy Elliott
|
|
19
19
|
- Nobuyoshi Nakada
|
|
20
|
-
autorequire:
|
|
21
20
|
bindir: bin
|
|
22
21
|
cert_chain: []
|
|
23
|
-
date:
|
|
22
|
+
date: 1980-01-02 00:00:00.000000000 Z
|
|
24
23
|
dependencies:
|
|
25
24
|
- !ruby/object:Gem::Dependency
|
|
26
25
|
name: mini_portile2
|
|
@@ -60,13 +59,15 @@ executables:
|
|
|
60
59
|
extensions:
|
|
61
60
|
- ext/nokogiri/extconf.rb
|
|
62
61
|
extra_rdoc_files:
|
|
62
|
+
- README.md
|
|
63
63
|
- ext/nokogiri/gumbo.c
|
|
64
64
|
- ext/nokogiri/html4_document.c
|
|
65
65
|
- ext/nokogiri/html4_element_description.c
|
|
66
66
|
- ext/nokogiri/html4_entity_lookup.c
|
|
67
|
+
- ext/nokogiri/html4_sax_parser.c
|
|
67
68
|
- ext/nokogiri/html4_sax_parser_context.c
|
|
68
69
|
- ext/nokogiri/html4_sax_push_parser.c
|
|
69
|
-
- ext/nokogiri/
|
|
70
|
+
- ext/nokogiri/libxml2_polyfill.c
|
|
70
71
|
- ext/nokogiri/nokogiri.c
|
|
71
72
|
- ext/nokogiri/test_global_handlers.c
|
|
72
73
|
- ext/nokogiri/xml_attr.c
|
|
@@ -95,7 +96,6 @@ extra_rdoc_files:
|
|
|
95
96
|
- ext/nokogiri/xml_text.c
|
|
96
97
|
- ext/nokogiri/xml_xpath_context.c
|
|
97
98
|
- ext/nokogiri/xslt_stylesheet.c
|
|
98
|
-
- README.md
|
|
99
99
|
files:
|
|
100
100
|
- Gemfile
|
|
101
101
|
- LICENSE-DEPENDENCIES.md
|
|
@@ -109,9 +109,10 @@ files:
|
|
|
109
109
|
- ext/nokogiri/html4_document.c
|
|
110
110
|
- ext/nokogiri/html4_element_description.c
|
|
111
111
|
- ext/nokogiri/html4_entity_lookup.c
|
|
112
|
+
- ext/nokogiri/html4_sax_parser.c
|
|
112
113
|
- ext/nokogiri/html4_sax_parser_context.c
|
|
113
114
|
- ext/nokogiri/html4_sax_push_parser.c
|
|
114
|
-
- ext/nokogiri/
|
|
115
|
+
- ext/nokogiri/libxml2_polyfill.c
|
|
115
116
|
- ext/nokogiri/nokogiri.c
|
|
116
117
|
- ext/nokogiri/nokogiri.h
|
|
117
118
|
- ext/nokogiri/test_global_handlers.c
|
|
@@ -193,6 +194,7 @@ files:
|
|
|
193
194
|
- lib/nokogiri/css/parser.rb
|
|
194
195
|
- lib/nokogiri/css/parser.y
|
|
195
196
|
- lib/nokogiri/css/parser_extras.rb
|
|
197
|
+
- lib/nokogiri/css/selector_cache.rb
|
|
196
198
|
- lib/nokogiri/css/syntax_error.rb
|
|
197
199
|
- lib/nokogiri/css/tokenizer.rb
|
|
198
200
|
- lib/nokogiri/css/tokenizer.rex
|
|
@@ -214,6 +216,7 @@ files:
|
|
|
214
216
|
- lib/nokogiri/html4/sax/parser_context.rb
|
|
215
217
|
- lib/nokogiri/html4/sax/push_parser.rb
|
|
216
218
|
- lib/nokogiri/html5.rb
|
|
219
|
+
- lib/nokogiri/html5/builder.rb
|
|
217
220
|
- lib/nokogiri/html5/document.rb
|
|
218
221
|
- lib/nokogiri/html5/document_fragment.rb
|
|
219
222
|
- lib/nokogiri/html5/node.rb
|
|
@@ -265,13 +268,17 @@ files:
|
|
|
265
268
|
- lib/xsd/xmlparser/nokogiri.rb
|
|
266
269
|
- patches/libxml2/0001-Remove-script-macro-support.patch
|
|
267
270
|
- patches/libxml2/0002-Update-entities-to-remove-handling-of-ssi.patch
|
|
268
|
-
- patches/libxml2/0003-libxml2.la-is-in-top_builddir.patch
|
|
269
271
|
- patches/libxml2/0009-allow-wildcard-namespaces.patch
|
|
270
272
|
- patches/libxml2/0010-update-config.guess-and-config.sub-for-libxml2.patch
|
|
271
273
|
- patches/libxml2/0011-rip-out-libxml2-s-libc_single_threaded-support.patch
|
|
274
|
+
- patches/libxml2/0019-xpath-Use-separate-static-hash-table-for-standard-fu.patch
|
|
275
|
+
- patches/libxml2/0020-CVE-2025-6021-tree-Fix-integer-overflow-in-xmlBuildQ.patch
|
|
276
|
+
- patches/libxml2/0021-CVE-2025-6170-Fix-potential-buffer-overflows-of-inte.patch
|
|
277
|
+
- patches/libxml2/0022-CVE-2025-49795-schematron-Fix-null-pointer-dereferen.patch
|
|
278
|
+
- patches/libxml2/0023-CVE-2025-49794-CVE-2025-49796-schematron-Fix-xmlSche.patch
|
|
272
279
|
- patches/libxslt/0001-update-config.guess-and-config.sub-for-libxslt.patch
|
|
273
|
-
- ports/archives/libxml2-2.
|
|
274
|
-
- ports/archives/libxslt-1.1.
|
|
280
|
+
- ports/archives/libxml2-2.13.8.tar.xz
|
|
281
|
+
- ports/archives/libxslt-1.1.43.tar.xz
|
|
275
282
|
homepage: https://nokogiri.org
|
|
276
283
|
licenses:
|
|
277
284
|
- MIT
|
|
@@ -282,7 +289,6 @@ metadata:
|
|
|
282
289
|
changelog_uri: https://nokogiri.org/CHANGELOG.html
|
|
283
290
|
source_code_uri: https://github.com/sparklemotion/nokogiri
|
|
284
291
|
rubygems_mfa_required: 'true'
|
|
285
|
-
post_install_message:
|
|
286
292
|
rdoc_options:
|
|
287
293
|
- "--main"
|
|
288
294
|
- README.md
|
|
@@ -292,15 +298,14 @@ required_ruby_version: !ruby/object:Gem::Requirement
|
|
|
292
298
|
requirements:
|
|
293
299
|
- - ">="
|
|
294
300
|
- !ruby/object:Gem::Version
|
|
295
|
-
version: 3.
|
|
301
|
+
version: 3.1.0
|
|
296
302
|
required_rubygems_version: !ruby/object:Gem::Requirement
|
|
297
303
|
requirements:
|
|
298
304
|
- - ">="
|
|
299
305
|
- !ruby/object:Gem::Version
|
|
300
306
|
version: '0'
|
|
301
307
|
requirements: []
|
|
302
|
-
rubygems_version: 3.
|
|
303
|
-
signing_key:
|
|
308
|
+
rubygems_version: 3.6.9
|
|
304
309
|
specification_version: 4
|
|
305
310
|
summary: Nokogiri (鋸) makes it easy and painless to work with XML and HTML from Ruby.
|
|
306
311
|
test_files: []
|
|
@@ -1,121 +0,0 @@
|
|
|
1
|
-
#ifndef HAVE_XMLFIRSTELEMENTCHILD
|
|
2
|
-
#include <nokogiri.h>
|
|
3
|
-
/**
|
|
4
|
-
* xmlFirstElementChild:
|
|
5
|
-
* @parent: the parent node
|
|
6
|
-
*
|
|
7
|
-
* Finds the first child node of that element which is a Element node
|
|
8
|
-
* Note the handling of entities references is different than in
|
|
9
|
-
* the W3C DOM element traversal spec since we don't have back reference
|
|
10
|
-
* from entities content to entities references.
|
|
11
|
-
*
|
|
12
|
-
* Returns the first element child or NULL if not available
|
|
13
|
-
*/
|
|
14
|
-
xmlNodePtr
|
|
15
|
-
xmlFirstElementChild(xmlNodePtr parent)
|
|
16
|
-
{
|
|
17
|
-
xmlNodePtr cur = NULL;
|
|
18
|
-
|
|
19
|
-
if (parent == NULL) {
|
|
20
|
-
return (NULL);
|
|
21
|
-
}
|
|
22
|
-
switch (parent->type) {
|
|
23
|
-
case XML_ELEMENT_NODE:
|
|
24
|
-
case XML_ENTITY_NODE:
|
|
25
|
-
case XML_DOCUMENT_NODE:
|
|
26
|
-
case XML_HTML_DOCUMENT_NODE:
|
|
27
|
-
cur = parent->children;
|
|
28
|
-
break;
|
|
29
|
-
default:
|
|
30
|
-
return (NULL);
|
|
31
|
-
}
|
|
32
|
-
while (cur != NULL) {
|
|
33
|
-
if (cur->type == XML_ELEMENT_NODE) {
|
|
34
|
-
return (cur);
|
|
35
|
-
}
|
|
36
|
-
cur = cur->next;
|
|
37
|
-
}
|
|
38
|
-
return (NULL);
|
|
39
|
-
}
|
|
40
|
-
|
|
41
|
-
/**
|
|
42
|
-
* xmlNextElementSibling:
|
|
43
|
-
* @node: the current node
|
|
44
|
-
*
|
|
45
|
-
* Finds the first closest next sibling of the node which is an
|
|
46
|
-
* element node.
|
|
47
|
-
* Note the handling of entities references is different than in
|
|
48
|
-
* the W3C DOM element traversal spec since we don't have back reference
|
|
49
|
-
* from entities content to entities references.
|
|
50
|
-
*
|
|
51
|
-
* Returns the next element sibling or NULL if not available
|
|
52
|
-
*/
|
|
53
|
-
xmlNodePtr
|
|
54
|
-
xmlNextElementSibling(xmlNodePtr node)
|
|
55
|
-
{
|
|
56
|
-
if (node == NULL) {
|
|
57
|
-
return (NULL);
|
|
58
|
-
}
|
|
59
|
-
switch (node->type) {
|
|
60
|
-
case XML_ELEMENT_NODE:
|
|
61
|
-
case XML_TEXT_NODE:
|
|
62
|
-
case XML_CDATA_SECTION_NODE:
|
|
63
|
-
case XML_ENTITY_REF_NODE:
|
|
64
|
-
case XML_ENTITY_NODE:
|
|
65
|
-
case XML_PI_NODE:
|
|
66
|
-
case XML_COMMENT_NODE:
|
|
67
|
-
case XML_DTD_NODE:
|
|
68
|
-
case XML_XINCLUDE_START:
|
|
69
|
-
case XML_XINCLUDE_END:
|
|
70
|
-
node = node->next;
|
|
71
|
-
break;
|
|
72
|
-
default:
|
|
73
|
-
return (NULL);
|
|
74
|
-
}
|
|
75
|
-
while (node != NULL) {
|
|
76
|
-
if (node->type == XML_ELEMENT_NODE) {
|
|
77
|
-
return (node);
|
|
78
|
-
}
|
|
79
|
-
node = node->next;
|
|
80
|
-
}
|
|
81
|
-
return (NULL);
|
|
82
|
-
}
|
|
83
|
-
|
|
84
|
-
/**
|
|
85
|
-
* xmlLastElementChild:
|
|
86
|
-
* @parent: the parent node
|
|
87
|
-
*
|
|
88
|
-
* Finds the last child node of that element which is a Element node
|
|
89
|
-
* Note the handling of entities references is different than in
|
|
90
|
-
* the W3C DOM element traversal spec since we don't have back reference
|
|
91
|
-
* from entities content to entities references.
|
|
92
|
-
*
|
|
93
|
-
* Returns the last element child or NULL if not available
|
|
94
|
-
*/
|
|
95
|
-
xmlNodePtr
|
|
96
|
-
xmlLastElementChild(xmlNodePtr parent)
|
|
97
|
-
{
|
|
98
|
-
xmlNodePtr cur = NULL;
|
|
99
|
-
|
|
100
|
-
if (parent == NULL) {
|
|
101
|
-
return (NULL);
|
|
102
|
-
}
|
|
103
|
-
switch (parent->type) {
|
|
104
|
-
case XML_ELEMENT_NODE:
|
|
105
|
-
case XML_ENTITY_NODE:
|
|
106
|
-
case XML_DOCUMENT_NODE:
|
|
107
|
-
case XML_HTML_DOCUMENT_NODE:
|
|
108
|
-
cur = parent->last;
|
|
109
|
-
break;
|
|
110
|
-
default:
|
|
111
|
-
return (NULL);
|
|
112
|
-
}
|
|
113
|
-
while (cur != NULL) {
|
|
114
|
-
if (cur->type == XML_ELEMENT_NODE) {
|
|
115
|
-
return (cur);
|
|
116
|
-
}
|
|
117
|
-
cur = cur->prev;
|
|
118
|
-
}
|
|
119
|
-
return (NULL);
|
|
120
|
-
}
|
|
121
|
-
#endif
|
|
@@ -1,25 +0,0 @@
|
|
|
1
|
-
From 0b6ae484761fa01242fe8b67b54e3eb2d282d83d Mon Sep 17 00:00:00 2001
|
|
2
|
-
From: Mike Dalessio <mike.dalessio@gmail.com>
|
|
3
|
-
Date: Wed, 4 Dec 2019 08:43:51 -0500
|
|
4
|
-
Subject: [PATCH] fix libxml2.la's path
|
|
5
|
-
|
|
6
|
-
---
|
|
7
|
-
Makefile.in | 2 +-
|
|
8
|
-
1 file changed, 1 insertion(+), 1 deletion(-)
|
|
9
|
-
|
|
10
|
-
diff --git a/Makefile.in b/Makefile.in
|
|
11
|
-
index cf96d41..1372d8b 100644
|
|
12
|
-
--- a/Makefile.in
|
|
13
|
-
+++ b/Makefile.in
|
|
14
|
-
@@ -1057,7 +1057,7 @@ clean-noinstLTLIBRARIES:
|
|
15
|
-
rm -f $${locs}; \
|
|
16
|
-
}
|
|
17
|
-
|
|
18
|
-
-libxml2.la: $(libxml2_la_OBJECTS) $(libxml2_la_DEPENDENCIES) $(EXTRA_libxml2_la_DEPENDENCIES)
|
|
19
|
-
+$(top_builddir)/libxml2.la: $(libxml2_la_OBJECTS) $(libxml2_la_DEPENDENCIES) $(EXTRA_libxml2_la_DEPENDENCIES)
|
|
20
|
-
$(AM_V_CCLD)$(libxml2_la_LINK) -rpath $(libdir) $(libxml2_la_OBJECTS) $(libxml2_la_LIBADD) $(LIBS)
|
|
21
|
-
|
|
22
|
-
testdso.la: $(testdso_la_OBJECTS) $(testdso_la_DEPENDENCIES) $(EXTRA_testdso_la_DEPENDENCIES)
|
|
23
|
-
--
|
|
24
|
-
2.17.1
|
|
25
|
-
|
|
Binary file
|
|
Binary file
|