Skip to content

Commit

Permalink
Merge pull request #2618 from OSInside/fix-application-id-schema
Browse files Browse the repository at this point in the history
kiwi/schema: Fix allowed value type for ISO publisher and application ID
  • Loading branch information
Conan-Kudo authored Nov 20, 2024
2 parents 2faacfb + 1c0d1dd commit 8ab85d3
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 6 deletions.
6 changes: 3 additions & 3 deletions kiwi/schema/kiwi.rnc
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ namespace nul = ""

safe-posix-name = xsd:token {pattern = "[a-zA-Z0-9_\-\.]+"}
safe-posix-short-name = xsd:token {pattern = "[a-zA-Z0-9_\-\.]{1,32}"}
safe-posix-long-name = xsd:token {pattern = "[a-zA-Z0-9_\-\.]{1,128}"}
ecma-119-achar-128-text = xsd:token {pattern = "[a-zA-Z0-9!-/:-?_ ]{1,128}"}
locale-name = xsd:token {pattern = "(POSIX|[a-z]{2,3}_[A-Z]{2})(,[a-z]{2,3}_[A-Z]{2})*"}
mac-address-type = xsd:token {pattern = "([0-9a-fA-F]{2}:){5}[0-9a-fA-F]{2}"}
size-type = xsd:token {pattern = "(\d*|image)"}
Expand Down Expand Up @@ -2232,7 +2232,7 @@ div {
## for the iso/(oem install iso) type only:
## Specifies the Application ID to be written
## into the master block. There is space for 128 characters.
attribute application_id { safe-posix-long-name }
attribute application_id { ecma-119-achar-128-text }
>> sch:pattern [ id = "application_id" is-a = "image_type"
sch:param [ name = "attr" value = "application_id" ]
sch:param [ name = "types" value = "iso oem" ]
Expand Down Expand Up @@ -2272,7 +2272,7 @@ div {
]
k.type.publisher.attribute =
## Specifies the publisher name of the ISO.
attribute publisher { text }
attribute publisher { ecma-119-achar-128-text }
>> sch:pattern [ id = "publisher" is-a = "image_type"
sch:param [ name = "attr" value = "publisher" ]
sch:param [ name = "types" value = "iso" ]
Expand Down
7 changes: 4 additions & 3 deletions kiwi/schema/kiwi.rng
Original file line number Diff line number Diff line change
Expand Up @@ -31,9 +31,9 @@
<param name="pattern">[a-zA-Z0-9_\-\.]{1,32}</param>
</data>
</define>
<define name="safe-posix-long-name">
<define name="ecma-119-achar-128-text">
<data type="token">
<param name="pattern">[a-zA-Z0-9_\-\.]{1,128}</param>
<param name="pattern">[a-zA-Z0-9!-/:-?_ ]{1,128}</param>
</data>
</define>
<define name="locale-name">
Expand Down Expand Up @@ -3219,7 +3219,7 @@ into the master block. There is space for 32 characters.</a:documentation>
<a:documentation>for the iso/(oem install iso) type only:
Specifies the Application ID to be written
into the master block. There is space for 128 characters.</a:documentation>
<ref name="safe-posix-long-name"/>
<ref name="ecma-119-achar-128-text"/>
</attribute>
<sch:pattern id="application_id" is-a="image_type">
<sch:param name="attr" value="application_id"/>
Expand Down Expand Up @@ -3273,6 +3273,7 @@ container image created by Kiwi. Default is true.</a:documentation>
<define name="k.type.publisher.attribute">
<attribute name="publisher">
<a:documentation>Specifies the publisher name of the ISO.</a:documentation>
<ref name="ecma-119-achar-128-text"/>
</attribute>
<sch:pattern id="publisher" is-a="image_type">
<sch:param name="attr" value="publisher"/>
Expand Down

0 comments on commit 8ab85d3

Please sign in to comment.