nora_mark 0.2beta3 → 0.2beta4
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/.travis.yml +5 -0
- data/Gemfile +2 -0
- data/README.md +17 -12
- data/example/nora-simple.css +52 -0
- data/example/noramark-reference-ja.nora +246 -0
- data/example/noramark-reference-ja_00001.xhtml +187 -0
- data/lib/nora_mark/html/{abstract_item_writer.rb → abstract_node_writer.rb} +3 -3
- data/lib/nora_mark/html/context.rb +3 -21
- data/lib/nora_mark/html/frontmatter_writer.rb +33 -0
- data/lib/nora_mark/html/generator.rb +122 -100
- data/lib/nora_mark/html/pages.rb +3 -9
- data/lib/nora_mark/html/paragraph_writer.rb +27 -23
- data/lib/nora_mark/html/tag_writer.rb +33 -34
- data/lib/nora_mark/html/writer_selector.rb +3 -3
- data/lib/nora_mark/node.rb +31 -0
- data/lib/nora_mark/parser.kpeg +133 -79
- data/lib/nora_mark/parser.kpeg.rb +1822 -1526
- data/lib/nora_mark/parser.rb +4 -23
- data/lib/nora_mark/version.rb +1 -1
- data/lib/nora_mark.rb +7 -2
- data/nora_mark.gemspec +1 -0
- data/spec/epub30-schemas/epub-nav-30.nvdl +16 -0
- data/spec/epub30-schemas/epub-nav-30.rnc +10 -0
- data/spec/epub30-schemas/epub-nav-30.sch +72 -0
- data/spec/epub30-schemas/epub-svg-30.nvdl +15 -0
- data/spec/epub30-schemas/epub-svg-30.rnc +15 -0
- data/spec/epub30-schemas/epub-svg-30.sch +10 -0
- data/spec/epub30-schemas/epub-xhtml-30.nvdl +15 -0
- data/spec/epub30-schemas/epub-xhtml-30.rnc +37 -0
- data/spec/epub30-schemas/epub-xhtml-30.sch +377 -0
- data/spec/epub30-schemas/epub30-catalog.xml +335 -0
- data/spec/epub30-schemas/media-overlay-30.nvdl +14 -0
- data/spec/epub30-schemas/media-overlay-30.rnc +46 -0
- data/spec/epub30-schemas/media-overlay-30.sch +9 -0
- data/spec/epub30-schemas/mod/datatypes.rnc +143 -0
- data/spec/epub30-schemas/mod/epub-mathml3-30.rnc +74 -0
- data/spec/epub30-schemas/mod/epub-prefix-attr.rnc +8 -0
- data/spec/epub30-schemas/mod/epub-ssml-attrs.rnc +11 -0
- data/spec/epub30-schemas/mod/epub-svg11-30.rnc +12 -0
- data/spec/epub30-schemas/mod/epub-svg11-re.sch +7 -0
- data/spec/epub30-schemas/mod/epub-switch.rnc +32 -0
- data/spec/epub30-schemas/mod/epub-trigger.rnc +17 -0
- data/spec/epub30-schemas/mod/epub-type-attr.rnc +7 -0
- data/spec/epub30-schemas/mod/epub-xhtml-mathml3-30.rnc +5 -0
- data/spec/epub30-schemas/mod/epub-xhtml-svg11-30.rnc +6 -0
- data/spec/epub30-schemas/mod/html5/LICENSE +23 -0
- data/spec/epub30-schemas/mod/html5/README +21 -0
- data/spec/epub30-schemas/mod/html5/html5-aria-30.rnc +105 -0
- data/spec/epub30-schemas/mod/html5/html5-attrib-30.rnc +44 -0
- data/spec/epub30-schemas/mod/html5/html5-document-30.rnc +44 -0
- data/spec/epub30-schemas/mod/html5/html5-edit-30.rnc +24 -0
- data/spec/epub30-schemas/mod/html5/html5-embed-30.rnc +155 -0
- data/spec/epub30-schemas/mod/html5/html5-forms-30.rnc +431 -0
- data/spec/epub30-schemas/mod/html5/html5-grouping-30.rnc +115 -0
- data/spec/epub30-schemas/mod/html5/html5-interactive-30.rnc +86 -0
- data/spec/epub30-schemas/mod/html5/html5-models-30.rnc +10 -0
- data/spec/epub30-schemas/mod/html5/html5-phrasing-30.rnc +134 -0
- data/spec/epub30-schemas/mod/html5/html5-script-30.rnc +164 -0
- data/spec/epub30-schemas/mod/html5/html5-sections-30.rnc +58 -0
- data/spec/epub30-schemas/mod/html5/html5-style-30.rnc +18 -0
- data/spec/epub30-schemas/mod/id-unique.sch +10 -0
- data/spec/epub30-schemas/mod/mathml/LICENSE +3 -0
- data/spec/epub30-schemas/mod/mathml/mathml3-common.rnc +84 -0
- data/spec/epub30-schemas/mod/mathml/mathml3-content.rnc +373 -0
- data/spec/epub30-schemas/mod/mathml/mathml3-presentation.rnc +536 -0
- data/spec/epub30-schemas/mod/mathml/mathml3-strict-content.rnc +60 -0
- data/spec/epub30-schemas/mod/security/LICENSE +4 -0
- data/spec/epub30-schemas/mod/security/Lenient-Encryption11-ghc.rnc +41 -0
- data/spec/epub30-schemas/mod/security/Lenient-Encryption11.rnc +39 -0
- data/spec/epub30-schemas/mod/security/Lenient-Signature-exclusiveC14N.rnc +25 -0
- data/spec/epub30-schemas/mod/security/Lenient-Signature11-properties-exclusiveC14N.rnc +32 -0
- data/spec/epub30-schemas/mod/security/Lenient-Signature11-properties.rnc +30 -0
- data/spec/epub30-schemas/mod/security/Lenient-Signature11.rnc +28 -0
- data/spec/epub30-schemas/mod/security/Strict-Encryption.rnc +27 -0
- data/spec/epub30-schemas/mod/security/Strict-Signature.rnc +22 -0
- data/spec/epub30-schemas/mod/security/exc-c14n.rnc +39 -0
- data/spec/epub30-schemas/mod/security/security_any.rnc +15 -0
- data/spec/epub30-schemas/mod/security/xenc-allowAnyForeign.rnc +25 -0
- data/spec/epub30-schemas/mod/security/xenc-schema-11.rnc +96 -0
- data/spec/epub30-schemas/mod/security/xenc-schema.rnc +145 -0
- data/spec/epub30-schemas/mod/security/xenc11-allowAnyForeign.rnc +19 -0
- data/spec/epub30-schemas/mod/security/xmldsig-allowAnyForeign.rnc +47 -0
- data/spec/epub30-schemas/mod/security/xmldsig-core-schema.rnc +276 -0
- data/spec/epub30-schemas/mod/security/xmldsig-filter2.rnc +16 -0
- data/spec/epub30-schemas/mod/security/xmldsig-properties-schema.rnc +34 -0
- data/spec/epub30-schemas/mod/security/xmldsig11-allowAnyForeign.rnc +18 -0
- data/spec/epub30-schemas/mod/security/xmldsig11-schema.rnc +133 -0
- data/spec/epub30-schemas/mod/security/xmlsec-ghc-allowAnyForeign.rnc +21 -0
- data/spec/epub30-schemas/mod/security/xmlsec-ghc-schema.rnc +42 -0
- data/spec/epub30-schemas/mod/svg11/LICENSE +1 -0
- data/spec/epub30-schemas/mod/svg11/README.txt +8 -0
- data/spec/epub30-schemas/mod/svg11/svg11-flat.rnc +3999 -0
- data/spec/epub30-schemas/ocf-container-30.rnc +16 -0
- data/spec/epub30-schemas/ocf-encryption-30.rnc +12 -0
- data/spec/epub30-schemas/ocf-signatures-30.rnc +8 -0
- data/spec/epub30-schemas/package-30.nvdl +14 -0
- data/spec/epub30-schemas/package-30.rnc +91 -0
- data/spec/epub30-schemas/package-30.sch +137 -0
- data/spec/jing-20091111/bin/jing.jar +0 -0
- data/spec/nora_mark_spec.rb +229 -68
- data/spec/spec_helper.rb +16 -0
- metadata +179 -6
- data/lib/nora_mark/html/header_writer.rb +0 -35
- data/spec/fixture/test_src_ja.nora +0 -50
|
@@ -0,0 +1,276 @@
|
|
|
1
|
+
# xmldsig-core-schema.rnc (derived from xmldsig-core-schema.xsd)
|
|
2
|
+
#
|
|
3
|
+
# Copyright 2011 W3C (Massachusetts Institute of Technology,
|
|
4
|
+
# Institut National de Recherche en Informatique et en Automatique,
|
|
5
|
+
# Keio University). All Rights Reserved. http://www.w3.org/Consortium/Legal/
|
|
6
|
+
#
|
|
7
|
+
# Use and distribution of all schemas in this directory are permitted under the terms
|
|
8
|
+
# W3C Software Notice and License
|
|
9
|
+
# http://www.w3.org/Consortium/Legal/2002/copyright-software-20021231
|
|
10
|
+
#
|
|
11
|
+
# 1. Differences from dsig-core-schema.xsd.
|
|
12
|
+
#
|
|
13
|
+
# 1.1 Attribute-value dependent content models
|
|
14
|
+
#
|
|
15
|
+
# The content models of CanonicalizationMethod, SignatureMethod,
|
|
16
|
+
# Transform, and DigestMethod elemenst are dependent on the value
|
|
17
|
+
# of the attribute Algorithm.
|
|
18
|
+
#
|
|
19
|
+
# 1.2 Customization
|
|
20
|
+
#
|
|
21
|
+
# The original XSD schema uses xsd:any several times, and it is
|
|
22
|
+
# not intended to be customized. However, this RELAX NG schema
|
|
23
|
+
# is intended to be customized always, and provides customization
|
|
24
|
+
# points rather than wildcards.
|
|
25
|
+
#
|
|
26
|
+
# This schema also defines lists of known algorithms. These definitions
|
|
27
|
+
# are expected to be customized when algorithms are added.
|
|
28
|
+
#
|
|
29
|
+
# A customization example is xmldsig-allowAnyForeign.rnc, which
|
|
30
|
+
# allows anything at any cutomization point.
|
|
31
|
+
#
|
|
32
|
+
# 2. Customization points
|
|
33
|
+
#
|
|
34
|
+
# 2.1 Union-combination (i.e., |= ) is intended
|
|
35
|
+
#
|
|
36
|
+
# (1) Algorithm identifiers and parameters
|
|
37
|
+
#
|
|
38
|
+
# Allow the combination of a particular value of @Algorithm
|
|
39
|
+
# and the parameter elements. See 6.1 in the xmldsig-core recommendation.
|
|
40
|
+
#
|
|
41
|
+
# ds_CanonicalizationMethodType
|
|
42
|
+
# ds_SignatureMethodType
|
|
43
|
+
# ds_TransformType
|
|
44
|
+
# ds_DigestMethodType
|
|
45
|
+
#
|
|
46
|
+
# Example:
|
|
47
|
+
# namespace foo = "http://www.example.com/someNewAlgorithm"
|
|
48
|
+
# ds_CanonicalizationMethodType |=
|
|
49
|
+
# attribute Algorithm {
|
|
50
|
+
# xsd:anyURI "http://www.example.com/someNewAlgorithm" },
|
|
51
|
+
# element foo:Param1 { text },
|
|
52
|
+
# element foo:Param2 { text }
|
|
53
|
+
#
|
|
54
|
+
# (2) Other contents
|
|
55
|
+
#
|
|
56
|
+
# Allow one element rather than a sequence of elements or empty sequence.
|
|
57
|
+
#
|
|
58
|
+
# ds_KeyInfoChild
|
|
59
|
+
# ds_KeyValueType
|
|
60
|
+
# ds_X509DataForeignChild
|
|
61
|
+
# ds_SPKIDataForeignChild
|
|
62
|
+
# ds_ObjectChild
|
|
63
|
+
# ds_SignaturePropertyChild
|
|
64
|
+
# ds_PGPDataForeignChild
|
|
65
|
+
#
|
|
66
|
+
# (3) Known algorithms
|
|
67
|
+
#
|
|
68
|
+
# ds_CanonicalizationAlgorithms
|
|
69
|
+
# ds_SignatureAlgorithms
|
|
70
|
+
# ds_TransformAlgorithms
|
|
71
|
+
# ds_DigestAlgorithms =
|
|
72
|
+
#
|
|
73
|
+
# 2.2 Overriding
|
|
74
|
+
#
|
|
75
|
+
# (1) ds_IdType
|
|
76
|
+
#
|
|
77
|
+
# This is defined as xsd:NCName. One might want to use xsd:ID
|
|
78
|
+
# instead, but jing is likely to report an error. This is because
|
|
79
|
+
# of the compatibility requirement for the ID/IDREF/IDREFS feature,
|
|
80
|
+
# which is specified in the OASIS committee specification
|
|
81
|
+
# "RELAX NG DTD Compatibility" (December 2001).
|
|
82
|
+
#
|
|
83
|
+
# (2) ds_xslt
|
|
84
|
+
#
|
|
85
|
+
# This is defined as any element, but one might want to use the
|
|
86
|
+
# schema created by James Clark.
|
|
87
|
+
|
|
88
|
+
default namespace = "http://www.w3.org/2000/09/xmldsig#"
|
|
89
|
+
namespace xsi = "http://www.w3.org/2001/XMLSchema-instance"
|
|
90
|
+
|
|
91
|
+
ds_CryptoBinary = xsd:base64Binary
|
|
92
|
+
ds_Signature = element Signature {
|
|
93
|
+
ds_SignatureType & attribute xsi:schemaLocation { text }?
|
|
94
|
+
}
|
|
95
|
+
ds_SignatureType =
|
|
96
|
+
attribute Id { ds_IdType }?,
|
|
97
|
+
ds_SignedInfo,
|
|
98
|
+
ds_SignatureValue,
|
|
99
|
+
ds_KeyInfo?,
|
|
100
|
+
ds_Object*
|
|
101
|
+
ds_SignatureValue = element SignatureValue { ds_SignatureValueType }
|
|
102
|
+
ds_SignatureValueType =
|
|
103
|
+
xsd:base64Binary,
|
|
104
|
+
attribute Id { ds_IdType }?
|
|
105
|
+
ds_SignedInfo = element SignedInfo { ds_SignedInfoType }
|
|
106
|
+
ds_SignedInfoType =
|
|
107
|
+
attribute Id { ds_IdType }?,
|
|
108
|
+
ds_CanonicalizationMethod,
|
|
109
|
+
ds_SignatureMethod,
|
|
110
|
+
ds_Reference+
|
|
111
|
+
ds_CanonicalizationMethod =
|
|
112
|
+
element CanonicalizationMethod { mixed { ds_CanonicalizationMethodType } }
|
|
113
|
+
ds_CanonicalizationMethodType =
|
|
114
|
+
attribute Algorithm {
|
|
115
|
+
xsd:anyURI "http://www.w3.org/TR/2001/REC-xml-c14n-20010315"
|
|
116
|
+
| xsd:anyURI "http://www.w3.org/TR/2001/REC-xml-c14n-20010315#WithComments"
|
|
117
|
+
}
|
|
118
|
+
| attribute Algorithm {
|
|
119
|
+
xsd:anyURI "http://www.w3.org/2006/12/xml-c14n11"
|
|
120
|
+
| xsd:anyURI "http://www.w3.org/2006/12/xml-c14n11#WithComments"
|
|
121
|
+
}
|
|
122
|
+
ds_SignatureMethod = element SignatureMethod { mixed { ds_SignatureMethodType } }
|
|
123
|
+
ds_SignatureMethodType =
|
|
124
|
+
(attribute Algorithm {
|
|
125
|
+
xsd:anyURI "http://www.w3.org/2000/09/xmldsig#hmac-sha1" },
|
|
126
|
+
element HMACOutputLength { ds_HMACOutputLengthType }?)
|
|
127
|
+
| attribute Algorithm {
|
|
128
|
+
xsd:anyURI "http://www.w3.org/2000/09/xmldsig#dsa-sha1" }
|
|
129
|
+
| attribute Algorithm {
|
|
130
|
+
xsd:anyURI "http://www.w3.org/2000/09/xmldsig#rsa-sha1" }
|
|
131
|
+
ds_Reference = element Reference { ds_ReferenceType }
|
|
132
|
+
ds_ReferenceType =
|
|
133
|
+
attribute Id { ds_IdType }?,
|
|
134
|
+
attribute URI { xsd:anyURI }?,
|
|
135
|
+
attribute Type { xsd:anyURI }?,
|
|
136
|
+
ds_Transforms?,
|
|
137
|
+
ds_DigestMethod,
|
|
138
|
+
ds_DigestValue
|
|
139
|
+
ds_Transforms = element Transforms { ds_TransformsType }
|
|
140
|
+
ds_TransformsType = ds_Transform+
|
|
141
|
+
ds_Transform = element Transform { mixed { ds_TransformType } }
|
|
142
|
+
ds_TransformType =
|
|
143
|
+
ds_CanonicalizationMethodType
|
|
144
|
+
| attribute Algorithm {
|
|
145
|
+
xsd:anyURI "http://www.w3.org/2000/09/xmldsig#base64" }
|
|
146
|
+
| (attribute Algorithm {
|
|
147
|
+
xsd:anyURI "http://www.w3.org/TR/1999/REC-xpath-19991116"},
|
|
148
|
+
element XPath { xsd:string })
|
|
149
|
+
| attribute Algorithm {
|
|
150
|
+
xsd:anyURI "http://www.w3.org/2000/09/xmldsig#enveloped-signature"}
|
|
151
|
+
| (attribute Algorithm {
|
|
152
|
+
xsd:anyURI "http://www.w3.org/TR/1999/REC-xslt-19991116"},
|
|
153
|
+
ds_Xslt)
|
|
154
|
+
ds_Xslt = security_anyElement
|
|
155
|
+
ds_DigestMethod = element DigestMethod { mixed { ds_DigestMethodType } }
|
|
156
|
+
ds_DigestMethodType =
|
|
157
|
+
attribute Algorithm {
|
|
158
|
+
xsd:anyURI "http://www.w3.org/2000/09/xmldsig#sha1" }
|
|
159
|
+
ds_DigestValue = element DigestValue { ds_DigestValueType }
|
|
160
|
+
ds_DigestValueType = xsd:base64Binary
|
|
161
|
+
ds_KeyInfo = element KeyInfo { mixed { ds_KeyInfoType } }
|
|
162
|
+
ds_KeyInfoType =
|
|
163
|
+
attribute Id { ds_IdType }?, ds_KeyInfoChild+
|
|
164
|
+
ds_KeyInfoChild =
|
|
165
|
+
ds_KeyName
|
|
166
|
+
| ds_KeyValue
|
|
167
|
+
| ds_RetrievalMethod
|
|
168
|
+
| ds_X509Data
|
|
169
|
+
| ds_PGPData
|
|
170
|
+
| ds_SPKIData
|
|
171
|
+
| ds_MgmtData
|
|
172
|
+
ds_KeyName = element KeyName { xsd:string }
|
|
173
|
+
ds_MgmtData = element MgmtData { xsd:string }
|
|
174
|
+
ds_KeyValue = element KeyValue { mixed { ds_KeyValueType } }
|
|
175
|
+
ds_KeyValueType = ds_DSAKeyValue | ds_RSAKeyValue
|
|
176
|
+
ds_RetrievalMethod = element RetrievalMethod { ds_RetrievalMethodType }
|
|
177
|
+
ds_RetrievalMethodType =
|
|
178
|
+
attribute URI { xsd:anyURI }?,
|
|
179
|
+
attribute Type { xsd:anyURI }?,
|
|
180
|
+
ds_Transforms?
|
|
181
|
+
ds_X509Data =
|
|
182
|
+
element X509Data { (ds_X509DataChild | ds_X509DataForeignChild?)+ }
|
|
183
|
+
ds_X509DataChild =
|
|
184
|
+
element X509IssuerSerial { ds_X509IssuerSerialType }
|
|
185
|
+
| element X509SKI { xsd:base64Binary }
|
|
186
|
+
| element X509SubjectName { xsd:string }
|
|
187
|
+
| element X509Certificate { xsd:base64Binary }
|
|
188
|
+
| element X509CRL { xsd:base64Binary }
|
|
189
|
+
ds_X509DataForeignChild = notAllowed
|
|
190
|
+
ds_X509IssuerSerialType =
|
|
191
|
+
element X509IssuerName { xsd:string },
|
|
192
|
+
element X509SerialNumber { xsd:integer }
|
|
193
|
+
ds_PGPData = element PGPData { ds_PGPDataType }
|
|
194
|
+
ds_PGPDataType =
|
|
195
|
+
(element PGPKeyID { xsd:base64Binary },
|
|
196
|
+
element PGPKeyPacket { xsd:base64Binary }?,
|
|
197
|
+
ds_PGPDataForeignChild*)
|
|
198
|
+
| (element PGPKeyPacket { xsd:base64Binary },
|
|
199
|
+
ds_PGPDataForeignChild*)
|
|
200
|
+
ds_PGPDataForeignChild = notAllowed
|
|
201
|
+
ds_SPKIData = element SPKIData { SPKIDataType }
|
|
202
|
+
SPKIDataType =
|
|
203
|
+
(element SPKISexp { xsd:base64Binary } | ds_SPKIDataForeignChild?)+
|
|
204
|
+
ds_SPKIDataForeignChild = notAllowed
|
|
205
|
+
ds_Object = element Object { mixed { ds_ObjectType } }
|
|
206
|
+
ds_ObjectType =
|
|
207
|
+
attribute Id { ds_IdType }?,
|
|
208
|
+
attribute MimeType { xsd:string }?,
|
|
209
|
+
attribute Encoding { xsd:anyURI }?,
|
|
210
|
+
ds_ObjectChild*
|
|
211
|
+
ds_ObjectChild = ds_anyDsElement
|
|
212
|
+
ds_Manifest = element Manifest { ds_ManifestType }
|
|
213
|
+
ds_ManifestType =
|
|
214
|
+
attribute Id { ds_IdType }?,
|
|
215
|
+
ds_Reference+
|
|
216
|
+
ds_SignatureProperties =
|
|
217
|
+
element SignatureProperties { ds_SignaturePropertiesType }
|
|
218
|
+
ds_SignaturePropertiesType =
|
|
219
|
+
attribute Id { ds_IdType }?,
|
|
220
|
+
ds_SignatureProperty+
|
|
221
|
+
ds_SignatureProperty =
|
|
222
|
+
element SignatureProperty { mixed { ds_SignaturePropertyType } }
|
|
223
|
+
ds_SignaturePropertyType =
|
|
224
|
+
attribute Target { xsd:anyURI },
|
|
225
|
+
attribute Id { ds_IdType }?,
|
|
226
|
+
ds_SignaturePropertyChild*
|
|
227
|
+
ds_SignaturePropertyChild = notAllowed
|
|
228
|
+
ds_HMACOutputLengthType = xsd:integer
|
|
229
|
+
ds_DSAKeyValue = element DSAKeyValue { ds_DSAKeyValueType }
|
|
230
|
+
ds_DSAKeyValueType =
|
|
231
|
+
(element P { ds_CryptoBinary },
|
|
232
|
+
element Q { ds_CryptoBinary })?,
|
|
233
|
+
element G { ds_CryptoBinary }?,
|
|
234
|
+
element Y { ds_CryptoBinary },
|
|
235
|
+
element J { ds_CryptoBinary }?,
|
|
236
|
+
(element Seed { ds_CryptoBinary },
|
|
237
|
+
element PgenCounter { ds_CryptoBinary })?
|
|
238
|
+
ds_RSAKeyValue = element RSAKeyValue { ds_RSAKeyValueType }
|
|
239
|
+
ds_RSAKeyValueType =
|
|
240
|
+
element Modulus { ds_CryptoBinary },
|
|
241
|
+
element Exponent { ds_CryptoBinary }
|
|
242
|
+
ds_IdType = xsd:NCName # xsd:ID does not work
|
|
243
|
+
|
|
244
|
+
#Definitions for mimicking xsd:any
|
|
245
|
+
ds_anyDsElement =
|
|
246
|
+
ds_Signature | ds_SignatureValue | ds_SignedInfo
|
|
247
|
+
| ds_CanonicalizationMethod | ds_SignatureMethod | ds_Reference
|
|
248
|
+
| ds_Transforms | ds_Transform | ds_DigestMethod | ds_DigestValue
|
|
249
|
+
| ds_KeyInfo | ds_KeyName | ds_MgmtData | ds_KeyValue
|
|
250
|
+
| ds_RetrievalMethod | ds_X509Data | ds_PGPData | ds_SPKIData
|
|
251
|
+
| ds_Object | ds_Manifest | ds_SignatureProperties
|
|
252
|
+
| ds_SignatureProperty | ds_DSAKeyValue | ds_RSAKeyValue
|
|
253
|
+
|
|
254
|
+
# List of known canonicalization algorithms
|
|
255
|
+
ds_CanonicalizationAlgorithms =
|
|
256
|
+
xsd:anyURI "http://www.w3.org/TR/2001/REC-xml-c14n-20010315"
|
|
257
|
+
| xsd:anyURI "http://www.w3.org/TR/2001/REC-xml-c14n-20010315#WithComments"
|
|
258
|
+
| xsd:anyURI "http://www.w3.org/2006/12/xml-c14n11"
|
|
259
|
+
| xsd:anyURI "http://www.w3.org/2006/12/xml-c14n11#WithComments"
|
|
260
|
+
|
|
261
|
+
# List of known signature algorithms
|
|
262
|
+
ds_SignatureAlgorithms =
|
|
263
|
+
xsd:anyURI "http://www.w3.org/2000/09/xmldsig#hmac-sha1"
|
|
264
|
+
| xsd:anyURI "http://www.w3.org/2000/09/xmldsig#dsa-sha1"
|
|
265
|
+
| xsd:anyURI "http://www.w3.org/2000/09/xmldsig#rsa-sha1"
|
|
266
|
+
|
|
267
|
+
# List of known transformation-but-non-canonicalization algorithms
|
|
268
|
+
ds_TransformAlgorithms =
|
|
269
|
+
xsd:anyURI "http://www.w3.org/2000/09/xmldsig#base64"
|
|
270
|
+
| xsd:anyURI "http://www.w3.org/TR/1999/REC-xpath-19991116"
|
|
271
|
+
| xsd:anyURI "http://www.w3.org/2000/09/xmldsig#enveloped-signature"
|
|
272
|
+
| xsd:anyURI "http://www.w3.org/TR/1999/REC-xslt-19991116"
|
|
273
|
+
|
|
274
|
+
# List of known digest algorithms
|
|
275
|
+
ds_DigestAlgorithms =
|
|
276
|
+
xsd:anyURI "http://www.w3.org/2000/09/xmldsig#sha1"
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
# xmldsig-filter2.rnc (derived from xmldsig-filter2.xsd)
|
|
2
|
+
#
|
|
3
|
+
# Copyright 2011 W3C (Massachusetts Institute of Technology,
|
|
4
|
+
# Institut National de Recherche en Informatique et en Automatique,
|
|
5
|
+
# Keio University). All Rights Reserved. http://www.w3.org/Consortium/Legal/
|
|
6
|
+
#
|
|
7
|
+
# Use and distribution of all schemas in this directory are permitted under the terms
|
|
8
|
+
# W3C Software Notice and License
|
|
9
|
+
# http://www.w3.org/Consortium/Legal/2002/copyright-software-20021231
|
|
10
|
+
|
|
11
|
+
|
|
12
|
+
default namespace = "http://www.w3.org/2002/06/xmldsig-filter2"
|
|
13
|
+
start = element XPath {
|
|
14
|
+
attribute Filter { string "intersect" | string "substract" | string "union" },
|
|
15
|
+
text
|
|
16
|
+
}
|
|
@@ -0,0 +1,34 @@
|
|
|
1
|
+
# xmldsig-properties-schema.rnc (derived from xmldsig-properties-schema.xsd)
|
|
2
|
+
#
|
|
3
|
+
# Copyright 2011 W3C (Massachusetts Institute of Technology,
|
|
4
|
+
# Institut National de Recherche en Informatique et en Automatique,
|
|
5
|
+
# Keio University). All Rights Reserved. http://www.w3.org/Consortium/Legal/
|
|
6
|
+
#
|
|
7
|
+
# Use and distribution of all schemas in this directory are permitted under the terms
|
|
8
|
+
# W3C Software Notice and License
|
|
9
|
+
# http://www.w3.org/Consortium/Legal/2002/copyright-software-20021231
|
|
10
|
+
#
|
|
11
|
+
# This schema allows Profile, Role, Identifier, Created, Expires,
|
|
12
|
+
# and ReplayProject elements as children of SignatureProperty
|
|
13
|
+
# elements.
|
|
14
|
+
|
|
15
|
+
default namespace = "http://www.w3.org/2009/xmldsig-properties"
|
|
16
|
+
|
|
17
|
+
ds_SignaturePropertyChild |=
|
|
18
|
+
dsp_Profile | dsp_Role | dsp_Identifier
|
|
19
|
+
| dsp_Created | dsp_Expires | dsp_ReplayProtect
|
|
20
|
+
dsp_Profile = element Profile { dsp_ProfileType }
|
|
21
|
+
dsp_ProfileType = attribute URI { xsd:anyURI }?
|
|
22
|
+
dsp_Role = element Role { dsp_RoleType }
|
|
23
|
+
dsp_RoleType = attribute URI { xsd:anyURI }?
|
|
24
|
+
dsp_Identifier = element Identifier { xsd:string }
|
|
25
|
+
dsp_Created = element Created { xsd:dateTime }
|
|
26
|
+
dsp_Expires = element Expires { xsd:dateTime }
|
|
27
|
+
dsp_ReplayProtect = element ReplayProtect { dsp_ReplayProtectType }
|
|
28
|
+
dsp_ReplayProtectType =
|
|
29
|
+
element timestamp { xsd:dateTime },
|
|
30
|
+
element nonce { dsp_NonceValueType }
|
|
31
|
+
dsp_NonceValueType =
|
|
32
|
+
attribute EncodingType { xsd:anyURI }?,
|
|
33
|
+
xsd:string
|
|
34
|
+
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
# xmldsig11-allowAnyForeign.rnc
|
|
2
|
+
#
|
|
3
|
+
# Copyright 2011 W3C (Massachusetts Institute of Technology,
|
|
4
|
+
# Institut National de Recherche en Informatique et en Automatique,
|
|
5
|
+
# Keio University). All Rights Reserved. http://www.w3.org/Consortium/Legal/
|
|
6
|
+
#
|
|
7
|
+
# Use and distribution of all schemas in this directory are permitted under the terms
|
|
8
|
+
# W3C Software Notice and License
|
|
9
|
+
# http://www.w3.org/Consortium/Legal/2002/copyright-software-20021231
|
|
10
|
+
#
|
|
11
|
+
# This schema mimicks <any namespace="##other" processContents="lax"/>
|
|
12
|
+
# in xmldsig11-schema.xsd.
|
|
13
|
+
#
|
|
14
|
+
# Schema authors might want to create a dedicated schema
|
|
15
|
+
# for a collection of particular algorithms rather than
|
|
16
|
+
# using this schema.
|
|
17
|
+
|
|
18
|
+
dsig11_OtherFieldIDType |= dsig11_anyForeignElement
|
|
@@ -0,0 +1,133 @@
|
|
|
1
|
+
# xmldsig11-schema.rnc
|
|
2
|
+
#
|
|
3
|
+
# Copyright 2011 W3C (Massachusetts Institute of Technology,
|
|
4
|
+
# Institut National de Recherche en Informatique et en Automatique,
|
|
5
|
+
# Keio University). All Rights Reserved. http://www.w3.org/Consortium/Legal/
|
|
6
|
+
#
|
|
7
|
+
# Use and distribution of all schemas in this directory are permitted under the terms
|
|
8
|
+
# W3C Software Notice and License
|
|
9
|
+
# http://www.w3.org/Consortium/Legal/2002/copyright-software-20021231
|
|
10
|
+
#
|
|
11
|
+
# This schema complements "xmldsig-core-schema.rnc" by
|
|
12
|
+
# introducing elements specific to 1.1. Note that the definition
|
|
13
|
+
# of ds_KeyValueType, ds_KeyInfoChild, and ds_X509DataChild
|
|
14
|
+
# in "xmldsig-core-schema.rnc" has been extended so that
|
|
15
|
+
# elements specific to 1.1 are allowed.
|
|
16
|
+
|
|
17
|
+
default namespace = "http://www.w3.org/2009/xmldsig11#"
|
|
18
|
+
|
|
19
|
+
ds_KeyValueType |= dsig11_ECKeyValue
|
|
20
|
+
ds_KeyInfoChild |= dsig11_DEREncodedKeyValue | dsig11_KeyInfoReference
|
|
21
|
+
ds_X509DataChild |= dsig11_OCSPResponse | dsig11_X509Digest
|
|
22
|
+
ds_CanonicalizationMethodType |=
|
|
23
|
+
attribute Algorithm {
|
|
24
|
+
xsd:anyURI "http://www.w3.org/2006/12/xml-c14n11"
|
|
25
|
+
| xsd:anyURI "http://www.w3.org/2006/12/xml-c14n11#WithComments"
|
|
26
|
+
}
|
|
27
|
+
ds_TransformType |=
|
|
28
|
+
attribute Algorithm {
|
|
29
|
+
xsd:anyURI "http://www.w3.org/2002/06/xmldsig-filter2"
|
|
30
|
+
},
|
|
31
|
+
external "xmldsig-filter2.rnc" +
|
|
32
|
+
ds_DigestMethodType |=
|
|
33
|
+
attribute Algorithm {
|
|
34
|
+
xsd:anyURI "http://www.w3.org/2001/04/xmlenc#sha256"
|
|
35
|
+
}
|
|
36
|
+
| attribute Algorithm {
|
|
37
|
+
xsd:anyURI "http://www.w3.org/2001/04/xmldsig-more#sha384"
|
|
38
|
+
}
|
|
39
|
+
| attribute Algorithm {
|
|
40
|
+
xsd:anyURI "http://www.w3.org/2001/04/xmlenc#sha512"
|
|
41
|
+
}
|
|
42
|
+
ds_SignatureMethodType |=
|
|
43
|
+
(attribute Algorithm {
|
|
44
|
+
xsd:anyURI "http://www.w3.org/2001/04/xmldsig-more#hmac-sha256"
|
|
45
|
+
| xsd:anyURI "http://www.w3.org/2001/04/xmldsig-more#hmac-sha384"
|
|
46
|
+
| xsd:anyURI "http://www.w3.org/2001/04/xmldsig-more#hmac-sha512" },
|
|
47
|
+
element HMACOutputLength { ds_HMACOutputLengthType }?)
|
|
48
|
+
| attribute Algorithm {
|
|
49
|
+
xsd:anyURI "http://www.w3.org/2009/xmldsig11#dsa-sha256" }
|
|
50
|
+
| attribute Algorithm {
|
|
51
|
+
xsd:anyURI "http://www.w3.org/2001/04/xmldsig-more#rsa-sha256"
|
|
52
|
+
| xsd:anyURI "http://www.w3.org/2001/04/xmldsig-more#rsa-sha384"
|
|
53
|
+
| xsd:anyURI "http://www.w3.org/2001/04/xmldsig-more#rsa-sha512" }
|
|
54
|
+
| attribute Algorithm {
|
|
55
|
+
xsd:anyURI "http://www.w3.org/2001/04/xmldsig-more#ecdsa-sha1"
|
|
56
|
+
| xsd:anyURI "http://www.w3.org/2001/04/xmldsig-more#ecdsa-sha256"
|
|
57
|
+
| xsd:anyURI "http://www.w3.org/2001/04/xmldsig-more#ecdsa-sha384"
|
|
58
|
+
| xsd:anyURI "http://www.w3.org/2001/04/xmldsig-more#ecdsa-sha512" }
|
|
59
|
+
dsig11_ECKeyValue = element ECKeyValue { dsig11_ECKeyValueType }
|
|
60
|
+
dsig11_ECKeyValueType =
|
|
61
|
+
attribute Id { ds_IdType }?,
|
|
62
|
+
(element ECParameters { dsig11_ECParametersType }
|
|
63
|
+
| element NamedCurve { dsig11_NamedCurveType }),
|
|
64
|
+
element PublicKey { dsig11_ECPointType }
|
|
65
|
+
dsig11_NamedCurveType = attribute URI { xsd:anyURI }
|
|
66
|
+
dsig11_ECPointType = ds_CryptoBinary
|
|
67
|
+
dsig11_ECParametersType =
|
|
68
|
+
element FieldID { dsig11_FieldIDType },
|
|
69
|
+
element Curve { dsig11_CurveType },
|
|
70
|
+
element Base { dsig11_ECPointType },
|
|
71
|
+
element Order { ds_CryptoBinary },
|
|
72
|
+
element CoFactor { xsd:integer }?,
|
|
73
|
+
element ValidationData { dsig11_ECValidationDataType }?
|
|
74
|
+
dsig11_FieldIDType = dsig11_Prime | dsig11_TnB | dsig11_PnB | dsig11_GnB | dsig11_OtherFieldIDType
|
|
75
|
+
dsig11_OtherFieldIDType = notAllowed
|
|
76
|
+
dsig11_CurveType =
|
|
77
|
+
element A { ds_CryptoBinary },
|
|
78
|
+
element B { ds_CryptoBinary }
|
|
79
|
+
dsig11_ECValidationDataType =
|
|
80
|
+
attribute hashAlgorithm { xsd:anyURI },
|
|
81
|
+
element seed { ds_CryptoBinary }
|
|
82
|
+
dsig11_Prime = element Prime { dsig11_PrimeFieldParamsType }
|
|
83
|
+
dsig11_PrimeFieldParamsType = element P { ds_CryptoBinary }
|
|
84
|
+
dsig11_GnB = element GnB { dsig11_CharTwoFieldParamsType }
|
|
85
|
+
dsig11_CharTwoFieldParamsType =
|
|
86
|
+
element M { xsd:positiveInteger }
|
|
87
|
+
dsig11_TnB = element TnB { dsig11_TnBFieldParamsType }
|
|
88
|
+
dsig11_TnBFieldParamsType =
|
|
89
|
+
dsig11_CharTwoFieldParamsType,
|
|
90
|
+
element K { xsd:positiveInteger }
|
|
91
|
+
dsig11_PnB = element PnB { dsig11_PnBFieldParamsType }
|
|
92
|
+
dsig11_PnBFieldParamsType =
|
|
93
|
+
dsig11_CharTwoFieldParamsType,
|
|
94
|
+
element K1 { xsd:positiveInteger },
|
|
95
|
+
element K2 { xsd:positiveInteger },
|
|
96
|
+
element K3 { xsd:positiveInteger }
|
|
97
|
+
dsig11_OCSPResponse = element OCSPResponse { xsd:base64Binary }
|
|
98
|
+
dsig11_DEREncodedKeyValue = element DEREncodedKeyValue { dsig11_DEREncodedKeyValueType }
|
|
99
|
+
dsig11_DEREncodedKeyValueType =
|
|
100
|
+
attribute Id { ds_IdType }?,
|
|
101
|
+
xsd:base64Binary
|
|
102
|
+
dsig11_KeyInfoReference = element KeyInfoReference { dsig11_KeyInfoReferenceType}
|
|
103
|
+
dsig11_KeyInfoReferenceType =
|
|
104
|
+
attribute URI { xsd:anyURI },
|
|
105
|
+
attribute Id { ds_IdType }?
|
|
106
|
+
dsig11_X509Digest = element X509Digest { dsig11_X509DigestType }
|
|
107
|
+
dsig11_X509DigestType =
|
|
108
|
+
attribute Algorithm {xsd:anyURI},
|
|
109
|
+
xsd:base64Binary
|
|
110
|
+
|
|
111
|
+
# List of known algorithms
|
|
112
|
+
ds_CanonicalizationAlgorithms |=
|
|
113
|
+
xsd:anyURI "http://www.w3.org/2006/12/xml-c14n11"
|
|
114
|
+
| xsd:anyURI "http://www.w3.org/2006/12/xml-c14n11#WithComments"
|
|
115
|
+
|
|
116
|
+
ds_SignatureAlgorithms |=
|
|
117
|
+
xsd:anyURI "http://www.w3.org/2001/04/xmldsig-more#hmac-sha256"
|
|
118
|
+
| xsd:anyURI "http://www.w3.org/2001/04/xmldsig-more#hmac-sha384"
|
|
119
|
+
| xsd:anyURI "http://www.w3.org/2001/04/xmldsig-more#hmac-sha512"
|
|
120
|
+
| xsd:anyURI "http://www.w3.org/2009/xmldsig11#dsa-sha256"
|
|
121
|
+
| xsd:anyURI "http://www.w3.org/2001/04/xmldsig-more#rsa-sha256"
|
|
122
|
+
| xsd:anyURI "http://www.w3.org/2001/04/xmldsig-more#rsa-sha384"
|
|
123
|
+
| xsd:anyURI "http://www.w3.org/2001/04/xmldsig-more#rsa-sha512"
|
|
124
|
+
| xsd:anyURI "http://www.w3.org/2001/04/xmldsig-more#ecdsa-sha1"
|
|
125
|
+
| xsd:anyURI "http://www.w3.org/2001/04/xmldsig-more#ecdsa-sha256"
|
|
126
|
+
| xsd:anyURI "http://www.w3.org/2001/04/xmldsig-more#ecdsa-sha384"
|
|
127
|
+
| xsd:anyURI "http://www.w3.org/2001/04/xmldsig-more#ecdsa-sha512"
|
|
128
|
+
ds_DigestAlgorithms |=
|
|
129
|
+
xsd:anyURI "http://www.w3.org/2001/04/xmlenc#sha256"
|
|
130
|
+
| xsd:anyURI "http://www.w3.org/2001/04/xmldsig-more#sha384"
|
|
131
|
+
| xsd:anyURI "http://www.w3.org/2001/04/xmlenc#sha512"
|
|
132
|
+
ds_TransformAlgorithms |=
|
|
133
|
+
xsd:anyURI "http://www.w3.org/2002/06/xmldsig-filter2"
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
# xmlsec-ghc-allowAnyForeign.rnc
|
|
2
|
+
#
|
|
3
|
+
# Copyright 2011 W3C (Massachusetts Institute of Technology,
|
|
4
|
+
# Institut National de Recherche en Informatique et en Automatique,
|
|
5
|
+
# Keio University). All Rights Reserved. http://www.w3.org/Consortium/Legal/
|
|
6
|
+
#
|
|
7
|
+
# Use and distribution of all schemas in this directory are permitted under the terms
|
|
8
|
+
# W3C Software Notice and License
|
|
9
|
+
# http://www.w3.org/Consortium/Legal/2002/copyright-software-20021231
|
|
10
|
+
#
|
|
11
|
+
# This schema mimicks <any namespace="##other" ../> in
|
|
12
|
+
# xmlsec-ghc-schema.xsd, thus allowing any parameter
|
|
13
|
+
# and any value for the attribute "Algorithm".
|
|
14
|
+
#
|
|
15
|
+
# Schema authors might want to create a dedicated schema
|
|
16
|
+
# for a collection of particular algorithms rather than
|
|
17
|
+
# using this schema.
|
|
18
|
+
|
|
19
|
+
gh_KeyEncapsulationMethodParams |=
|
|
20
|
+
attribute Algorithm {xsd:anyURI - gh_KeyEncapsulationAlgorithms },
|
|
21
|
+
security_anyElement*
|
|
@@ -0,0 +1,42 @@
|
|
|
1
|
+
# xmlsec-ghc-schema.rnc (derived from xmlsec-ghc-schema.xsd)
|
|
2
|
+
#
|
|
3
|
+
# Copyright 2011 W3C (Massachusetts Institute of Technology,
|
|
4
|
+
# Institut National de Recherche en Informatique et en Automatique,
|
|
5
|
+
# Keio University). All Rights Reserved. http://www.w3.org/Consortium/Legal/
|
|
6
|
+
#
|
|
7
|
+
# Use and distribution of all schemas in this directory are permitted under the terms
|
|
8
|
+
# W3C Software Notice and License
|
|
9
|
+
# http://www.w3.org/Consortium/Legal/2002/copyright-software-20021231
|
|
10
|
+
#
|
|
11
|
+
|
|
12
|
+
default namespace gh = "http://www.w3.org/2009/xmlsec-gh#"
|
|
13
|
+
|
|
14
|
+
gh_GenericHybridCipherMethod =
|
|
15
|
+
element GenericHybridCipherMethod {
|
|
16
|
+
gh_GenericHybridCipherMethodType
|
|
17
|
+
}
|
|
18
|
+
|
|
19
|
+
gh_GenericHybridCipherMethodType =
|
|
20
|
+
element KeyEncapsulationMethod { gh_KeyEncapsulationMethodType },
|
|
21
|
+
element DataEncapsulationMethod { xenc_EncryptionMethodType }
|
|
22
|
+
|
|
23
|
+
gh_KeyEncapsulationMethodType =
|
|
24
|
+
xenc11_KeyDerivationMethod,
|
|
25
|
+
element KeyLen { xsd:positiveInteger } ,
|
|
26
|
+
gh_KeyEncapsulationMethodParams
|
|
27
|
+
|
|
28
|
+
gh_KeyEncapsulationMethodParams =
|
|
29
|
+
attribute Algorithm {xsd:anyURI "http://www.w3.org/2009/xmlsec-gh#rsaes-kem"}
|
|
30
|
+
| attribute Algorithm {xsd:anyURI "http://www.w3.org/2009/xmlsec-gh#ecies-kem" }
|
|
31
|
+
|
|
32
|
+
xenc_EncryptionMethodOtherParams |=
|
|
33
|
+
attribute Algorithm { xsd:anyURI "http://www.w3.org/2009/xmlsec-gh#generic-hybrid" },
|
|
34
|
+
gh_GenericHybridCipherMethod
|
|
35
|
+
|
|
36
|
+
# List of known algorithms
|
|
37
|
+
xenc_EncryptionAlgorithms |=
|
|
38
|
+
xsd:anyURI "http://www.w3.org/2009/xmlsec-gh#generic-hybrid"
|
|
39
|
+
gh_KeyEncapsulationAlgorithms =
|
|
40
|
+
xsd:anyURI "http://www.w3.org/2009/xmlsec-gh#rsaes-kem"
|
|
41
|
+
| xsd:anyURI "http://www.w3.org/2009/xmlsec-gh#ecies-kem"
|
|
42
|
+
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
License is shown in the header of svg11-flat.rnc.
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
$Id: README.txt 3106 2011-08-24 07:56:19Z eb2mmrt $
|
|
2
|
+
$Author: eb2mmrt $
|
|
3
|
+
|
|
4
|
+
This directory contains a RELAX NG schema, namely svg11-flat.rnc, for
|
|
5
|
+
SVG 1.1 (2nd Edition). It is automatically created by trang from
|
|
6
|
+
svg11-flat.dtd, available at
|
|
7
|
+
http://www.w3.org/Graphics/SVG/1.1/DTD/svg11-flat.dtd (08-July-2011).
|
|
8
|
+
|